Fix bug on newbus device deletion: we should delete the child's devinfo

on deletion, not the parent's.

MFC after:	3 weeks
This commit is contained in:
nwhitehorn 2019-06-16 21:56:45 +00:00
parent ef2d5dd0f6
commit de41fd6837

View File

@ -294,7 +294,7 @@ ofw_pcibus_child_deleted(device_t dev, device_t child)
{
struct ofw_pcibus_devinfo *dinfo;
dinfo = device_get_ivars(dev);
dinfo = device_get_ivars(child);
ofw_bus_gen_destroy_devinfo(&dinfo->opd_obdinfo);
pci_child_deleted(dev, child);
}