summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorSubrata Banik <subrata.banik@intel.com>2018-11-14 15:50:03 +0530
committerSubrata Banik <subrata.banik@intel.com>2018-11-17 09:37:19 +0000
commit8ad5a62de94c40aa5ad757d8a7238b029dafa959 (patch)
tree0dba32a4e404673621ae18c1f5bdd4e8f2a3f2e7 /src
parent990db2213f5e69974e6334f001aa847d1def718a (diff)
soc/intel/icelake: Make static IRQ mapping for PIC mode
This patch makes static PIRQ->IRQ mapping, where IRQ10 is mapped to PBRC and IRQ11 is mapped for PARC/PCRC/PDRC/PERC/PFRC/PGRC/PHRC. Change-Id: I9693f2a52529961e6b611b69e389f01f77f77d63 Signed-off-by: Subrata Banik <subrata.banik@intel.com> Reviewed-on: https://review.coreboot.org/29509 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Nico Huber <nico.h@gmx.de>
Diffstat (limited to 'src')
-rw-r--r--src/soc/intel/icelake/chip.h11
-rw-r--r--src/soc/intel/icelake/lpc.c26
2 files changed, 13 insertions, 24 deletions
diff --git a/src/soc/intel/icelake/chip.h b/src/soc/intel/icelake/chip.h
index 12daea50c6..cb06fcb06a 100644
--- a/src/soc/intel/icelake/chip.h
+++ b/src/soc/intel/icelake/chip.h
@@ -34,17 +34,6 @@ struct soc_intel_icelake_config {
/* Common struct containing soc config data required by common code */
struct soc_intel_common_config common_soc_config;
- /* Interrupt Routing configuration.
- * If bit7 is 1, the interrupt is disabled. */
- uint8_t pirqa_routing;
- uint8_t pirqb_routing;
- uint8_t pirqc_routing;
- uint8_t pirqd_routing;
- uint8_t pirqe_routing;
- uint8_t pirqf_routing;
- uint8_t pirqg_routing;
- uint8_t pirqh_routing;
-
/* GPE configuration */
uint32_t gpe0_en_1; /* GPE0_EN_31_0 */
uint32_t gpe0_en_2; /* GPE0_EN_63_32 */
diff --git a/src/soc/intel/icelake/lpc.c b/src/soc/intel/icelake/lpc.c
index 8859c5d473..93d543f444 100644
--- a/src/soc/intel/icelake/lpc.c
+++ b/src/soc/intel/icelake/lpc.c
@@ -28,6 +28,7 @@
#include <intelblocks/pcr.h>
#include <reg_script.h>
#include <soc/iomap.h>
+#include <soc/irq.h>
#include <soc/lpc.h>
#include <soc/pci_devs.h>
#include <soc/pcr_ids.h>
@@ -143,17 +144,16 @@ static void pch_enable_ioapic(const struct device *dev)
void soc_pch_pirq_init(const struct device *dev)
{
- const config_t *config = dev->chip_info;
uint8_t pch_interrupt_routing[MAX_PXRC_CONFIG];
- pch_interrupt_routing[0] = config->pirqa_routing;
- pch_interrupt_routing[1] = config->pirqb_routing;
- pch_interrupt_routing[2] = config->pirqc_routing;
- pch_interrupt_routing[3] = config->pirqd_routing;
- pch_interrupt_routing[4] = config->pirqe_routing;
- pch_interrupt_routing[5] = config->pirqf_routing;
- pch_interrupt_routing[6] = config->pirqg_routing;
- pch_interrupt_routing[7] = config->pirqh_routing;
+ pch_interrupt_routing[0] = PCH_IRQ11;
+ pch_interrupt_routing[1] = PCH_IRQ10;
+ pch_interrupt_routing[2] = PCH_IRQ11;
+ pch_interrupt_routing[3] = PCH_IRQ11;
+ pch_interrupt_routing[4] = PCH_IRQ11;
+ pch_interrupt_routing[5] = PCH_IRQ11;
+ pch_interrupt_routing[6] = PCH_IRQ11;
+ pch_interrupt_routing[7] = PCH_IRQ11;
itss_irq_init(pch_interrupt_routing);
#if defined(__SIMPLE_DEVICE__)
@@ -171,16 +171,16 @@ void soc_pch_pirq_init(const struct device *dev)
switch (int_pin) {
case 1: /* INTA# */
- int_line = config->pirqa_routing;
+ int_line = PCH_IRQ11;
break;
case 2: /* INTB# */
- int_line = config->pirqb_routing;
+ int_line = PCH_IRQ10;
break;
case 3: /* INTC# */
- int_line = config->pirqc_routing;
+ int_line = PCH_IRQ11;
break;
case 4: /* INTD# */
- int_line = config->pirqd_routing;
+ int_line = PCH_IRQ11;
break;
}