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
Unknown Object (File)
Wed, Oct 23, 9:42 AM
Unknown Object (File)
Wed, Oct 23, 9:41 AM
Unknown Object (File)
Wed, Oct 23, 9:41 AM
Unknown Object (File)
Wed, Oct 23, 9:40 AM
Unknown Object (File)
Fri, Oct 11, 2:51 AM
Unknown Object (File)
Sep 20 2024, 9:13 AM
Unknown Object (File)
Aug 29 2024, 4:50 PM
Unknown Object (File)
Aug 25 2024, 1:38 AM
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

Event Timeline

jhb retitled this revision from to Fix PCI bus detach to delete child devices..
jhb updated this object.
jhb edited the test plan for this revision. (Show Details)
jhb added a reviewer: imp.
This revision was automatically updated to reflect the committed changes.