if_msk in 6.2

Pyun YongHyeon pyunyh at gmail.com
Thu Apr 5 00:15:08 UTC 2007


On Wed, Apr 04, 2007 at 09:06:49PM +0200, Marv wrote:
 > Thanks for your reply. I checked out the kernel source tree of RELENG_6,
 > applied your patch and compiled a new kernel.
 > 
 > The kernel boots and detects a 88E8038 Ethernet card but then hangs:
 > 
 > mskc0: <Marvell Yukon 88E8038 Gigabit Ethernet> irq 16 at device 0.0 on
 > pci2
 > mskc0: 0x4000 bytes of rid 0x10 res 3 failed (0, 0xffffffff).
 > mskc0: unknown device: id=0xff, rev=0x0f
 > 
 > (doing nothing no more at this point).
 > 
 > Was there some kind of detection failure or is my ethernet controller
 > not configured properly to fit the driver?
 > 

Since msk(4) supports 88E8038 I guess the device was not properly
initialized/recognized by system BIOS.

But it's driver bug if it hang your system when it encounter an
exceptional condition. Try attached patch and report back the result.
It wouldn't fix device recognization but it will not hang your system.

-- 
Regards,
Pyun YongHyeon
-------------- next part --------------
Index: if_msk.c
===================================================================
RCS file: /home/ncvs/src/sys/dev/msk/if_msk.c,v
retrieving revision 1.11.2.2
diff -u -r1.11.2.2 if_msk.c
--- if_msk.c	2 Apr 2007 01:22:31 -0000	1.11.2.2
+++ if_msk.c	5 Apr 2007 00:12:53 -0000
@@ -1581,8 +1581,8 @@
 	    sc->msk_hw_id > CHIP_ID_YUKON_FE) {
 		device_printf(dev, "unknown device: id=0x%02x, rev=0x%02x\n",
 		    sc->msk_hw_id, sc->msk_hw_rev);
-		error = ENXIO;
-		goto fail;
+		mtx_destroy(&sc->msk_mtx);
+		return (ENXIO);
 	}
 
 	SYSCTL_ADD_PROC(device_get_sysctl_ctx(dev),


More information about the freebsd-net mailing list