summaryrefslogtreecommitdiff
path: root/src/soc/intel/denverton_ns/romstage.c
diff options
context:
space:
mode:
authorKyösti Mälkki <kyosti.malkki@gmail.com>2018-12-29 08:04:16 +0200
committerKyösti Mälkki <kyosti.malkki@gmail.com>2019-01-03 12:16:33 +0000
commite16c9df4542a40c176225e9db034e750eb957d5d (patch)
tree11b04c93bb55fd5b2e3eed47c131cc9f5a821ff2 /src/soc/intel/denverton_ns/romstage.c
parente2c653e049d0c4db6c2712658eaa5838dac73ee9 (diff)
downloadcoreboot-e16c9df4542a40c176225e9db034e750eb957d5d.tar.xz
soc/intel: Fix bad uses of __SIMPLE_DEVICE__
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 <kyosti.malkki@gmail.com> Reviewed-on: https://review.coreboot.org/c/30497 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Arthur Heymans <arthur@aheymans.xyz>
Diffstat (limited to 'src/soc/intel/denverton_ns/romstage.c')
-rw-r--r--src/soc/intel/denverton_ns/romstage.c8
1 files changed, 0 insertions, 8 deletions
diff --git a/src/soc/intel/denverton_ns/romstage.c b/src/soc/intel/denverton_ns/romstage.c
index 617b64a619..34fd7bbd25 100644
--- a/src/soc/intel/denverton_ns/romstage.c
+++ b/src/soc/intel/denverton_ns/romstage.c
@@ -49,11 +49,7 @@ static void display_fsp_smbios_memory_info_hob(void)
static void early_pmc_init(void)
{
/* PMC (B0:D31:F2). */
-#if defined(__SIMPLE_DEVICE__)
pci_devfn_t dev = PCH_PMC_DEV;
-#else
- struct device *dev = PCH_PMC_DEV;
-#endif
/* Is PMC present */
if (pci_read_config16(dev, 0) == 0xffff) {
@@ -102,11 +98,7 @@ static void early_pmc_init(void)
static void early_tco_init(void)
{
/* SMBUS (B0:D31:F4). */
-#if defined(__SIMPLE_DEVICE__)
pci_devfn_t dev = PCI_DEV(0, SMBUS_DEV, SMBUS_FUNC);
-#else
- struct device *dev = PCI_DEV(0, SMBUS_DEV, SMBUS_FUNC);
-#endif
/* Configure TCO base address */
if (pci_read_config16(dev, TCOBASE) == 0xffff) {