Print device names for children that fail to detach.

Free child array when we're done with it.

Forgotten by: imp
Submitted by: Nick Hibma <hibma@skylink.it>
This commit is contained in:
Warner Losh 1999-12-02 19:51:34 +00:00
parent b11b638301
commit b152132e64
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=54043

View File

@ -194,8 +194,10 @@ disable_slot(struct slot *slt)
device_get_children(pccarddev, &kids, &nkids);
for (i = 0; i < nkids; i++) {
if ((ret = device_delete_child(pccarddev, kids[i])) != 0)
printf("pccard: delete failed: %d\n", ret);
printf("pccard: delete of %s failed: %d\n",
device_get_nameunit(kids[i]), ret);
}
free(kids, M_TEMP);
/* Power off the slot 1/2 second after removal of the card */
slt->poff_ch = timeout(power_off_slot, (caddr_t)slt, hz / 2);