boards: Migrate Renesas RA4M1 to the new configuration

Migrate to the new GPIO and Interrupt drivers based on FSP.

Signed-off-by: TOKITA Hiroshi <tokita.hiroshi@gmail.com>
This commit is contained in:
TOKITA Hiroshi 2025-02-06 06:46:54 +09:00 committed by Benjamin Cabé
commit 1ef5dfce63
8 changed files with 22 additions and 34 deletions

View file

@ -5,12 +5,14 @@
*/
/dts-v1/;
#include <renesas/ra/r7fa4m1ab3cfm.dtsi>
#include <renesas/ra/ra4/r7fa4m1ab3cfm.dtsi>
#include <zephyr/dt-bindings/gpio/gpio.h>
#include <zephyr/dt-bindings/adc/adc.h>
/ {
model = "Arduino Uno R4 Board";
compatible = "renesas,r7fa4m1ab3cfm";
compatible = "renesas,ra4m1", "renesas,ra";
chosen {
zephyr,console = &uart2;
@ -25,6 +27,9 @@
status = "okay";
pinctrl-0 = <&sci2_default>;
pinctrl-names = "default";
interrupts = <4 1>, <5 1>, <6 1>, <7 1>;
interrupt-names = "rxi", "txi", "tei", "eri";
uart2: uart {
current-speed = <115200>;
status = "okay";
@ -35,6 +40,16 @@
status = "okay";
};
&port_irq0 {
interrupts = <27 12>;
status = "okay";
};
&port_irq1 {
interrupts = <28 12>;
status = "okay";
};
&flash0 {
partitions {
compatible = "fixed-partitions";
@ -55,10 +70,6 @@
};
};
&fcu {
status = "okay";
};
&hoco {
status = "okay";
clock-frequency = <48000000>;

View file

@ -4,8 +4,6 @@
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/pinctrl/renesas/pinctrl-ra.h>
&pinctrl {
sci2_default: sci2_default {
group1 {

View file

@ -1,10 +1,6 @@
# Copyright (c) 2023 TOKITA Hiroshi <tokita.hiroshi@fujitsu.com>
# SPDX-License-Identifier: Apache-2.0
CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC=48000000
CONFIG_BUILD_OUTPUT_HEX=y
# Enable UART driver
CONFIG_SERIAL=y
CONFIG_UART_INTERRUPT_DRIVEN=y
@ -16,6 +12,4 @@ CONFIG_UART_CONSOLE=y
# Enable GPIO
CONFIG_GPIO=y
CONFIG_CLOCK_CONTROL=y
CONFIG_USE_DT_CODE_PARTITION=y

View file

@ -4,8 +4,6 @@
* SPDX-License-Identifier: Apache-2.0
*/
#include <zephyr/dt-bindings/pinctrl/renesas/pinctrl-ra.h>
&pinctrl {
sci2_default: sci2_default {
group1 {

View file

@ -1,10 +1,6 @@
# Copyright (c) 2024 TOKITA Hiroshi <tokita.hiroshi@fujitsu.com>
# SPDX-License-Identifier: Apache-2.0
CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC=48000000
CONFIG_BUILD_OUTPUT_HEX=y
# Enable UART driver
CONFIG_SERIAL=y
CONFIG_UART_INTERRUPT_DRIVEN=y
@ -16,6 +12,4 @@ CONFIG_UART_CONSOLE=y
# Enable GPIO
CONFIG_GPIO=y
CONFIG_CLOCK_CONTROL=y
CONFIG_USE_DT_CODE_PARTITION=y

View file

@ -5,14 +5,13 @@
*/
/dts-v1/;
#include <renesas/ra/r7fa4m1ab3cfm.dtsi>
#include <renesas/ra/ra4/r7fa4m1ab3cfm.dtsi>
#include <zephyr/dt-bindings/gpio/gpio.h>
#include <zephyr/dt-bindings/input/input-event-codes.h>
#include <zephyr/dt-bindings/pinctrl/renesas/pinctrl-ra.h>
/ {
model = "Mikroe Clicker RA4M1";
compatible = "renesas,r7fa4m1ab3cfm";
compatible = "renesas,ra4m1", "renesas,ra";
chosen {
zephyr,console = &uart0;
@ -115,7 +114,8 @@
status = "okay";
};
&fcu {
&port_irq9 {
interrupts = <27 12>;
status = "okay";
};
@ -129,6 +129,7 @@
};
&iclk {
clock-frequency = <12000000>;
div = <1>;
};

View file

@ -1,10 +1,6 @@
# Copyright (c) 2024 Ian Morris
# SPDX-License-Identifier: Apache-2.0
CONFIG_SYS_CLOCK_HW_CYCLES_PER_SEC=12000000
CONFIG_BUILD_OUTPUT_HEX=y
# Enable uart driver
CONFIG_SERIAL=y
@ -14,6 +10,3 @@ CONFIG_UART_CONSOLE=y
# Enable GPIO
CONFIG_GPIO=y
# Enable Clocks
CONFIG_CLOCK_CONTROL=y

View file

@ -13,7 +13,6 @@ config SOC_SERIES_RA4M1
select HAS_SWO
select XIP
select SOC_EARLY_INIT_HOOK
select DYNAMIC_INTERRUPTS if SOC_R7FA4M1AB3CFM
select GPIO_RA_HAS_VBTICTLR
if SOC_SERIES_RA4M1