Furquan Shaikh has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/41441 )
Change subject: device: Probe fw_config and disable device if it is not found ......................................................................
Patch Set 14:
(1 comment)
https://review.coreboot.org/c/coreboot/+/41441/14/src/device/pci_device.c File src/device/pci_device.c:
https://review.coreboot.org/c/coreboot/+/41441/14/src/device/pci_device.c@12... PS14, Line 1267: fw_config_probe_device Should this instead be handled as a separate step in dev_enumerate() before scan_bus() is called i.e. loop through all devices in the tree and call fw_config_probe_device() for each device in the tree? That way we don't need to add this check in different scan bus callbacks.
The downside that I see with the approach is that fw_config_probe_device() wouldn't get called for any device that is added by scan_bus. But there is no way to actually add fw_config probe property if the device is not defined in the device tree statically. So, a check in dev_enumerate() should work?