summaryrefslogtreecommitdiff
path: root/src/device/pci_rom.c
diff options
context:
space:
mode:
authorMartin Roth <martinroth@google.com>2017-06-24 14:00:01 -0600
committerMartin Roth <martinroth@google.com>2017-06-28 17:48:57 +0000
commitb3b114c28f6e7c11b327fce84d93141498d5f665 (patch)
tree4ca1b11a12b72dded9f8bf96ec39691621239400 /src/device/pci_rom.c
parentebade5dec9e05291f64b0687130d6fbce52270f0 (diff)
src/device: add IS_ENABLED() around Kconfig symbol references
Some of these can be changed from #if to if(), but that will happen in a follow-on commmit. Change-Id: I66cde1adcf373889b03f144793c0b4f46d21ca31 Signed-off-by: Martin Roth <martinroth@google.com> Reviewed-on: https://review.coreboot.org/20338 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Philippe Mathieu-Daudé <f4bug@amsat.org> Reviewed-by: Patrick Georgi <pgeorgi@google.com>
Diffstat (limited to 'src/device/pci_rom.c')
-rw-r--r--src/device/pci_rom.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/device/pci_rom.c b/src/device/pci_rom.c
index a3f5775a1b..6456d17d6d 100644
--- a/src/device/pci_rom.c
+++ b/src/device/pci_rom.c
@@ -63,7 +63,7 @@ struct rom_header *pci_rom_probe(struct device *dev)
rom_address = pci_read_config32(dev, PCI_ROM_ADDRESS);
if (rom_address == 0x00000000 || rom_address == 0xffffffff) {
-#if CONFIG_BOARD_EMULATION_QEMU_X86
+#if IS_ENABLED(CONFIG_BOARD_EMULATION_QEMU_X86)
if ((dev->class >> 8) == PCI_CLASS_DISPLAY_VGA)
rom_address = 0xc0000;
else
@@ -149,7 +149,7 @@ struct rom_header *pci_rom_load(struct device *dev,
* devices have a mismatch between the hardware and the ROM.
*/
if (PCI_CLASS_DISPLAY_VGA == (dev->class >> 8)) {
-#if !CONFIG_MULTIPLE_VGA_ADAPTERS
+#if !IS_ENABLED(CONFIG_MULTIPLE_VGA_ADAPTERS)
extern device_t vga_pri; /* Primary VGA device (device.c). */
if (dev != vga_pri) return NULL; /* Only one VGA supported. */
#endif