aboutsummaryrefslogtreecommitdiff
path: root/src/soc/intel/icelake/gpio.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/soc/intel/icelake/gpio.c')
-rw-r--r--src/soc/intel/icelake/gpio.c21
1 files changed, 15 insertions, 6 deletions
diff --git a/src/soc/intel/icelake/gpio.c b/src/soc/intel/icelake/gpio.c
index b1c46abe29..96c5c838ad 100644
--- a/src/soc/intel/icelake/gpio.c
+++ b/src/soc/intel/icelake/gpio.c
@@ -76,8 +76,9 @@ static const struct pad_group icl_community5_groups[] = {
INTEL_GPP_BASE(GPP_C0, GPP_S0, GPP_S7, 320), /* GPP_S */
};
-static const struct pad_community icl_communities[] = {
- { /* GPP G, B, A */
+static const struct pad_community icl_communities[TOTAL_GPIO_COMM] = {
+ /* GPP G, B, A */
+ [COMM_0] = {
.port = PID_GPIOCOM0,
.first_pad = GPP_G0,
.last_pad = GPP_A23,
@@ -95,7 +96,9 @@ static const struct pad_community icl_communities[] = {
.num_reset_vals = ARRAY_SIZE(rst_map_com0),
.groups = icl_community0_groups,
.num_groups = ARRAY_SIZE(icl_community0_groups),
- }, { /* GPP H, D, F */
+ },
+ /* GPP H, D, F */
+ [COMM_1] = {
.port = PID_GPIOCOM1,
.first_pad = GPP_H0,
.last_pad = GPP_F19,
@@ -113,7 +116,9 @@ static const struct pad_community icl_communities[] = {
.num_reset_vals = ARRAY_SIZE(rst_map),
.groups = icl_community1_groups,
.num_groups = ARRAY_SIZE(icl_community1_groups),
- }, { /* GPD */
+ },
+ /* GPD */
+ [COMM_2] = {
.port = PID_GPIOCOM2,
.first_pad = GPD0,
.last_pad = GPD11,
@@ -131,7 +136,9 @@ static const struct pad_community icl_communities[] = {
.num_reset_vals = ARRAY_SIZE(rst_map),
.groups = icl_community2_groups,
.num_groups = ARRAY_SIZE(icl_community2_groups),
- }, { /* GPP C, E */
+ },
+ /* GPP C, E */
+ [COMM_3] = {
.port = PID_GPIOCOM4,
.first_pad = GPP_C0,
.last_pad = GPP_E23,
@@ -149,7 +156,9 @@ static const struct pad_community icl_communities[] = {
.num_reset_vals = ARRAY_SIZE(rst_map),
.groups = icl_community4_groups,
.num_groups = ARRAY_SIZE(icl_community4_groups),
- }, { /* GPP R, S */
+ },
+ /* GPP R, S */
+ [COMM_4] = {
.port = PID_GPIOCOM5,
.first_pad = GPP_R0,
.last_pad = GPP_S7,