summaryrefslogtreecommitdiff
path: root/src/device/pci_device.c
diff options
context:
space:
mode:
authorKyösti Mälkki <kyosti.malkki@gmail.com>2019-01-23 16:15:48 +0200
committerNico Huber <nico.h@gmx.de>2019-03-06 11:53:56 +0000
commite079e5ccc2e707e5b6bd3b011e04c9138f159808 (patch)
treeed42a3f97712d440debed515776d4a7e3587305a /src/device/pci_device.c
parentad7758ca521bab7f1aaa0977516002f905cc0a67 (diff)
downloadcoreboot-e079e5ccc2e707e5b6bd3b011e04c9138f159808.tar.xz
device/pci_ops: Inline PCI config accessors for ramstage
Inlining here allows the check for (dev != NULL) to be optimised and evaluated just once inside the calling function body. Change-Id: I0b5b4f4adb8eaa483a31353324da19917db85f4a Signed-off-by: Kyösti Mälkki <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/31751 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Aaron Durbin <adurbin@chromium.org> Reviewed-by: Nico Huber <nico.h@gmx.de>
Diffstat (limited to 'src/device/pci_device.c')
-rw-r--r--src/device/pci_device.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/device/pci_device.c b/src/device/pci_device.c
index 4e51de0713..2233ddca67 100644
--- a/src/device/pci_device.c
+++ b/src/device/pci_device.c
@@ -693,6 +693,11 @@ void pci_dev_enable_resources(struct device *dev)
pci_write_config16(dev, PCI_COMMAND, command);
}
+void __noreturn pcidev_die(void)
+{
+ die("PCI: dev is NULL!\n");
+}
+
void pci_bus_enable_resources(struct device *dev)
{
u16 ctrl;