1 /* 2 * Copyright (c) 2019 Vestas Wind Systems A/S 3 * Copyright (c) 2022 NXP 4 * 5 * SPDX-License-Identifier: Apache-2.0 6 */ 7 8 #include <zephyr/init.h> 9 #include <zephyr/drivers/pinctrl.h> 10 twr_ke18f_pinmux_init(void)11static int twr_ke18f_pinmux_init(void) 12 { 13 14 int err; /* Used by pinctrl functions */ 15 16 /* Declare pin configuration state for flexio pin here */ 17 PINCTRL_DT_DEFINE(DT_NODELABEL(flexio)); 18 19 /* Apply pinctrl state directly, since there is no flexio device driver */ 20 err = pinctrl_apply_state(PINCTRL_DT_DEV_CONFIG_GET(DT_NODELABEL(flexio)), 21 PINCTRL_STATE_DEFAULT); 22 if (err) { 23 return err; 24 } 25 26 return 0; 27 } 28 29 SYS_INIT(twr_ke18f_pinmux_init, PRE_KERNEL_1, 0); 30