John Newbigin wrote:
> 
> I have found a solution to another problem with the bonding driver.
> 
> If you ifconfig down an enslaved eth device, the bonding driver is not
> notified and if there is an attempt to use the device then a crash
> results.  I have added a one line fix to dev_close in net/core/dev.c
> 
>         /* if the device is a slave we should not touch it*/
>         if(dev->flags&IFF_SLAVE)
>                 return -EBUSY;
> 
> I put it after the check to see if the interface is up.
> 
> This may not be the best solution but it prevents the kernel crashes and
> as bond_release is not implemented there is not much point making the
> device release it's self.
> 
> Since I made this change and the one in my last message I have not been
> able to produce a crash.
> 
> (here is a script which will cause the crash on 2.2.16)
> #!/bin/bash
> insmod eepro100
> insmod bonding
> ifconfig bond0 192.168.1.2 up
> ifenslave bond0 eth0
> ifconfig eth0 down
> ifconfig bond0 down
> ifconfig bond0 192.168.1.2 up
> ifconfig bond0 down
> 
> Again, if someone could confirm this fix it would be good.
> 

If you could post the fixes as patches, that would make this easier to
do.

Otherwise, someone has to duplicate your effort.

-- 
------------------------+--------------------------------------------------
Thomas Davis            | PDSF Project Leader
[EMAIL PROTECTED]         | 
(510) 486-4524          | "Only a petabyte of data this year?"
-
To unsubscribe from this list: send the line "unsubscribe linux-net" in
the body of a message to [EMAIL PROTECTED]

Reply via email to