From 5b3c3b153b81205ce727cb14eaf63da746a7b450 Mon Sep 17 00:00:00 2001 From: Dale Rahn Date: Mon, 3 May 2004 16:58:12 +0000 Subject: If wi@pcmcia fails in wiattach(), disestablish the interrupt and let the rest of the cleanup code run. ok millert@ --- sys/dev/pcmcia/if_wi_pcmcia.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) (limited to 'sys/dev/pcmcia/if_wi_pcmcia.c') diff --git a/sys/dev/pcmcia/if_wi_pcmcia.c b/sys/dev/pcmcia/if_wi_pcmcia.c index 1254ec0e2d5..9b9f8e363cd 100644 --- a/sys/dev/pcmcia/if_wi_pcmcia.c +++ b/sys/dev/pcmcia/if_wi_pcmcia.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_wi_pcmcia.c,v 1.46 2004/04/06 21:08:57 millert Exp $ */ +/* $OpenBSD: if_wi_pcmcia.c,v 1.47 2004/05/03 16:58:11 drahn Exp $ */ /* $NetBSD: if_wi_pcmcia.c,v 1.14 2001/11/26 04:34:56 ichiro Exp $ */ /* @@ -353,8 +353,10 @@ wi_pcmcia_attach(parent, self, aux) goto bad; } - wi_attach(sc, &wi_func_io); - return; + if (wi_attach(sc, &wi_func_io) == 0) + return; + + pcmcia_intr_disestablish(psc->sc_pf, sc->sc_ih); bad: if (state > 2) -- cgit v1.2.3