diff --git a/boards/arm/frdm_k22f/pinmux.c b/boards/arm/frdm_k22f/pinmux.c index 2c7343167aa..1342f91df9d 100644 --- a/boards/arm/frdm_k22f/pinmux.c +++ b/boards/arm/frdm_k22f/pinmux.c @@ -54,26 +54,11 @@ static int frdm_k22f_pinmux_init(const struct device *dev) pinmux_pin_set(portd, 3, PORT_PCR_MUX(kPORT_MuxAlt3)); #endif - /* SW2 */ - pinmux_pin_set(portc, 1, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* SW3 */ - pinmux_pin_set(portb, 17, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* FXOS8700 INT1 */ - pinmux_pin_set(portd, 0, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* FXOS8700 INT2 */ - pinmux_pin_set(portd, 1, PORT_PCR_MUX(kPORT_MuxAsGpio)); - #if DT_NODE_HAS_COMPAT_STATUS(DT_NODELABEL(ftm0), nxp_kinetis_ftm_pwm, okay) && CONFIG_PWM /* Red, green, blue LEDs as PWM channels*/ pinmux_pin_set(porta, 1, PORT_PCR_MUX(kPORT_MuxAlt3)); pinmux_pin_set(porta, 2, PORT_PCR_MUX(kPORT_MuxAlt3)); pinmux_pin_set(portd, 5, PORT_PCR_MUX(kPORT_MuxAlt4)); -#else - /* Red, green, blue LEDs as GPIO channels*/ - pinmux_pin_set(porta, 1, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porta, 2, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portd, 5, PORT_PCR_MUX(kPORT_MuxAsGpio)); #endif #if DT_NODE_HAS_STATUS(DT_NODELABEL(spi0), okay) && CONFIG_SPI @@ -92,18 +77,6 @@ static int frdm_k22f_pinmux_init(const struct device *dev) | PORT_PCR_ODE_MASK); #endif -#if CONFIG_SHIELD_FRDM_STBC_AGM01 - /* FXOS8700 INT1 */ - pinmux_pin_set(portb, 16, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* FXOS8700 INT2 */ - pinmux_pin_set(porta, 4, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* FXAS21002 INT1 */ - pinmux_pin_set(portb, 18, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* FXAS21002 INT2 */ - pinmux_pin_set(portb, 19, PORT_PCR_MUX(kPORT_MuxAsGpio)); -#endif - return 0; } diff --git a/boards/arm/frdm_k64f/pinmux.c b/boards/arm/frdm_k64f/pinmux.c index 26013416cf7..1636231e422 100644 --- a/boards/arm/frdm_k64f/pinmux.c +++ b/boards/arm/frdm_k64f/pinmux.c @@ -57,54 +57,6 @@ static int frdm_k64f_pinmux_init(const struct device *dev) pinmux_pin_set(portc, 16, PORT_PCR_MUX(kPORT_MuxAlt3)); pinmux_pin_set(portc, 17, PORT_PCR_MUX(kPORT_MuxAlt3)); #endif - /* SW2 / FXOS8700 INT1 */ - pinmux_pin_set(portc, 6, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* FXOS8700 INT2 */ - pinmux_pin_set(portc, 13, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* SW3 */ - pinmux_pin_set(porta, 4, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* Red, green, blue LEDs */ - pinmux_pin_set(portb, 22, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porte, 26, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portb, 21, PORT_PCR_MUX(kPORT_MuxAsGpio)); - -#ifdef CONFIG_MODEM_WNCM14A2A - /* WNC-M14A2A Modem POWER_ON */ - pinmux_pin_set(portb, 9, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* WNC-M14A2A Shield PMOD_D1 */ - pinmux_pin_set(portb, 10, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* WNC-M14A2A Shield PMOD_D2 */ - pinmux_pin_set(portb, 11, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* WNC-M14A2A Modem WWAN_STATE */ - pinmux_pin_set(portb, 23, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* WNC-M14A2A Modem WAKEUP_ENABLE */ - pinmux_pin_set(portc, 2, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* WNC-M14A2A Modem HTS221_DRDY */ - pinmux_pin_set(portc, 3, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* WNC-M14A2A Shield LEVEL_TRANSFORM_ENABLE */ - pinmux_pin_set(portc, 4, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* WNC-M14A2A Modem RESET */ - pinmux_pin_set(portc, 12, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* WNC-M14A2A Modem BOOT_MODE_SELECT */ - pinmux_pin_set(portc, 17, PORT_PCR_MUX(kPORT_MuxAsGpio)); -#endif - -#ifdef CONFIG_MODEM_UBLOX_SARA_R4 - /* Modem RESET */ - pinmux_pin_set(portc, 2, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* Modem POWER_ON */ - pinmux_pin_set(porta, 2, PORT_PCR_MUX(kPORT_MuxAsGpio)); -#endif - -#ifdef CONFIG_IEEE802154_MCR20A - /* FRDM-MCR20A Reset (D5) */ - pinmux_pin_set(porta, 2, PORT_PCR_MUX(kPORT_MuxAsGpio)); - /* FRDM-MCR20A IRQ_B (D2) */ - pinmux_pin_set(portb, 9, PORT_PCR_MUX(kPORT_MuxAsGpio)); -#endif #if DT_NODE_HAS_STATUS(DT_NODELABEL(spi0), okay) && CONFIG_SPI /* SPI0 CS0, SCK, SOUT, SIN */ @@ -164,18 +116,6 @@ static int frdm_k64f_pinmux_init(const struct device *dev) PORT_PCR_PE_MASK | PORT_PCR_PS_MASK); #endif -#if CONFIG_SHIELD_ADAFRUIT_2_8_TFT_TOUCH_V2 - pinmux_pin_set(portb, 23, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 4, PORT_PCR_MUX(kPORT_MuxAsGpio)); -#endif - -#if CONFIG_SHIELD_ADAFRUIT_WINC1500 - /* IRQ, ENable, RST */ - pinmux_pin_set(portc, 3, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 2, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porta, 2, PORT_PCR_MUX(kPORT_MuxAsGpio)); -#endif - return 0; } diff --git a/boards/arm/frdm_k82f/pinmux.c b/boards/arm/frdm_k82f/pinmux.c index ba49234847f..8ab0d5fd647 100644 --- a/boards/arm/frdm_k82f/pinmux.c +++ b/boards/arm/frdm_k82f/pinmux.c @@ -43,20 +43,8 @@ static int frdm_k82f_pinmux_init(const struct device *dev) pinmux_pin_set(portc, 8, PORT_PCR_MUX(kPORT_MuxAlt3)); pinmux_pin_set(portc, 9, PORT_PCR_MUX(kPORT_MuxAlt3)); pinmux_pin_set(portc, 10, PORT_PCR_MUX(kPORT_MuxAlt4)); -#else - /* Red, green, blue LEDs as GPIOs */ - pinmux_pin_set(portc, 8, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 9, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 10, PORT_PCR_MUX(kPORT_MuxAsGpio)); #endif - /* Buttons */ - pinmux_pin_set(porta, 4, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 6, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* FXOS8700 INT1 */ - pinmux_pin_set(portc, 13, PORT_PCR_MUX(kPORT_MuxAsGpio)); - #if DT_NODE_HAS_STATUS(DT_NODELABEL(i2c3), okay) && CONFIG_I2C /* I2C3 SDA, SCL */ pinmux_pin_set(porta, 1, PORT_PCR_MUX(kPORT_MuxAlt4) @@ -71,9 +59,6 @@ static int frdm_k82f_pinmux_init(const struct device *dev) pinmux_pin_set(porte, 2, PORT_PCR_MUX(kPORT_MuxAlt2)); pinmux_pin_set(porte, 4, PORT_PCR_MUX(kPORT_MuxAlt2)); pinmux_pin_set(porte, 5, PORT_PCR_MUX(kPORT_MuxAlt2)); - /* SPI1 NOR RESET, WP */ - pinmux_pin_set(porte, 0, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porte, 3, PORT_PCR_MUX(kPORT_MuxAsGpio)); #endif #if DT_NODE_HAS_STATUS(DT_NODELABEL(lpuart4), okay) && CONFIG_SERIAL diff --git a/boards/arm/frdm_kl25z/pinmux.c b/boards/arm/frdm_kl25z/pinmux.c index 691738c5964..8ecd70c62a9 100644 --- a/boards/arm/frdm_kl25z/pinmux.c +++ b/boards/arm/frdm_kl25z/pinmux.c @@ -44,19 +44,6 @@ static int frdm_kl25z_pinmux_init(const struct device *dev) pinmux_pin_set(porta, 2, PORT_PCR_MUX(kPORT_MuxAlt2)); #endif - /* SW0 and SW1 */ - pinmux_pin_set(porta, 16, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porta, 17, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* Red, green, blue LEDs. */ - pinmux_pin_set(portd, 1, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portb, 18, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portb, 19, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* MMA8451 INT1, INT2 */ - pinmux_pin_set(porta, 14, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porta, 15, PORT_PCR_MUX(kPORT_MuxAsGpio)); - #if DT_NODE_HAS_STATUS(DT_NODELABEL(i2c0), okay) && CONFIG_I2C /* I2C0 SCL, SDA */ pinmux_pin_set(porte, 24, PORT_PCR_MUX(kPORT_MuxAlt5) diff --git a/boards/arm/frdm_kw41z/pinmux.c b/boards/arm/frdm_kw41z/pinmux.c index beb0a48e086..94d9cc1b263 100644 --- a/boards/arm/frdm_kw41z/pinmux.c +++ b/boards/arm/frdm_kw41z/pinmux.c @@ -33,16 +33,11 @@ static int frdm_kw41z_pinmux_init(const struct device *dev) */ #if defined(CONFIG_PWM) && DT_NODE_HAS_STATUS(DT_NODELABEL(tpm0), okay) pinmux_pin_set(portc, 1, PORT_PCR_MUX(kPORT_MuxAlt5)); -#else - pinmux_pin_set(portc, 1, PORT_PCR_MUX(kPORT_MuxAsGpio)); #endif #if defined(CONFIG_PWM) && DT_NODE_HAS_STATUS(DT_NODELABEL(tpm2), okay) pinmux_pin_set(porta, 19, PORT_PCR_MUX(kPORT_MuxAlt5)); pinmux_pin_set(porta, 18, PORT_PCR_MUX(kPORT_MuxAlt5)); -#else - pinmux_pin_set(porta, 19, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porta, 18, PORT_PCR_MUX(kPORT_MuxAsGpio)); #endif #if DT_NODE_HAS_STATUS(DT_NODELABEL(i2c1), okay) && CONFIG_I2C @@ -58,10 +53,6 @@ static int frdm_kw41z_pinmux_init(const struct device *dev) pinmux_pin_set(portb, 2, PORT_PCR_MUX(kPORT_PinDisabledOrAnalog)); #endif - /* SW3, SW4 */ - pinmux_pin_set(portc, 4, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 5, PORT_PCR_MUX(kPORT_MuxAsGpio)); - #if DT_NODE_HAS_STATUS(DT_NODELABEL(lpuart0), okay) && CONFIG_SERIAL /* UART0 RX, TX */ pinmux_pin_set(portc, 6, PORT_PCR_MUX(kPORT_MuxAlt4)); diff --git a/boards/arm/hexiwear_k64/pinmux.c b/boards/arm/hexiwear_k64/pinmux.c index 38a0921c67c..aa1c8a95934 100644 --- a/boards/arm/hexiwear_k64/pinmux.c +++ b/boards/arm/hexiwear_k64/pinmux.c @@ -39,11 +39,6 @@ static int hexiwear_k64_pinmux_init(const struct device *dev) pinmux_pin_set(portc, 8, PORT_PCR_MUX(kPORT_MuxAlt3)); pinmux_pin_set(portc, 9, PORT_PCR_MUX(kPORT_MuxAlt3)); pinmux_pin_set(portd, 0, PORT_PCR_MUX(kPORT_MuxAlt4)); -#else - /* Red, green, blue LEDs as GPIOs */ - pinmux_pin_set(portc, 8, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 9, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portd, 0, PORT_PCR_MUX(kPORT_MuxAsGpio)); #endif #if DT_NODE_HAS_STATUS(DT_NODELABEL(i2c0), okay) && CONFIG_I2C @@ -53,9 +48,6 @@ static int hexiwear_k64_pinmux_init(const struct device *dev) pinmux_pin_set(portb, 1, PORT_PCR_MUX(kPORT_MuxAlt2) | PORT_PCR_ODE_MASK); - /* 3V3B_EN */ - pinmux_pin_set(portb, 12, PORT_PCR_MUX(kPORT_MuxAsGpio)); - const struct device *gpiob = device_get_binding(DT_LABEL(DT_NODELABEL(gpiob))); @@ -69,11 +61,6 @@ static int hexiwear_k64_pinmux_init(const struct device *dev) pinmux_pin_set(portc, 11, PORT_PCR_MUX(kPORT_MuxAlt2) | PORT_PCR_ODE_MASK); #endif - /* FXAS21002 INT2 */ - pinmux_pin_set(portc, 18, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* FXOS8700 INT2 */ - pinmux_pin_set(portd, 13, PORT_PCR_MUX(kPORT_MuxAsGpio)); #if DT_NODE_HAS_STATUS(DT_NODELABEL(uart0), okay) && CONFIG_SERIAL /* UART0 RX, TX */ @@ -88,13 +75,6 @@ static int hexiwear_k64_pinmux_init(const struct device *dev) #endif #if defined(CONFIG_MAX30101) && DT_NODE_HAS_STATUS(DT_NODELABEL(gpioa), okay) - const struct device *porta = - DEVICE_DT_GET(DT_NODELABEL(porta)); - __ASSERT_NO_MSG(device_is_ready(porta)); - - /* LDO - MAX30101 power supply */ - pinmux_pin_set(porta, 29, PORT_PCR_MUX(kPORT_MuxAsGpio)); - const struct device *gpioa = device_get_binding(DT_LABEL(DT_NODELABEL(gpioa))); @@ -102,8 +82,6 @@ static int hexiwear_k64_pinmux_init(const struct device *dev) #endif #ifdef CONFIG_BATTERY_SENSE - pinmux_pin_set(portc, 14, PORT_PCR_MUX(kPORT_MuxAsGpio)); - const struct device *gpioc = device_get_binding(DT_LABEL(DT_NODELABEL(gpioc))); diff --git a/boards/arm/ip_k66f/pinmux.c b/boards/arm/ip_k66f/pinmux.c index 7bb19c7c012..c7399b29e86 100644 --- a/boards/arm/ip_k66f/pinmux.c +++ b/boards/arm/ip_k66f/pinmux.c @@ -38,10 +38,6 @@ static int ip_k66f_pinmux_init(const struct device *dev) __ASSERT_NO_MSG(device_is_ready(porte)); #endif - /* Red0, Red2 LEDs */ - pinmux_pin_set(porta, 8, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porta, 10, PORT_PCR_MUX(kPORT_MuxAsGpio)); - #if DT_NODE_HAS_STATUS(DT_NODELABEL(enet), okay) && CONFIG_NET_L2_ETHERNET pinmux_pin_set(porta, 12, PORT_PCR_MUX(kPORT_MuxAlt4));/* RMII_RXD1 */ pinmux_pin_set(porta, 13, PORT_PCR_MUX(kPORT_MuxAlt4));/* RMII_RXD0 */ @@ -49,9 +45,6 @@ static int ip_k66f_pinmux_init(const struct device *dev) pinmux_pin_set(porta, 15, PORT_PCR_MUX(kPORT_MuxAlt4));/* RMII_RX_EN */ pinmux_pin_set(porta, 16, PORT_PCR_MUX(kPORT_MuxAlt4));/* RMII_TXD0 */ pinmux_pin_set(porta, 17, PORT_PCR_MUX(kPORT_MuxAlt4));/* RMII_TXD1 */ - pinmux_pin_set(porta, 24, PORT_PCR_MUX(kPORT_MuxAsGpio));/* !ETH_RST */ - pinmux_pin_set(porta, 25, PORT_PCR_MUX(kPORT_MuxAsGpio));/* !ETH_PME */ - pinmux_pin_set(porta, 26, PORT_PCR_MUX(kPORT_MuxAsGpio));/* !ETH_INT */ #if DT_NODE_HAS_STATUS(DT_NODELABEL(porte), okay) /* RMII_REF_CLK */ pinmux_pin_set(porte, 26, PORT_PCR_MUX(kPORT_MuxAlt2)); diff --git a/boards/arm/twr_ke18f/pinmux.c b/boards/arm/twr_ke18f/pinmux.c index b4f61e9c254..d4a9b5574ca 100644 --- a/boards/arm/twr_ke18f/pinmux.c +++ b/boards/arm/twr_ke18f/pinmux.c @@ -43,11 +43,6 @@ static int twr_ke18f_pinmux_init(const struct device *dev) pinmux_pin_set(portb, 5, PORT_PCR_MUX(kPORT_MuxAlt2)); pinmux_pin_set(portd, 15, PORT_PCR_MUX(kPORT_MuxAlt2)); pinmux_pin_set(portd, 16, PORT_PCR_MUX(kPORT_MuxAlt2)); -#else - /* Tri-color LED as GPIO */ - pinmux_pin_set(portb, 5, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portd, 15, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portd, 16, PORT_PCR_MUX(kPORT_MuxAsGpio)); #endif #if DT_NODE_HAS_COMPAT_STATUS(DT_NODELABEL(ftm2), nxp_kinetis_ftm_pwm, okay) && CONFIG_PWM @@ -61,12 +56,6 @@ static int twr_ke18f_pinmux_init(const struct device *dev) pinmux_pin_set(portc, 11, PORT_PCR_MUX(kPORT_MuxAlt2)); pinmux_pin_set(portc, 12, PORT_PCR_MUX(kPORT_MuxAlt2)); pinmux_pin_set(portc, 13, PORT_PCR_MUX(kPORT_MuxAlt2)); -#else - /* User LEDs as GPIO */ - pinmux_pin_set(portc, 10, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 11, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 12, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 13, PORT_PCR_MUX(kPORT_MuxAsGpio)); #endif #if DT_NODE_HAS_STATUS(DT_NODELABEL(pwt), okay) && CONFIG_PWM_CAPTURE @@ -74,10 +63,6 @@ static int twr_ke18f_pinmux_init(const struct device *dev) pinmux_pin_set(porte, 11, PORT_PCR_MUX(kPORT_MuxAlt2)); #endif - /* Buttons */ - pinmux_pin_set(portd, 3, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portd, 6, PORT_PCR_MUX(kPORT_MuxAsGpio)); - #if DT_NODE_HAS_STATUS(DT_NODELABEL(lpuart0), okay) && CONFIG_SERIAL /* UART0 RX, TX */ pinmux_pin_set(portb, 0, PORT_PCR_MUX(kPORT_MuxAlt2)); @@ -93,8 +78,6 @@ static int twr_ke18f_pinmux_init(const struct device *dev) #ifdef CONFIG_BOARD_TWR_KE18F_SPI_0_PCS2 /* SPI0 PCS2 */ pinmux_pin_set(porte, 6, PORT_PCR_MUX(kPORT_MuxAlt2)); -#else - pinmux_pin_set(porte, 6, PORT_PCR_MUX(kPORT_MuxAsGpio)); #endif #if DT_NODE_HAS_STATUS(DT_NODELABEL(lpspi1), okay) && CONFIG_SPI @@ -106,14 +89,10 @@ static int twr_ke18f_pinmux_init(const struct device *dev) #ifdef CONFIG_BOARD_TWR_KE18F_SPI_1_PCS0 /* SPI1 PCS0 */ pinmux_pin_set(portd, 3, PORT_PCR_MUX(kPORT_MuxAlt3)); -#else - pinmux_pin_set(portd, 3, PORT_PCR_MUX(kPORT_MuxAsGpio)); #endif #ifdef CONFIG_BOARD_TWR_KE18F_SPI_1_PCS2 /* SPI1 PCS2 */ pinmux_pin_set(porta, 16, PORT_PCR_MUX(kPORT_MuxAlt3)); -#else - pinmux_pin_set(porta, 16, PORT_PCR_MUX(kPORT_MuxAsGpio)); #endif #ifdef CONFIG_BOARD_TWR_KE18F_FLEXIO_CLKOUT @@ -139,15 +118,6 @@ static int twr_ke18f_pinmux_init(const struct device *dev) pinmux_pin_set(porte, 5, PORT_PCR_MUX(kPORT_MuxAlt5)); #endif - /* FXOS8700 INT1, INT2, RST */ -#if DT_NODE_HAS_PROP(DT_INST(0, nxp_fxos8700), int1_gpios) - pinmux_pin_set(porta, 14, PORT_PCR_MUX(kPORT_MuxAsGpio)); -#endif -#if DT_NODE_HAS_PROP(DT_INST(0, nxp_fxos8700), int2_gpios) - pinmux_pin_set(portc, 17, PORT_PCR_MUX(kPORT_MuxAsGpio)); -#endif - pinmux_pin_set(portc, 15, PORT_PCR_MUX(kPORT_MuxAsGpio)); - #if DT_NODE_HAS_STATUS(DT_NODELABEL(adc0), okay) && CONFIG_ADC /* Thermistor A, B */ pinmux_pin_set(porta, 0, PORT_PCR_MUX(kPORT_PinDisabledOrAnalog)); diff --git a/boards/arm/twr_kv58f220m/pinmux.c b/boards/arm/twr_kv58f220m/pinmux.c index b0573e38f6b..ca5031247d7 100644 --- a/boards/arm/twr_kv58f220m/pinmux.c +++ b/boards/arm/twr_kv58f220m/pinmux.c @@ -38,22 +38,6 @@ static int twr_kv58f220m_pinmux_init(const struct device *dev) __ASSERT_NO_MSG(device_is_ready(porte)); #endif - /* LEDs */ - pinmux_pin_set(porte, 11, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porte, 12, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porte, 29, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porte, 30, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* Buttons */ - pinmux_pin_set(porta, 4, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(porte, 4, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portb, 5, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portb, 4, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* FXOS8700 INT1, INT2 */ - pinmux_pin_set(portc, 18, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 19, PORT_PCR_MUX(kPORT_MuxAsGpio)); - #if DT_NODE_HAS_STATUS(DT_NODELABEL(i2c1), okay) && CONFIG_I2C /* I2C1 SCL, SDA */ pinmux_pin_set(portd, 8, PORT_PCR_MUX(kPORT_MuxAlt2) diff --git a/boards/arm/usb_kw24d512/pinmux.c b/boards/arm/usb_kw24d512/pinmux.c index dbbbbe8a2fa..fd23091163f 100644 --- a/boards/arm/usb_kw24d512/pinmux.c +++ b/boards/arm/usb_kw24d512/pinmux.c @@ -44,13 +44,6 @@ static int usb_kw24d512_pinmux_init(const struct device *dev) pinmux_pin_set(porta, 2, PORT_PCR_MUX(kPORT_MuxAlt2)); #endif - /* SW1 */ - pinmux_pin_set(portc, 4, PORT_PCR_MUX(kPORT_MuxAsGpio)); - - /* blue LEDs D2, D3 */ - pinmux_pin_set(portd, 4, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portd, 5, PORT_PCR_MUX(kPORT_MuxAsGpio)); - #if DT_NODE_HAS_STATUS(DT_NODELABEL(spi1), okay) && CONFIG_SPI /* SPI1 CS0, SCK, SOUT, SIN */ pinmux_pin_set(portb, 10, PORT_PCR_MUX(kPORT_MuxAlt2)); @@ -59,11 +52,6 @@ static int usb_kw24d512_pinmux_init(const struct device *dev) pinmux_pin_set(portb, 17, PORT_PCR_MUX(kPORT_MuxAlt2)); #endif -#ifdef CONFIG_IEEE802154_MCR20A - /* Reset, IRQ_B */ - pinmux_pin_set(portb, 19, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portb, 3, PORT_PCR_MUX(kPORT_MuxAsGpio)); -#endif return 0; } diff --git a/samples/net/cloud/tagoio_http_post/CMakeLists.txt b/samples/net/cloud/tagoio_http_post/CMakeLists.txt index f49ae336b2a..3c35c226d23 100644 --- a/samples/net/cloud/tagoio_http_post/CMakeLists.txt +++ b/samples/net/cloud/tagoio_http_post/CMakeLists.txt @@ -6,5 +6,4 @@ project(tagoio_http_post) target_sources(app PRIVATE src/main.c) target_sources(app PRIVATE src/sockets.c) -target_sources(app PRIVATE src/pinmux.c) target_sources_ifdef(CONFIG_WIFI app PRIVATE src/wifi.c) diff --git a/samples/net/cloud/tagoio_http_post/src/pinmux.c b/samples/net/cloud/tagoio_http_post/src/pinmux.c deleted file mode 100644 index 25170eca395..00000000000 --- a/samples/net/cloud/tagoio_http_post/src/pinmux.c +++ /dev/null @@ -1,30 +0,0 @@ -/* - * Copyright (c) 2020 Gerson Fernando Budke - * - * SPDX-License-Identifier: Apache-2.0 - */ - -#include -#include - -#if defined(CONFIG_BOARD_FRDM_K64F) -#include -#endif - -static int tagoio_pinmux_init(const struct device *dev) -{ - ARG_UNUSED(dev); - -#if defined(CONFIG_BOARD_FRDM_K64F) - const struct device *portc = DEVICE_DT_GET(DT_NODELABEL(portc)); - - __ASSERT_NO_MSG(device_is_ready(portc)); - - pinmux_pin_set(portc, 2, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(portc, 3, PORT_PCR_MUX(kPORT_MuxAsGpio)); -#endif - - return 0; -} - -SYS_INIT(tagoio_pinmux_init, POST_KERNEL, CONFIG_PINMUX_INIT_PRIORITY); diff --git a/tests/drivers/gpio/gpio_basic_api/src/main.c b/tests/drivers/gpio/gpio_basic_api/src/main.c index de82dedb50d..1d9fd2b8a5e 100644 --- a/tests/drivers/gpio/gpio_basic_api/src/main.c +++ b/tests/drivers/gpio/gpio_basic_api/src/main.c @@ -8,7 +8,7 @@ #include "test_gpio.h" /* Grotesque hack for pinmux boards */ -#if defined(CONFIG_BOARD_FRDM_K64F) || defined(CONFIG_BOARD_RV32M1_VEGA) +#if defined(CONFIG_BOARD_RV32M1_VEGA) #include #include #elif defined(CONFIG_BOARD_UDOO_NEO_FULL_M4) @@ -33,14 +33,7 @@ static void board_setup(void) } #endif -#if defined(CONFIG_BOARD_FRDM_K64F) - /* TODO figure out how to get this from "GPIO_2" */ - const char *pmx_name = "portc"; - const struct device *pmx = device_get_binding(pmx_name); - - pinmux_pin_set(pmx, PIN_OUT, PORT_PCR_MUX(kPORT_MuxAsGpio)); - pinmux_pin_set(pmx, PIN_IN, PORT_PCR_MUX(kPORT_MuxAsGpio)); -#elif defined(CONFIG_BOARD_UDOO_NEO_FULL_M4) +#if defined(CONFIG_BOARD_UDOO_NEO_FULL_M4) /* * Configure pin mux. * The following code needs to configure the same GPIOs which were