soc/amd/common/block/gpio_defs: Support wake and debounce configuration
Add a pad configuration macro to support configuring both wake and debounce. This support is required by Pen Detect GPIO. BUG=b:180539900 TEST=Build Guybrush mainboard. Change-Id: I3343a4e80fd5aa3047d76ff9f91ea57c3763bbca Signed-off-by: Karthikeyan Ramasubramanian <kramasub@google.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/51680 Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Marshall Dawson <marshalldawson3rd@gmail.com> Reviewed-by: Mathew King <mathewk@chromium.org> Reviewed-by: Furquan Shaikh <furquan@google.com>
This commit is contained in:
parent
76def38abb
commit
c3c7f8fc60
|
@ -241,6 +241,12 @@
|
|||
PAD_CFG_STRUCT(pin, pin ## _IOMUX_GPIOxx, \
|
||||
PAD_PULL(pull) | PAD_DEBOUNCE_CONFIG(type) | PAD_DEBOUNCE_CONFIG(time))
|
||||
|
||||
/* Wake + debounce configuration */
|
||||
#define PAD_WAKE_DEBOUNCE(pin, pull, trigger, waketype, debtype, time) \
|
||||
PAD_CFG_STRUCT(pin, pin ## _IOMUX_GPIOxx, \
|
||||
PAD_PULL(pull) | PAD_TRIGGER(trigger) | PAD_WAKE_ENABLE(waketype) | \
|
||||
PAD_DEBOUNCE_CONFIG(debtype) | PAD_DEBOUNCE_CONFIG(time))
|
||||
|
||||
/* No-connect pad - configured as input with PULL_DOWN */
|
||||
#define PAD_NC(pin) \
|
||||
PAD_CFG_STRUCT(pin, pin ## _IOMUX_GPIOxx, PAD_PULL(PULL_DOWN))
|
||||
|
|
Loading…
Reference in New Issue