ARM: dts: imx: Add support for Data Modul i.MX8M Mini eDM SBC
Subsystems (3)
PATCH v4 1/1 ARM: dts: imx: Add support for Data Modul i.MX8M Mini eDM SBC
Add support for Data Modul i.MX8M Mini eDM SBC board. This is an evaluation board for various custom display units. Currently supported are serial console, ethernet, eMMC, SD, SPI NOR, USB host and USB OTG.
---
V2: - Disable UHS mode support in SPL, the overhead incured by bringing up UHS
mode in SPL does not make sense for loading less than 1 MiB u-boot.itb.
- Select primary boot device based on boot device indicated by BootROM, either eMMC or SD boot device is supported. Always select the other boot device, SD or eMMC, as fallback boot device.
- Set 'devnum' environment variable based on boot device indicated by BootROM unless the 'devnum' variable is already set. This way it is possible to boot from the same boot media from which BootROM started U-Boot SPL and U-Boot SPL started U-Boot itself.
- Add RB from Fabio
V3: - Drop CONFIG_SYS_PROMPT_HUSH_PS2 and CONFIG_SYS_I2C_SPEED which
were since converted to Kconfig
V4: - Drop CONFIG_SYS_MMC_IMG_LOAD_PART which was since removed
--- arch/arm/dts/Makefile | 1 + .../dts/imx8mm-data-modul-edm-sbc-u-boot.dtsi | 116 ++ arch/arm/dts/imx8mm-data-modul-edm-sbc.dts | 996 +++++++++ arch/arm/mach-imx/imx8m/Kconfig | 8 + board/data_modul/imx8mm_edm_sbc/Kconfig | 12 + board/data_modul/imx8mm_edm_sbc/MAINTAINERS | 8 + board/data_modul/imx8mm_edm_sbc/Makefile | 13 + board/data_modul/imx8mm_edm_sbc/common.c | 37 + .../imx8mm_data_modul_edm_sbc.c | 110 + board/data_modul/imx8mm_edm_sbc/imximage.cfg | 8 + .../data_modul/imx8mm_edm_sbc/lpddr4_timing.h | 14 + .../imx8mm_edm_sbc/lpddr4_timing_2G_32.c | 1845 +++++++++++++++++ .../imx8mm_edm_sbc/lpddr4_timing_4G_32.c | 1842 ++++++++++++++++ board/data_modul/imx8mm_edm_sbc/spl.c | 179 ++ configs/imx8mm_data_modul_edm_sbc_defconfig | 227 ++ include/configs/imx8mm_data_modul_edm_sbc.h | 129 ++ 16 files changed, 5545 insertions(+) create mode 100644 arch/arm/dts/imx8mm-data-modul-edm-sbc-u-boot.dtsi create mode 100644 arch/arm/dts/imx8mm-data-modul-edm-sbc.dts create mode 100644 board/data_modul/imx8mm_edm_sbc/Kconfig create mode 100644 board/data_modul/imx8mm_edm_sbc/MAINTAINERS create mode 100644 board/data_modul/imx8mm_edm_sbc/Makefile create mode 100644 board/data_modul/imx8mm_edm_sbc/common.c create mode 100644 board/data_modul/imx8mm_edm_sbc/imx8mm_data_modul_edm_sbc.c create mode 100644 board/data_modul/imx8mm_edm_sbc/imximage.cfg create mode 100644 board/data_modul/imx8mm_edm_sbc/lpddr4_timing.h create mode 100644 board/data_modul/imx8mm_edm_sbc/lpddr4_timing_2G_32.c create mode 100644 board/data_modul/imx8mm_edm_sbc/lpddr4_timing_4G_32.c create mode 100644 board/data_modul/imx8mm_edm_sbc/spl.c create mode 100644 configs/imx8mm_data_modul_edm_sbc_defconfig create mode 100644 include/configs/imx8mm_data_modul_edm_sbc.h
arch/arm/dts/Makefile +1 -0
@@ -900,6 +900,7 @@ dtb-$(CONFIG_ARCH_IMX8ULP) += \ imx8ulp-evk.dtb dtb-$(CONFIG_ARCH_IMX8M) += \ + imx8mm-data-modul-edm-sbc.dtb \ imx8mm-evk.dtb \ imx8mm-icore-mx8mm-ctouch2.dtb \ imx8mm-icore-mx8mm-edimm2.2.dtb \
arch/arm/dts/imx8mm-data-modul-edm-sbc-u-boot.dtsi new file +116 -0
116 lines not on this page · raw message
arch/arm/dts/imx8mm-data-modul-edm-sbc.dts new file +996 -0
996 lines not on this page · raw message
arch/arm/mach-imx/imx8m/Kconfig +8 -0
@@ -46,6 +46,13 @@ config TARGET_IMX8MQ_PHANBELL select IMX8MQ select IMX8M_LPDDR4 +config TARGET_IMX8MM_DATA_MODUL_EDM_SBC + bool "Data Modul eDM SBC i.MX8M Mini" + select BINMAN + select IMX8MM + select IMX8M_LPDDR4 + select SUPPORT_SPL + config TARGET_IMX8MM_EVK bool "imx8mm LPDDR4 EVK board" select BINMAN
@@ -209,6 +216,7 @@ source "board/advantech/imx8mp_rsb3720a1/Kconfig" source "board/beacon/imx8mm/Kconfig" source "board/beacon/imx8mn/Kconfig" source "board/compulab/imx8mm-cl-iot-gate/Kconfig" +source "board/data_modul/imx8mm_edm_sbc/Kconfig" source "board/engicam/imx8mm/Kconfig" source "board/freescale/imx8mq_evk/Kconfig" source "board/freescale/imx8mm_evk/Kconfig"
board/data_modul/imx8mm_edm_sbc/Kconfig new file +12 -0
@@ -0,0 +1,12 @@ +if TARGET_IMX8MM_DATA_MODUL_EDM_SBC + +config SYS_BOARD + default "imx8mm_edm_sbc" + +config SYS_VENDOR + default "data_modul" + +config SYS_CONFIG_NAME + default "imx8mm_data_modul_edm_sbc" + +endif
board/data_modul/imx8mm_edm_sbc/MAINTAINERS new file +8 -0
@@ -0,0 +1,8 @@ +Data Modul eDM SBC i.MX8M Mini +M: Marek Vasut <[email protected]> +S: Maintained +F: arch/arm/dts/imx8mm-data-modul-edm-sbc.dts +F: arch/arm/dts/imx8mm-data-modul-edm-sbc-u-boot.dtsi +F: board/data_modul/imx8mm_data_modul_edm_sbc/ +F: configs/imx8mm_data_modul_edm_sbc_defconfig +F: include/configs/imx8mm_data_modul_edm_sbc.h
board/data_modul/imx8mm_edm_sbc/Makefile new file +13 -0
@@ -0,0 +1,13 @@ +# +# Copyright (C) 2022 Marek Vasut <[email protected]> +# +# SPDX-License-Identifier: GPL-2.0+ +# + +ifdef CONFIG_SPL_BUILD +obj-y += spl.o lpddr4_timing_2G_32.o lpddr4_timing_4G_32.o +else +obj-y += imx8mm_data_modul_edm_sbc.o +endif + +obj-y += common.o
board/data_modul/imx8mm_edm_sbc/common.c new file +37 -0
@@ -0,0 +1,37 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* +* Copyright 2022 Marek Vasut <[email protected]> +*/ + +#include <common.h> +#include <asm/io.h> +#include <asm-generic/gpio.h> + +#include "lpddr4_timing.h" + +DECLARE_GLOBAL_DATA_PTR ; + +u8 dmo_get_memcfg (void ) +{ +struct gpio_desc gpio[4 ]; +u8 memcfg =0 ; +ofnode node; +int i, ret; + + node =ofnode_path ("/config" ); +if (!ofnode_valid (node)) { +printf ("%s: no /config node?\n" , __func__); +return BIT (2 ) |BIT (0 ); + } + + ret =gpio_request_list_by_name_nodev (node, +"dmo,ram-coding-gpios" , + gpio,ARRAY_SIZE (gpio), +GPIOD_IS_IN ); +for (i =0 ; i < ret; i++) + memcfg |= !!dm_gpio_get_value (&(gpio[i])) << i; + +gpio_free_list_nodev (gpio, ret); + +return memcfg; +}
board/data_modul/imx8mm_edm_sbc/imx8mm_data_modul_edm_sbc.c new file +110 -0
110 lines not on this page · raw message
board/data_modul/imx8mm_edm_sbc/imximage.cfg new file +8 -0
@@ -0,0 +1,8 @@ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* + * Copyright 2019 NXP + */ + +FIT +BOOT_FROM sd +LOADER u-boot-spl-ddr.bin 0x7E1000
board/data_modul/imx8mm_edm_sbc/lpddr4_timing.h new file +14 -0
@@ -0,0 +1,14 @@ +/* SPDX-License-Identifier: GPL-2.0+ */ +/* +* Copyright 2022 Marek Vasut <[email protected]> +*/ + +#ifndef __LPDDR4_TIMING_H__ +#define __LPDDR4_TIMING_H__ + +extern struct dram_timing_info dmo_imx8mm_sbc_dram_timing_16_32; +extern struct dram_timing_info dmo_imx8mm_sbc_dram_timing_32_32; + +u8 dmo_get_memcfg (void ); + +#endif /* __LPDDR4_TIMING_H__ */
board/data_modul/imx8mm_edm_sbc/lpddr4_timing_2G_32.c new file +1845 -0
1,659 lines not on this page · raw message
board/data_modul/imx8mm_edm_sbc/lpddr4_timing_4G_32.c new file +1842 -0
1,842 lines not on this page · raw message
board/data_modul/imx8mm_edm_sbc/spl.c new file +179 -0
179 lines not on this page · raw message
configs/imx8mm_data_modul_edm_sbc_defconfig new file +227 -0
227 lines not on this page · raw message
include/configs/imx8mm_data_modul_edm_sbc.h new file +129 -0
129 lines not on this page · raw message
The rest of this diff is not shown. View the raw message.
Signature · 1 line
2.35.1
Part of the diff is not shown here. View the raw message.