Page MenuHomeFreeBSD

Fix PCI bus detach to delete child devices.
ClosedPublic

Authored by jhb on Apr 20 2016, 2:40 AM.
Tags
None
Referenced Files
F133368674: D6020.id15363.diff
Sat, Oct 25, 6:13 AM
F133360509: D6020.diff
Sat, Oct 25, 4:48 AM
Unknown Object (File)
Thu, Oct 23, 12:54 AM
Unknown Object (File)
Wed, Oct 22, 10:56 PM
Unknown Object (File)
Wed, Oct 15, 6:26 AM
Unknown Object (File)
Tue, Oct 14, 10:33 PM
Unknown Object (File)
Tue, Oct 14, 10:33 PM
Unknown Object (File)
Tue, Oct 14, 10:33 PM
Subscribers

Details

Summary

Fix PCI bus detach to delete child devices.

Arguably, bus_generic_detach() should be calling device_delete_children()
as most (if not all) buses should delete child devices when detaching,
but that's a larger problem to solve.

If I had my druthers I'd probably rename bus_generic_detach() to
device_detach_children() and change bus_generic_detach() to call
device_detach_children() followed by device_delete_children().

Test Plan
  • the hotplug patches detach (and delete) the PCI bus on card insertion and exercised this change

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable