Thread (12 messages) flat view 12 messages, 3 authors, 2012-07-05

Re: [PATCH net-next 1/2] ieee802154: sparse warnings: make symbols static

From: Eric Dumazet <hidden>
Date: 2012-07-04 13:45:32

On Wed, 2012-07-04 at 17:38 +0400, Alexander Smirnov wrote:
Do I need to create 2 separate patches: one for revert and second to
initialize spinlock correctly, or I can combine these changes in one
patch?
you can combine patch
quoted
You should validate this code with LOCKDEP
Nothing was shown by LOCKDEP for 6lowpan. :-(
Because path was not hit ( fragment expire )

You would have to simulate a drop or something to trigger the lockdep
splat, when lowpan_fragment_timer_expired() fires.
I've selected the following options:

-*- Spinlock and rw-lock debugging: basic checks
-*- Mutex debugging: basic checks
-*- Lock debugging: detect incorrect freeing of live locks
[*] Lock usage statistics
[*] Lock dependency engine debugging
quoted
lowpan_dellink() does a spin_lock(&flist_lock);
while same lock can be taken by lowpan_fragment_timer_expired() from
timer irq, -> deadlock.
What would be the best way to solve this context mismatch? Can I do
something like following:
1. create some 6lowpan internal workqueue
2. replace lowpan_fragment_timer_expired() body by queue_work() with
current list_deleting routine
3. when 6lowpan is going to be deleted - I'll flush the queue and
remove all the timers and respective fragments
Just use the spin_lock_bh() variant to disable BH, so that timer doesnt
deadlock with you.
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help