summaryrefslogtreecommitdiffstats
path: root/sys/fs/deadfs
diff options
context:
space:
mode:
authorwpaul <wpaul@FreeBSD.org>2000-08-11 17:47:55 +0000
committerwpaul <wpaul@FreeBSD.org>2000-08-11 17:47:55 +0000
commitb63adaba9374df1dcdea65a97e4ca4d0d139fe82 (patch)
treeaf968abcc3818c7c51f0105c40096aa676cd6062 /sys/fs/deadfs
parentfb936aa69704bb5510bc14c9d67353f31f80ebfc (diff)
downloadFreeBSD-src-b63adaba9374df1dcdea65a97e4ca4d0d139fe82.zip
FreeBSD-src-b63adaba9374df1dcdea65a97e4ca4d0d139fe82.tar.gz
Fix a bug brought to light by the people working on SMPng. I don't quite
understand exactly what it is about SMPng that tickles this bug. What I do know is that the foo_init() routine in most drivers is often called twice when an interface is brought up. One time is due to the ifconfig(8) command calling the SIOCSIFFLAGS ioctl to set the IFF_UP flag, and another is probably due to the kernel calling ifp->if_init at some point. In any case, the SMPng changes seem to affect the timing of these two events in such a way that there is a significant delay before any packets are sent onto the wire after the interface is first brought up. This manifested itself locally as an SMPng test machine which failed to obtain an address via DHCP when booting up. It looks like the second call to fxp_init() is happening faster now than it did before, and I think it catches the chip while it's in the process of dealing with the configuration command from the first call. Whatever the case, a FXP_CSR_SCB_CNA interrupt event is now generated shortly after the second fxp_init() call. (This interrupt is apparently never generated by a non-SMPng kernel, so nobody noticed.) There are two problems with this: first, fxp_intr() does not handle the FXP_CSR_SCB_CNA interrupt event (it never tests for it or does anything to deal with it), and second, the meaning of FXP_CSR_SCB_CNA is not documented in the driver. (Apparently it means "command unit not active.") Bad coder. No biscuit. The fix is to have the FXP_CSR_SCB_CNA interrupt handled just like the FXP_SCB_STATACK_CXTNO interrupt. This prevents the state machine for the configuration/RX filter programming stuff from getting wedged for several seconds and preventing packet transmission. Noticed by: jhb
Diffstat (limited to 'sys/fs/deadfs')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud