From e16c9df4542a40c176225e9db034e750eb957d5d Mon Sep 17 00:00:00 2001 From: Kyösti Mälkki Date: Sat, 29 Dec 2018 08:04:16 +0200 Subject: soc/intel: Fix bad uses of __SIMPLE_DEVICE__ MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cases of *dev = PCI_DEV(b,d,f) are invalid. Not caught because files only build with __SIMPLE_DEVICE__ defined. Remove cases of testing __SIMPLE_DEVICE__ in files that are not build for ramstage. Change-Id: If10a0efa187c9b1d9a5577008aa46f050f0aa309 Signed-off-by: Kyösti Mälkki Reviewed-on: https://review.coreboot.org/c/30497 Tested-by: build bot (Jenkins) Reviewed-by: Arthur Heymans --- src/soc/intel/denverton_ns/smihandler.c | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) (limited to 'src/soc/intel/denverton_ns/smihandler.c') diff --git a/src/soc/intel/denverton_ns/smihandler.c b/src/soc/intel/denverton_ns/smihandler.c index d97bc24f59..85f99d7966 100644 --- a/src/soc/intel/denverton_ns/smihandler.c +++ b/src/soc/intel/denverton_ns/smihandler.c @@ -65,12 +65,8 @@ static void busmaster_disable_on_bus(int bus) for (slot = 0; slot < 0x20; slot++) { for (func = 0; func < 8; func++) { u32 reg32; -#if defined(__SIMPLE_DEVICE__) - pci_devfn_t dev = PCI_DEV(bus, slot, func); -#else - struct device *dev = PCI_DEV(bus, slot, func); -#endif + pci_devfn_t dev = PCI_DEV(bus, slot, func); val = pci_read_config32(dev, PCI_VENDOR_ID); if (val == 0xffffffff || val == 0x00000000 || -- cgit v1.2.3