@@ -529,33 +529,25 @@ static int gpio_ite_init(const struct device *dev)
529529 return 0 ;
530530}
531531
532- #define GPIO_ITE_DEV_CFG_DATA (inst ) \
533- static struct gpio_ite_data gpio_ite_data_##inst; \
534- static const struct gpio_ite_cfg gpio_ite_cfg_##inst = { \
535- .common = { \
536- .port_pin_mask = \
537- GPIO_PORT_PIN_MASK_FROM_DT_INST(inst) \
538- }, \
539- .reg_gpdr = DT_INST_REG_ADDR_BY_IDX(inst, 0), \
540- .reg_gpdmr = DT_INST_REG_ADDR_BY_IDX(inst, 1), \
541- .reg_gpotr = DT_INST_REG_ADDR_BY_IDX(inst, 2), \
542- .reg_p18scr = DT_INST_REG_ADDR_BY_IDX(inst, 3), \
543- .reg_gpcr = DT_INST_REG_ADDR_BY_IDX(inst, 4), \
544- .wuc_base = DT_INST_PROP_OR(inst, wuc_base, {0}), \
545- .wuc_mask = DT_INST_PROP_OR(inst, wuc_mask, {0}), \
546- .gpio_irq = IT8XXX2_DT_GPIO_IRQ_LIST(inst), \
547- .has_volt_sel = DT_INST_PROP_OR(inst, has_volt_sel, {0}), \
548- .num_pins = DT_INST_PROP(inst, ngpios), \
549- .kbs_ctrl = DT_INST_PROP_OR(inst, keyboard_controller, 0), \
550- }; \
551- DEVICE_DT_INST_DEFINE(inst, \
552- gpio_ite_init, \
553- NULL, \
554- &gpio_ite_data_##inst, \
555- &gpio_ite_cfg_##inst, \
556- PRE_KERNEL_1, \
557- CONFIG_GPIO_INIT_PRIORITY, \
558- &gpio_ite_driver_api);
532+ #define GPIO_ITE_DEV_CFG_DATA (inst ) \
533+ static struct gpio_ite_data gpio_ite_data_##inst; \
534+ static const struct gpio_ite_cfg gpio_ite_cfg_##inst = { \
535+ .common = {.port_pin_mask = GPIO_PORT_PIN_MASK_FROM_DT_INST(inst)}, \
536+ .reg_gpdr = DT_INST_REG_ADDR_BY_IDX(inst, 0), \
537+ .reg_gpdmr = DT_INST_REG_ADDR_BY_IDX(inst, 1), \
538+ .reg_gpotr = DT_INST_REG_ADDR_BY_IDX(inst, 2), \
539+ .reg_p18scr = DT_INST_REG_ADDR_BY_IDX(inst, 3), \
540+ .reg_gpcr = DT_INST_REG_ADDR_BY_IDX(inst, 4), \
541+ .wuc_base = DT_INST_PROP_OR(inst, wuc_base, {0}), \
542+ .wuc_mask = DT_INST_PROP_OR(inst, wuc_mask, {0}), \
543+ .gpio_irq = IT8XXX2_DT_GPIO_IRQ_LIST(inst), \
544+ .has_volt_sel = DT_INST_PROP_OR(inst, has_volt_sel, {0}), \
545+ .num_pins = DT_INST_PROP(inst, ngpios), \
546+ .kbs_ctrl = DT_INST_PROP_OR(inst, keyboard_controller, 0), \
547+ }; \
548+ DEVICE_DT_INST_DEFINE(inst, gpio_ite_init, NULL, &gpio_ite_data_##inst, \
549+ &gpio_ite_cfg_##inst, PRE_KERNEL_1, CONFIG_GPIO_INIT_PRIORITY, \
550+ &gpio_ite_driver_api);
559551
560552DT_INST_FOREACH_STATUS_OKAY (GPIO_ITE_DEV_CFG_DATA )
561553
0 commit comments