From 68c851bcd702e7816cdb6e504f7386ec404ecf13 Mon Sep 17 00:00:00 2001 From: Elyes HAOUAS Date: Tue, 12 Jun 2018 22:06:09 +0200 Subject: src: Get rid of device_t Use of device_t is deprecated. Change-Id: I6adc0429ae9ecc8f726d6167a6458d9333dc515f Signed-off-by: Elyes HAOUAS Reviewed-on: https://review.coreboot.org/27036 Tested-by: build bot (Jenkins) Reviewed-by: Patrick Georgi --- src/soc/intel/common/block/lpc/lpc_lib.c | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) (limited to 'src/soc/intel/common/block/lpc') diff --git a/src/soc/intel/common/block/lpc/lpc_lib.c b/src/soc/intel/common/block/lpc/lpc_lib.c index 58b588e508..d27f877c85 100644 --- a/src/soc/intel/common/block/lpc/lpc_lib.c +++ b/src/soc/intel/common/block/lpc/lpc_lib.c @@ -167,7 +167,11 @@ bool lpc_fits_fixed_mmio_window(uintptr_t base, size_t size) */ static void lpc_set_bios_control_reg(uint8_t bios_cntl_bit) { - device_t dev = PCH_DEV_LPC; +#if defined(__SIMPLE_DEVICE__) + pci_devfn_t dev = PCH_DEV_LPC; +#else + struct device *dev = PCH_DEV_LPC; +#endif uint8_t bc_cntl; assert(IS_POWER_OF_2(bios_cntl_bit)); @@ -210,7 +214,11 @@ void lpc_set_eiss(void) */ void lpc_set_serirq_mode(enum serirq_mode mode) { - device_t dev = PCH_DEV_LPC; +#if defined(__SIMPLE_DEVICE__) + pci_devfn_t dev = PCH_DEV_LPC; +#else + struct device *dev = PCH_DEV_LPC; +#endif uint8_t scnt; scnt = pci_read_config8(dev, LPC_SERIRQ_CTL); -- cgit v1.2.3