diff mbox series

[v2,2/3] board: add the qemu board support for mcf54418

Message ID 20240410171211.1633127-3-jeanmichel.hautbois@yoseli.org
State New
Headers show
Series Add support for the MCF5441x Coldfire | expand

Commit Message

Jean-Michel Hautbois April 10, 2024, 5:12 p.m. UTC
The Coldfire MCF54418 needs a board to give the proper linux defconfig
to buildroot. Add it based on a simplified Linux stmark2_defconfig file.
While at it, add a the needed config to run qemu, using a copy of the
qemu_m68k_mcf5208_defconfig as there is not so much difference to expect
except the CPU value.

Signed-off-by: Jean-Michel Hautbois <jeanmichel.hautbois@yoseli.org>
---
 board/qemu/m68k-mcf54418/linux.config | 23 +++++++++++++++++++++++
 configs/qemu_m68k_mcf5441x_defconfig  | 19 +++++++++++++++++++
 2 files changed, 42 insertions(+)
 create mode 100644 board/qemu/m68k-mcf54418/linux.config
 create mode 100644 configs/qemu_m68k_mcf5441x_defconfig
diff mbox series

Patch

diff --git a/board/qemu/m68k-mcf54418/linux.config b/board/qemu/m68k-mcf54418/linux.config
new file mode 100644
index 0000000000..e950052061
--- /dev/null
+++ b/board/qemu/m68k-mcf54418/linux.config
@@ -0,0 +1,23 @@ 
+CONFIG_COLDFIRE=y
+CONFIG_M5441x=y
+CONFIG_CLOCK_FREQ=240000000
+CONFIG_STMARK2=y
+CONFIG_UBOOT=y
+CONFIG_RAMBASE=0x40000000
+CONFIG_RAMSIZE=0x8000000
+CONFIG_VECTORBASE=0x40000000
+CONFIG_KERNELBASE=0x40001000
+# CONFIG_BLK_DEV_BSG is not set
+CONFIG_BINFMT_FLAT=y
+CONFIG_SERIAL_MCF=y
+CONFIG_SERIAL_MCF_BAUDRATE=115200
+CONFIG_SERIAL_MCF_CONSOLE=y
+CONFIG_BOOTPARAM=y
+CONFIG_BOOTPARAM_STRING="console=ttyS0,115200"
+CONFIG_NET=y
+CONFIG_PACKET=y
+CONFIG_UNIX=y
+CONFIG_INET=y
+CONFIG_NETDEVICES=y
+CONFIG_NET_VENDOR_FREESCALE=y
+CONFIG_FEC=y
diff --git a/configs/qemu_m68k_mcf5441x_defconfig b/configs/qemu_m68k_mcf5441x_defconfig
new file mode 100644
index 0000000000..6b550feb8b
--- /dev/null
+++ b/configs/qemu_m68k_mcf5441x_defconfig
@@ -0,0 +1,19 @@ 
+BR2_m68k=y
+BR2_m68k_cf5441x=y
+BR2_PACKAGE_HOST_LINUX_HEADERS_CUSTOM_6_1=y
+BR2_PTHREADS=y
+BR2_STATIC_LIBS=y
+BR2_TARGET_GENERIC_GETTY_PORT="ttyS0"
+BR2_SYSTEM_DHCP="eth0"
+BR2_ROOTFS_POST_IMAGE_SCRIPT="board/qemu/post-image.sh"
+BR2_ROOTFS_POST_SCRIPT_ARGS="$(BR2_DEFCONFIG)"
+BR2_LINUX_KERNEL=y
+BR2_LINUX_KERNEL_CUSTOM_VERSION=y
+BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="6.1.26"
+BR2_LINUX_KERNEL_USE_CUSTOM_CONFIG=y
+BR2_LINUX_KERNEL_CUSTOM_CONFIG_FILE="board/qemu/m68k-mcf54418/linux.config"
+BR2_PACKAGE_BUSYBOX_CONFIG="package/busybox/busybox-minimal.config"
+BR2_TARGET_ROOTFS_INITRAMFS=y
+# BR2_TARGET_ROOTFS_TAR is not set
+BR2_PACKAGE_HOST_QEMU=y
+BR2_PACKAGE_HOST_QEMU_SYSTEM_MODE=y