intel/skylake: gpio macro adding - gpio output with term and 20k pd

This is also required for kunimitsu fab3 gpio settings.

BUG=None
BRANCH=None
TEST=Built and booted kunimitsu.

Change-Id: I61d71fe4576cd57d17f21aecb188cd5b7fdecca0
Signed-off-by: Patrick Georgi <patrick@georgi-clan.de>
Original-Commit-Id: f65c2618a47c71aad277fb2a11b17ade0a97e5f8
Original-Change-Id: Iebf272b5cc3e67ec35259f5b3e9041ab4cdaa207
Original-Signed-off-by: Robbie Zhang <robbie.zhang@intel.com>
Original-Reviewed-on: https://chromium-review.googlesource.com/294757
Original-Reviewed-by: Aaron Durbin <adurbin@chromium.org>
Reviewed-on: http://review.coreboot.org/11424
Tested-by: build bot (Jenkins)
Reviewed-by: Aaron Durbin <adurbin@chromium.org>
This commit is contained in:
robbie zhang 2015-08-21 09:39:55 -07:00 committed by Patrick Georgi
parent 7a2defb2dd
commit 1f79be1f52
2 changed files with 8 additions and 3 deletions

View File

@ -113,12 +113,16 @@ void gpio_configure_pads(const struct pad_config *cfgs, size_t num);
_PAD_CFG(pad_, term_, \ _PAD_CFG(pad_, term_, \
_DW0_VALS(rst_, RAW, NO, LEVEL, NO, NO, NO, NO, NO, NO, func_, NO, NO)) _DW0_VALS(rst_, RAW, NO, LEVEL, NO, NO, NO, NO, NO, NO, func_, NO, NO))
/* General purpose output. By default no termination. */ /* General purpose output with termination. */
#define PAD_CFG_GPO(pad_, val_, rst_) \ #define PAD_CFG_TERM_GPO(pad_, val_, term_, rst_) \
_PAD_CFG(pad_, NONE, \ _PAD_CFG(pad_, term_, \
_DW0_VALS(rst_, RAW, NO, LEVEL, NO, NO, NO, NO, NO, NO, GPIO, YES, NO) \ _DW0_VALS(rst_, RAW, NO, LEVEL, NO, NO, NO, NO, NO, NO, GPIO, YES, NO) \
| PAD_FIELD_VAL(GPIOTXSTATE, val_)) | PAD_FIELD_VAL(GPIOTXSTATE, val_))
/* General purpose output. By default no termination. */
#define PAD_CFG_GPO(pad_, val_, rst_) \
PAD_CFG_TERM_GPO(pad_, val_, NONE, rst_)
/* General purpose input with no special IRQ routing. */ /* General purpose input with no special IRQ routing. */
#define PAD_CFG_GPI(pad_, term_, rst_) \ #define PAD_CFG_GPI(pad_, term_, rst_) \
_PAD_CFG_ATTRS(pad_, term_, \ _PAD_CFG_ATTRS(pad_, term_, \

View File

@ -492,6 +492,7 @@
#define PAD_TERM_MASK 0xf #define PAD_TERM_MASK 0xf
#define PAD_TERM_NONE 0 #define PAD_TERM_NONE 0
#define PAD_TERM_5K_PD 2 #define PAD_TERM_5K_PD 2
#define PAD_TERM_20K_PD 4
#define PAD_TERM_1K_PU 9 #define PAD_TERM_1K_PU 9
#define PAD_TERM_2K_PU 11 #define PAD_TERM_2K_PU 11
#define PAD_TERM_5K_PU 10 #define PAD_TERM_5K_PU 10