Nico Huber has posted comments on this change. ( https://review.coreboot.org/c/coreboot/+/31685 )
Change subject: device/pci_ops: Reuse romstage PCI config for ramstage ......................................................................
Patch Set 5: Code-Review+1
(1 comment)
I'm not very fond of the FIXME ;) is there a solution in the queue, yet? If not, I fear callers could get used to the fact that the "ops" check for NULL while we should actually encourage them to explicitly check before calling.
https://review.coreboot.org/#/c/31685/5/src/include/device/pci_type.h File src/include/device/pci_type.h:
https://review.coreboot.org/#/c/31685/5/src/include/device/pci_type.h@32 PS5, Line 32: * the check themselves. Maybe the following strategy would work: for pcidev_behind() and alike add a _or_die() version and always call that in case the author doesn't care about error handling. And then assume "ops" aren't called with NULL, ofc.