summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorFelix Held <felix-coreboot@felixheld.de>2021-10-27 18:31:16 +0200
committerFelix Held <felix-coreboot@felixheld.de>2021-11-02 15:50:03 +0000
commit43cf27d3a7d90e07099396d2ff8af2c1435669ee (patch)
tree17195db0a1ee864be6d1f854af96a3636edbad7d
parent0d7e2a461ae2795081b767a1cae54ae6190020b3 (diff)
downloadcoreboot-43cf27d3a7d90e07099396d2ff8af2c1435669ee.tar.gz
coreboot-43cf27d3a7d90e07099396d2ff8af2c1435669ee.tar.bz2
coreboot-43cf27d3a7d90e07099396d2ff8af2c1435669ee.zip
include/device/pci_ids,soc/amd/common/block/lpc: drop duplicate PCI IDs
PCI_DEVICE_ID_AMD_FAM17H_LPC and PCI_DEVICE_ID_AMD_FAM17H_SMBUS redefine the same values that are already defined by PCI_DEVICE_ID_AMD_CZ_LPC and PCI_DEVICE_ID_AMD_CZ_SMBUS, so drop PCI_DEVICE_ID_AMD_FAM17H_LPC and PCI_DEVICE_ID_AMD_FAM17H_SMBUS. Also add some comments to the places in the code where the defines are used to clarify which ID is used on which hardware generation. Signed-off-by: Felix Held <felix-coreboot@felixheld.de> Change-Id: Id0b3d7b5a886ccc76d82ada6be4145e85fd51ede Reviewed-on: https://review.coreboot.org/c/coreboot/+/58696 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Jason Glenesk <jason.glenesk@gmail.com> Reviewed-by: Raul Rangel <rrangel@chromium.org>
-rw-r--r--src/include/device/pci_ids.h2
-rw-r--r--src/soc/amd/common/block/lpc/lpc.c3
-rw-r--r--src/soc/amd/common/block/smbus/sm.c1
-rw-r--r--src/southbridge/amd/pi/hudson/lpc.c2
-rw-r--r--src/southbridge/amd/pi/hudson/sm.c1
5 files changed, 6 insertions, 3 deletions
diff --git a/src/include/device/pci_ids.h b/src/include/device/pci_ids.h
index 0e4da4192191..1ed6ac9edacb 100644
--- a/src/include/device/pci_ids.h
+++ b/src/include/device/pci_ids.h
@@ -620,8 +620,6 @@
#define PCI_DEVICE_ID_AMD_FAM17H_SATA_AHCI_RAID_VER0 0x7916
#define PCI_DEVICE_ID_AMD_FAM17H_SATA_AHCI_RAID_VER1 0x7917
#define PCI_DEVICE_ID_AMD_FAM17H_MODEL18H_SD 0x7906
-#define PCI_DEVICE_ID_AMD_FAM17H_SMBUS 0x790B
-#define PCI_DEVICE_ID_AMD_FAM17H_LPC 0x790E
#define PCI_DEVICE_ID_AMD_FAM17H_MODEL18H_GBE 0x1458
#define PCI_DEVICE_ID_AMD_FAM17H_MODEL60H_GBE 0x1641
#define PCI_DEVICE_ID_AMD_FAM17H_I2S_AC97 0x1644
diff --git a/src/soc/amd/common/block/lpc/lpc.c b/src/soc/amd/common/block/lpc/lpc.c
index 496816b0f3f7..7c466459e67c 100644
--- a/src/soc/amd/common/block/lpc/lpc.c
+++ b/src/soc/amd/common/block/lpc/lpc.c
@@ -322,9 +322,10 @@ static struct device_operations lpc_ops = {
};
static const unsigned short pci_device_ids[] = {
+ /* PCI device ID is used on all discrete FCHs and Family 16h Models 00h-3Fh */
PCI_DEVICE_ID_AMD_SB900_LPC,
+ /* PCI device ID is used on all integrated FCHs except Family 16h Models 00h-3Fh */
PCI_DEVICE_ID_AMD_CZ_LPC,
- PCI_DEVICE_ID_AMD_FAM17H_LPC,
0
};
static const struct pci_driver lpc_driver __pci_driver = {
diff --git a/src/soc/amd/common/block/smbus/sm.c b/src/soc/amd/common/block/smbus/sm.c
index ce66cbbb7a57..ae2edc150613 100644
--- a/src/soc/amd/common/block/smbus/sm.c
+++ b/src/soc/amd/common/block/smbus/sm.c
@@ -89,5 +89,6 @@ static struct device_operations smbus_ops = {
static const struct pci_driver smbus_driver __pci_driver = {
.ops = &smbus_ops,
.vendor = PCI_VENDOR_ID_AMD,
+ /* PCI device ID is used on all integrated FCHs except Family 16h Models 00h-3Fh */
.device = PCI_DEVICE_ID_AMD_CZ_SMBUS,
};
diff --git a/src/southbridge/amd/pi/hudson/lpc.c b/src/southbridge/amd/pi/hudson/lpc.c
index 77d39c5e915e..784147c9173e 100644
--- a/src/southbridge/amd/pi/hudson/lpc.c
+++ b/src/southbridge/amd/pi/hudson/lpc.c
@@ -354,7 +354,9 @@ static struct device_operations lpc_ops = {
};
static const unsigned short pci_device_ids[] = {
+ /* PCI device ID is used on all discrete FCHs and Family 16h Models 00h-3Fh */
PCI_DEVICE_ID_AMD_SB900_LPC,
+ /* PCI device ID is used on all integrated FCHs except Family 16h Models 00h-3Fh */
PCI_DEVICE_ID_AMD_CZ_LPC,
0
};
diff --git a/src/southbridge/amd/pi/hudson/sm.c b/src/southbridge/amd/pi/hudson/sm.c
index 6f9e03c2d32c..f6422cf37e74 100644
--- a/src/southbridge/amd/pi/hudson/sm.c
+++ b/src/southbridge/amd/pi/hudson/sm.c
@@ -106,5 +106,6 @@ static struct device_operations smbus_ops = {
static const struct pci_driver smbus_driver __pci_driver = {
.ops = &smbus_ops,
.vendor = PCI_VENDOR_ID_AMD,
+ /* PCI device ID is used on all discrete FCHs and Family 16h Models 00h-3Fh */
.device = PCI_DEVICE_ID_AMD_SB900_SM,
};