From baad32ada6ffbc67f435b8fca225f53a865bba41 Mon Sep 17 00:00:00 2001 From: Robert Watson Date: Sun, 23 May 2004 22:22:29 +0000 Subject: [PATCH] Only initialize the if_sis callout as MPSAFE if debug.mpsafenet is set true. Otherwise, assertion checks for Giant in the network stack will fail causing a panic. Reported by: simon --- sys/pci/if_sis.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/sys/pci/if_sis.c b/sys/pci/if_sis.c index f8c92c90b13..02dac7c0a11 100644 --- a/sys/pci/if_sis.c +++ b/sys/pci/if_sis.c @@ -1234,7 +1234,10 @@ sis_attach(dev) } sc->sis_unit = unit; - callout_init(&sc->sis_stat_ch, CALLOUT_MPSAFE); + if (debug_mpsafenet) + callout_init(&sc->sis_stat_ch, CALLOUT_MPSAFE); + else + callout_init(&sc->sis_stat_ch, 0); bcopy(eaddr, (char *)&sc->arpcom.ac_enaddr, ETHER_ADDR_LEN); /*