summaryrefslogtreecommitdiff
path: root/sys/dev
diff options
context:
space:
mode:
authoronoe <onoe@NetBSD.org>2001-06-28 10:34:17 +0000
committeronoe <onoe@NetBSD.org>2001-06-28 10:34:17 +0000
commit950ec87b20e99003fae076e501b5dc2b5dbc5e2d (patch)
tree4c98ed347cdf6a0e69f260082562109da79c4f0c /sys/dev
parent7fc92b8a863ab3e9e07ec07711a9f51cb1f3500c (diff)
Do not re-enable after resume if interface is marked down.
Diffstat (limited to 'sys/dev')
-rw-r--r--sys/dev/ic/an.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/sys/dev/ic/an.c b/sys/dev/ic/an.c
index e6f8958f373..60492fbece2 100644
--- a/sys/dev/ic/an.c
+++ b/sys/dev/ic/an.c
@@ -1,4 +1,4 @@
-/* $NetBSD: an.c,v 1.15 2001/06/21 12:49:06 onoe Exp $ */
+/* $NetBSD: an.c,v 1.16 2001/06/28 10:34:17 onoe Exp $ */
/*
* Copyright (c) 1997, 1998, 1999
* Bill Paul <wpaul@ctr.columbia.edu>. All rights reserved.
@@ -384,7 +384,8 @@ an_power(int why, void *arg)
an_stop(ifp, 1);
break;
case PWR_RESUME:
- an_init(ifp);
+ if (ifp->if_flags & IFF_UP)
+ an_init(ifp);
break;
case PWR_SOFTSUSPEND:
case PWR_SOFTSTANDBY:
@@ -485,7 +486,7 @@ an_ioctl(struct ifnet *ifp, u_long command, caddr_t data)
(ifp->if_flags & IFF_PROMISC) ? 0xffff : 0);
else if (ifp->if_flags & IFF_UP)
error = an_init(ifp);
- else if (sc->sc_enabled && !(ifp->if_flags & IFF_UP))
+ else if (sc->sc_enabled)
an_stop(ifp, 1);
sc->an_if_flags = ifp->if_flags;
break;