Herbert Xu wrote:
> Baruch Even <[EMAIL PROTECTED]> wrote:
> 
>>+       case NETDEV_UNREGISTER:
>>       case NETDEV_GOING_DOWN:
>>       case NETDEV_DOWN:
>>               /* Find every socket on this device and kill it. */
> 
> 
> This brings up the question as to why we need to flush it on
> NETDEV_GOING_DOWN and NETDEV_DOWN as well.  If it's possible
> for things to get added after the flush then isn't it pointless
> to flush there?

It's the first time I've looked at this code and I'm not completely sure
I understand the whole state machine for net devices, which is why I
opted to do the simplest thing that might work. Someone more versed in
this code can do better.

I've taken the time to survey the other protocols/devices that handle
these events and it does seem like there is a complete seperation
between the actions of these events (which makes sense otherwise why
have different events).

It does look like it should be sufficient to remove all sockets only in
the unregister case but I'm not sure why we should also keep those
sockets when a device was taken down?

Baruch
-
To unsubscribe from this list: send the line "unsubscribe netdev" in
the body of a message to [EMAIL PROTECTED]
More majordomo info at  http://vger.kernel.org/majordomo-info.html

Reply via email to