1
0
mirror of https://git.FreeBSD.org/src.git synced 2024-12-03 09:00:21 +00:00

When booted -v (eg bootverbose is non-zero), have pccard report what

resources it is attempting to assign to a child object.  This should
help people track down mysterious resource allocation problems more
easily.

# Unfortunately, it is harder to do the conflict check and report which
# resource failed if the driver itself doesn't.
This commit is contained in:
Warner Losh 2001-07-30 00:03:58 +00:00
parent 9e27954de1
commit 4c7bc18993
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=80570

View File

@ -226,6 +226,13 @@ allocate_driver(struct slot *slt, struct dev_desc *desc)
child = device_add_child(pccarddev, devi->name, desc->unit);
device_set_flags(child, desc->flags);
device_set_ivars(child, devi);
if (bootverbose) {
device_printf(pccarddev,
"Assigning %s: io 0x%x-0x%x irq %d mem 0x%lx-0x%lx\n",
device_get_nameunit(child),
desc->iobase, desc->iobase + desc->iosize - 1,
irq, desc->mem, desc->mem + desc->memsize - 1);
}
err = bus_set_resource(child, SYS_RES_IOPORT, 0, desc->iobase,
desc->iosize);
if (err)