netdev
[Top] [All Lists]

Re: PATCH: bonding might sleep with lock held

To: Andi Kleen <ak@xxxxxxx>
Subject: Re: PATCH: bonding might sleep with lock held
From: Jay Vosburgh <fubar@xxxxxxxxxx>
Date: Thu, 13 May 2004 11:44:45 -0700
Cc: netdev@xxxxxxxxxxx
In-reply-to: Message from Andi Kleen <ak@xxxxxxx> of "Thu, 13 May 2004 10:20:53 +0200." <20040513082053.GC27682@xxxxxxxxxxxxx>
Sender: netdev-bounce@xxxxxxxxxxx
Andi Kleen <ak@xxxxxxx> wrote:
[...]
>>      This patch replaces dev_remove_pack() with __dev_remove_pack()
>> and adds a synchronize_net() call outside the lock.  The patch is
>> against 2.6.5, but applied to 2.6.6 for me.
>
>I would rather fix bond_close to not call this with the lock hold.
>You can just move the call a few lines up. dev->close has own
>synchronization anyways and dev_remove_pack has a lock too, so this
>should be safe.

        It will race against the timers, although I don't see anything
in there offhand that would conflict.  It just feels somehow unclean to
do it without the lock.

        -J

---
        -Jay Vosburgh, IBM Linux Technology Center, fubar@xxxxxxxxxx


<Prev in Thread] Current Thread [Next in Thread>