From 777099046f88f96921e21ad2e0a58b2fe66b25aa Mon Sep 17 00:00:00 2001 From: Werner Zeh Date: Mon, 29 Aug 2022 12:44:02 +0200 Subject: soc/intel/spi: Move BIOS flash SPI controllers to fast SPI driver There are two classes of SPI controllers on Intel chipsets: * generic usable SPI controllers * SPI controller hosting the BIOS flash (fast SPI controller) While the first class can be used for generic peripheral attachment the second class mostly controls the BIOS flash and a TPM device (if enabled). The generic SPI driver is not fully applicable to the fast SPI controller. In addition, the fast SPI controller reports the reserved MMIO range used for the BIOS flash mapping so that the OS is aware of this range. This patch moves the fast SPI controller of all known SoCs to the fast SPI driver in common code. In addition, the PCI device for the fast SPI controller is removed from the function 'spi_soc_devfn_to_bus' as this is a callback of the generic SPI driver. Change-Id: Ia881c1d274acdcf7f042dd8284048a7dd018a84b Signed-off-by: Werner Zeh Reviewed-on: https://review.coreboot.org/c/coreboot/+/67173 Tested-by: build bot (Jenkins) Reviewed-by: Tim Wawrzynczak --- src/soc/intel/common/block/fast_spi/fast_spi.c | 15 +++++++++++++++ 1 file changed, 15 insertions(+) (limited to 'src/soc/intel/common/block/fast_spi/fast_spi.c') diff --git a/src/soc/intel/common/block/fast_spi/fast_spi.c b/src/soc/intel/common/block/fast_spi/fast_spi.c index ffda237d86fd..e46effcc4e89 100644 --- a/src/soc/intel/common/block/fast_spi/fast_spi.c +++ b/src/soc/intel/common/block/fast_spi/fast_spi.c @@ -541,8 +541,23 @@ static struct device_operations fast_spi_dev_ops = { }; static const unsigned short pci_device_ids[] = { + PCI_DID_INTEL_ADP_M_N_HWSEQ_SPI, + PCI_DID_INTEL_ADP_P_HWSEQ_SPI, + PCI_DID_INTEL_ADP_S_HWSEQ_SPI, PCI_DID_INTEL_APL_HWSEQ_SPI, PCI_DID_INTEL_GLK_HWSEQ_SPI, + PCI_DID_INTEL_CMP_HWSEQ_SPI, + PCI_DID_INTEL_CMP_H_HWSEQ_SPI, + PCI_DID_INTEL_CNL_HWSEQ_SPI, + PCI_DID_INTEL_CNP_H_HWSEQ_SPI, + PCI_DID_INTEL_ICP_HWSEQ_SPI, + PCI_DID_INTEL_JSP_HWSEQ_SPI, + PCI_DID_INTEL_LWB_SPI, + PCI_DID_INTEL_LWB_SPI_SUPER, + PCI_DID_INTEL_MCC_SPI0, + PCI_DID_INTEL_MTL_HWSEQ_SPI, + PCI_DID_INTEL_SPR_HWSEQ_SPI, + PCI_DID_INTEL_TGP_SPI0, 0 }; -- cgit v1.2.3