summaryrefslogtreecommitdiff
path: root/sys/dev/cardbus
diff options
context:
space:
mode:
authorRobert Nagy <robert@cvs.openbsd.org>2005-05-27 18:57:20 +0000
committerRobert Nagy <robert@cvs.openbsd.org>2005-05-27 18:57:20 +0000
commitfa161475baff484beb7cc471d504f6ccafa77c52 (patch)
treeb2e24432bd2cc6a89f0ee47a19251d3b693000cb /sys/dev/cardbus
parent1a896445c7694d2ce95289d51e5b56d7af4632e9 (diff)
make sure to enable socket on resume.
in order for the enable to work disable the socket on suspend. lot of help from mickey@ ok jsg@ millert@
Diffstat (limited to 'sys/dev/cardbus')
-rw-r--r--sys/dev/cardbus/if_atw_cardbus.c17
-rw-r--r--sys/dev/cardbus/if_rtw_cardbus.c17
2 files changed, 6 insertions, 28 deletions
diff --git a/sys/dev/cardbus/if_atw_cardbus.c b/sys/dev/cardbus/if_atw_cardbus.c
index c940725e14f..2a160255470 100644
--- a/sys/dev/cardbus/if_atw_cardbus.c
+++ b/sys/dev/cardbus/if_atw_cardbus.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_atw_cardbus.c,v 1.8 2005/05/16 01:36:25 brad Exp $ */
+/* $OpenBSD: if_atw_cardbus.c,v 1.9 2005/05/27 18:57:19 robert Exp $ */
/* $NetBSD: if_atw_cardbus.c,v 1.9 2004/07/23 07:07:55 dyoung Exp $ */
/*-
@@ -331,21 +331,10 @@ atw_cardbus_disable(struct atw_softc *sc)
void
atw_cardbus_power(struct atw_softc *sc, int why)
{
- struct atw_cardbus_softc *csc = (void *) sc;
-
printf("%s: atw_cardbus_power\n", sc->sc_dev.dv_xname);
- if (why == PWR_RESUME) {
- /*
- * Give the PCI configuration registers a kick
- * in the head.
- */
-#ifdef DIAGNOSTIC
- if (ATW_IS_ENABLED(sc) == 0)
- panic("atw_cardbus_power");
-#endif
- atw_cardbus_setup(csc);
- }
+ if (why == PWR_RESUME)
+ atw_enable(sc);
}
void
diff --git a/sys/dev/cardbus/if_rtw_cardbus.c b/sys/dev/cardbus/if_rtw_cardbus.c
index 9aef539f7d3..26b6ea9c168 100644
--- a/sys/dev/cardbus/if_rtw_cardbus.c
+++ b/sys/dev/cardbus/if_rtw_cardbus.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: if_rtw_cardbus.c,v 1.5 2005/05/16 01:36:25 brad Exp $ */
+/* $OpenBSD: if_rtw_cardbus.c,v 1.6 2005/05/27 18:57:19 robert Exp $ */
/* $NetBSD: if_rtw_cardbus.c,v 1.4 2004/12/20 21:05:34 dyoung Exp $ */
/*-
@@ -395,22 +395,11 @@ rtw_cardbus_disable(struct rtw_softc *sc)
void
rtw_cardbus_power(struct rtw_softc *sc, int why)
{
- struct rtw_cardbus_softc *csc = (void *) sc;
-
RTW_DPRINTF(RTW_DEBUG_ATTACH,
("%s: rtw_cardbus_power\n", sc->sc_dev.dv_xname));
- if (why == PWR_RESUME) {
- /*
- * Give the PCI configuration registers a kick
- * in the head.
- */
-#ifdef DIAGNOSTIC
- if ((sc->sc_flags & RTW_F_ENABLED) == 0)
- panic("rtw_cardbus_power");
-#endif
- rtw_cardbus_setup(csc);
- }
+ if (why == PWR_RESUME)
+ rtw_enable(sc);
}
void