Re: NETDEV_CHANGE events when __LINK_STATE_NOCARRIER is modified

2001-05-15 Thread David S. Miller
Andrew Morton writes: > > Again, BKL has nothing to do with this (and ioctl does not hold it) > > asmlinkage long sys_ioctl(unsigned int fd, unsigned int cmd, unsigned long arg) > { > struct file * filp; > unsigned int flag; > int on, error = -EBADF; > >

Re: NETDEV_CHANGE events when __LINK_STATE_NOCARRIER is modified

2001-05-15 Thread Andrew Morton
[EMAIL PROTECTED] wrote: > > Hello! > > > It protects the as-yet-unchanged PCI and Cardbus drivers from a > > fatal race. > > Fatal race remained. Don't think so. We have exclusion against all netdevice ioctls across probe. Still. It doesn't matter. > Andrew, you start again the story abou

Re: NETDEV_CHANGE events when __LINK_STATE_NOCARRIER is modified

2001-05-14 Thread Andrew Morton
[EMAIL PROTECTED] wrote: > > Hello! > > > Note that using dev->name during probe was always incorrect. Think > > about the error case: > ... > > So, using interface name in this manner was always buggy because it > > conveys no useful information to the user. > > I used to think about cases of

Re: NETDEV_CHANGE events when __LINK_STATE_NOCARRIER is modified

2001-05-14 Thread Jeff Garzik
[EMAIL PROTECTED] wrote: > > Each bus should > > Not all the device are bound to some "bus". True. Each driver author would make a decision, for what's best to appear in their probe time printk's... > > Are you talking about his 140k patch? > > Yes! > > Size of patch and "simplicity" are or

Re: NETDEV_CHANGE events when __LINK_STATE_NOCARRIER is modified

2001-05-14 Thread kuznet
Hello! > Note that using dev->name during probe was always incorrect. Think > about the error case: ... > So, using interface name in this manner was always buggy because it > conveys no useful information to the user. I used to think about cases of success. 8) In any case the question follows:

Re: NETDEV_CHANGE events when __LINK_STATE_NOCARRIER is modified

2001-05-14 Thread Jeff Garzik
[EMAIL PROTECTED] wrote: > > Hello! > > > Jeff has introduced `alloc_etherdev()' which allocates storage > > for a netdev but doesn't register it. The one quirk with this > > approach (and why it's vastly simpler than my thing) > > I do not see where it is simpler. The only difference is that

Re: NETDEV_CHANGE events when __LINK_STATE_NOCARRIER is modified

2001-05-14 Thread kuznet
Hello! > Jeff has introduced `alloc_etherdev()' which allocates storage > for a netdev but doesn't register it. The one quirk with this > approach (and why it's vastly simpler than my thing) I do not see where it is simpler. The only difference is that name is unknown. 8) > Not many drivers

Re: NETDEV_CHANGE events when __LINK_STATE_NOCARRIER is modified

2001-05-13 Thread kuznet
Hello! > I believe these events get sent to the cardmgr daemon and it does > all the ifconf magic to change the device state. Compare this also to the situation with netif_present(). After Linus said that it is called from thread context, I prepared corresponding code for netif_present (and for