summaryrefslogtreecommitdiffstats
path: root/sys/dev/cardbus
diff options
context:
space:
mode:
authorimp <imp@FreeBSD.org>2002-02-07 06:43:02 +0000
committerimp <imp@FreeBSD.org>2002-02-07 06:43:02 +0000
commit245009060517202788fc1dbf8a5d426cd61262e2 (patch)
tree82f77145ca9e91e15629a06f8b5c022213d681d6 /sys/dev/cardbus
parente1bdd69900920a89472349782d7a69ee64542203 (diff)
downloadFreeBSD-src-245009060517202788fc1dbf8a5d426cd61262e2.zip
FreeBSD-src-245009060517202788fc1dbf8a5d426cd61262e2.tar.gz
Get rid of the bogus DETACH_NOWARN and don't warn when asked to detach
a card that isn't there unless we're booting verbose. It serves no purpose.
Diffstat (limited to 'sys/dev/cardbus')
-rw-r--r--sys/dev/cardbus/cardbus.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/sys/dev/cardbus/cardbus.c b/sys/dev/cardbus/cardbus.c
index 4fae016..c6a30e5 100644
--- a/sys/dev/cardbus/cardbus.c
+++ b/sys/dev/cardbus/cardbus.c
@@ -208,7 +208,7 @@ cardbus_attach_card(device_t cbdev)
static int curr_bus_number = 2; /* XXX EVILE BAD (see below) */
int bus, slot, func;
- cardbus_detach_card(cbdev, DETACH_NOWARN); /* detach existing cards */
+ cardbus_detach_card(cbdev, 0); /* detach existing cards */
POWER_ENABLE_SOCKET(brdev, cbdev);
bus = pcib_get_bus(cbdev);
@@ -272,10 +272,9 @@ cardbus_detach_card(device_t cbdev, int flags)
device_get_children(cbdev, &devlist, &numdevs);
if (numdevs == 0) {
- if (!(flags & DETACH_NOWARN)) {
+ if (bootverbose)
DEVPRINTF((cbdev, "detach_card: no card to detach!\n"));
- POWER_DISABLE_SOCKET(device_get_parent(cbdev), cbdev);
- }
+ POWER_DISABLE_SOCKET(device_get_parent(cbdev), cbdev);
free(devlist, M_TEMP);
return ENOENT;
}
OpenPOWER on IntegriCloud