Page MenuHomeFreeBSD

intelspi: don't leak spibus children on detach
ClosedPublic

Authored by yuripv on Sep 8 2018, 5:44 AM.
Tags
None
Referenced Files
Unknown Object (File)
Wed, Oct 29, 10:44 PM
Unknown Object (File)
Fri, Oct 24, 7:57 PM
Unknown Object (File)
Fri, Oct 24, 3:47 AM
Unknown Object (File)
Fri, Oct 24, 3:47 AM
Unknown Object (File)
Fri, Oct 24, 3:47 AM
Unknown Object (File)
Fri, Oct 24, 3:47 AM
Unknown Object (File)
Thu, Oct 23, 7:07 PM
Unknown Object (File)
Thu, Oct 23, 4:06 AM

Details

Test Plan
  1. kldload intelspi
  2. kldunload intelspi

Diff Detail

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

Event Timeline

kib added inline comments.
sys/dev/intel/spi.c
500 ↗(On Diff #47809)

There is device delete_children(9). It would be much more convenient to use there.

But I suspect that intelspi should be considered bus and then bus_generic_detach(9) used instead. See the call for bus generic_attach() above.

use bus_generic_detach().

yuripv added inline comments.
sys/dev/intel/spi.c
500 ↗(On Diff #47809)

Even better, works the same.

This revision is now accepted and ready to land.Sep 8 2018, 5:52 PM
This revision was automatically updated to reflect the committed changes.