summaryrefslogtreecommitdiff
path: root/src/superio/ite/common/Kconfig
diff options
context:
space:
mode:
authorMichał Żygowski <michal.zygowski@3mdeb.com>2024-07-15 12:03:32 +0200
committerMichał Żygowski <michal.zygowski@3mdeb.com>2024-07-19 14:35:09 +0000
commitd1efb66be6fb79d2e22395d03dff269448b636b9 (patch)
treeab653f5201e9638e832486f0551713d3de2150f4 /src/superio/ite/common/Kconfig
parenteff64c675723c740381ebcbe904f513c5cb671c3 (diff)
superio/ite/common: Add common driver for GPIO and LED configuration
Add a generic driver to configure GPIOs and LEDs on common ITE SuperIOs. The driver supports most ITE SuperIOs, except Embedded Controllers. The driver allows configuring every GPIO property with pin granularity. Verified against datasheets of all ITE SIOs currently supported by coreboot, except IT8721F (assumed to be the same as IT8720F), IT8623E and IT8629E. Change-Id: If610d2809b56c63444c3406c26fad412c94136a5 Signed-off-by: Michał Żygowski <michal.zygowski@3mdeb.com> Reviewed-on: https://review.coreboot.org/c/coreboot/+/83355 Reviewed-by: Nicholas Sudsgaard <devel+coreboot@nsudsgaard.com> Tested-by: build bot (Jenkins) <no-reply@coreboot.org> Reviewed-by: Nico Huber <nico.h@gmx.de>
Diffstat (limited to 'src/superio/ite/common/Kconfig')
-rw-r--r--src/superio/ite/common/Kconfig27
1 files changed, 27 insertions, 0 deletions
diff --git a/src/superio/ite/common/Kconfig b/src/superio/ite/common/Kconfig
index 4701056bfa..c5eeec6c87 100644
--- a/src/superio/ite/common/Kconfig
+++ b/src/superio/ite/common/Kconfig
@@ -5,6 +5,33 @@
config SUPERIO_ITE_COMMON_PRE_RAM
bool
+config SUPERIO_ITE_COMMON_GPIO_PRE_RAM
+ bool
+ help
+ Enable generic pre-ram driver for configuring ITE SIO GPIOs.
+ It applies only to ITE SIOs not ITE ECs using LDN 7 (typically)
+ to configure GPIO Simple I/O mode.
+
+if SUPERIO_ITE_COMMON_GPIO_PRE_RAM
+
+config SUPERIO_ITE_COMMON_NUM_GPIO_SETS
+ int
+ help
+ The maximum number of GPIO sets supported by ITE SIO chip.
+ Each SIO chip must set this config option to a proper values
+ if it intends to enable SUPERIO_ITE_COMMON_GPIO_PRE_RAM.
+
+config SUPERIO_ITE_COMMON_GPIO_LED_FREQ_5BIT
+ bool
+ default n
+ help
+ Selected ITE SIOs control the GPIO LED frequency using 5 bits
+ instead of two. The LED register layout is also different for
+ these chips. Select this if the SIO GP LED Frequency control
+ field has 5 bits and support duty cycle as well.
+
+endif
+
# Generic ITE environment controller driver
config SUPERIO_ITE_ENV_CTRL
bool