From a680b9b09cc8ea287124448c455e6e49a3fb5c9f Mon Sep 17 00:00:00 2001 From: Wojciech Sipak Date: Thu, 6 Jul 2023 12:18:50 +0200 Subject: [PATCH] boards: quick_feather: use pinctrl driver Pinmuxing was previously done in the board.c file. Now it is done by the pinctrl driver. Signed-off-by: Wojciech Sipak --- boards/arm/quick_feather/CMakeLists.txt | 5 ----- boards/arm/quick_feather/board.c | 23 ---------------------- boards/arm/quick_feather/board.h | 19 ------------------ boards/arm/quick_feather/quick_feather.dts | 14 +++++++++++++ 4 files changed, 14 insertions(+), 47 deletions(-) delete mode 100644 boards/arm/quick_feather/CMakeLists.txt delete mode 100644 boards/arm/quick_feather/board.c delete mode 100644 boards/arm/quick_feather/board.h diff --git a/boards/arm/quick_feather/CMakeLists.txt b/boards/arm/quick_feather/CMakeLists.txt deleted file mode 100644 index 77aee051c0c72ca..000000000000000 --- a/boards/arm/quick_feather/CMakeLists.txt +++ /dev/null @@ -1,5 +0,0 @@ -# Copyright (c) 2020 Antmicro -# SPDX-License-Identifier: Apache-2.0 - -zephyr_library_sources(board.c) -zephyr_include_directories(.) diff --git a/boards/arm/quick_feather/board.c b/boards/arm/quick_feather/board.c deleted file mode 100644 index cf89c208ced0dd0..000000000000000 --- a/boards/arm/quick_feather/board.c +++ /dev/null @@ -1,23 +0,0 @@ -/* - * Copyright (c) 2020 Antmicro - * - * SPDX-License-Identifier: Apache-2.0 - */ - -#include -#include -#include - -static int eos_s3_board_init(void) -{ - - /* IO MUX setup for UART */ - eos_s3_io_mux(UART_TX_PAD, UART_TX_PAD_CFG); - eos_s3_io_mux(UART_RX_PAD, UART_RX_PAD_CFG); - - IO_MUX->UART_rxd_SEL = UART_RX_SEL; - - return 0; -} - -SYS_INIT(eos_s3_board_init, PRE_KERNEL_1, CONFIG_BOARD_INIT_PRIORITY); diff --git a/boards/arm/quick_feather/board.h b/boards/arm/quick_feather/board.h deleted file mode 100644 index 857a6edd037270c..000000000000000 --- a/boards/arm/quick_feather/board.h +++ /dev/null @@ -1,19 +0,0 @@ -/* - * Copyright (c) 2020 Antmicro - * - * SPDX-License-Identifier: Apache-2.0 - */ - -#ifndef __INC_BOARD_H -#define __INC_BOARD_H - -#include - -#define UART_TX_PAD 44 -#define UART_TX_PAD_CFG UART_TXD_PAD44 -#define UART_RX_PAD 45 -#define UART_RX_PAD_CFG UART_RXD_PAD45 - -#define UART_RX_SEL UART_RXD_SEL_PAD45 - -#endif /* __INC_BOARD_H */ diff --git a/boards/arm/quick_feather/quick_feather.dts b/boards/arm/quick_feather/quick_feather.dts index 9bde6c938c3490d..2dc8053255a04ac 100644 --- a/boards/arm/quick_feather/quick_feather.dts +++ b/boards/arm/quick_feather/quick_feather.dts @@ -6,6 +6,7 @@ /dts-v1/; #include +#include / { model = "QuickLogic Quick Feather board"; @@ -56,6 +57,17 @@ }; }; +&pinctrl { + uart_rx_default: uart_rx_default { + pinmux = ; + input-enable; + }; + uart_tx_default: uart_tx_default { + pinmux = ; + output-enable; + }; +}; + &cpu0 { clock-frequency = <61440000>; }; @@ -67,4 +79,6 @@ &uart0 { status = "okay"; current-speed = <115200>; + pinctrl-0 = <&uart_rx_default &uart_tx_default>; + pinctrl-names = "default"; };