diff options
author | Li Cheng Sooi <li.cheng.sooi@intel.com> | 2017-02-24 02:52:13 +0800 |
---|---|---|
committer | Aaron Durbin <adurbin@chromium.org> | 2017-03-09 16:41:18 +0100 |
commit | 75d8d8da47a3cc759d7395f5b0ef91ba13a59e51 (patch) | |
tree | 573ef1a93871c9122f806039df97a2b91318fa76 /src/soc | |
parent | 6a740539d1005eb14d21da40d7d14ff7250da508 (diff) |
soc/intel/skylake: Add GPIO macros for IOxAPIC and SCI
Add two GPIO macros:
1. PAD_CFG_GPI_APIC_EDGE allows a pin to be route to the
APIC with input assuming the events are edge triggered.
2. PAD_CFG_GPI_ACPI_SCI_LEVEL to route the general purpose
input to SCI assuming the events are level triggered.
Change-Id: I944a9abac66b7780b2336148ae8c7fa3a8410f3f
Signed-off-by: Rahul Kumar Gupta <rahul.kumarxx.gupta@intel.com>
Reviewed-on: https://review.coreboot.org/18533
Tested-by: build bot (Jenkins)
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-by: Paul Menzel <paulepanter@users.sourceforge.net>
Diffstat (limited to 'src/soc')
-rw-r--r-- | src/soc/intel/skylake/include/soc/gpio.h | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/src/soc/intel/skylake/include/soc/gpio.h b/src/soc/intel/skylake/include/soc/gpio.h index 75d8abe63a..c0e37db91e 100644 --- a/src/soc/intel/skylake/include/soc/gpio.h +++ b/src/soc/intel/skylake/include/soc/gpio.h @@ -152,12 +152,23 @@ void gpio_configure_pads(const struct pad_config *cfgs, size_t num); _DW0_VALS(rst_, RAW, NO, LEVEL, NO, YES, YES, NO, NO, NO, GPIO, NO, \ YES)) +/* General purpose input passed through to IOxAPIC. This assumes edge + * triggered events. */ +#define PAD_CFG_GPI_APIC_EDGE(pad_, term_, rst_) \ + _PAD_CFG(pad_, term_, \ + _DW0_VALS(rst_, RAW, NO, EDGE, NO, NO, YES, NO, NO, NO, GPIO, NO, YES)) + /* General purpose input routed to SCI. This assumes edge triggered events. */ #define PAD_CFG_GPI_ACPI_SCI(pad_, term_, rst_, inv_) \ _PAD_CFG_ATTRS(pad_, term_, \ _DW0_VALS(rst_, RAW, NO, EDGE, NO, inv_, \ NO, YES, NO, NO, GPIO, NO, YES), PAD_FIELD(HOSTSW, ACPI)) +#define PAD_CFG_GPI_ACPI_SCI_LEVEL(pad_, term_, rst_, inv_) \ + _PAD_CFG_ATTRS(pad_, term_, \ + _DW0_VALS(rst_, RAW, NO, LEVEL, NO, inv_, \ + NO, YES, NO, NO, GPIO, NO, YES), PAD_FIELD(HOSTSW, ACPI)) + /* General purpose input routed to SMI. This assumes edge triggered events. */ #define PAD_CFG_GPI_ACPI_SMI(pad_, term_, rst_, inv_) \ _PAD_CFG_ATTRS(pad_, term_, \ |