soc/intel/alderlake: Add support for I2C6 and I2C7
As per the EDS revision 1.3 add support for I2C6 and I2C7.
Signed-off-by: Varshit B Pandya <varshit.b.pandya@intel.com>
Change-Id: Id918d55e48b91993af9de8381995917aef55edc9
Reviewed-on: https://review.coreboot.org/c/coreboot/+/55996
Reviewed-by: Tim Wawrzynczak <twawrzynczak@chromium.org>
Reviewed-by: Maulik V Vaghela <maulik.v.vaghela@intel.com>
Reviewed-by: Paul Menzel <paulepanter@mailbox.org>
Tested-by: build bot (Jenkins) <no-reply@coreboot.org>
diff --git a/src/include/device/pci_ids.h b/src/include/device/pci_ids.h
index 24e8426..a4458ea 100644
--- a/src/include/device/pci_ids.h
+++ b/src/include/device/pci_ids.h
@@ -3526,6 +3526,8 @@
#define PCI_DEVICE_ID_INTEL_ADP_P_I2C3 0x51eb
#define PCI_DEVICE_ID_INTEL_ADP_P_I2C4 0x51c5
#define PCI_DEVICE_ID_INTEL_ADP_P_I2C5 0x51c6
+#define PCI_DEVICE_ID_INTEL_ADP_P_I2C6 0x51d8
+#define PCI_DEVICE_ID_INTEL_ADP_P_I2C7 0x51d9
#define PCI_DEVICE_ID_INTEL_ADP_S_I2C0 0x7acc
#define PCI_DEVICE_ID_INTEL_ADP_S_I2C1 0x7acd
diff --git a/src/soc/intel/alderlake/Kconfig b/src/soc/intel/alderlake/Kconfig
index 677e141..743be57 100644
--- a/src/soc/intel/alderlake/Kconfig
+++ b/src/soc/intel/alderlake/Kconfig
@@ -223,7 +223,7 @@
config SOC_INTEL_I2C_DEV_MAX
int
- default 6
+ default 8
config SOC_INTEL_UART_DEV_MAX
int
diff --git a/src/soc/intel/alderlake/acpi/serialio.asl b/src/soc/intel/alderlake/acpi/serialio.asl
index f7bf452..a325953 100644
--- a/src/soc/intel/alderlake/acpi/serialio.asl
+++ b/src/soc/intel/alderlake/acpi/serialio.asl
@@ -38,6 +38,18 @@
Name (_DDN, "Serial IO I2C Controller 5")
}
+Device (I2C6)
+{
+ Name (_ADR, 0x00100000)
+ Name (_DDN, "Serial IO I2C Controller 6")
+}
+
+Device (I2C7)
+{
+ Name (_ADR, 0x00100001)
+ Name (_DDN, "Serial IO I2C Controller 7")
+}
+
Device (SPI0)
{
Name (_ADR, 0x001e0002)
diff --git a/src/soc/intel/alderlake/chip.c b/src/soc/intel/alderlake/chip.c
index 88b3195..4a060af 100644
--- a/src/soc/intel/alderlake/chip.c
+++ b/src/soc/intel/alderlake/chip.c
@@ -78,6 +78,8 @@
case PCH_DEVFN_I2C3: return "I2C3";
case PCH_DEVFN_I2C4: return "I2C4";
case PCH_DEVFN_I2C5: return "I2C5";
+ case PCH_DEVFN_I2C6: return "I2C6";
+ case PCH_DEVFN_I2C7: return "I2C7";
case PCH_DEVFN_SATA: return "SATA";
case PCH_DEVFN_PCIE1: return "RP01";
case PCH_DEVFN_PCIE2: return "RP02";
diff --git a/src/soc/intel/alderlake/chipset.cb b/src/soc/intel/alderlake/chipset.cb
index b05a1e9..532ec38 100644
--- a/src/soc/intel/alderlake/chipset.cb
+++ b/src/soc/intel/alderlake/chipset.cb
@@ -79,6 +79,8 @@
device pci 0d.2 alias tcss_dma0 off end
device pci 0d.3 alias tcss_dma1 off end
device pci 0e.0 alias vmd off end
+ device pci 10.0 alias i2c6 off end
+ device pci 10.1 alias i2c7 off end
device pci 10.6 alias thc0 off end
device pci 10.7 alias thc1 off end
device pci 12.0 alias ish off end
diff --git a/src/soc/intel/alderlake/i2c.c b/src/soc/intel/alderlake/i2c.c
index ef34e2e..5fcca2a 100644
--- a/src/soc/intel/alderlake/i2c.c
+++ b/src/soc/intel/alderlake/i2c.c
@@ -25,6 +25,10 @@
return 4;
case PCH_DEVFN_I2C5:
return 5;
+ case PCH_DEVFN_I2C6:
+ return 6;
+ case PCH_DEVFN_I2C7:
+ return 7;
}
return -1;
}
@@ -44,6 +48,10 @@
return PCH_DEVFN_I2C4;
case 5:
return PCH_DEVFN_I2C5;
+ case 6:
+ return PCH_DEVFN_I2C6;
+ case 7:
+ return PCH_DEVFN_I2C7;
}
return -1;
}
diff --git a/src/soc/intel/alderlake/include/soc/serialio.h b/src/soc/intel/alderlake/include/soc/serialio.h
index e42af5f..d1a9a01 100644
--- a/src/soc/intel/alderlake/include/soc/serialio.h
+++ b/src/soc/intel/alderlake/include/soc/serialio.h
@@ -18,6 +18,8 @@
PchSerialIoIndexI2C3,
PchSerialIoIndexI2C4,
PchSerialIoIndexI2C5,
+ PchSerialIoIndexI2C6,
+ PchSerialIoIndexI2C7,
};
enum {
diff --git a/src/soc/intel/common/block/i2c/i2c.c b/src/soc/intel/common/block/i2c/i2c.c
index a82b1eb..21e6a32 100644
--- a/src/soc/intel/common/block/i2c/i2c.c
+++ b/src/soc/intel/common/block/i2c/i2c.c
@@ -250,6 +250,8 @@
PCI_DEVICE_ID_INTEL_ADP_P_I2C3,
PCI_DEVICE_ID_INTEL_ADP_P_I2C4,
PCI_DEVICE_ID_INTEL_ADP_P_I2C5,
+ PCI_DEVICE_ID_INTEL_ADP_P_I2C6,
+ PCI_DEVICE_ID_INTEL_ADP_P_I2C7,
PCI_DEVICE_ID_INTEL_ADP_S_I2C0,
PCI_DEVICE_ID_INTEL_ADP_S_I2C1,
PCI_DEVICE_ID_INTEL_ADP_S_I2C2,