diff options
author | Dale Rahn <drahn@cvs.openbsd.org> | 2006-07-10 00:16:19 +0000 |
---|---|---|
committer | Dale Rahn <drahn@cvs.openbsd.org> | 2006-07-10 00:16:19 +0000 |
commit | ff19685e6b215b7f0266b53e4155019b1d2fa35f (patch) | |
tree | 390f143f7a0d0f0410a105ecc63045af7c22b487 /sys/dev/pci | |
parent | 233b7e9a4ef092cf7125322e2bcdf5a5d6345964 (diff) |
Fully initialize the softc structure before enabling interrupt. ok brad@
Diffstat (limited to 'sys/dev/pci')
-rw-r--r-- | sys/dev/pci/if_em.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/sys/dev/pci/if_em.c b/sys/dev/pci/if_em.c index 490a64396ec..d451add0d88 100644 --- a/sys/dev/pci/if_em.c +++ b/sys/dev/pci/if_em.c @@ -31,7 +31,7 @@ POSSIBILITY OF SUCH DAMAGE. ***************************************************************************/ -/* $OpenBSD: if_em.c,v 1.137 2006/07/08 04:34:34 brad Exp $ */ +/* $OpenBSD: if_em.c,v 1.138 2006/07/10 00:16:18 drahn Exp $ */ /* $FreeBSD: if_em.c,v 1.46 2004/09/29 18:28:28 mlaier Exp $ */ #include <dev/pci/if_em.h> @@ -1436,6 +1436,8 @@ em_allocate_pci_resources(struct em_softc *sc) return (ENXIO); } + sc->hw.back = &sc->osdep; + intrstr = pci_intr_string(pc, ih); sc->sc_intrhand = pci_intr_establish(pc, ih, IPL_NET, em_intr, sc, sc->sc_dv.dv_xname); @@ -1447,8 +1449,6 @@ em_allocate_pci_resources(struct em_softc *sc) return (ENXIO); } printf(": %s", intrstr); - - sc->hw.back = &sc->osdep; return (0); } |