arm64: imx: Add support for imx8mp-beacon-kit
Subsystems (3)
PATCH v2 1/1 arm64: imx: Add support for imx8mp-beacon-kit
Beacon Embedded has an i.MX8M Plus development kit which consists of a SOM + baseboard. The SOM includes Bluetooth, WiFi, QSPI, eMMC, and one Ethernet PHY. The baseboard includes audio, HDMI, USB-C Dual Role port, USB Hub with five ports, a PCIe slot, and a second Ethernet PHY. The device trees are already queued for inclusion in Linux 6.3.
---
V2: Move default environment from imx8mp_beacon.h to imx8mp_beacon.env
Move README to beacon-imx8mp.rst
arch/arm/dts/Makefile +1 -0
@@ -986,6 +986,7 @@ dtb-$(CONFIG_ARCH_IMX8M) += \ imx8mn-beacon-kit.dtb \ imx8mq-mnt-reform2.dtb \ imx8mq-phanbell.dtb \ + imx8mp-beacon-kit.dtb \ imx8mp-dhcom-pdk2.dtb \ imx8mp-evk.dtb \ imx8mp-icore-mx8mp-edimm2.2.dtb \
arch/arm/dts/imx8mp-beacon-kit-u-boot.dtsi new file +216 -0
216 lines not on this page · raw message
arch/arm/dts/imx8mp-beacon-kit.dts new file +550 -0
550 lines not on this page · raw message
arch/arm/dts/imx8mp-beacon-som.dtsi new file +416 -0
416 lines not on this page · raw message
arch/arm/mach-imx/imx8m/Kconfig +11 -0
@@ -170,6 +170,16 @@ config TARGET_IMX8MN_VENICE select GATEWORKS_SC select MISC +config TARGET_IMX8MP_BEACON + bool "imx8mm Beacon Embedded devkit" + select BINMAN + select IMX8MP + select SUPPORT_SPL + select IMX8M_LPDDR4 + select FSL_CAAM + select ARCH_MISC_INIT + select SPL_CRYPTO if SPL + config TARGET_IMX8MP_DH_DHCOM_PDK2 bool "DH electronics DHCOM Premium Developer Kit (2) i.MX8M Plus" select BINMAN
@@ -326,6 +336,7 @@ endchoice source "board/advantech/imx8mp_rsb3720a1/Kconfig" source "board/beacon/imx8mm/Kconfig" source "board/beacon/imx8mn/Kconfig" +source "board/beacon/imx8mp/Kconfig" source "board/bsh/imx8mn_smm_s2/Kconfig" source "board/cloos/imx8mm_phg/Kconfig" source "board/compulab/imx8mm-cl-iot-gate/Kconfig"
board/beacon/imx8mp/Kconfig new file +16 -0
@@ -0,0 +1,16 @@ +if TARGET_IMX8MP_BEACON + +config SYS_BOARD + default "imx8mp" + +config SYS_VENDOR + default "beacon" + +config SYS_CONFIG_NAME + default "imx8mp_beacon" + +config IMX_CONFIG + default "board/freescale/imx8mp_evk/imximage-8mp-lpddr4.cfg" + + +endif
board/beacon/imx8mp/MAINTAINERS new file +6 -0
@@ -0,0 +1,6 @@ +i.MX8MP Beacon EmbeddedWorks Devkit +M: Adam Ford <[email protected]> +S: Maintained +F: board/beacon/imx8mp/ +F: include/configs/imx8mp_beacon.h +F: configs/imx8mp_beacon_defconfig
board/beacon/imx8mp/Makefile new file +13 -0
@@ -0,0 +1,13 @@ +# +# SPDX-License-Identifier: GPL-2.0+ +# +# Copyright 2022 Logic PD, Inc dba Beacon EmbeddedWorks +# + +obj-y += imx8mp_beacon.o +obj-y += ../../freescale/common/ + +ifdef CONFIG_SPL_BUILD +obj-y += spl.o +obj-$(CONFIG_IMX8M_LPDDR4) += lpddr4_timing.o +endif
board/beacon/imx8mp/imx8mp_beacon.c new file +63 -0
63 lines not on this page · raw message
board/beacon/imx8mp/imx8mp_beacon.env new file +29 -0
@@ -0,0 +1,29 @@ +arch=arm +baudrate=115200 +board=imx8mp +board_name=imx8mp +boot_fdt=try +boot_fit=no +bootcmd=mmc dev ${mmcdev}; if mmc rescan; then if run loadbootscript; then run bootscript; else if run loadimage; then run mmcboot; else run netboot; fi; fi; else booti ${loadaddr} - ${fdt_addr}; fi +bootdelay=2 +console=ttymxc1,115200 +ethprime=eth1 +fdt_addr=0x43000000 +fdt_addr_r=0x43000000 +fdt_file=imx8mp-beacon-kit.dtb +finduuid=part uuid mmc ${mmcdev}:2 uuid +image=Image +kernel_addr_r=0x40480000 +loadaddr=0x40480000 +loadfdt=echo ${fdt_file}; fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr_r} ${fdt_file} +loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image} +mmcargs=setenv bootargs console=${console} root=PARTUUID=${uuid} rootwait rw ${mtdparts} ${optargs} +mmcboot=echo Booting from mmc ...; run finduuid; run mmcargs; if test ${boot_fit} = yes || test ${boot_fit} = try; then bootm ${loadaddr}; else if run loadfdt; then booti ${loadaddr} - ${fdt_addr_r}; else echo WARN: Cannot load the DT; fi; fi; +mmcdev=1 +mmcpart=1 +netargs=setenv bootargs ${jh_clk} console=${console} root=/dev/nfs ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp +netboot=echo Booting from net ...; run netargs; if test ${ip_dyn} = yes; then setenv get_cmd dhcp; else setenv get_cmd tftp; fi; ${get_cmd} ${loadaddr} ${image}; if test ${boot_fit} = yes || test ${boot_fit} = try; then bootm ${loadaddr}; else if ${get_cmd} ${fdt_addr_r} ${fdt_file}; then booti ${loadaddr} - ${fdt_addr_r}; else echo WARN: Cannot load the DT; fi; fi; +optargs=audit=0 video=LVDS-1:d video=LVDS-2:d +scriptaddr=0x40480000 +soc=imx8m +vendor=beacon
board/beacon/imx8mp/imximage-8mp-lpddr4.cfg new file +9 -0
@@ -0,0 +1,9 @@ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* + * Copyright 2021 NXP + */ + + +ROM_VERSION v2 +BOOT_FROM sd +LOADER u-boot-spl-ddr.bin 0x920000
board/beacon/imx8mp/lpddr4_timing.c new file +1881 -0
1,652 lines not on this page · raw message
board/beacon/imx8mp/spl.c new file +132 -0
132 lines not on this page · raw message
configs/imx8mp_beacon_defconfig new file +171 -0
171 lines not on this page · raw message
doc/board/beacon/beacon-imx8mp.rst new file +52 -0
52 lines not on this page · raw message
include/configs/imx8mp_beacon.h new file +31 -0
Lines of this file are not shown. View the raw message.
The rest of this diff is not shown. View the raw message.
Signature · 1 line
2.34.1
Part of the diff is not shown here. View the raw message.
Quoted 7 lines · Adam Ford
Beacon Embedded has an i.MX8M Plus development kit which consists of a SOM + baseboard. The SOM includes Bluetooth, WiFi, QSPI, eMMC, and one Ethernet PHY. The baseboard includes audio, HDMI, USB-C Dual Role port, USB Hub with five ports, a PCIe slot, and a second Ethernet PHY. The device trees are already queued for inclusion in Linux 6.3.
Signed-off-by Adam Ford <[email protected]>
[snip]
board/beacon/imx8mp/imx8mp_beacon.env line 4
Quoted 10 lines
board/beacon/imx8mp/imx8mp_beacon.env new file +4
-0@@ -0,0 +1,29 @@ +arch=arm +baudrate=115200 +board=imx8mp +board_name=imx8mp
You don't need to specify the variables that will be set via include/env_default.h (and if you see an example that is, whoops), just what you normally would have put in CFG_EXTRA_ENV_SETTINGS. I see a few more in here as well that should be pulled.
doc/board/beacon/beacon-imx8mp.rst
Quoted 6 lines
doc/board/beacon/beacon-imx8mp.rst new file +0
-0@@ -0,0 +1,52 @@
I _think_ this is fine itself, but please run 'make htmldocs' (see doc/build/documentation.rst for instructions) as I'm pretty sure you didn't since this is a new directory and so index files need to be updated too.
[snip]
doc/board/beacon/beacon-imx8mp.rst line 11
Quoted 13 lines
doc/board/beacon/beacon-imx8mp.rst new file +12
-0+++ b/include/configs/imx8mp_beacon.h@@ -0,0 +1,31 @@ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* + * Copyright 2022 Logic PD, Inc dba Beacon EmbeddedWorks + */ + +#ifndef __IMX8MP_BEACON_H +#define __IMX8MP_BEACON_H + +#include <linux/sizes.h> +#include <linux/stringify.h> +#include <asm/arch/imx-regs.h>
While I'm seeing it again, do we _really_ need these includes here?
Quoted 7 lines
doc/board/beacon/beacon-imx8mp.rst new file +7
-0+#define CFG_SYS_UBOOT_BASE (QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512) + +#if defined(CONFIG_CMD_NET) +#define PHY_ANEG_TIMEOUT 20000 +#endif + +/* Link Definitions */
doc/board/beacon/beacon-imx8mp.rst line 28
Quoted 10 lines
doc/board/beacon/beacon-imx8mp.rst new file +10
-0+ +#define CFG_SYS_INIT_RAM_ADDR 0x40000000 +#define CFG_SYS_INIT_RAM_SIZE 0x80000 + +/* Totally 6GB DDR */ +#define CFG_SYS_SDRAM_BASE 0x40000000 +#define PHYS_SDRAM 0x40000000 +#define PHYS_SDRAM_SIZE 0xC0000000 /* 3 GB */ +#define PHYS_SDRAM_2 0x100000000 +#define PHYS_SDRAM_2_SIZE 0xC0000000 /* 3 GB */
And are all of these still, strictly, required? I can accept that they are but it's good to confirm, as part of the CONFIG migration work I saw a lot of seemingly not needed anymore defines in config header files, and we're getting closer now to being able to make the file optional.
Signature · 1 line
Tom