|
20 | 20 | * Entries will be NULL if the GPIO port is not enabled.
|
21 | 21 | */
|
22 | 22 | static GPIO_PRT_Type *const gpio_ports[] = {
|
23 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt0)), |
24 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt1)), |
25 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt2)), |
26 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt3)), |
27 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt4)), |
28 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt5)), |
29 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt6)), |
30 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt7)), |
31 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt8)), |
32 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt9)), |
33 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt10)), |
34 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt11)), |
35 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt12)), |
36 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt13)), |
37 |
| - GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt14)) |
38 |
| -}; |
| 23 | + GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt0)), GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt1)), |
| 24 | + GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt2)), GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt3)), |
| 25 | + GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt4)), GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt5)), |
| 26 | + GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt6)), GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt7)), |
| 27 | + GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt8)), GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt9)), |
| 28 | + GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt10)), GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt11)), |
| 29 | + GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt12)), GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt13)), |
| 30 | + GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt14)), GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt15)), |
| 31 | + GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt16)), GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt17)), |
| 32 | + GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt18)), GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt19)), |
| 33 | + GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt20)), GPIO_PORT_OR_NULL(DT_NODELABEL(gpio_prt21))}; |
39 | 34 |
|
40 | 35 | /* @brief This function returns gpio drive mode, according to.
|
41 | 36 | * bias and drive mode params defined in pinctrl node.
|
@@ -99,7 +94,11 @@ int pinctrl_configure_pins(const pinctrl_soc_pin_t *pins, uint8_t pin_cnt, uintp
|
99 | 94 | uint32_t pin_num = CAT1_PINMUX_GET_PIN_NUM(pins[i].pinmux);
|
100 | 95 |
|
101 | 96 | /* Initialize pin */
|
| 97 | +#if defined(COMPONENT_SECURE_DEVICE) || defined(CY_PDL_TZ_ENABLED) |
| 98 | + Cy_GPIO_Pin_SecFastInit(gpio_ports[port_num], pin_num, drv_mode, 1, hsiom); |
| 99 | +#else |
102 | 100 | Cy_GPIO_Pin_FastInit(gpio_ports[port_num], pin_num, drv_mode, 1, hsiom);
|
| 101 | +#endif /* defined(CY_PDL_TZ_ENABLED) */ |
103 | 102 |
|
104 | 103 | /* Force output to enable pulls */
|
105 | 104 | switch (drv_mode) {
|
|
0 commit comments