PERFORCE change 112957 for review
M. Warner Losh
imp at bsdimp.com
Fri Jan 19 08:51:32 UTC 2007
In message: <200701152255.l0FMtKId033379 at repoman.freebsd.org>
Hans Petter Selasky <hselasky at freebsd.org> writes:
: ==== //depot/projects/usb/src/sys/dev/pccbb/pccbb.c#3 (text+ko) ====
:
: @@ -302,10 +302,11 @@
: * for the kldload/unload case to work. If we failed to do that, then
: * we'd get duplicate devices when cbb.ko was reloaded.
: */
: - device_get_children(brdev, &devlist, &numdevs);
: - for (tmp = 0; tmp < numdevs; tmp++)
: - device_delete_child(brdev, devlist[tmp]);
: - free(devlist, M_TEMP);
: + if (!device_get_children(brdev, &devlist, &numdevs)) {
: + for (tmp = 0; tmp < numdevs; tmp++)
Actually this is a problem. While the old code ignores errors, I
don't think that's really the right thing to do here. It is critical
that the children be deleted.
Warner
More information about the p4-projects
mailing list