[PATCH v1 2/5] configs: verdin-imx8mm: enable spl_gpio_hog
From: Andrejs Cainikovs Enable CONFIG_SPL_GPIO_HOG option to be able to control GPIO hogs from SPL. Signed-off-by: Andrejs Cainikovs Signed-off-by: Marcel Ziswiler --- configs/verdin-imx8mm_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/configs/verdin-imx8mm_defconfig b/configs/verdin-imx8mm_defconfig index 0eb18915154..09e14c6f8c4 100644 --- a/configs/verdin-imx8mm_defconfig +++ b/configs/verdin-imx8mm_defconfig @@ -98,6 +98,7 @@ CONFIG_CLK_COMPOSITE_CCF=y CONFIG_SPL_CLK_IMX8MM=y CONFIG_CLK_IMX8MM=y CONFIG_GPIO_HOG=y +CONFIG_SPL_GPIO_HOG=y CONFIG_MXC_GPIO=y CONFIG_DM_I2C=y CONFIG_MISC=y -- 2.36.1
[PATCH v1 0/5] verdin-imx8mm/verdin-imx8mp: fix ctrl_sleep_moci# handling
From: Marcel Ziswiler This series first synchronises the device tree to get some fixes thereof from Linux and then goes about fixing the CTRL_SLEEP_MOCI# handling we lately found to be problematic in certain cases (e.g. on the Yavia carrier board). Andrejs Cainikovs (4): configs: verdin-imx8mm: enable spl_gpio_hog arm64: dts: verdin-imx8mm: add ctrl_sleep_moci# hog configs: verdin-imx8mp: enable spl_gpio_hog arm64: dts: verdin-imx8mp: add ctrl_sleep_moci# hog Marcel Ziswiler (1): verdin-imx8mm/verdin-imx8mp: synchronise device trees with linux arch/arm/dts/imx8mm-mx8menlo.dts | 17 +- arch/arm/dts/imx8mm-verdin-dahlia.dtsi| 150 -- arch/arm/dts/imx8mm-verdin-dev.dtsi | 97 ++- .../dts/imx8mm-verdin-wifi-dev-u-boot.dtsi| 8 + arch/arm/dts/imx8mm-verdin.dtsi | 30 ++-- arch/arm/dts/imx8mp-verdin-dahlia.dtsi| 129 --- arch/arm/dts/imx8mp-verdin-dev.dtsi | 125 ++- .../dts/imx8mp-verdin-wifi-dev-u-boot.dtsi| 8 + arch/arm/dts/imx8mp-verdin-wifi.dtsi | 5 + arch/arm/dts/imx8mp-verdin.dtsi | 91 +++ board/toradex/verdin-imx8mm/MAINTAINERS | 1 - board/toradex/verdin-imx8mp/MAINTAINERS | 1 - configs/verdin-imx8mm_defconfig | 1 + configs/verdin-imx8mp_defconfig | 1 + 14 files changed, 327 insertions(+), 337 deletions(-) delete mode 100644 arch/arm/dts/imx8mm-verdin-dahlia.dtsi delete mode 100644 arch/arm/dts/imx8mp-verdin-dahlia.dtsi -- 2.36.1
[PATCH v1 1/5] verdin-imx8mm/verdin-imx8mp: synchronise device trees with linux
From: Marcel Ziswiler Synchronise device trees with linux v6.5-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx8mm-mx8menlo.dts| 17 +-- arch/arm/dts/imx8mm-verdin-dahlia.dtsi | 150 arch/arm/dts/imx8mm-verdin-dev.dtsi | 97 ++- arch/arm/dts/imx8mm-verdin.dtsi | 30 ++--- arch/arm/dts/imx8mp-verdin-dahlia.dtsi | 129 arch/arm/dts/imx8mp-verdin-dev.dtsi | 125 +++- arch/arm/dts/imx8mp-verdin-wifi.dtsi| 5 + arch/arm/dts/imx8mp-verdin.dtsi | 91 +- board/toradex/verdin-imx8mm/MAINTAINERS | 1 - board/toradex/verdin-imx8mp/MAINTAINERS | 1 - 10 files changed, 309 insertions(+), 337 deletions(-) delete mode 100644 arch/arm/dts/imx8mm-verdin-dahlia.dtsi delete mode 100644 arch/arm/dts/imx8mp-verdin-dahlia.dtsi diff --git a/arch/arm/dts/imx8mm-mx8menlo.dts b/arch/arm/dts/imx8mm-mx8menlo.dts index 32f6f2f50c1..0b123a84018 100644 --- a/arch/arm/dts/imx8mm-mx8menlo.dts +++ b/arch/arm/dts/imx8mm-mx8menlo.dts @@ -10,6 +10,7 @@ / { model = "MENLO MX8MM EMBEDDED DEVICE"; compatible = "menlo,mx8menlo", +"toradex,verdin-imx8mm-nonwifi", "toradex,verdin-imx8mm", "fsl,imx8mm"; @@ -250,21 +251,21 @@ /* SODIMM 96 */ MX8MM_IOMUXC_SAI1_RXD2_GPIO4_IO40x1c4 /* CPLD_D[7] */ - MX8MM_IOMUXC_SAI1_RXD3_GPIO4_IO50x1c4 + MX8MM_IOMUXC_SAI1_RXD3_GPIO4_IO50x184 /* CPLD_D[6] */ - MX8MM_IOMUXC_SAI1_RXFS_GPIO4_IO00x1c4 + MX8MM_IOMUXC_SAI1_RXFS_GPIO4_IO00x184 /* CPLD_D[5] */ - MX8MM_IOMUXC_SAI1_TXC_GPIO4_IO110x1c4 + MX8MM_IOMUXC_SAI1_TXC_GPIO4_IO110x184 /* CPLD_D[4] */ - MX8MM_IOMUXC_SAI1_TXD0_GPIO4_IO12 0x1c4 + MX8MM_IOMUXC_SAI1_TXD0_GPIO4_IO12 0x184 /* CPLD_D[3] */ - MX8MM_IOMUXC_SAI1_TXD1_GPIO4_IO13 0x1c4 + MX8MM_IOMUXC_SAI1_TXD1_GPIO4_IO13 0x184 /* CPLD_D[2] */ - MX8MM_IOMUXC_SAI1_TXD2_GPIO4_IO14 0x1c4 + MX8MM_IOMUXC_SAI1_TXD2_GPIO4_IO14 0x184 /* CPLD_D[1] */ - MX8MM_IOMUXC_SAI1_TXD3_GPIO4_IO15 0x1c4 + MX8MM_IOMUXC_SAI1_TXD3_GPIO4_IO15 0x184 /* CPLD_D[0] */ - MX8MM_IOMUXC_SAI1_TXD4_GPIO4_IO16 0x1c4 + MX8MM_IOMUXC_SAI1_TXD4_GPIO4_IO16 0x184 /* KBD_intK */ MX8MM_IOMUXC_SAI2_MCLK_GPIO4_IO27 0x1c4 /* DISP_reset */ diff --git a/arch/arm/dts/imx8mm-verdin-dahlia.dtsi b/arch/arm/dts/imx8mm-verdin-dahlia.dtsi deleted file mode 100644 index c2a5c2f7b20..000 --- a/arch/arm/dts/imx8mm-verdin-dahlia.dtsi +++ /dev/null @@ -1,150 +0,0 @@ -// SPDX-License-Identifier: GPL-2.0-or-later OR MIT -/* - * Copyright 2022 Toradex - */ - -/ { - sound_card: sound-card { - compatible = "simple-audio-card"; - simple-audio-card,bitclock-master = <&dailink_master>; - simple-audio-card,format = "i2s"; - simple-audio-card,frame-master = <&dailink_master>; - simple-audio-card,name = "imx8mm-wm8904"; - simple-audio-card,routing = - "Headphone Jack", "HPOUTL", - "Headphone Jack", "HPOUTR", - "IN2L", "Line In Jack", - "IN2R", "Line In Jack", - "Headphone Jack", "MICBIAS", - "IN1L", "Headphone Jack"; - simple-audio-card,widgets = - "Microphone", "Headphone Jack", - "Headphone", "Headphone Jack", - "Line", "Line In Jack"; - - dailink_master: simple-audio-card,codec { - clocks = <&clk IMX8MM_CLK_SAI2_ROOT>; - sound-dai = <&wm8904_1a>; - }; - - simple-audio-card,cpu { - sound-dai = <&sai2>; - }; - }; -}; - -/* Verdin SPI_1 */ -&ecspi2 { - status = "okay"; -}; - -/*
[PATCH v1 4/5] configs: verdin-imx8mp: enable spl_gpio_hog
From: Andrejs Cainikovs Enable CONFIG_SPL_GPIO_HOG option to be able to control GPIO hogs from SPL. Signed-off-by: Andrejs Cainikovs Signed-off-by: Marcel Ziswiler --- configs/verdin-imx8mp_defconfig | 1 + 1 file changed, 1 insertion(+) diff --git a/configs/verdin-imx8mp_defconfig b/configs/verdin-imx8mp_defconfig index f1fa2b8f496..37ab9e44140 100644 --- a/configs/verdin-imx8mp_defconfig +++ b/configs/verdin-imx8mp_defconfig @@ -108,6 +108,7 @@ CONFIG_CLK_COMPOSITE_CCF=y CONFIG_CLK_IMX8MP=y CONFIG_FSL_CAAM=y CONFIG_GPIO_HOG=y +CONFIG_SPL_GPIO_HOG=y CONFIG_MXC_GPIO=y CONFIG_DM_PCA953X=y CONFIG_DM_I2C=y -- 2.36.1
[PATCH v1 5/5] arm64: dts: verdin-imx8mp: add ctrl_sleep_moci# hog
From: Andrejs Cainikovs Drive CTRL_SLEEP_MOCI# high at boot (SPL) using a GPIO hog, this signal may be used to control some power-rails on the carrier board, therefore it should be set to high when the module is booting. To do this as early as possible is generally a good idea and the issue was noticed on the Yavia carrier board where it is needed to power the I2C EEPROM on the carrier board. Signed-off-by: Andrejs Cainikovs Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx8mp-verdin-wifi-dev-u-boot.dtsi | 8 1 file changed, 8 insertions(+) diff --git a/arch/arm/dts/imx8mp-verdin-wifi-dev-u-boot.dtsi b/arch/arm/dts/imx8mp-verdin-wifi-dev-u-boot.dtsi index 9c6c417f7ee..0162f9b2da3 100644 --- a/arch/arm/dts/imx8mp-verdin-wifi-dev-u-boot.dtsi +++ b/arch/arm/dts/imx8mp-verdin-wifi-dev-u-boot.dtsi @@ -62,6 +62,10 @@ &gpio4 { bootph-pre-ram; + + ctrl-sleep-moci-hog { + bootph-pre-ram; + }; }; &gpio5 { @@ -106,6 +110,10 @@ bootph-pre-ram; }; +&pinctrl_ctrl_sleep_moci { + bootph-pre-ram; +}; + &pinctrl_i2c1 { bootph-pre-ram; }; -- 2.36.1
[PATCH v1 3/5] arm64: dts: verdin-imx8mm: add ctrl_sleep_moci# hog
From: Andrejs Cainikovs Drive CTRL_SLEEP_MOCI# high at boot (SPL) using a GPIO hog, this signal may be used to control some power-rails on the carrier board, therefore it should be set to high when the module is booting. To do this as early as possible is generally a good idea and the issue was noticed on the Yavia carrier board where it is needed to power the I2C EEPROM on the carrier board. Signed-off-by: Andrejs Cainikovs Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi | 8 1 file changed, 8 insertions(+) diff --git a/arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi b/arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi index 494229e4e62..2b268f55cb9 100644 --- a/arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi +++ b/arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi @@ -56,6 +56,10 @@ &gpio5 { bootph-pre-ram; + + ctrl-sleep-moci-hog { + bootph-pre-ram; + }; }; &i2c1 { @@ -88,6 +92,10 @@ }; }; +&pinctrl_ctrl_sleep_moci { + bootph-pre-ram; +}; + &pinctrl_i2c1 { bootph-pre-ram; }; -- 2.36.1
[PATCH v3 1/3] toradex: tdx-cfg-block: add verdin am62 skus
From: Marcel Ziswiler Add initial Verdin AM62 Quad 1GB WB IT prototype and launch configuration SKUs to ConfigBlock handling. 0069: Verdin AM62 Quad 1GB WB IT 0071: Verdin AM62 Solo 512MB 0072: Verdin AM62 Solo 512MB WB IT 0073: Verdin AM62 Dual 1GB ET 0074: Verdin AM62 Dual 1GB IT 0075: Verdin AM62 Dual 1GB WB IT 0076: Verdin AM62 Quad 2GB WB IT Signed-off-by: Marcel Ziswiler Signed-off-by: Emanuele Ghidoli --- Changes in v3: - Add Verdin AM62 launch configuration SKUs as well. board/toradex/common/tdx-cfg-block.c | 7 +++ board/toradex/common/tdx-cfg-block.h | 10 -- 2 files changed, 15 insertions(+), 2 deletions(-) diff --git a/board/toradex/common/tdx-cfg-block.c b/board/toradex/common/tdx-cfg-block.c index e513f4a2919..8ad4907bfe4 100644 --- a/board/toradex/common/tdx-cfg-block.c +++ b/board/toradex/common/tdx-cfg-block.c @@ -139,7 +139,14 @@ const struct toradex_som toradex_modules[] = { [66] = { "Verdin iMX8M Plus Quad 8GB WB", TARGET_IS_ENABLED(VERDIN_IMX8MP) }, [67] = { "Apalis iMX8QM 8GB WB IT", TARGET_IS_ENABLED(APALIS_IMX8) }, [68] = { "Verdin iMX8M Mini Quad 2GB WB IT", TARGET_IS_ENABLED(VERDIN_IMX8MM) }, + [69] = { "Verdin AM62 Quad 1GB WB IT", TARGET_IS_ENABLED(VERDIN_AM62_A53) }, [70] = { "Verdin iMX8M Plus Quad 8GB WB IT", TARGET_IS_ENABLED(VERDIN_IMX8MP) }, + [71] = { "Verdin AM62 Solo 512MB", TARGET_IS_ENABLED(VERDIN_AM62_A53) }, + [72] = { "Verdin AM62 Solo 512MB WB IT", TARGET_IS_ENABLED(VERDIN_AM62_A53) }, + [73] = { "Verdin AM62 Dual 1GB ET", TARGET_IS_ENABLED(VERDIN_AM62_A53) }, + [74] = { "Verdin AM62 Dual 1GB IT", TARGET_IS_ENABLED(VERDIN_AM62_A53) }, + [75] = { "Verdin AM62 Dual 1GB WB IT", TARGET_IS_ENABLED(VERDIN_AM62_A53) }, + [76] = { "Verdin AM62 Quad 2GB WB IT", TARGET_IS_ENABLED(VERDIN_AM62_A53) }, }; const char * const toradex_carrier_boards[] = { diff --git a/board/toradex/common/tdx-cfg-block.h b/board/toradex/common/tdx-cfg-block.h index 45fa04ca38a..5c204931a2d 100644 --- a/board/toradex/common/tdx-cfg-block.h +++ b/board/toradex/common/tdx-cfg-block.h @@ -94,8 +94,14 @@ enum { VERDIN_IMX8MPQ_8GB_WIFI_BT, APALIS_IMX8QM_8GB_WIFI_BT_IT, VERDIN_IMX8MMQ_WIFI_BT_IT_NO_CAN, - /* 69 */ - VERDIN_IMX8MPQ_8GB_WIFI_BT_IT = 70, /* 70 */ + VERDIN_AM62Q_WIFI_BT_IT, + VERDIN_IMX8MPQ_8GB_WIFI_BT_IT, /* 70 */ + VERDIN_AM62S_512MB, + VERDIN_AM62S_512MB_WIFI_BT_IT, + VERDIN_AM62D_1G_ET, + VERDIN_AM62D_1G_IT, + VERDIN_AM62D_1G_WIFI_BT_IT, /* 75 */ + VERDIN_AM62Q_2G_WIFI_BT_IT, }; enum { -- 2.36.1
[PATCH v3 2/3] arm: mach-k3: am62: fix 2nd mux option of clkout0
From: Marcel Ziswiler Fix second mux option of clkout0 which should really be DEV_BOARD0_CLKOUT0_IN_PARENT_HSDIV4_16FFT_MAIN_2_HSDIVOUT1_CLK10 rather than twice the same according to [1]. [1] https://software-dl.ti.com/tisci/esd/latest/5_soc_doc/am62x/clocks.html#clocks-for-board0-device Signed-off-by: Marcel Ziswiler Reviewed-by: Bryan Brattlof --- (no changes since v2) Changes in v2: - Add Bryan's reviewed-by tag. Thanks! arch/arm/mach-k3/am62x/clk-data.c | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-k3/am62x/clk-data.c b/arch/arm/mach-k3/am62x/clk-data.c index c0881778fe7..d7bfed0e031 100644 --- a/arch/arm/mach-k3/am62x/clk-data.c +++ b/arch/arm/mach-k3/am62x/clk-data.c @@ -57,7 +57,7 @@ static const char * const sam62_pll_ctrl_wrap_mcu_0_sysclkout_clk_parents[] = { static const char * const clkout0_ctrl_out0_parents[] = { "hsdiv4_16fft_main_2_hsdivout1_clk", - "hsdiv4_16fft_main_2_hsdivout1_clk", + "hsdiv4_16fft_main_2_hsdivout1_clk10", }; static const char * const clk_32k_rc_sel_out0_parents[] = { @@ -195,6 +195,7 @@ static const struct clk_data clk_list[] = { CLK_DIV("hsdiv4_16fft_main_1_hsdivout1_clk", "pllfracf_ssmod_16fft_main_1_foutvcop_clk", 0x681084, 0, 7, 0, 0), CLK_DIV("hsdiv4_16fft_main_1_hsdivout2_clk", "pllfracf_ssmod_16fft_main_1_foutvcop_clk", 0x681088, 0, 7, 0, 0), CLK_DIV("hsdiv4_16fft_main_2_hsdivout1_clk", "pllfracf_ssmod_16fft_main_2_foutvcop_clk", 0x682084, 0, 7, 0, 0), + CLK_DIV("hsdiv4_16fft_main_2_hsdivout1_clk10", "pllfracf_ssmod_16fft_main_2_foutvcop_clk", 0x682084, 0, 7, 0, 0), CLK_DIV("hsdiv4_16fft_main_2_hsdivout2_clk", "pllfracf_ssmod_16fft_main_2_foutvcop_clk", 0x682088, 0, 7, 0, 0), CLK_DIV("hsdiv4_16fft_mcu_0_hsdivout0_clk", "pllfracf_ssmod_16fft_mcu_0_foutvcop_clk", 0x4040080, 0, 7, 0, 0), CLK_MUX_PLLCTRL("sam62_pll_ctrl_wrap_main_0_sysclkout_clk", sam62_pll_ctrl_wrap_main_0_sysclkout_clk_parents, 2, 0x41, 0), @@ -313,7 +314,7 @@ static const struct dev_clk soc_dev_clk_data[] = { DEV_CLK(146, 5, "sam62_pll_ctrl_wrap_main_0_chip_div1_clk_clk"), DEV_CLK(157, 20, "clkout0_ctrl_out0"), DEV_CLK(157, 21, "hsdiv4_16fft_main_2_hsdivout1_clk"), - DEV_CLK(157, 22, "hsdiv4_16fft_main_2_hsdivout1_clk"), + DEV_CLK(157, 22, "hsdiv4_16fft_main_2_hsdivout1_clk10"), DEV_CLK(157, 24, "sam62_pll_ctrl_wrap_main_0_chip_div1_clk_clk"), DEV_CLK(157, 25, "board_0_ddr0_ck0_out"), DEV_CLK(157, 40, "mshsi2c_main_0_porscl"), -- 2.36.1
[PATCH v3 0/3] board: toradex: add verdin am62 support
From: Marcel Ziswiler This series adds initial support for the Toradex Verdin AM62 SoM [1]. The first commit adds resp. PID4 to the ConfigBlock, the second one fixes an early clocking issue confirmed to be a weird bug in TI's scripting. And last but not least support for the Toradex Verdin AM62 is added. Please note that this series is based on Emanuele's recent work on get_ram_size() [2] and the addition of the 0070 verdin i.mx 8m plus quad sku [3]. [1] https://www.toradex.com/computer-on-modules/verdin-arm-family/ti-am62 [2] https://lore.kernel.org/all/20230530133327.178278-1-france...@dolcini.it [3] https://lore.kernel.org/all/20230515130641.26028-1-france...@dolcini.it Changes in v3: - Add Verdin AM62 launch configuration SKUs as well. - Integrate our recent find of CTRL_SLEEP_MOCI# needing to be driven from A53 SPL as it may be used to control some power-rails on the carrier board. E.g. on the Yavia carrier board it is needed to power the I2C EEPROM on the carrier board. - Improve boot environment in R5 SPL vs. A53. - Integrate launch configuration SKUs to Wi-Fi handling. - Re-sync device trees from Linux kernel v6.5-rc1. - Add warning if memory is less than expected. Changes in v2: - Add Bryan's reviewed-by tag. Thanks! - Use 1.2 GHz rather than 1.25 GHz A53 clock as on the EVM/SK. - Also add power-domain 166 as on the EVM/SK. - Get rid of main_bcdma and main_pktdma as not required in R5 SPL. - Get rid of all bootph-pre-ram in Ethernet and SDHC1 aka SD card related pinctrls as not required in any SPL. - Enable CONFIG_TI_SECURE_DEVICE by default as Non-HS devices will continue to boot due to runtime device type detection. - Disable FAT and SPI support as not required in R5 SPL. - Also enable CONFIG_SPL_MMC_HS200_SUPPORT in R5 SPL. - Enable CONFIG_LEGACY_IMAGE_FORMAT to allow sourcing unsigned script images e.g. like our current boot scripts. - Increase CONFIG_SYS_BOOTM_LEN to 64 MB to allow booting bigger compressed images as e.g. in the Toradex Easy Installer case. - Change memory configurations to operate at temperatures of up to 95 degrees celsius. - Increase CONFIG_SYS_MAXARGS from default 16 to 64. - Enable CONFIG_CMD_REMOTEPROC, CONFIG_SPL_DM_GPIO_LOOKUP_LABEL and CONFIG_SPL_I2C_EEPROM. - For R5 SPL increase CONFIG_SPL_STACK_R_MALLOC_SIMPLE_LEN to 0x14, enable CONFIG_SPL_I2C, CONFIG_DM_I2C and CONFIG_SYS_I2C_OMAP24XX and savedefconfig got rid of CONFIG_SPL_FIT_IMAGE_POST_PROCESS. Marcel Ziswiler (3): toradex: tdx-cfg-block: add verdin am62 skus arm: mach-k3: am62: fix 2nd mux option of clkout0 board: toradex: add verdin am62 support arch/arm/dts/Makefile |3 + arch/arm/dts/k3-am62-verdin-dev.dtsi | 196 ++ arch/arm/dts/k3-am62-verdin-wifi.dtsi | 39 + arch/arm/dts/k3-am62-verdin.dtsi | 1411 +++ .../dts/k3-am625-verdin-lpddr4-1600MTs.dtsi | 2190 + arch/arm/dts/k3-am625-verdin-r5.dts | 115 + .../dts/k3-am625-verdin-wifi-dev-u-boot.dtsi | 223 ++ arch/arm/dts/k3-am625-verdin-wifi-dev.dts | 22 + arch/arm/mach-k3/Kconfig |1 + arch/arm/mach-k3/am62x/clk-data.c |5 +- board/toradex/common/tdx-cfg-block.c |7 + board/toradex/common/tdx-cfg-block.h | 10 +- board/toradex/verdin-am62/Kconfig | 80 + board/toradex/verdin-am62/MAINTAINERS | 16 + board/toradex/verdin-am62/Makefile|6 + board/toradex/verdin-am62/verdin-am62.c | 123 + configs/verdin-am62_a53_defconfig | 185 ++ configs/verdin-am62_r5_defconfig | 111 + doc/board/toradex/verdin-am62.rst | 167 ++ include/configs/verdin-am62.h | 55 + 20 files changed, 4961 insertions(+), 4 deletions(-) create mode 100644 arch/arm/dts/k3-am62-verdin-dev.dtsi create mode 100644 arch/arm/dts/k3-am62-verdin-wifi.dtsi create mode 100644 arch/arm/dts/k3-am62-verdin.dtsi create mode 100644 arch/arm/dts/k3-am625-verdin-lpddr4-1600MTs.dtsi create mode 100644 arch/arm/dts/k3-am625-verdin-r5.dts create mode 100644 arch/arm/dts/k3-am625-verdin-wifi-dev-u-boot.dtsi create mode 100644 arch/arm/dts/k3-am625-verdin-wifi-dev.dts create mode 100644 board/toradex/verdin-am62/Kconfig create mode 100644 board/toradex/verdin-am62/MAINTAINERS create mode 100644 board/toradex/verdin-am62/Makefile create mode 100644 board/toradex/verdin-am62/verdin-am62.c create mode 100644 configs/verdin-am62_a53_defconfig create mode 100644 configs/verdin-am62_r5_defconfig create mode 100644 doc/board/toradex/verdin-am62.rst create mode 100644 include/configs/verdin-am62.h -- 2.36.1
Re: Strange construct in binman description
Hi Simon On Jul 23, 2023 05:48, Simon Glass wrote: Hi Marcel, I just noticed this in an imx8 description: binman_configuration: @config-SEQ { I remember having stumbled over this before but I do not remember any exact details, sorry. Since this is a generator node, binman blindly generates a phandle for each not it generates. This means that if there is more than one config node, then they will have duplicate phandles. I have sent a series to correct this, but it fails the build on: imx8mm_venice imx8mn_venice imx8mp_venice Ah, now I get it. You mixed up venice (Gate works) with verdin (Toradex). I am a bit unsure about what this is supposed to do. Could you please take a look? I'm more than happy to do that but you are probably much better off enquiring Tim Harvey from Gateworks about this. I put him on CC. Regards, Simon Cheers Marcel
Re: [PATCH v3 3/3] board: toradex: add verdin am62 support
Hi Nishanth On Fri, 2023-07-21 at 08:37 -0500, Nishanth Menon wrote: > On 09:40-20230715, Marcel Ziswiler wrote: > > From: Marcel Ziswiler > > > > This adds initial support for the Toradex Verdin AM62 Quad 1GB WB IT > > V1.0A module. They are strapped to boot from their on-module eMMC. > > U-Boot supports booting from the on-module eMMC only, DFU support is > > disabled for now due to missing AM62x USB support. > > > > Boot sequence is: > > SYSFW ---> R5 SPL (both in tiboot3.bin) ---> ATF (TF-A) ---> OP-TEE > > ---> A53 SPL (part of tispl.bin) ---> U-boot proper (u-boot.img) > > > > Signed-off-by: Marcel Ziswiler > > > > --- > > > > Changes in v3: > > - Integrate our recent find of CTRL_SLEEP_MOCI# needing to be driven > > from A53 SPL as it may be used to control some power-rails on the > > carrier board. E.g. on the Yavia carrier board it is needed to power > > the I2C EEPROM on the carrier board. > > - Improve boot environment in R5 SPL vs. A53. > > - Integrate launch configuration SKUs to Wi-Fi handling. > > - Re-sync device trees from Linux kernel v6.5-rc1. > > - Add warning if memory is less than expected. > > Thank you. we are in the middle of a bunch of cleanup for AM62 at the > moment - fixing up mdio, dts, ethernet etc and introducing binman at the > moment. I am, of course, fully aware of this and actually internally do have patches on top of all such work which already got posted to the mailing list to make sure our stuff also works with this. I am also more than happy to provide more feedback to help in moving this all forward. > I think it might be better to introduce new platforms with those > changes incorporated. While I do understand what you are saying I am also a little bit disappointed that we are now blocked since more than one and a half months without a clear path/timeline moving forward. > -- > > Regards, > Nishanth Menon > Key (0xDDB5849D1736249D) / Fingerprint: F8A2 8693 54EB 8232 17A3 1A34 DDB5 > 849D 1736 249D Cheers Marcel
Re: [PATCH v1] board: toradex: verdin-imx8mp: enable usb device and fastboot support
Hi Stefano Maybe you missed that one (i.MX 8M Plus vs. Mini)? Thanks! Cheers Marcel On Mon, 2023-08-28 at 19:24 -0300, Fabio Estevam wrote: > Hi Marcel, > > On Mon, Aug 28, 2023 at 6:38 PM Marcel Ziswiler wrote: > > > > From: Marcel Ziswiler > > > > Enable USB device and fastboot support which may be used to load the > > Toradex Easy Installer FIT image. > > > > While at it also enable USB mass storage aka UMS support. > > > > Note that the i.MX 8M Plus recovery mode support is based on the USB > > boot stage of the BOOTROM and does NOT require USB SDP SPL aka serial > > downloader support. > > > > Signed-off-by: Marcel Ziswiler > > Reviewed-by: Fabio Estevam
[REGRESSION] imx: spl_imx_romapi: boot loops
Hi On our weekly master upstream CI build we noticed Verdin iMX8M Plus boot looping. Bisecting pointed to the following commit: commit 4b4472438f5a ("imx: spl_imx_romapi: avoid tricky use of spl_load_simple_fit() to get full FIT size") It looks like this introduced a regression. Before and after console output (with DEBUG defined in arch/arm/mach-imx/spl_imx_romapi.c) below: Any comments? Cheers Marcel Before: U-Boot SPL 2023.10-00969-g9960d4a5402-dirty (Oct 24 2023 - 09:20:03 +0200) Training FAILED DDR configured as single rank SEC0: RNG instantiated Normal Boot WDT: Started watchdog@3028 with servicing every 1000ms (60s timeout) Trying to boot from BOOTROM Boot Stage: Primary boot Find img info 0x4802b000, size 1044 Need continue download 1024 Download 932864, Total size 934544 NOTICE: Do not release JR0 to NS as it can be used by HAB NOTICE: BL31: v2.9(release):v2.9.0-619-g5f01b0b11 NOTICE: BL31: Built : 11:08:02, Sep 6 2023 U-Boot 2023.10-00969-g9960d4a5402-dirty (Oct 24 2023 - 09:20:03 +0200) CPU: Freescale i.MX8MP[8] rev1.1 1600 MHz (running at 1200 MHz) [snip] After (e.g. commit 4b4472438f5 or master): U-Boot SPL 2024.01-rc1-dirty (Oct 24 2023 - 09:28:26 +0200) Training FAILED DDR configured as single rank SEC0: RNG instantiated Normal Boot WDT: Started watchdog@3028 with servicing every 1000ms (60s timeout) Trying to boot from BOOTROM Boot Stage: Primary boot Find img info 0x4802b000, size 1044 Need continue download 1024 downloading another 0xc9000 bytes downloading another 0x1ae00 bytes => this crash/resets and boot loops forever
Re: [REGRESSION] imx: spl_imx_romapi: boot loops
Hi Rasmus Thanks for your help. On Tue, 2023-10-24 at 11:18 +0200, Rasmus Villemoes wrote: [snip] > Hm. Can you show the result of 'fdtdump u-boot.itb | head' ⬢[zim@toolbox u-boot.git]$ fdtdump u-boot.itb | head fdtdump is a low-level debugging tool, not meant for general use. If you want to decompile a dtb, you probably want dtc -I dtb -O dts /dts-v1/; // magic: 0xd00dfeed // totalsize: 0x414 (1044) // off_dt_struct: 0x38 // off_dt_strings: 0x370 // off_mem_rsvmap: 0x28 // version: 17 // last_comp_version: 2 // boot_cpuid_phys: 0x0 // size_dt_strings: 0xa1 > as well as > just the actual file sizes of u-boot.itb and flash.bin. ⬢[zim@toolbox u-boot.git]$ ls -l u-boot.itb u-boot.bin -rw-r--r--. 1 zim zim 882984 Oct 24 11:42 u-boot.bin -rw-r--r--. 1 zim zim 934504 Oct 24 11:42 u-boot.itb > Also, in spl_romapi_read_stream(), can you add a print out what > ss->pagesize is, and also an unconditional printf() after the > rom_api_download_image() - we apparently don't hit the "Failure download > %d", but I'd still like to see if we even return from that > rom_api_download_image() call. U-Boot SPL 2024.01-rc1-dirty (Oct 24 2023 - 11:56:41 +0200) Training FAILED DDR configured as single rank SEC0: RNG instantiated Normal Boot WDT: Started watchdog@3028 with servicing every 1000ms (60s timeout) Trying to boot from BOOTROM Boot Stage: Primary boot Find img info 0x4802b000, size 1044 Need continue download 1024 spl_romapi_read_stream ss->pagesize 0x200 spl_romapi_read_stream ss->pagesize 0x200 downloading another 0xc9000 bytes rom_api_download_image()=240 spl_romapi_read_stream ss->pagesize 0x200 downloading another 0x1ae00 bytes rom_api_download_image()=240 spl_romapi_read_stream� > Rasmus Cheers Marcel
Re: [REGRESSION] imx: spl_imx_romapi: boot loops
Hi Rasmus Thanks again. On Tue, 2023-10-24 at 13:17 +0200, Rasmus Villemoes wrote: [snip] > > > > So this is interesting. I tried disabling CONFIG_IMX_HAB (because that > case doesn't create an .itb with external data) and boot on a board > which is not locked down, and I get > > Trying to boot from BOOTROM > Boot Stage: USB boot > Find img info 0x4802df00, size 1504 > already have 256 bytes > Need continue download 2048 > spl_romapi_read_stream(): ss->pagesize = 0x1 > spl_romapi_read_stream(): ss->pagesize = 0x1 > downloading another 0x9d768 bytes > spl_romapi_read_stream(): rom_api_download_image -> 240 > spl_romapi_read_stream(): ss->pagesize = 0x1 > downloading another 0x1ff18 bytes > spl_romapi_read_stream(): rom_api_download_image -> 240 > spl_romapi_read_stream(): ss->pagesize = 0x1 > spl_romapi_read_stream(): ss->pagesize = 0x1 > downloading another 0x1622 bytes > spl_romapi_read_stream(): rom_api_download_image -> 240 > NOTICE: BL31: v2.6(release):lf-5.15.71-2.2.0-0-g3c1583ba0-dirty > NOTICE: BL31: Built : 11:00:38, Nov 21 2022 > > and this works just fine. But in my case ss->pagesize is 1, whereas you > have 512. > > Just exactly how are you booting? It says "Boot Stage: Primary boot" > whereas I'm doing serial download with uuu (i.e. "Boot Stage: USB boot"). Yes, regular eMMC boot. Serial download also works for me (note this requires a patch still not merged upstream [1]): U-Boot SPL 2024.01-rc1-1-g36413e27727-dirty (Oct 24 2023 - 15:03:05 +0200) Training FAILED DDR configured as single rank SEC0: RNG instantiated Normal Boot WDT: Started watchdog@3028 with servicing every 1000ms (60s timeout) Trying to boot from BOOTROM Boot Stage: USB boot Find img info 0x4802b000, size 1044 Need continue download 1024 spl_romapi_read_stream ss->pagesize 0x1 spl_romapi_read_stream ss->pagesize 0x1 downloading another 0xd6480 bytes rom_api_download_image()=240 spl_romapi_read_stream ss->pagesize 0x1 downloading another 0x1ac70 bytes rom_api_download_image()=240 spl_romapi_read_stream ss->pagesize 0x1 NOTICE: Do not release JR0 to NS as it can be used by HAB NOTICE: BL31: v2.9(release):v2.9.0-619-g5f01b0b11 NOTICE: BL31: Built : 11:08:02, Sep 6 2023 U-Boot 2024.01-rc1-1-g36413e27727-dirty (Oct 24 2023 - 15:03:05 +0200) CPU: Freescale i.MX8MP[8] rev1.1 1600 MHz (running at 1200 MHz) [snip] > It seems weird that you even end up in the is_boot_from_stream_device() > if you're booting from eMMC (which would explain the 512 byte page size). At least I am not aware that we would be doing anything special for eMMC boot. > Also, the prints above reveal that the download of the 0x1ae00 succeeds, > but then we enter the function once more, and for some reason your > printf() gets cut short; in my boot, that's for fetching another 0x1622 > bytes. My guess is that the board hangs because it tries to download > more data than the stream can supply, due to the rounding-up to > ss->pagesize. Can you try with this > > diff --git a/arch/arm/dts/imx8mp-u-boot.dtsi > b/arch/arm/dts/imx8mp-u-boot.dtsi > index e54df1766fa..4b5e9ff466f 100644 > --- a/arch/arm/dts/imx8mp-u-boot.dtsi > +++ b/arch/arm/dts/imx8mp-u-boot.dtsi > @@ -100,6 +100,7 @@ > > itb { > filename = "u-boot.itb"; > + align-size = <512>; > > fit { > description = "Configuration to load ATF before > U-Boot"; > > so that u-boot.itb is extended so it's a multiple of 512 bytes? Unfortunately, that did not help. I mean it does make the u-boot.itb a multiple of 512 but keeps crashing the exact way as before. > Rasmus [1] https://lore.kernel.org/all/20230828213803.454303-1-mar...@ziswiler.com Cheers Marcel
Re: [REGRESSION] imx: spl_imx_romapi: boot loops
Hi Fabio Thanks! On Wed, 2023-10-25 at 09:20 -0300, Fabio Estevam wrote: > Hi Marcel, > > On Tue, Oct 24, 2023 at 10:16 AM Marcel Ziswiler > wrote: > > > Yes, regular eMMC boot. Serial download also works for me (note this > > requires a patch still not merged > > upstream > > I tried the top of tree U-Boot on the imx8mp-evk and I was not able to > reproduce the error here. > > Below is the boot log from the SD card: Yes, it only seems to be an issue for the eMMC Fastboot case as that one has some special handling (whatever that is). > U-Boot SPL 2024.01-rc1-00054-gfb428b618194 (Oct 25 2023 - 09:17:12 -0300) > SEC0: RNG instantiated > Normal Boot > WDT: Started watchdog@3028 with servicing every 1000ms (60s timeout) > Trying to boot from BOOTROM > Boot Stage: Primary boot > image offset 0x8000, pagesize 0x200, ivt offset 0x0 > NOTICE: BL31: v2.6(release):lf-6.1.1-1.0.0-0-g616a4588f333 > NOTICE: BL31: Built : 10:38:04, Oct 12 2023 > > > U-Boot 2024.01-rc1-00054-gfb428b618194 (Oct 25 2023 - 09:17:12 -0300) > > CPU: Freescale i.MX8MP[8] rev1.0 at 1200 MHz > Reset cause: POR > Model: NXP i.MX8MPlus EVK board > DRAM: 6 GiB > Core: 103 devices, 26 uclasses, devicetree: separate > WDT: Started watchdog@3028 with servicing every 1000ms (60s timeout) > MMC: FSL_SDHC: 1, FSL_SDHC: 2 > Loading Environment from MMC... OK > In: serial@3089 > Out: serial@3089 > Err: serial@3089 > SEC0: RNG instantiated > Net: > Error: ethernet@30bf address not set. > > Error: ethernet@30be address not set. > Could not get PHY for FEC0: addr 1 > > Error: ethernet@30bf address not set. > > Error: ethernet@30bf address not set. > No ethernet found. > > Hit any key to stop autoboot: 0 > u-boot=>
Re: [REGRESSION] imx: spl_imx_romapi: boot loops
Hi Rasmus On Tue, 2023-10-24 at 16:32 +0200, Rasmus Villemoes wrote: > On 24/10/2023 15.15, Marcel Ziswiler wrote: > > Hi Marcel > > tl;dr: can you try > > @@ -330,7 +335,7 @@ static int spl_romapi_load_image_stream(struct > spl_image_info *spl_image, > > ss.base = phdr; > ss.end = p; > - ss.pagesize = pagesize; > + ss.pagesize = 1024; > > memset(&load, 0, sizeof(load)); > load.bl_len = 1; > > and also put 1024 in the binman node so u-boot.itb is also 1024-byte > aligned? That did not help. > This will likely break usb boot (where pagesize==1), so if you want the > binary to work with usb you can make the RHS instead "(pagesize > 1 ? > 1024 : 1)" or something like that. > > I don't think it will work, but OTOH my analysis below doesn't find any > other (fundamental) difference between the old and new code. > > > > > On Tue, 2023-10-24 at 13:17 +0200, Rasmus Villemoes wrote: > > > > > > > > and this works just fine. But in my case ss->pagesize is 1, whereas you > > > have 512. > > > > > > Just exactly how are you booting? It says "Boot Stage: Primary boot" > > > whereas I'm doing serial download with uuu (i.e. "Boot Stage: USB boot"). > > > > Yes, regular eMMC boot. > > [snip] > > > > > At least I am not aware that we would be doing anything special for eMMC > > boot. > > Well, I/we usually do boot from eMMC (except during bootstrap where we > use uuu), more precisely from the eMMC boot partitions, but that doesn't > end up using the spl_romapi_load_image_stream() but instead the expected > spl_romapi_load_image_seekable(). > > Perhaps some NXP folks can explain the logic behind > > static int is_boot_from_stream_device(u32 boot) > { > u32 interface; > > interface = boot >> 16; > if (interface >= BT_DEV_TYPE_USB) > return 1; > > if (interface == BT_DEV_TYPE_MMC && (boot & 1)) > return 1; > > return 0; > } > > Apparently that "boot & 1" is an indication that "eMMC fast boot mode" > is enabled (not to be confused with fastboot which is a USB protocol > that only becomes relevant once U-Boot proper is up and running). Yes, we use eMMC fast boot mode. > As I've complained about previously, the ROM API is almost entirely > undocumented. There's something in imx93rm.pdf (which is where I have > that eMMC fast boot info from), but I have no idea if that applies to > imx8/imx8mp as well. > > Are there any alignment requirements on the destination and/or the size > parameter? Is there some timing requirements so that if we read too late > the data is lost? So could e.g. a bunch of printf debugging break boot? > > Because I really can't see the fundamental difference between now and > then. Both before and after the commit in question, the code does: > > - read 1024 bytes at a time, search each chunk for FDT magic > > This then gives the "Find img info 0x4802b000" > > - make sure the leftover within that 1024 chunk is a full FDT header > (usually ok, so no output) > > - read the FDT size from that header, round up to a multiple of 1024, > fetch that - that's the "Need continue download 1024". > > And then the flow deviates. > > The old code would do the fake spl_fit_load to figure out the maximum > offset (thus the real total .itb size), then take that remaining size, > round up to ->pagesize (512), and fetch that with one final > rom_api_download_image(p, 0, imagesize);. > > My code instead does a number of rom_api_download_image() calls, where > each size argument is rounded up to the ->pagesize from the boot_info > query (i.e. 512). So it's possible that for one of those calls, the > destination is only 512-byte aligned (because a previous call fetched an > odd number of 512 byte blocks), and that doesn't happen in the previous > case where all but the last rom_api_download_image() have fetched 1024 > byte aligned chunks. > > What am I missing? Good question. Some more debugging revealed that we are missing 464 bytes at the beginning of the buffer. Why would that be? > Rasmus Cheers Marcel
[PATCH v1 1/2] imx: spl_imx_romapi: fix comment about stream(usb) download failure
From: Marcel Ziswiler Fix comment about Stream(USB) download failure. Fixes: 1cbebc786276 ("imx: add rom api support") Signed-off-by: Marcel Ziswiler --- arch/arm/mach-imx/spl_imx_romapi.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/mach-imx/spl_imx_romapi.c b/arch/arm/mach-imx/spl_imx_romapi.c index 93d48e56aca..cb220869b50 100644 --- a/arch/arm/mach-imx/spl_imx_romapi.c +++ b/arch/arm/mach-imx/spl_imx_romapi.c @@ -285,7 +285,7 @@ static int spl_romapi_load_image_stream(struct spl_image_info *spl_image, ret = rom_api_download_image(p, 0, pg); if (ret != ROM_API_OKAY) { - puts("Steam(USB) download failure\n"); + puts("Stream(USB) download failure\n"); return -1; } @@ -305,7 +305,7 @@ static int spl_romapi_load_image_stream(struct spl_image_info *spl_image, ret = rom_api_download_image(p, 0, pg); if (ret != ROM_API_OKAY) { - puts("Steam(USB) download failure\n"); + puts("Stream(USB) download failure\n"); return -1; } -- 2.36.1
[PATCH v1 0/2] imx: spl_imx_romapi: fixes
From: Marcel Ziswiler The first patch is a trivial spelling fix in comments. The second fixes a recent regression that only manifests in the eMMC fast boot mode case which does actually also use streaming rather than seekable. Thanks go to Rasmus who helped me debug this and suggested the fix. @Stefano: This one is also still missing [1]. Thanks! [1] https://lore.kernel.org/all/20230828213803.454303-1-mar...@ziswiler.com Marcel Ziswiler (2): imx: spl_imx_romapi: fix comment about stream(usb) download failure imx: spl_imx_romapi: fix emmc fast boot mode case arch/arm/mach-imx/spl_imx_romapi.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) -- 2.36.1
[PATCH v1 2/2] imx: spl_imx_romapi: fix emmc fast boot mode case
From: Marcel Ziswiler This fixes a regression in the eMMC fast boot mode case where the buffer was missing 464 bytes. The code figures out how many bytes must at least be fetched to honor the current read, rounds that up to the ss->pagesize [which is a no-op in the USB download case because that has ->pagesize==1], fetches that many bytes, but then recorded the original upper bound as the new end of the valid data. However, this did not take into account the rounding up to the ss->pagesize. Fix this by recording the actual bytes downloaded. Fixes: 4b4472438f5a ("imx: spl_imx_romapi: avoid tricky use of spl_load_simple_fit() to get full FIT size") Signed-off-by: Marcel Ziswiler --- arch/arm/mach-imx/spl_imx_romapi.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/mach-imx/spl_imx_romapi.c b/arch/arm/mach-imx/spl_imx_romapi.c index cb220869b50..5eb5a3d3c4a 100644 --- a/arch/arm/mach-imx/spl_imx_romapi.c +++ b/arch/arm/mach-imx/spl_imx_romapi.c @@ -162,7 +162,7 @@ static ulong spl_romapi_read_stream(struct spl_load_info *load, ulong sector, return 0; } - ss->end = end; + ss->end += bytes; } memcpy(buf, (void *)(sector), count); -- 2.36.1
Re: [REGRESSION] imx: spl_imx_romapi: boot loops
Hi Rasmus On Wed, 2023-10-25 at 20:35 +0200, Rasmus Villemoes wrote: > On 25/10/2023 18.01, Marcel Ziswiler wrote: > > Hi Rasmus > > > > On Tue, 2023-10-24 at 16:32 +0200, Rasmus Villemoes wrote: > > > > What am I missing? > > > > Good question. Some more debugging revealed that we are missing 464 bytes > > at the beginning of the buffer. > > Why > > would that be? > > [slaps forehead] > > bytes = end - ss->end; > bytes += ss->pagesize - 1; > bytes /= ss->pagesize; > bytes *= ss->pagesize; > > ret = rom_api_download_image(ss->end, 0, bytes); > ... > ss->end = end; > > So I figure out how many bytes must at least be fetched to honor the > current read, round that up to the ss->pagesize [which is a no-op in the > usb download case because that has ->pagesize==1, so I even considered > leaving that rounding-up out], fetch that many bytes, but then record > the original upper bound as the new end of the valid data. That can > certainly account for losing something 0 < foo < pagesize number of bytes. > > So let's try if changing that last line to > > ss->end += bytes; > > works better. Yes, that cuts it. Please find the fix here [1]. > Rasmus Thanks again for all your help! [1] https://lore.kernel.org/all/20231026073220.244387-1-mar...@ziswiler.com Cheers Marcel
Re: [PATCH v5 2/2] board: mediatek: add mt8195 demo board
Hi Fabien and Macpaul Thanks for your patch set. On Fri, 2023-08-04 at 19:04 +0800, Macpaul Lin wrote: > From: Fabien Parent > > Add mt8195-demo board support. > This demo purpose board uses MediaTek's MT8195 SoC. > > Signed-off-by: Fabien Parent > Signed-off-by: Amjad Ouled-Ameur > Signed-off-by: Macpaul Lin > --- > MAINTAINERS | 1 + > arch/arm/dts/Makefile | 1 + > arch/arm/dts/mt8195-demo.dts | 122 > board/mediatek/mt8195/MAINTAINERS | 6 ++ > board/mediatek/mt8195/Makefile | 3 + > board/mediatek/mt8195/README | 65 +++ Rather than such scattered README files nowadays it is preferred adding such documentation at doc/board/mediatek. > board/mediatek/mt8195/mt8195_demo.c | 38 + > configs/mt8195_demo_defconfig | 99 ++ > include/configs/mt8195.h | 46 +++ > 9 files changed, 381 insertions(+) > create mode 100644 arch/arm/dts/mt8195-demo.dts > create mode 100644 board/mediatek/mt8195/MAINTAINERS > create mode 100644 board/mediatek/mt8195/Makefile > create mode 100644 board/mediatek/mt8195/README > create mode 100644 board/mediatek/mt8195/mt8195_demo.c > create mode 100644 configs/mt8195_demo_defconfig > create mode 100644 include/configs/mt8195.h > > Changes for v2 and v3: > - no change. > > Changes for v4: > - Remove CONFIG_SYS_NS16550 related settings in mt8195.h. > > Changes for v5: > - Fix Copyright year to 2023. > - Fix build error by adding 'CONFIG_TEXT_BASE' in defconfig. > - Add README for mt8195-demo board includes toolchain setting > 'CROSS_COMPILE=aarch64-linux-gnu-' > - Fix 'CONFIG_EXTRA_ENV_SETTINGS' with 'CFG_EXTRA_ENV_SETTINGS' > according to checkpatch error. > - Update dram to 8GB size. > - dts > - Add optee and pcsi support in firmware section. > - mt8195_demo_defconfig > - enable I2C, DFU, GPT, MBR support > - enable some USB ethernet adaptors > - rebase patchset to v2023-10.rc1 > > diff --git a/MAINTAINERS b/MAINTAINERS > index 4d0f017e7e..454d3615f4 100644 > --- a/MAINTAINERS > +++ b/MAINTAINERS > @@ -396,6 +396,7 @@ F:drivers/watchdog/mtk_wdt.c > F: drivers/net/mtk_eth.c > F: drivers/net/mtk_eth.h > F: drivers/reset/reset-mediatek.c > +F: include/configs/mt8195.h > F: tools/mtk_image.c > F: tools/mtk_image.h > F: tools/mtk_nand_headers.c > diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile > index e66c32e268..d7104b77bf 100644 > --- a/arch/arm/dts/Makefile > +++ b/arch/arm/dts/Makefile > @@ -1342,6 +1342,7 @@ dtb-$(CONFIG_ARCH_MEDIATEK) += \ > mt7986a-emmc-rfb.dtb \ > mt7986b-emmc-rfb.dtb \ > mt8183-pumpkin.dtb \ > + mt8195-demo.dtb \ > mt8512-bm1-emmc.dtb \ > mt8516-pumpkin.dtb \ > mt8518-ap1-emmc.dtb > diff --git a/arch/arm/dts/mt8195-demo.dts b/arch/arm/dts/mt8195-demo.dts > new file mode 100644 > index 00..e4063cd143 > --- /dev/null > +++ b/arch/arm/dts/mt8195-demo.dts > @@ -0,0 +1,122 @@ > +// SPDX-License-Identifier: GPL-2.0 OR MIT > +/* > + * Copyright (C) 2023 MediaTek Inc. > + * Copyright (C) 2023 BayLibre SAS. > + * Author: Macpaul Lin > + * Author: Fabien Parent > + */ > + > +/dts-v1/; > + > +#include > +#include "mt8195.dtsi" > + > +/ { > + model = "MediaTek MT8195 demo board"; > + compatible = "mediatek,mt8195-demo", "mediatek,mt8195"; > + > + memory@4000 { > + /* 8GB */ > + device_type = "memory"; > + reg = <0 0x4000 2 0x>; > + }; > + > + firmware: firmware { > + optee { > + compatible = "linaro,optee-tz"; > + method = "smc"; > + }; > + > + psci: psci { > + compatible = "arm,psci-1.0"; > + method = "smc"; > + }; > + }; > + > + reserved-memory { > + #address-cells = <2>; > + #size-cells = <2>; > + ranges; > + > + /* 2 MiB reserved for ARM Trusted Firmware (BL31) */ > + bl31_secmon_reserved: secmon@5460 { > + no-map; > + reg = <0 0x5460 0x0 0x20>; > + }; > + > + /* 12 MiB reserved for OP-TEE (BL32) > + * +---+ 0x43e0_ > + * | SHMEM 2MiB | > + * +---+ 0x43c0_ > + * | | TA_RAM 8MiB | > + * + TZDRAM +--+ 0x4340_ > + * | | TEE_RAM 2MiB | > + * +---+ 0x4320_ > + */ > + optee_reserved: optee@4320 { > + no-map; > + reg = <0 0x4320 0 0x00c0>; > + }; > + }; > + > + chosen { > + stdout-path = &uart0; > + }; > + > + reg_1p8v: regulator
Re: [PATCH 1/3] arm: dts: k3-am625-sk-u-boot.dtsi: Update main_bcdma and main_pktdma nodes
On Fri, 2023-10-27 at 16:46 +0300, Roger Quadros wrote: > From: Siddharth Vadapalli > > Update main_bcdma and main_pktdma nodes for native configuration in the > absence of DM services. > > Reported-by: Nishanth Menon > Signed-off-by: Siddharth Vadapalli > Signed-off-by: Roger Quadros > --- > arch/arm/dts/k3-am625-sk-u-boot.dtsi | 27 +++ > 1 file changed, 27 insertions(+) > > diff --git a/arch/arm/dts/k3-am625-sk-u-boot.dtsi > b/arch/arm/dts/k3-am625-sk-u-boot.dtsi > index b78d34b459..7186f0830f 100644 > --- a/arch/arm/dts/k3-am625-sk-u-boot.dtsi > +++ b/arch/arm/dts/k3-am625-sk-u-boot.dtsi > @@ -154,6 +154,33 @@ > bootph-all; > }; > > +&main_bcdma { > + reg = <0x00 0x485c0100 0x00 0x100>, > + <0x00 0x4c00 0x00 0x2>, > + <0x00 0x4a82 0x00 0x2>, > + <0x00 0x4aa4 0x00 0x2>, > + <0x00 0x4bc0 0x00 0x10>, > + <0x00 0x4860 0x00 0x8000>, > + <0x00 0x484a4000 0x00 0x2000>, > + <0x00 0x484c2000 0x00 0x2000>; > + reg-names = "gcfg", "bchanrt", "rchanrt", "tchanrt", > + "ringrt" , "cfg", "tchan", "rchan"; > +}; > + > +&main_pktdma { > + bootph-all; I believe that property would usually be added as the last item of a node. > + reg = <0x00 0x485c 0x00 0x100>, > + <0x00 0x4a80 0x00 0x2>, > + <0x00 0x4aa0 0x00 0x2>, > + <0x00 0x4b80 0x00 0x20>, > + <0x00 0x485e 0x00 0x1>, > + <0x00 0x484a 0x00 0x2000>, > + <0x00 0x484c 0x00 0x2000>, > + <0x00 0x4843 0x00 0x1000>; > + reg-names = "gcfg", "rchanrt", "tchanrt", "ringrt", > + "cfg", "tchan", "rchan", "rflow"; > +}; > + > &cpsw3g { > bootph-all; > ethernet-ports {
Re: [PATCH 2/3] arm: dts: k3-am625-verdin-wifi-dev-u-boot.dtsi: Fix DMA/Ethernet
On Fri, 2023-10-27 at 16:46 +0300, Roger Quadros wrote: > Update main_bcdma and main_pktdma nodes for native configuration in the > absence of DM services. u-boot k3-udma driver expects these additional > register fields else probe will fail. > > Reported-by: Nishanth Menon > Signed-off-by: Roger Quadros With just one minor nitpick blow. Tested-by: Marcel Ziswiler > --- > .../dts/k3-am625-verdin-wifi-dev-u-boot.dtsi | 27 +++ > 1 file changed, 27 insertions(+) > > diff --git a/arch/arm/dts/k3-am625-verdin-wifi-dev-u-boot.dtsi > b/arch/arm/dts/k3-am625-verdin-wifi-dev-u- > boot.dtsi > index afa24d07a4..730cb21ce9 100644 > --- a/arch/arm/dts/k3-am625-verdin-wifi-dev-u-boot.dtsi > +++ b/arch/arm/dts/k3-am625-verdin-wifi-dev-u-boot.dtsi > @@ -42,6 +42,33 @@ > bootph-all; > }; > > +&main_bcdma { > + reg = <0x00 0x485c0100 0x00 0x100>, > + <0x00 0x4c00 0x00 0x2>, > + <0x00 0x4a82 0x00 0x2>, > + <0x00 0x4aa4 0x00 0x2>, > + <0x00 0x4bc0 0x00 0x10>, > + <0x00 0x4860 0x00 0x8000>, > + <0x00 0x484a4000 0x00 0x2000>, > + <0x00 0x484c2000 0x00 0x2000>; > + reg-names = "gcfg", "bchanrt", "rchanrt", "tchanrt", > + "ringrt" , "cfg", "tchan", "rchan"; > +}; > + > +&main_pktdma { > + bootph-all; Ditto, I believe that property would usually be added as the last item of a node. > + reg = <0x00 0x485c 0x00 0x100>, > + <0x00 0x4a80 0x00 0x2>, > + <0x00 0x4aa0 0x00 0x2>, > + <0x00 0x4b80 0x00 0x20>, > + <0x00 0x485e 0x00 0x1>, > + <0x00 0x484a 0x00 0x2000>, > + <0x00 0x484c 0x00 0x2000>, > + <0x00 0x4843 0x00 0x1000>; > + reg-names = "gcfg", "rchanrt", "tchanrt", "ringrt", > + "cfg", "tchan", "rchan", "rflow"; > +}; > + > &cpsw3g { > bootph-all; > };
Re: [PATCH 0/3] arm: dts: k3-am6: Fix Ethernet/DMA
Hi Nishanth On Fri, 2023-10-27 at 15:46 -0500, Nishanth Menon wrote: > On 16:46-20231027, Roger Quadros wrote: > > Hi, > > > > Since commit [1], Ethernet is broken on TI AM62 and AM64 platforms. > > > > The commit [1] is not the culprit. It just unearths the problem by fixing > > the error check in k3-udma.c. This issue was silently being ignored earlier > > due to wrong error check. [NULL instead of FDT_ADDR_T_NONE]. > > > > Fix the issue by adding the necessary register spaces for the u-boot K3-UDMA > > driver for AM62 and AM64 platforms. > > > > [1] - 5fecea171de3dd ("treewide: use dev_read_addr_*_ptr() where > > appropriate") > > > > cheers, > > -roger > > > > Roger Quadros (1): > > arm: dts: k3-am625-verdin-wifi-dev-u-boot.dtsi: Fix DMA/Ethernet > > > > Siddharth Vadapalli (2): > > arm: dts: k3-am625-sk-u-boot.dtsi: Update main_bcdma and main_pktdma > > nodes > > arm: dts: k3-am642: Update main_bcdma and main_pktdma nodes > > > > arch/arm/dts/k3-am625-sk-u-boot.dtsi | 27 +++ > > .../dts/k3-am625-verdin-wifi-dev-u-boot.dtsi | 27 +++ > > arch/arm/dts/k3-am642-evm-u-boot.dtsi | 27 +++ > > arch/arm/dts/k3-am642-sk-u-boot.dtsi | 23 > > 4 files changed, 104 insertions(+) > > > > > > base-commit: 351da15f71e3d70dbc63e90781b403415452d864 > > -- > > 2.34.1 > > > > > Thanks for this. > > Reviewed-by: Nishanth Menon > > NOTE: These extra properties are already in discussion in Linux > community. > > https://lore.kernel.org/linux-arm-kernel/20230810174356.3322583-1-vigne...@ti.com/ > > Marcel, could the Toradex team confirm as well? Yes, I just successfully tested it. With what you say above I also assume eventually those properties will move to the SoC dtsi rather than having to be separately defined U-Boot-specific in each and every board. Thanks guys. Cheers Marcel
Re: [PATCH v1 2/2] imx: spl_imx_romapi: fix emmc fast boot mode case
Hi Stefano On Thu, 2023-10-26 at 10:36 +0200, Stefano Babic wrote: > On 26.10.23 10:29, Rasmus Villemoes wrote: > > On 26/10/2023 09.32, Marcel Ziswiler wrote: > > > From: Marcel Ziswiler > > > > > > This fixes a regression in the eMMC fast boot mode case where the buffer > > > was missing 464 bytes. > > > > > > The code figures out how many bytes must at least be fetched to honor > > > the current read, rounds that up to the ss->pagesize [which is a no-op > > > in the USB download case because that has ->pagesize==1], fetches that > > > many bytes, but then recorded the original upper bound as the new end of > > > the valid data. However, this did not take into account the rounding up > > > to the ss->pagesize. Fix this by recording the actual bytes downloaded. > > > > > > Fixes: 4b4472438f5a ("imx: spl_imx_romapi: avoid tricky use of > > > spl_load_simple_fit() to get full FIT > > > size") > > > Signed-off-by: Marcel Ziswiler > > > > > > > Thanks for reporting and fixing this, and sorry for the trouble. > > > > Acked-by: Rasmus Villemoes > > > > And thanks for all your work - I will apply this fix soon. Any news on applying this fix? Note that master still stays broken as of today. > Regards, > Stefano Cheers Marcel
TF-A Hang on NXP i.MX 8M Plus QuadLite
Hi there We recently got our first batch of i.MX 8M Plus QuadLite based SoMs. While NXP downstream works just fine on them they just hang booting with latest upstream U-Boot (and TF-A). Replacing TF-A with the downstream NXP one made upstream U-Boot work as well. Further debugging TF-A showed imx_gpc_pm_domain_enable() to be the culprit. Looking more specifically I discovered the following so far downstream-only commit [1]. So it looks like in downstream NXP is limiting the to-be-enabled power management domains to HSIOMIX, USB1_PHY and USB2_PHY. Anybody knows why exactly this is done and why this got never upstreamed? Thank you very much for any insights into this matter. [1] https://github.com/nxp-imx/imx-atf/commit/47759cfca10b2286a218062915d4a280848cfc15 Cheers Marcel
Re: [PATCH v2 0/8] Add DFU, emmc and usb boot for TI am62x
Hi Sjoerd On Thu, 2023-06-01 at 08:37 +0200, Sjoerd Simons wrote: > On Wed, 2023-05-31 at 17:14 -0400, Tom Rini wrote: > > On Thu, Apr 06, 2023 at 08:55:34PM +0200, Sjoerd Simons wrote: > > > > > This series adds more boot sources for the TI am62x. For that the > > > dts' > > > are synced from the upstream ti-next git tree (to add usb nodes), > > > some > > > dwc3 glue is and finally the default configuration is tuned to add > > > support for DFU and USB (host and gadget) > > > > This seems, conceptually, fine. But as we're getting the TI dts > > files > > in sync with the kernel, I'm deferring this version and you'll want > > to > > rebase and re-post once everything has settled. > > Thanks for the update/hint ;) I also got a few review comments so the > plan is to include those and repost.. Just my may has been stupidly > busy causing me to not get around it in the first place, so maybe that > turned into good timing in the end. Any progress on this? I still carry your re-based series on top of latest master [1] and USB DFU is working very well on Verdin AM62. Thanks! [1] https://github.com/ziswiler/u-boot/tree/verdin-am62-usb-support Cheers Marcel
[PATCH v1] board: toradex: verdin-imx8mm: enable usb sdp spl recovery support
From: Marcel Ziswiler Enable USB SDP SPL aka serial downloader recovery mode support. While at it also enable fastboot support which may be used to subsequently load further stages like a Toradex Easy Installer FIT image. Signed-off-by: Marcel Ziswiler --- .../dts/imx8mm-verdin-wifi-dev-u-boot.dtsi| 17 configs/verdin-imx8mm_defconfig | 20 +++ 2 files changed, 37 insertions(+) diff --git a/arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi b/arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi index 2b268f55cb9..b06ce3fa034 100644 --- a/arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi +++ b/arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi @@ -34,6 +34,10 @@ bootph-pre-ram; }; +&aips4 { + bootph-pre-ram; +}; + &binman_uboot { offset = <0x5fc00>; }; @@ -124,6 +128,19 @@ bootph-pre-ram; }; +&usbmisc1 { + bootph-pre-ram; +}; + +/* Verdin USB_1 */ +&usbotg1 { + bootph-pre-ram; +}; + +&usbphynop1 { + bootph-pre-ram; +}; + &usdhc1 { bootph-pre-ram; }; diff --git a/configs/verdin-imx8mm_defconfig b/configs/verdin-imx8mm_defconfig index 09e14c6f8c4..2fbde394577 100644 --- a/configs/verdin-imx8mm_defconfig +++ b/configs/verdin-imx8mm_defconfig @@ -69,6 +69,8 @@ CONFIG_CMD_I2C=y CONFIG_CMD_MMC=y CONFIG_CMD_READ=y CONFIG_CMD_USB=y +CONFIG_CMD_USB_SDP=y +CONFIG_CMD_USB_MASS_STORAGE=y CONFIG_CMD_BOOTCOUNT=y CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y @@ -97,6 +99,12 @@ CONFIG_SPL_CLK_COMPOSITE_CCF=y CONFIG_CLK_COMPOSITE_CCF=y CONFIG_SPL_CLK_IMX8MM=y CONFIG_CLK_IMX8MM=y +CONFIG_USB_FUNCTION_FASTBOOT=y +CONFIG_FASTBOOT_BUF_ADDR=0x4280 +CONFIG_FASTBOOT_BUF_SIZE=0x4000 +CONFIG_FASTBOOT_FLASH=y +CONFIG_FASTBOOT_UUU_SUPPORT=y +CONFIG_FASTBOOT_FLASH_MMC_DEV=0 CONFIG_GPIO_HOG=y CONFIG_SPL_GPIO_HOG=y CONFIG_MXC_GPIO=y @@ -120,6 +128,8 @@ CONFIG_PHY_FIXED=y CONFIG_DM_MDIO=y CONFIG_FEC_MXC=y CONFIG_MII=y +CONFIG_SPL_PHY=y +CONFIG_SPL_NOP_PHY=y CONFIG_PINCTRL=y CONFIG_SPL_PINCTRL=y CONFIG_PINCTRL_IMX8M=y @@ -139,8 +149,18 @@ CONFIG_SYSRESET_WATCHDOG=y CONFIG_DM_THERMAL=y CONFIG_IMX_TMU=y CONFIG_USB=y +CONFIG_SPL_USB_HOST=y CONFIG_USB_EHCI_HCD=y +CONFIG_MXC_USB_OTG_HACTIVE=y CONFIG_USB_KEYBOARD=y CONFIG_USB_HOST_ETHER=y +CONFIG_USB_GADGET=y +CONFIG_SPL_USB_GADGET=y +CONFIG_USB_GADGET_MANUFACTURER="Toradex" +CONFIG_USB_GADGET_VENDOR_NUM=0x1b67 +CONFIG_USB_GADGET_PRODUCT_NUM=0x4000 +CONFIG_CI_UDC=y +CONFIG_SDP_LOADADDR=0x4040 +CONFIG_SPL_USB_SDP_SUPPORT=y CONFIG_IMX_WATCHDOG=y CONFIG_HEXDUMP=y -- 2.36.1
Re: [PATCH V5 02/17] include: configs: am62x_evm: Drop unused SDRAM address
On Thu, 2023-08-24 at 07:05 -0500, Nishanth Menon wrote: > On 10:13-20230824, Mattijs Korpershoek wrote: > > Hi Nishanth, > > > > On mer., août 23, 2023 at 22:10, Nishanth Menon wrote: > > > > > Drop unused macro. This was meant for a second region of DDR which we > > > do not need for AM62x evm configurations. > > > > > > Signed-off-by: Nishanth Menon > > > --- > > > New patch (part of bootstd transition) > > > > > > include/configs/am62x_evm.h | 3 --- > > > 1 file changed, 3 deletions(-) > > > > What about include/configs/verdin-am62.h ? > > > > It seems that that board, which is am62x based, also has the un-needed > > include. > > > > Since i'm not 100% sure, I have added Marcel (who posted the verdin am62 > > support) here. > > Toradex team, Can you handle that cleanup? I stayed focussed on am62x_evm side > of things. Yes, of course. > > > diff --git a/include/configs/am62x_evm.h b/include/configs/am62x_evm.h > > > index 44180dc7687b..379e0c13a395 100644 > > > --- a/include/configs/am62x_evm.h > > > +++ b/include/configs/am62x_evm.h > > > @@ -12,9 +12,6 @@ > > > #include > > > #include > > > > > > -/* DDR Configuration */ > > > -#define CFG_SYS_SDRAM_BASE10x88000 > > > - > > > /* Now for the remaining common defines */ > > > #include > > > > > > -- > > > 2.40.0
Re: [PATCH v7 1/2] phy: phy-imx8mq-usb: add vbus regulator support
Hi Tim Thanks! On Thu, 2023-07-13 at 11:56 -0700, Tim Harvey wrote: > Add support for enabling and disabling vbus-supply regulator found > on several imx8mp boards in the usb3_phy0 and usb3_phy1 nodes. > > Signed-off-by: Tim Harvey > Reviewed-by: Adam Ford > Reviewed-by: Marek Vasut Tested-by: Marcel Ziswiler > --- > v7: > - add #ifdef protection around clk_disable error path > > v6: > - move changes to clk to separate patch > - sort new vars in reverse christmas tree style > > v5: > - remove #if CONFIG_IS_ENABLED around struct members > (you can not conditionally include if using if (CONFIG_IS_ENABLED(foo)) ) > - replace clk '#if CONFIG_IS_ENABLED(CLK)' with 'if (CONFIG_IS_ENABLED(CLK))' > > v4: > - use regulator_set_enable_if_allowed to handle regulator reference > counting > errors > - added Marek's rb tag > > v3: > - change pr_err to dev_err > - add #if CONFIG_IS_ENABLED around vbus_supply in struct > - add fail path to disable clock if regulator enable failed > > v2: > - protect ret with __maybe_unused in case CONFIG_CLK and > CONFIG_DM_REGULATOR not defined > - add error prints on failures > - add Adam's rb tag > Signed-off-by: Tim Harvey > --- > drivers/phy/phy-imx8mq-usb.c | 39 +--- > 1 file changed, 36 insertions(+), 3 deletions(-) > > diff --git a/drivers/phy/phy-imx8mq-usb.c b/drivers/phy/phy-imx8mq-usb.c > index 69f01de55538..9fa78ef4da3d 100644 > --- a/drivers/phy/phy-imx8mq-usb.c > +++ b/drivers/phy/phy-imx8mq-usb.c > @@ -14,6 +14,8 @@ > #include > #include > #include > +#include > +#include > > #define PHY_CTRL0 0x0 > #define PHY_CTRL0_REF_SSP_EN BIT(2) > @@ -81,6 +83,7 @@ struct imx8mq_usb_phy { > #endif > void __iomem *base; > enum imx8mpq_phy_type type; > + struct udevice *vbus_supply; > }; > > static const struct udevice_id imx8mq_usb_phy_of_match[] = { > @@ -173,9 +176,9 @@ static int imx8mq_usb_phy_power_on(struct phy *usb_phy) > struct udevice *dev = usb_phy->dev; > struct imx8mq_usb_phy *imx_phy = dev_get_priv(dev); > u32 value; > + int ret; > > #if CONFIG_IS_ENABLED(CLK) > - int ret; > ret = clk_enable(&imx_phy->phy_clk); > if (ret) { > printf("Failed to enable usb phy clock\n"); > @@ -183,12 +186,26 @@ static int imx8mq_usb_phy_power_on(struct phy *usb_phy) > } > #endif > > + if (CONFIG_IS_ENABLED(DM_REGULATOR) && imx_phy->vbus_supply) { > + ret = regulator_set_enable_if_allowed(imx_phy->vbus_supply, > true); > + if (ret && ret != -ENOSYS) { > + dev_err(dev, "Failed to enable VBUS regulator: %d\n", > ret); > + goto err; > + } > + } > + > /* Disable rx term override */ > value = readl(imx_phy->base + PHY_CTRL6); > value &= ~PHY_CTRL6_RXTERM_OVERRIDE_SEL; > writel(value, imx_phy->base + PHY_CTRL6); > > return 0; > + > +err: > +#if CONFIG_IS_ENABLED(CLK) > + clk_disable(&imx_phy->phy_clk); > +#endif > + return ret; > } > > static int imx8mq_usb_phy_power_off(struct phy *usb_phy) > @@ -196,6 +213,7 @@ static int imx8mq_usb_phy_power_off(struct phy *usb_phy) > struct udevice *dev = usb_phy->dev; > struct imx8mq_usb_phy *imx_phy = dev_get_priv(dev); > u32 value; > + int ret; > > /* Override rx term to be 0 */ > value = readl(imx_phy->base + PHY_CTRL6); > @@ -206,6 +224,14 @@ static int imx8mq_usb_phy_power_off(struct phy *usb_phy) > clk_disable(&imx_phy->phy_clk); > #endif > > + if (CONFIG_IS_ENABLED(DM_REGULATOR) && imx_phy->vbus_supply) { > + ret = regulator_set_enable_if_allowed(imx_phy->vbus_supply, > false); > + if (ret && ret != -ENOSYS) { > + dev_err(dev, "Failed to disable VBUS regulator: > %d\n", ret); > + return ret; > + } > + } > + > return 0; > } > > @@ -224,6 +250,7 @@ struct phy_ops imx8mq_usb_phy_ops = { > int imx8mq_usb_phy_probe(struct udevice *dev) > { > struct imx8mq_usb_phy *priv = dev_get_priv(dev); > + int ret; > > priv->type = dev_get_driver_data(dev); > priv->base = dev_read_addr_ptr(dev); > @@ -232,8 +259,6 @@ int imx8mq_usb_phy_probe(
Re: [PATCH v2 3/3] board: toradex: add verdin am62 support
Sali Alexander On August 25, 2023 6:24:01 PM GMT+02:00, "Sverdlin, Alexander" wrote: >Hello Marcel, > >On Fri, 2023-08-25 at 15:20 +0200, Alexander Sverdlin wrote: >> > +Build U-Boot for R5 >> > +--- >> > + >> > +.. code-block:: bash >> > + >> > + $ export ARCH=arm >> > + $ export CROSS_COMPILE=arm-none-linux-gnueabihf- >> > + $ make verdin-am62_r5_defconfig O=/tmp/r5 >> > + $ make O=/tmp/r5 >> > + $ cd ../k3-image-gen >> > + $ make SOC=am62x SBL=/tmp/r5/spl/u-boot-spl.bin >> > SYSFW_PATH=../ti-linux-firmware/ti-sysfw/ti-fs-firmware-am62x-gp.bin >> > + $ cp tiboot3-am62x-gp-evm.bin ../tiboot3.bin >> > + >> >> the existing K3 platforms have been converted to binman workflow: >> https://patchwork.ozlabs.org/project/uboot/patch/20230721184446.5821-21-n-fran...@ti.com/ >> >> Do you think it makes sense to convert the newly added Verdin board >> to binman workflow as well? > >I'm sorry for the noise, I totally missed the fact this has been fixed and >accepted already! Don't worry and enjoy (;-p). Cheers Marcel
Re: [PATCH v2] arm: dts: imx8m: move CAAM nodes into common u-boot.dtsi
Hi Tim Thanks! On Thu, 2023-08-24 at 12:03 -0700, Tim Harvey wrote: > Move the crypto and sec_jr* nodes from board-specific > u-boot.dtsi files into the common files. Additionally protect the > nodes with ifdef CONFIG_FSL_CAAM as they don't serve any purpose if > that is not enabled. > > Signed-off-by: Tim Harvey Reviewed-by: Marcel Ziswiler > --- > v2: > - fix invalid ifdef > - add rb tags from Fabio and Peng > --- > arch/arm/dts/imx8mm-evk-u-boot.dtsi | 16 --- > .../dts/imx8mm-kontron-bl-common-u-boot.dtsi | 16 --- > arch/arm/dts/imx8mm-u-boot.dtsi | 20 +++ > arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi | 16 --- > arch/arm/dts/imx8mn-u-boot.dtsi | 20 +++ > arch/arm/dts/imx8mp-beacon-kit-u-boot.dtsi | 16 --- > arch/arm/dts/imx8mp-evk-u-boot.dtsi | 16 --- > .../imx8mp-icore-mx8mp-edimm2.2-u-boot.dtsi | 16 --- > arch/arm/dts/imx8mp-u-boot.dtsi | 20 +++ > .../dts/imx8mp-verdin-wifi-dev-u-boot.dtsi | 16 --- > 10 files changed, 60 insertions(+), 112 deletions(-) > > diff --git a/arch/arm/dts/imx8mm-evk-u-boot.dtsi > b/arch/arm/dts/imx8mm-evk-u-boot.dtsi > index 155670da18d1..9a5b0795133b 100644 > --- a/arch/arm/dts/imx8mm-evk-u-boot.dtsi > +++ b/arch/arm/dts/imx8mm-evk-u-boot.dtsi > @@ -65,22 +65,6 @@ > bootph-pre-ram; > }; > > -&crypto { > - bootph-pre-ram; > -}; > - > -&sec_jr0 { > - bootph-pre-ram; > -}; > - > -&sec_jr1 { > - bootph-pre-ram; > -}; > - > -&sec_jr2 { > - bootph-pre-ram; > -}; > - > &usbmisc1 { > bootph-pre-ram; > }; > diff --git a/arch/arm/dts/imx8mm-kontron-bl-common-u-boot.dtsi > b/arch/arm/dts/imx8mm-kontron-bl-common-u- > boot.dtsi > index 1ad9d49a1118..ae542fdcffad 100644 > --- a/arch/arm/dts/imx8mm-kontron-bl-common-u-boot.dtsi > +++ b/arch/arm/dts/imx8mm-kontron-bl-common-u-boot.dtsi > @@ -18,22 +18,6 @@ > }; > }; > > -&crypto { > - bootph-pre-ram; > -}; > - > -&sec_jr0 { > - bootph-pre-ram; > -}; > - > -&sec_jr1 { > - bootph-pre-ram; > -}; > - > -&sec_jr2 { > - bootph-pre-ram; > -}; > - > &i2c1 { > bootph-pre-ram; > bootph-all; > diff --git a/arch/arm/dts/imx8mm-u-boot.dtsi b/arch/arm/dts/imx8mm-u-boot.dtsi > index a843bb851eaf..0bd7ad980b66 100644 > --- a/arch/arm/dts/imx8mm-u-boot.dtsi > +++ b/arch/arm/dts/imx8mm-u-boot.dtsi > @@ -18,6 +18,12 @@ > #endif > }; > > +#ifdef CONFIG_FSL_CAAM > +&crypto { > + bootph-pre-ram; > +}; > +#endif > + > &soc { > bootph-all; > bootph-pre-ram; > @@ -216,6 +222,20 @@ > bootph-pre-ram; > }; > > +#ifdef CONFIG_FSL_CAAM > +&sec_jr0 { > + bootph-pre-ram; > +}; > + > +&sec_jr1 { > + bootph-pre-ram; > +}; > + > +&sec_jr2 { > + bootph-pre-ram; > +}; > +#endif > + > &spba1 { > bootph-all; > bootph-pre-ram; > diff --git a/arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi > b/arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi > index 315714f39848..c31f3dec3de4 100644 > --- a/arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi > +++ b/arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi > @@ -57,22 +57,6 @@ > bootph-pre-ram; > }; > > -&crypto { > - bootph-pre-ram; > -}; > - > -&sec_jr0 { > - bootph-pre-ram; > -}; > - > -&sec_jr1 { > - bootph-pre-ram; > -}; > - > -&sec_jr2 { > - bootph-pre-ram; > -}; > - > &usdhc1 { > bootph-pre-ram; > }; > diff --git a/arch/arm/dts/imx8mn-u-boot.dtsi b/arch/arm/dts/imx8mn-u-boot.dtsi > index 86c9a6cd67f0..3a9e4c16281e 100644 > --- a/arch/arm/dts/imx8mn-u-boot.dtsi > +++ b/arch/arm/dts/imx8mn-u-boot.dtsi > @@ -54,6 +54,12 @@ > /delete-property/ assigned-clock-rates; > }; > > +#ifdef CONFIG_FSL_CAAM > +&crypto { > + bootph-pre-ram; > +}; > +#endif > + > &iomuxc { > bootph-pre-ram; > }; > @@ -63,6 +69,20 @@ > bootph-all; > }; > > +#ifdef CONFIG_FSL_CAAM > +&sec_jr0 { > + bootph-pre-ram; > +}; > + > +&sec_jr1 { > + bootph-pre-ram; > +}; > + > +&sec_jr2 { > + bootph-pre-ram; > +}; > +#endif > + > &spba1 { > bootph-pre-ram; > }; > diff --git a/arch/arm/dts/imx8mp-beacon-kit-u-boot.dtsi > b/arch/arm/dts/imx8mp-b
Re: [PATCH v2 1/3] arm: dts: imx8mm: move firmware/optee node to common imx8mm-u-boot.dtsi
Hi Tim Thanks! On Thu, 2023-08-24 at 12:01 -0700, Tim Harvey wrote: > Move the firmware/optee node to the common imx8mm-u-boot.dtsi and > protect it with an ifdef CONFIG_OPTEE as it is a meaningless node > without the optee driver enabled. > > Signed-off-by: Tim Harvey > Reviewed-by: Fabio Estevam For the entire series. Reviewed-by: Marcel Ziswiler > --- > v2: added Fabio's rb tag > --- > arch/arm/dts/imx8mm-cl-iot-gate-optee-u-boot.dtsi | 7 --- > arch/arm/dts/imx8mm-cl-iot-gate-u-boot.dtsi | 7 --- > arch/arm/dts/imx8mm-evk-u-boot.dtsi | 7 --- > arch/arm/dts/imx8mm-kontron-bl-common-u-boot.dtsi | 7 --- > arch/arm/dts/imx8mm-phg-u-boot.dtsi | 7 --- > arch/arm/dts/imx8mm-u-boot.dtsi | 9 + > arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi | 7 --- > 7 files changed, 9 insertions(+), 42 deletions(-) > > diff --git a/arch/arm/dts/imx8mm-cl-iot-gate-optee-u-boot.dtsi > b/arch/arm/dts/imx8mm-cl-iot-gate-optee-u- > boot.dtsi > index 484e31824b85..d12ce6069cc7 100644 > --- a/arch/arm/dts/imx8mm-cl-iot-gate-optee-u-boot.dtsi > +++ b/arch/arm/dts/imx8mm-cl-iot-gate-optee-u-boot.dtsi > @@ -6,13 +6,6 @@ > #include "imx8mm-u-boot.dtsi" > > / { > - firmware { > - optee { > - compatible = "linaro,optee-tz"; > - method = "smc"; > - }; > - }; > - > wdt-reboot { > compatible = "wdt-reboot"; > bootph-pre-ram; > diff --git a/arch/arm/dts/imx8mm-cl-iot-gate-u-boot.dtsi > b/arch/arm/dts/imx8mm-cl-iot-gate-u-boot.dtsi > index 1878c4e13fbe..219504f61105 100644 > --- a/arch/arm/dts/imx8mm-cl-iot-gate-u-boot.dtsi > +++ b/arch/arm/dts/imx8mm-cl-iot-gate-u-boot.dtsi > @@ -6,13 +6,6 @@ > #include "imx8mm-u-boot.dtsi" > > / { > - firmware { > - optee { > - compatible = "linaro,optee-tz"; > - method = "smc"; > - }; > - }; > - > wdt-reboot { > compatible = "wdt-reboot"; > bootph-pre-ram; > diff --git a/arch/arm/dts/imx8mm-evk-u-boot.dtsi > b/arch/arm/dts/imx8mm-evk-u-boot.dtsi > index 13688ec0d0f2..155670da18d1 100644 > --- a/arch/arm/dts/imx8mm-evk-u-boot.dtsi > +++ b/arch/arm/dts/imx8mm-evk-u-boot.dtsi > @@ -11,13 +11,6 @@ > wdt = <&wdog1>; > bootph-pre-ram; > }; > - > - firmware { > - optee { > - compatible = "linaro,optee-tz"; > - method = "smc"; > - }; > - }; > }; > > &aips4 { > diff --git a/arch/arm/dts/imx8mm-kontron-bl-common-u-boot.dtsi > b/arch/arm/dts/imx8mm-kontron-bl-common-u- > boot.dtsi > index 65dfd33725ee..1ad9d49a1118 100644 > --- a/arch/arm/dts/imx8mm-kontron-bl-common-u-boot.dtsi > +++ b/arch/arm/dts/imx8mm-kontron-bl-common-u-boot.dtsi > @@ -16,13 +16,6 @@ > wdt = <&wdog1>; > bootph-pre-ram; > }; > - > - firmware { > - optee { > - compatible = "linaro,optee-tz"; > - method = "smc"; > - }; > - }; > }; > > &crypto { > diff --git a/arch/arm/dts/imx8mm-phg-u-boot.dtsi > b/arch/arm/dts/imx8mm-phg-u-boot.dtsi > index 3ced97cfaafa..c9e0b4420500 100644 > --- a/arch/arm/dts/imx8mm-phg-u-boot.dtsi > +++ b/arch/arm/dts/imx8mm-phg-u-boot.dtsi > @@ -11,13 +11,6 @@ > wdt = <&wdog1>; > bootph-pre-ram; > }; > - > - firmware { > - optee { > - compatible = "linaro,optee-tz"; > - method = "smc"; > - }; > - }; > }; > > &aips4 { > diff --git a/arch/arm/dts/imx8mm-u-boot.dtsi b/arch/arm/dts/imx8mm-u-boot.dtsi > index 035282bf0b00..a843bb851eaf 100644 > --- a/arch/arm/dts/imx8mm-u-boot.dtsi > +++ b/arch/arm/dts/imx8mm-u-boot.dtsi > @@ -7,6 +7,15 @@ > binman: binman { > multiple-images; > }; > + > +#ifdef CONFIG_OPTEE > + firmware { > + optee { > + compatible = "linaro,optee-tz"; > + method = "smc"; > + }; > + }; > +#endif > }; > > &soc { > diff --git a/arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi > b/arch/arm/dts/imx8mm-verdin-wifi-dev-u- > boot.dtsi > index 2b268f55cb95..24e565a06c2f 100644 > --- a/arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi > +++ b/arch/arm/dts/imx8mm-verdin-wifi-dev-u-boot.dtsi > @@ -6,13 +6,6 @@ > #include "imx8mm-u-boot.dtsi" > > / { > - firmware { > - optee { > - compatible = "linaro,optee-tz"; > - method = "smc"; > - }; > - }; > - > wdt-reboot { > compatible = "wdt-reboot"; > bootph-pre-ram; Cheers Marcel
[PATCH v1] board: toradex: verdin-imx8mp: enable usb device and fastboot support
From: Marcel Ziswiler Enable USB device and fastboot support which may be used to load the Toradex Easy Installer FIT image. While at it also enable USB mass storage aka UMS support. Note that the i.MX 8M Plus recovery mode support is based on the USB boot stage of the BOOTROM and does NOT require USB SDP SPL aka serial downloader support. Signed-off-by: Marcel Ziswiler --- configs/verdin-imx8mp_defconfig | 16 +++- 1 file changed, 15 insertions(+), 1 deletion(-) diff --git a/configs/verdin-imx8mp_defconfig b/configs/verdin-imx8mp_defconfig index 2df0f4f3443..4c6650c3453 100644 --- a/configs/verdin-imx8mp_defconfig +++ b/configs/verdin-imx8mp_defconfig @@ -79,6 +79,7 @@ CONFIG_CMD_I2C=y CONFIG_CMD_MMC=y CONFIG_CMD_READ=y CONFIG_CMD_USB=y +CONFIG_CMD_USB_MASS_STORAGE=y CONFIG_CMD_BOOTCOUNT=y CONFIG_CMD_CACHE=y CONFIG_CMD_TIME=y @@ -108,6 +109,12 @@ CONFIG_BOOTCOUNT_ENV=y CONFIG_CLK_COMPOSITE_CCF=y CONFIG_CLK_IMX8MP=y CONFIG_FSL_CAAM=y +CONFIG_USB_FUNCTION_FASTBOOT=y +CONFIG_FASTBOOT_BUF_ADDR=0x4280 +CONFIG_FASTBOOT_BUF_SIZE=0x4000 +CONFIG_FASTBOOT_FLASH=y +CONFIG_FASTBOOT_UUU_SUPPORT=y +CONFIG_FASTBOOT_FLASH_MMC_DEV=0 CONFIG_GPIO_HOG=y CONFIG_SPL_GPIO_HOG=y CONFIG_MXC_GPIO=y @@ -138,6 +145,7 @@ CONFIG_DWC_ETH_QOS_IMX=y CONFIG_FEC_MXC=y CONFIG_RGMII=y CONFIG_MII=y +CONFIG_PHY=y CONFIG_PHY_IMX8MQ_USB=y CONFIG_PINCTRL=y CONFIG_SPL_PINCTRL=y @@ -160,14 +168,20 @@ CONFIG_SYSRESET_WATCHDOG=y CONFIG_DM_THERMAL=y CONFIG_IMX_TMU=y CONFIG_USB=y +# CONFIG_SPL_DM_USB is not set +CONFIG_DM_USB_GADGET=y CONFIG_USB_XHCI_HCD=y CONFIG_USB_XHCI_DWC3=y CONFIG_USB_XHCI_DWC3_OF_SIMPLE=y CONFIG_USB_EHCI_HCD=y -CONFIG_MXC_USB_OTG_HACTIVE=y +# CONFIG_USB_EHCI_MX7 is not set CONFIG_USB_DWC3=y CONFIG_USB_DWC3_GENERIC=y CONFIG_USB_KEYBOARD=y CONFIG_USB_HOST_ETHER=y +CONFIG_USB_GADGET=y +CONFIG_USB_GADGET_MANUFACTURER="Toradex" +CONFIG_USB_GADGET_VENDOR_NUM=0x1b67 +CONFIG_USB_GADGET_PRODUCT_NUM=0x4000 CONFIG_IMX_WATCHDOG=y CONFIG_HEXDUMP=y -- 2.36.1
[PATCH v1] include: configs: verdin-am62: drop unused sdram address
From: Marcel Ziswiler Drop unused macro. This was copied straight from the AM62x EVM but while meant for a second region of DDR this is not even needed for the AM62x EVM configurations and has meanwhile also been dropped there. Note that on the Verdin AM62, we do auto-detect the amount of SDRAM. While at it also update the comment noting that CFG_SYS_SDRAM_SIZE is the maximum which is only used for such auto-detection. Signed-off-by: Marcel Ziswiler --- include/configs/verdin-am62.h | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/include/configs/verdin-am62.h b/include/configs/verdin-am62.h index 7990ea83102..e1a5f5ad44b 100644 --- a/include/configs/verdin-am62.h +++ b/include/configs/verdin-am62.h @@ -13,8 +13,7 @@ /* DDR Configuration */ #define CFG_SYS_SDRAM_BASE 0x8000 -#define CFG_SYS_SDRAM_BASE10x88000 -#define CFG_SYS_SDRAM_SIZE SZ_2G /* Maximum supported size */ +#define CFG_SYS_SDRAM_SIZE SZ_2G /* Maximum supported size, auto-detection is used */ #define MEM_LAYOUT_ENV_SETTINGS \ "fdt_addr_r=0x9020\0" \ -- 2.36.1
Re: [PATCH V5 02/17] include: configs: am62x_evm: Drop unused SDRAM address
On Thu, 2023-08-24 at 18:15 +0200, Francesco Dolcini wrote: [snip] > > > > > What about include/configs/verdin-am62.h ? > > > > > > > > > > It seems that that board, which is am62x based, also has the un-needed > > > > > include. > > > > > > > > > > Since i'm not 100% sure, I have added Marcel (who posted the verdin > > > > > am62 > > > > > support) here. > > > > > > > > Toradex team, Can you handle that cleanup? I stayed focussed on > > > > am62x_evm side > > > > of things. > > > > > > Yes, of course. > > > > I believe that this is used on verdin-am62, please double check marcel. > > No, likely I need to go home and not spread incomplete information here ... (;-p) We took care of it. https://lore.kernel.org/all/20230828215037.482278-1-mar...@ziswiler.com Thanks! Cheers Marcel
[PATCH v1 0/2] doc: board: toradex: documentation update
From: Marcel Ziswiler This series contains some minor documentation updates. The second commit documents what got discussed here [1] and therefore depends on Emanuele's series landing first. [1] https://lore.kernel.org/all/zodsx2vmnf20i...@francesco-nb.int.toradex.com Marcel Ziswiler (2): doc: board: toradex: minor documentation update doc: board: toradex: verdin-am62: document update u-boot wrapper doc/board/toradex/apalis-imx8.rst | 22 + doc/board/toradex/colibri-imx8x.rst | 31 --- doc/board/toradex/colibri_imx7.rst | 38 +++-- doc/board/toradex/verdin-am62.rst | 22 ++--- doc/board/toradex/verdin-imx8mm.rst | 9 +++ doc/board/toradex/verdin-imx8mp.rst | 9 +++ 6 files changed, 85 insertions(+), 46 deletions(-) -- 2.36.1
[PATCH v1 1/2] doc: board: toradex: minor documentation update
From: Marcel Ziswiler - Update SPDX-License-Identifier from obsolete GPL-2.0+ to GPL-2.0-or-later. - Add links to product websites of SoM and carrier board where missing. - Add information about update U-Boot wrapper where missing. - Add sectionauthor where missing. - Update information about imx-seco from version 3.7.4 to 3.8.1. - Various minor grammatic and spelling fixes. - Improve whitespace by adding or removing new lines. - Change from code-block for output to just Output::. Signed-off-by: Marcel Ziswiler --- doc/board/toradex/apalis-imx8.rst | 22 + doc/board/toradex/colibri-imx8x.rst | 31 --- doc/board/toradex/colibri_imx7.rst | 38 +++-- doc/board/toradex/verdin-am62.rst | 8 +++--- doc/board/toradex/verdin-imx8mm.rst | 9 +++ doc/board/toradex/verdin-imx8mp.rst | 9 +++ 6 files changed, 71 insertions(+), 46 deletions(-) diff --git a/doc/board/toradex/apalis-imx8.rst b/doc/board/toradex/apalis-imx8.rst index 849b1172bd4..ffc4c7d222a 100644 --- a/doc/board/toradex/apalis-imx8.rst +++ b/doc/board/toradex/apalis-imx8.rst @@ -1,7 +1,11 @@ -.. SPDX-License-Identifier: GPL-2.0+ +.. SPDX-License-Identifier: GPL-2.0-or-later +.. sectionauthor:: Marcel Ziswiler -Apalis iMX8QM V1.0B Module -== +Apalis iMX8 Module +== + +- SoM: https://www.toradex.com/computer-on-modules/apalis-arm-family/nxp-imx-8 +- Carrier board: https://www.toradex.com/products/carrier-board/apalis-evaluation-board Quick Start --- @@ -49,6 +53,7 @@ Copy the following firmware to the U-Boot folder: Build U-Boot + .. code-block:: bash $ make apalis-imx8_defconfig @@ -61,8 +66,8 @@ Get the latest version of the universal update utility (uuu) aka ``mfgtools 3.0` https://community.nxp.com/external-link.jspa?url=https%3A%2F%2Fgithub.com%2FNXPmicro%2Fmfgtools%2Freleases -Put the module into USB recovery aka serial downloader mode, connect USB device -to your host and execute uuu: +Put the module into USB recovery aka serial downloader mode, connect the USB +device to your host and execute ``uuu``: .. code-block:: bash @@ -80,3 +85,10 @@ partition and boot: setexpr blkcnt ${filesize} + 0x1ff && setexpr blkcnt ${blkcnt} / 0x200 mmc dev 0 1 mmc write ${loadaddr} 0x0 ${blkcnt} + +As a convenience, instead of the last three commands, one may also use the +update U-Boot wrapper: + +.. code-block:: bash + +> run update_uboot diff --git a/doc/board/toradex/colibri-imx8x.rst b/doc/board/toradex/colibri-imx8x.rst index 545568c844a..9e61d98c6b1 100644 --- a/doc/board/toradex/colibri-imx8x.rst +++ b/doc/board/toradex/colibri-imx8x.rst @@ -1,7 +1,11 @@ -.. SPDX-License-Identifier: GPL-2.0+ +.. SPDX-License-Identifier: GPL-2.0-or-later +.. sectionauthor:: Marcel Ziswiler -Colibri iMX8QXP V1.0D Module - +Colibri iMX8X Module + + +- SoM: https://www.toradex.com/computer-on-modules/colibri-arm-family/nxp-imx-8x +- Carrier board: https://www.toradex.com/products/carrier-board/colibri-evaluation-board Quick Start --- @@ -23,18 +27,19 @@ Get and Build the ARM Trusted Firmware Get scfw_tcm.bin and ahab-container.img --- + .. code-block:: bash $ wget https://github.com/toradex/i.MX-System-Controller-Firmware/raw/master/src/scfw_export_mx8qx_b0/build_mx8qx_b0/mx8qx-colibri-scfw-tcm.bin -$ wget https://www.nxp.com/lgfiles/NMG/MAD/YOCTO/imx-seco-3.7.4.bin -$ sh imx-seco-3.7.4.bin --auto-accept +$ wget https://www.nxp.com/lgfiles/NMG/MAD/YOCTO/imx-seco-3.8.1.bin +$ sh imx-seco-3.8.1.bin --auto-accept Copy the following firmware to the U-Boot folder: .. code-block:: bash $ cp imx-atf/build/imx8qx/release/bl31.bin . -$ cp imx-seco-3.7.4/firmware/seco/mx8qxc0-ahab-container.img mx8qx-ahab-container.img +$ cp imx-seco-3.8.1/firmware/seco/mx8qxc0-ahab-container.img mx8qx-ahab-container.img Build U-Boot @@ -51,8 +56,8 @@ Get the latest version of the universal update utility (uuu) aka ``mfgtools 3.0` https://community.nxp.com/external-link.jspa?url=https%3A%2F%2Fgithub.com%2FNXPmicro%2Fmfgtools%2Freleases -Put the module into USB recovery aka serial downloader mode, connect USB device -to your host and execute ``uuu``: +Put the module into USB recovery aka serial downloader mode, connect the USB +device to your host and execute ``uuu``: .. code-block:: bash @@ -61,7 +66,8 @@ to your host and execute ``uuu``: Flash the U-Boot Binary into the eMMC - -Burn the ``u-boot-dtb.imx`` binary to the primary eMMC hardware boot area partition: +Burn the ``u-boot-dtb.imx`` binary to the primary eMMC hardware boot area +partition and boot: .. code-block:: bash @@ -69,3 +75,10 @@ Burn the ``u-boot-dtb.imx`` binary to the primary eMMC hardware boot
[PATCH v1 2/2] doc: board: toradex: verdin-am62: document update u-boot wrapper
From: Marcel Ziswiler Now with the update U-Boot wrappers having been sorted out, document their usage. Signed-off-by: Marcel Ziswiler --- doc/board/toradex/verdin-am62.rst | 14 ++ 1 file changed, 14 insertions(+) diff --git a/doc/board/toradex/verdin-am62.rst b/doc/board/toradex/verdin-am62.rst index ecc7e0777cb..e8d90273288 100644 --- a/doc/board/toradex/verdin-am62.rst +++ b/doc/board/toradex/verdin-am62.rst @@ -74,6 +74,20 @@ Flash to eMMC => fatload mmc 1 ${loadaddr} u-boot.img => mmc write ${loadaddr} 0x1400 0x2000 +As a convenience, instead of having to remember all those addresses and sizes, +one may also use the update U-Boot wrappers: + +.. code-block:: bash + +> tftpboot ${loadaddr} tiboot3-am62x-gp-verdin.bin +> run update_tiboot3 + +> tftpboot ${loadaddr} tispl.bin +> run update_tispl + +> tftpboot ${loadaddr} u-boot.img +> run update_uboot + Boot -- 2.36.1
Re: [PATCH v1 1/2] verdin-am62: add u-boot update wrappers
On Thu, 2023-08-24 at 16:42 +0200, Francesco Dolcini wrote: > Hello Nishanth, > > On Thu, Aug 24, 2023 at 07:10:57AM -0500, Nishanth Menon wrote: > > On 13:19-20230824, Francesco Dolcini wrote: > > > On Thu, Aug 24, 2023 at 10:08:49AM +0200, Emanuele Ghidoli wrote: > > > > From: Emanuele Ghidoli > > > > > > > > Add update_tiboot3, update_tispl and update_uboot wrappers to update > > > > R5 SPL, A53 SPL and A53 U-boot respectively. > > > > > > > > Usage example: > > > > > tftpboot ${loadaddr} tiboot3-am62x-gp-verdin.bin > > > > > run update_tiboot3 > > > > > > > > > tftpboot ${loadaddr} tispl.bin > > > > > run update_tispl > > > > > > > > > tftpboot ${loadaddr} u-boot.img > > > > > run update_uboot > > > > > > > > Signed-off-by: Emanuele Ghidoli > > > > > > Acked-by: Francesco Dolcini > > > > Should you update documentation to indicate the usage? > > Yeah, probably we could add it. I would not remove the existing direct > command usage since this is adding just env variables that could be > removed from the env even at runtime. > > In general the reason for these commands is that our users are > accustomed to have a "guided" way to update u-boot without having to dig > into the documentation. They are just convenient. > > Marcel: what do you think? Sure, we took care of it here: https://lore.kernel.org/all/20230828220154.483362-1-mar...@ziswiler.com > Francesco Cheers Marcel
Re: [PATCH 02/32] spl: Use CONFIG_SPL... instead of CONFIG_..._SPL_...
Hi Simon For the Toradex Apalis, Colibri and Verdin SoMs. On Wed, 2023-08-30 at 12:04 -0600, Simon Glass wrote: > We like to put the SPL first so it is clear that it relates to SPL. Rename > various malloc-related options which have crept in, to stick to this > convention. > > Signed-off-by: Simon Glass Reviewed-by: Marcel Ziswiler [snip] Cheers Marcel
Re: [PATCH] verdin-imx8mp: drop unused tdx easy installer ifdef
Hi Hiago Thanks! On Mon, 2023-09-04 at 10:24 -0300, Hiago De Franco wrote: > From: Hiago De Franco > > Drop unused code related to CONFIG_TDX_EASY_INSTALLER, that existed only on > toradex downstream branch. > > Signed-off-by: Hiago De Franco Acked-by: Marcel Ziswiler > --- > include/configs/verdin-imx8mp.h | 10 ++ > 1 file changed, 2 insertions(+), 8 deletions(-) > > diff --git a/include/configs/verdin-imx8mp.h b/include/configs/verdin-imx8mp.h > index 942081ab84..d980bd66ae 100644 > --- a/include/configs/verdin-imx8mp.h > +++ b/include/configs/verdin-imx8mp.h > @@ -36,20 +36,14 @@ > func(DHCP, dhcp, na) > #include > > -#if defined(CONFIG_TDX_EASY_INSTALLER) > -# define BOOT_SCRIPT "boot-tezi.scr" > -#else > -# define BOOT_SCRIPT "boot.scr" > -#endif > - > /* Initial environment variables */ > #define CFG_EXTRA_ENV_SETTINGS \ > BOOTENV \ > MEM_LAYOUT_ENV_SETTINGS \ > "bootcmd_mfg=fastboot 0\0" \ > "boot_file=Image\0" \ > - "boot_scripts=" BOOT_SCRIPT "\0" \ > - "boot_script_dhcp=" BOOT_SCRIPT "\0" \ > + "boot_scripts=boot.scr\0" \ > + "boot_script_dhcp=boot.scr\0" \ > "console=ttymxc2\0" \ > "fdt_board=dev\0" \ > "initrd_addr=0x4380\0" \ Cheers Marcel
Re: [PATCH v3 00/16]Introduce initial TI's J784S4 and AM69 support
On Fri, 2023-09-08 at 16:35 +0530, Apurva Nandan wrote: > Hello Everyone! > > This series will introduce basic support (SD and UART) support for Texas > Instruments J784S4 EVM. > > The J784S4 SoC device tree patches are taken from kernel patch submissions > and will be updated as they are accepted and merged to the kernel tree. > All other patches are specific to SPL and u-boot and do not have > dependency on other trees. Appreciate a review for acceptance to u-boot > tree. > > Here are some of the salient features of the J784S4 automotive grade > application processor: > > The J784S4 SoC belongs to the K3 Multicore SoC architecture > platform, providing advanced system integration in automotive, > ADAS and industrial applications requiring AI at the network edge. > This SoC extends the K3 Jacinto 7 family of SoCs with focus on > raising performance and integration while providing interfaces, > memory architecture and compute performance for multi-sensor, high > concurrency applications. > > Some highlights of this SoC are: > * Up to 8 Cortex-A72s, four clusters of lockstep capable dual Cortex-R5F MCUs, > 4 C7x floating point vector DSPs with Matrix Multiply Accelerator(MMA) for > deep learning and CNN. > * 3D GPU: Automotive grade IMG BXS-4-64 BTW: Is it actually an IMG BXS-4-64 MC1 or MC4? > * Vision Processing Accelerator (VPAC) with image signal processor and Depth > and Motion Processing Accelerator (DMPAC) > * Three CSI2.0 4L RX plus two CSI2.0 4L TX, two DSI Tx, one eDP/DP and one > DPI interface. > * Integrated gigabit ethernet switch, up to 8 ports (TDA4VH), two ports > support 10Gb USXGMII; Two 4 lane PCIe-GEN3 controllers, USB3.0 Dual-role > device subsystems, Up to 20 MCANs, among other peripherals. > > See J784S4 Technical Reference Manual (SPRUJ52 - JUNE 2022) > for further details: http://www.ti.com/lit/zip/spruj52 > > In addtion, the J784S4 EVM board is designed for TI J784S4 SoC. It > supports the following interfaces: > * 32 GB DDR4 RAM > * x2 Gigabit Ethernet interfaces capable of working in Switch and MAC mode > * x1 Input Audio Jack, x1 Output Audio Jack > * x1 USB2.0 Hub with two Type A host and x1 USB 3.1 Type-C Port > * x2 4L PCIe connector > * x1 UHS-1 capable micro-SD card slot > * 512 Mbit OSPI flash, 1 Gbit Octal NAND flash, 512 Mbit QSPI flash, > UFS flash. > * x6 UART through UART-USB bridge > * XDS110 for onboard JTAG debug using USB > * Temperature sensors, user push buttons and LEDs > * 40-pin User Expansion Connector > * x2 ENET Expansion Connector, x1 GESI expander, x2 Display connector > * x1 15-pin CSI header > * x6 MCAN instances > > Schematics: https://www.ti.com/lit/zip/sprr458 > > bootlog: > https://paste.sr.ht/~hnagalla/f14840abc854519f912923662f1fdc8075d92107 > > Changes in v3: > 1) Added AM69 SK support in the series > 2) Switched from distroboot to bootstd support > 3) Added remoteproc support for J784S4 > 4) Added documentation for both SoCs > 5) Added binman support > 6) Removed unnecessarry nodes from r5-evm.dts and evm-u-boot.dtsi > 7) Added HS device support > 8) Added env file for environement variables > 9) Removed ti-serdes-mux bindings > 10) Cleaned up all files and synced with latest > 11) Addressed all previous review comments > > Note: The base dts files have been sync from next-20230905 linux tag as per > review comment received > on previous re-roll: > https://lore.kernel.org/u-boot/20230321155227.GV8135@bill-the-cat/ > > Link to v2: > https://lore.kernel.org/u-boot/20230321141028.24456-1-hnaga...@ti.com/ > > Changes in v2: > - Refactored environement scripts to 'j784s4.env' and removed scripts not > needed for basic board bootup. > - Imported the J7874S4 basic device tree files from v6.2 linux kernel. > - Moved j784s4 clock definitions and clock data into one patch/commit. > - coalesce board commits into one commit. > > Apurva Nandan (9): > arm: dts: Introduce j784s4 dts from linux kernel > arm: mach-k3: Add basic support for J784S4 SoC definition > soc: ti: k3-socinfo: Add entry for J784S4 SoC > arm: mach-k3: j784s4: Add clk and power support > drivers: dma: Add support for J784S4 SoC > board: ti: j784s4: Add board support for J784S4 EVM > arm: dts: Introduce j784s4 u-boot dts files > configs: j784s4_evm: Add defconfig for j784s4 evm and am69 sk > doc: board: ti: k3: Add J784S4 EVM and AM69 SK documentation > > Dasnavis Sabiya (5): > arm: dts: Introduce am69-sk dts from linux kernel > board: ti: j784s4: Add support for board detection by EEPROM read > board: ti: j784s4: Update env to use am69-sk dtb > arm: dts: Introduce am69-sk u-boot dts files > arm: dts: k3-j784s4-binman: Add support for AM69 SK > > Hari Nagalla (2): > remoteproc: k3-r5: Extend support for R5F clusters on J784S4 SoCs > remoteproc: k3-dsp: Extend support for C71x DSPs on J784S4 SoCs > > arch/arm/dts/Makefile | 4 + > arch/arm/dts/k3-am69-r5-sk.dts | 105 + > arch/a
Re: [PATCH v3 02/16] arm: mach-k3: Add basic support for J784S4 SoC definition
On Fri, 2023-09-08 at 16:35 +0530, Apurva Nandan wrote: > Add j784s4 initialization files for initial SPL boot. > > Signed-off-by: Hari Nagalla > [ add firewall configurations and change the R5 MCU scratchpad ] > Signed-off-by: Manorit Chawdhry > Signed-off-by: Dasnavis Sabiya > Signed-off-by: Apurva Nandan > --- > arch/arm/mach-k3/Kconfig | 16 +- > arch/arm/mach-k3/Makefile | 3 + > arch/arm/mach-k3/arm64-mmu.c | 52 +++ > arch/arm/mach-k3/include/mach/hardware.h | 4 + > .../mach-k3/include/mach/j784s4_hardware.h | 60 > arch/arm/mach-k3/include/mach/j784s4_spl.h | 46 +++ > arch/arm/mach-k3/include/mach/spl.h | 6 +- > arch/arm/mach-k3/j784s4_fdt.c | 15 + > arch/arm/mach-k3/j784s4_init.c | 332 ++ > 9 files changed, 526 insertions(+), 8 deletions(-) > create mode 100644 arch/arm/mach-k3/include/mach/j784s4_hardware.h > create mode 100644 arch/arm/mach-k3/include/mach/j784s4_spl.h > create mode 100644 arch/arm/mach-k3/j784s4_fdt.c > create mode 100644 arch/arm/mach-k3/j784s4_init.c > > diff --git a/arch/arm/mach-k3/Kconfig b/arch/arm/mach-k3/Kconfig > index 9168bf842d..0af2ec6ddb 100644 > --- a/arch/arm/mach-k3/Kconfig > +++ b/arch/arm/mach-k3/Kconfig > @@ -22,6 +22,9 @@ config SOC_K3_AM625 > config SOC_K3_AM62A7 > bool "TI's K3 based AM62A7 SoC Family Support" > > +config SOC_K3_J784S4 > + bool "TI's K3 based J784S4 SoC Family Support" > + > endchoice > > config SYS_SOC > @@ -30,7 +33,7 @@ config SYS_SOC > config SYS_K3_NON_SECURE_MSRAM_SIZE > hex > default 0x8 if SOC_K3_AM654 > - default 0x10 if SOC_K3_J721E || SOC_K3_J721S2 > + default 0x10 if SOC_K3_J721E || SOC_K3_J721S2 || SOC_K3_J784S4 > default 0x1c if SOC_K3_AM642 > default 0x3c000 if SOC_K3_AM625 || SOC_K3_AM62A7 > help > @@ -42,7 +45,7 @@ config SYS_K3_NON_SECURE_MSRAM_SIZE > config SYS_K3_MAX_DOWNLODABLE_IMAGE_SIZE > hex > default 0x58000 if SOC_K3_AM654 > - default 0xc if SOC_K3_J721E || SOC_K3_J721S2 > + default 0xc if SOC_K3_J721E || SOC_K3_J721S2 || SOC_K3_J784S4 > default 0x18 if SOC_K3_AM642 > default 0x38000 if SOC_K3_AM625 || SOC_K3_AM62A7 > help > @@ -52,15 +55,14 @@ config SYS_K3_MAX_DOWNLODABLE_IMAGE_SIZE > config SYS_K3_MCU_SCRATCHPAD_BASE > hex > default 0x4028 if SOC_K3_AM654 > - default 0x41cff9fc if SOC_K3_J721S2 > - default 0x41cff9fc if SOC_K3_J721E > + default 0x41cff9fc if SOC_K3_J721E || SOC_K3_J721S2 || SOC_K3_J784S4 > help > Describes the base address of MCU Scratchpad RAM. > > config SYS_K3_MCU_SCRATCHPAD_SIZE > hex > default 0x200 if SOC_K3_AM654 > - default 0x200 if SOC_K3_J721E || SOC_K3_J721S2 > + default 0x200 if SOC_K3_J721E || SOC_K3_J721S2 || SOC_K3_J784S4 > help > Describes the size of MCU Scratchpad RAM. > > @@ -68,7 +70,7 @@ config SYS_K3_BOOT_PARAM_TABLE_INDEX > hex > default 0x41c7fbfc if SOC_K3_AM654 > default 0x41cffbfc if SOC_K3_J721E > - default 0x41cfdbfc if SOC_K3_J721S2 > + default 0x41cfdbfc if SOC_K3_J721S2 || SOC_K3_J784S4 > default 0x701bebfc if SOC_K3_AM642 > default 0x43c3f290 if SOC_K3_AM625 > default 0x43c3f290 if SOC_K3_AM62A7 && CPU_V7R > @@ -172,7 +174,7 @@ config K3_ATF_LOAD_ADDR > > config K3_DM_FW > bool "Separate DM firmware image" > - depends on SPL && CPU_V7R && (SOC_K3_J721E || SOC_K3_J721S2 || > SOC_K3_AM625 || SOC_K3_AM62A7) && > !CLK_TI_SCI && !TI_SCI_POWER_DOMAIN > + depends on SPL && CPU_V7R && (SOC_K3_J721E || SOC_K3_J721S2 || > SOC_K3_AM625 || SOC_K3_AM62A7 || > SOC_K3_J784S4) && !CLK_TI_SCI && !TI_SCI_POWER_DOMAIN > default y > help > Enabling this will indicate that the system has separate DM > diff --git a/arch/arm/mach-k3/Makefile b/arch/arm/mach-k3/Makefile > index fd77b8bbba..6fe36c265c 100644 > --- a/arch/arm/mach-k3/Makefile > +++ b/arch/arm/mach-k3/Makefile > @@ -7,6 +7,7 @@ obj-$(CONFIG_SOC_K3_J721E) += j721e/ j7200/ > obj-$(CONFIG_SOC_K3_J721S2) += j721s2/ > obj-$(CONFIG_SOC_K3_AM625) += am62x/ > obj-$(CONFIG_SOC_K3_AM62A7) += am62ax/ > +obj-$(CONFIG_SOC_K3_J784S4) += j784s4/ > obj-$(CONFIG_ARM64) += arm64-mmu.o > obj-$(CONFIG_CPU_V7R) += r5_mpu.o lowlevel_init.o > obj-$(CONFIG_ARM64) += cache.o > @@ -16,6 +17,7 @@ obj-$(CONFIG_SOC_K3_AM654) += am654_fdt.o > obj-$(CONFIG_SOC_K3_J721E) += j721e_fdt.o > obj-$(CONFIG_SOC_K3_J721S2) += j721s2_fdt.o > obj-$(CONFIG_SOC_K3_AM625) += am625_fdt.o > +obj-$(CONFIG_SOC_K3_J784S4) += j784s4_fdt.o > endif > ifeq ($(CONFIG_SPL_BUILD),y) > obj-$(CONFIG_SOC_K3_AM654) += am654_init.o > @@ -24,6 +26,7 @@ obj-$(CONFIG_SOC_K3_J721S2) += j721s2_init.o > obj-$(CONFIG_SOC_K3_AM642) += am642_init.o > obj-$
Re: [PATCH v3 03/16] soc: ti: k3-socinfo: Add entry for J784S4 SoC
On Fri, 2023-09-08 at 16:35 +0530, Apurva Nandan wrote: > Add support for J784S4 SoC Identification. > > Signed-off-by: Hari Nagalla > Signed-off-by: Apurva Nandan > --- > arch/arm/mach-k3/include/mach/hardware.h | 1 + > drivers/soc/soc_ti_k3.c | 3 +++ > 2 files changed, 4 insertions(+) > > diff --git a/arch/arm/mach-k3/include/mach/hardware.h > b/arch/arm/mach-k3/include/mach/hardware.h > index 03b18f6bad..bada87d0b2 100644 > --- a/arch/arm/mach-k3/include/mach/hardware.h > +++ b/arch/arm/mach-k3/include/mach/hardware.h > @@ -50,6 +50,7 @@ > #define JTAG_ID_PARTNO_J721S2 0xbb75 > #define JTAG_ID_PARTNO_AM62X 0xbb7e > #define JTAG_ID_PARTNO_AM62AX 0xbb8d > +#define JTAG_ID_PARTNO_J784S4 0xbb80 Not sure whether it would be smarter to sort this based on the JTAG ID or the name of the define like you did. > #define K3_SOC_ID(id, ID) \ > static inline bool soc_is_##id(void) \ > diff --git a/drivers/soc/soc_ti_k3.c b/drivers/soc/soc_ti_k3.c > index b720131ae5..6f7fcf9e11 100644 > --- a/drivers/soc/soc_ti_k3.c > +++ b/drivers/soc/soc_ti_k3.c > @@ -45,6 +45,9 @@ static const char *get_family_string(u32 idreg) > case JTAG_ID_PARTNO_AM62AX: > family = "AM62AX"; > break; > + case JTAG_ID_PARTNO_J784S4: > + family = "J784S4"; > + break; > default: > family = "Unknown Silicon"; > };
Re: [PATCH v3 04/16] arm: mach-k3: j784s4: Add clk and power support
On Fri, 2023-09-08 at 16:35 +0530, Apurva Nandan wrote: > Add clk and device data which can be used by respective drivers > to configure clocks and PSC. > > Signed-off-by: Hari Nagalla > Signed-off-by: Apurva Nandan > --- > arch/arm/mach-k3/j784s4/Makefile | 5 + > arch/arm/mach-k3/j784s4/clk-data.c | 428 + > arch/arm/mach-k3/j784s4/dev-data.c | 98 ++ > drivers/clk/ti/clk-k3.c | 6 + > drivers/power/domain/ti-power-domain.c | 6 + > include/k3-clk.h | 1 + > include/k3-dev.h | 1 + > 7 files changed, 545 insertions(+) > create mode 100644 arch/arm/mach-k3/j784s4/Makefile > create mode 100644 arch/arm/mach-k3/j784s4/clk-data.c > create mode 100644 arch/arm/mach-k3/j784s4/dev-data.c > > diff --git a/arch/arm/mach-k3/j784s4/Makefile > b/arch/arm/mach-k3/j784s4/Makefile > new file mode 100644 > index 00..b6cd23457d > --- /dev/null > +++ b/arch/arm/mach-k3/j784s4/Makefile > @@ -0,0 +1,5 @@ > +# SPDX-License-Identifier: GPL-2.0+ Should be: GPL-2.0-or-later > +# > +# Copyright (C) 2022 Texas Instruments Incorporated - https://www.ti.com/ > +obj-y += clk-data.o > +obj-y += dev-data.o > diff --git a/arch/arm/mach-k3/j784s4/clk-data.c > b/arch/arm/mach-k3/j784s4/clk-data.c > new file mode 100644 > index 00..1c9f0698ea > --- /dev/null > +++ b/arch/arm/mach-k3/j784s4/clk-data.c > @@ -0,0 +1,428 @@ > +// SPDX-License-Identifier: GPL-2.0+ Ditto. > +/* > + * J784S4 specific clock platform data > + * > + * This file is auto generated. Please do not hand edit and report any issues > + * to Bryan Brattlof . > + * > + * Copyright (C) 2020-2022 Texas Instruments Incorporated - > https://www.ti.com/ > + */ > + > +#include > +#include "k3-clk.h" > + > +static const char * const gluelogic_hfosc0_clkout_parents[] = { > + "osc_19_2_mhz", > + "osc_20_mhz", > + "osc_24_mhz", > + "osc_25_mhz", > + "osc_26_mhz", > + "osc_27_mhz", > +}; > + > +static const char * const mcu_ospi0_iclk_sel_out0_parents[] = { > + "board_0_mcu_ospi0_dqs_out", > + "fss_mcu_0_ospi_0_ospi_oclk_clk", > +}; > + > +static const char * const mcu_ospi1_iclk_sel_out0_parents[] = { > + "board_0_mcu_ospi1_dqs_out", > + "fss_mcu_0_ospi_1_ospi_oclk_clk", > +}; > + > +static const char * const wkup_fref_clksel_out0_parents[] = { > + "gluelogic_hfosc0_clkout", > + "j7am_wakeup_16ff_wkup_0_wkup_rcosc_12p5m_clk", > +}; > + > +static const char * const k3_pll_ctrl_wrap_wkup_0_sysclkout_clk_parents[] = { > + "wkup_fref_clksel_out0", > + "hsdiv1_16fft_mcu_0_hsdivout0_clk", > +}; > + > +static const char * const mcu_ospi_ref_clk_sel_out0_parents[] = { > + "hsdiv4_16fft_mcu_1_hsdivout4_clk", > + "hsdiv4_16fft_mcu_2_hsdivout4_clk", > +}; > + > +static const char * const mcu_ospi_ref_clk_sel_out1_parents[] = { > + "hsdiv4_16fft_mcu_1_hsdivout4_clk", > + "hsdiv4_16fft_mcu_2_hsdivout4_clk", > +}; > + > +static const char * const wkup_gpio0_clksel_out0_parents[] = { > + "k3_pll_ctrl_wrap_wkup_0_chip_div1_clk_clk", > + "k3_pll_ctrl_wrap_wkup_0_chip_div1_clk_clk", > + "j7am_wakeup_16ff_wkup_0_wkup_rcosc_32k_clk", > + "j7am_wakeup_16ff_wkup_0_wkup_rcosc_12p5m_clk", > +}; > + > +static const char * const mcu_usart_clksel_out0_parents[] = { > + "hsdiv4_16fft_mcu_1_hsdivout3_clk", > + "postdiv3_16fft_main_1_hsdivout5_clk", > +}; > + > +static const char * const wkup_i2c_mcupll_bypass_out0_parents[] = { > + "hsdiv4_16fft_mcu_1_hsdivout3_clk", > + "gluelogic_hfosc0_clkout", > +}; > + > +static const char * const main_pll_hfosc_sel_out0_parents[] = { > + "gluelogic_hfosc0_clkout", > + "board_0_hfosc1_clk_out", > +}; > + > +static const char * const main_pll_hfosc_sel_out1_parents[] = { > + "gluelogic_hfosc0_clkout", > + "board_0_hfosc1_clk_out", > +}; > + > +static const char * const main_pll_hfosc_sel_out12_parents[] = { > + "gluelogic_hfosc0_clkout", > + "board_0_hfosc1_clk_out", > +}; > + > +static const char * const main_pll_hfosc_sel_out19_parents[] = { > + "gluelogic_hfosc0_clkout", > + "board_0_hfosc1_clk_out", > +}; > + > +static const char * const main_pll_hfosc_sel_out2_parents[] = { > + "gluelogic_hfosc0_clkout", > + "board_0_hfosc1_clk_out", > +}; > + > +static const char * const main_pll_hfosc_sel_out26_0_parents[] = { > + "gluelogic_hfosc0_clkout", > + "board_0_hfosc1_clk_out", > +}; > + > +static const char * const main_pll_hfosc_sel_out27_0_parents[] = { > + "gluelogic_hfosc0_clkout", > + "board_0_hfosc1_clk_out", > +}; > + > +static const char * const main_pll_hfosc_sel_out28_parents[] = { > + "gluelogic_hfosc0_clkout", > + "board_0_hfosc1_clk_out", > +}; > + > +static const char * const main_pll_hfosc_sel_out3_parents[] = { > + "gluelogic_hfosc0_clkout", > + "board_0
Re: [PATCH v3 05/16] drivers: dma: Add support for J784S4 SoC
On Fri, 2023-09-08 at 16:35 +0530, Apurva Nandan wrote: > Add support for DMA in J784S4 SoC. > > Signed-off-by: Jayesh Choudhary > Signed-off-by: Hari Nagalla > Signed-off-by: Apurva Nandan > --- > drivers/dma/ti/Makefile | 1 + > drivers/dma/ti/k3-psil-j784s4.c | 166 ++ > drivers/dma/ti/k3-psil-priv.h | 1 + > drivers/dma/ti/k3-psil.c | 2 + > drivers/firmware/ti_sci_static_data.h | 34 ++ > drivers/ram/Kconfig | 2 +- > 6 files changed, 205 insertions(+), 1 deletion(-) > create mode 100644 drivers/dma/ti/k3-psil-j784s4.c > > diff --git a/drivers/dma/ti/Makefile b/drivers/dma/ti/Makefile > index 6807eb8e8b..bd4ce68d9c 100644 > --- a/drivers/dma/ti/Makefile > +++ b/drivers/dma/ti/Makefile > @@ -8,3 +8,4 @@ k3-psil-data-$(CONFIG_SOC_K3_J721E) += k3-psil-j721e.o > k3-psil-data-$(CONFIG_SOC_K3_J721S2) += k3-psil-j721s2.o > k3-psil-data-$(CONFIG_SOC_K3_AM642) += k3-psil-am64.o > k3-psil-data-$(CONFIG_SOC_K3_AM625) += k3-psil-am62.o > +k3-psil-data-$(CONFIG_SOC_K3_J784S4) += k3-psil-j784s4.o > diff --git a/drivers/dma/ti/k3-psil-j784s4.c b/drivers/dma/ti/k3-psil-j784s4.c > new file mode 100644 > index 00..d62d5e9c33 > --- /dev/null > +++ b/drivers/dma/ti/k3-psil-j784s4.c > @@ -0,0 +1,166 @@ > +// SPDX-License-Identifier: GPL-2.0 Should be: GPL-2.0-only > +/* > + * Copyright (C) 2022 Texas Instruments Incorporated - https://www.ti.com > + */ > +#include > + > +#include "k3-psil-priv.h" > + > +#define PSIL_PDMA_XY_TR(x) \ > + { \ > + .thread_id = x, \ > + .ep_config = { \ > + .ep_type = PSIL_EP_PDMA_XY, \ > + }, \ > + } > + > +#define PSIL_PDMA_XY_PKT(x)\ > + { \ > + .thread_id = x, \ > + .ep_config = { \ > + .ep_type = PSIL_EP_PDMA_XY, \ > + .pkt_mode = 1, \ > + }, \ > + } > + > +#define PSIL_PDMA_MCASP(x) \ > + { \ > + .thread_id = x, \ > + .ep_config = { \ > + .ep_type = PSIL_EP_PDMA_XY, \ > + .pdma_acc32 = 1,\ > + .pdma_burst = 1,\ > + }, \ > + } > + > +#define PSIL_ETHERNET(x) \ > + { \ > + .thread_id = x, \ > + .ep_config = { \ > + .ep_type = PSIL_EP_NATIVE, \ > + .pkt_mode = 1, \ > + .needs_epib = 1,\ > + .psd_size = 16, \ > + }, \ > + } > + > +#define PSIL_SA2UL(x, tx) \ > + { \ > + .thread_id = x, \ > + .ep_config = { \ > + .ep_type = PSIL_EP_NATIVE, \ > + .pkt_mode = 1, \ > + .needs_epib = 1,\ > + .psd_size = 64, \ > + .notdpkt = tx, \ > + }, \ > + } > + > +/* PSI-L source thread IDs, used for RX (DMA_DEV_TO_MEM) */ > +static struct psil_ep j784s4_src_ep_map[] = { > + /* PDMA_MCASP - McASP0-4 */ > + PSIL_PDMA_MCASP(0x4400), > + PSIL_PDMA_MCASP(0x4401), > + PSIL_PDMA_MCASP(0x4402), > + PSIL_PDMA_MCASP(0x4403), > + PSIL_PDMA_MCASP(0x4404), > + /* PDMA_SPI_G0 - SPI0-3 */ > + PSIL_PDMA_XY_PKT(0x4600), > + PSIL_PDMA_XY_PKT(0x4601), > + PSIL_PDMA_XY_PKT(0x4602), > + PSIL_PDMA_XY_PKT(0x4603), > + PSIL_PDMA_XY_PKT(0x4604), > + PSIL_PDMA_XY_PKT(0x4605), > + PSIL_PDMA_XY_PKT(0x4606), > + PSIL_PDMA_XY_PKT(0x4607), > + PSIL_PDMA_XY_PKT(0x4608), > + PSIL_PDMA_XY_PKT(0x4609), > + PSIL_PDMA_XY_PKT(0x460a), > + PSIL_PDMA_XY_PKT(0x460b), > + PSIL_PDMA_XY_PKT(0x460c), > + PSIL_PDMA_XY_PKT(0x460d), > + PSIL_PDMA_XY_PKT(0x460e), > + PSIL_PDMA_XY_PKT(0x460f), > + /* PDMA_SPI_G1 - SPI4-7 */ > + PSIL_PD
Re: [PATCH v3 10/16] arm: dts: Introduce am69-sk dts from linux kernel
On Fri, 2023-09-08 at 16:35 +0530, Apurva Nandan wrote: > From: Dasnavis Sabiya > > Introduce the basic am69-sk evm dts from the next-20230905 tag of the > linux kernel. > > Signed-off-by: Dasnavis Sabiya > Signed-off-by: Apurva Nandan > --- > arch/arm/dts/Makefile | 3 +- > arch/arm/dts/k3-am69-sk.dts | 364 > 2 files changed, 366 insertions(+), 1 deletion(-) > create mode 100644 arch/arm/dts/k3-am69-sk.dts > > diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile > index 363f7a1171..1bcdbea9e5 100644 > --- a/arch/arm/dts/Makefile > +++ b/arch/arm/dts/Makefile > @@ -1330,7 +1330,8 @@ dtb-$(CONFIG_SOC_K3_J721S2) += > k3-am68-sk-base-board.dtb\ > k3-am68-sk-r5-base-board.dtb\ > k3-j721s2-common-proc-board.dtb\ > k3-j721s2-r5-common-proc-board.dtb > -dtb-$(CONFIG_SOC_K3_J784S4) += k3-j784s4-evm.dtb\ > +dtb-$(CONFIG_SOC_K3_J784S4) += k3-am69-sk.dtb\ > + k3-j784s4-evm.dtb\ > k3-j784s4-r5-evm.dtb > dtb-$(CONFIG_SOC_K3_AM642) += k3-am642-evm.dtb \ > k3-am642-r5-evm.dtb \ > diff --git a/arch/arm/dts/k3-am69-sk.dts b/arch/arm/dts/k3-am69-sk.dts > new file mode 100644 > index 00..0699370911 > --- /dev/null > +++ b/arch/arm/dts/k3-am69-sk.dts > @@ -0,0 +1,364 @@ > +// SPDX-License-Identifier: GPL-2.0 Should be: GPL-2.0-only > +/* > + * Copyright (C) 2022-2023 Texas Instruments Incorporated - > https://www.ti.com/ > + * > + * Design Files: https://www.ti.com/lit/zip/SPRR466 > + * TRM: https://www.ti.com/lit/zip/spruj52 > + */ > + > +/dts-v1/; > + > +#include > +#include > +#include "k3-j784s4.dtsi" > + > +/ { > + compatible = "ti,am69-sk", "ti,j784s4"; > + model = "Texas Instruments AM69 SK"; I never understood TI's naming. Somewhere they call it Evaluation Module (EVM), somewhere Starter Kit (SK) and even at other places Evaluation Board (EVB). > + > + chosen { > + stdout-path = "serial2:115200n8"; > + }; > + > + aliases { > + serial0 = &wkup_uart0; > + serial1 = &mcu_uart0; > + serial2 = &main_uart8; > + mmc0 = &main_sdhci0; > + mmc1 = &main_sdhci1; > + i2c0 = &wkup_i2c0; > + i2c3 = &main_i2c0; > + ethernet0 = &mcu_cpsw_port1; > + }; > + > + memory@8000 { > + device_type = "memory"; > + /* 32G RAM */ > + reg = <0x00 0x8000 0x00 0x8000>, > + <0x08 0x8000 0x07 0x8000>; > + }; > + > + reserved_memory: reserved-memory { > + #address-cells = <2>; > + #size-cells = <2>; > + ranges; > + > + secure_ddr: optee@9e80 { > + reg = <0x00 0x9e80 0x00 0x0180>; > + no-map; > + }; > + }; > + > + vusb_main: regulator-vusb-main5v0 { > + /* USB MAIN INPUT 5V DC */ > + compatible = "regulator-fixed"; > + regulator-name = "vusb-main5v0"; > + regulator-min-microvolt = <500>; > + regulator-max-microvolt = <500>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + vsys_5v0: regulator-vsys5v0 { > + /* Output of LM61460 */ > + compatible = "regulator-fixed"; > + regulator-name = "vsys_5v0"; > + regulator-min-microvolt = <500>; > + regulator-max-microvolt = <500>; > + vin-supply = <&vusb_main>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + vsys_3v3: regulator-vsys3v3 { > + /* Output of LM5143 */ > + compatible = "regulator-fixed"; > + regulator-name = "vsys_3v3"; > + regulator-min-microvolt = <330>; > + regulator-max-microvolt = <330>; > + vin-supply = <&vusb_main>; > + regulator-always-on; > + regulator-boot-on; > + }; > + > + vdd_mmc1: regulator-sd { > + /* Output of TPS22918 */ > + compatible = "regulator-fixed"; > + regulator-name = "vdd_mmc1"; > + regulator-min-microvolt = <330>; > + regulator-max-microvolt = <330>; > + regulator-boot-on; > + enable-active-high; > + vin-supply = <&vsys_3v3>; > + gpio = <&exp1 2 GPIO_ACTIVE_HIGH>; > + }; > + > + vdd_sd_dv: regulator-tlv71033 { > + /* Output of TLV71033 */ > + compatible = "regulator-gpio"; > + regulator-name = "tlv71033"; > + pinctrl-names =
Re: [PATCH v3 13/16] arm: dts: Introduce am69-sk u-boot dts files
On Fri, 2023-09-08 at 16:35 +0530, Apurva Nandan wrote: > From: Dasnavis Sabiya > > Introduce the base dts files needed for u-boot or to augment the linux > dtbs for use in the u-boot-spl and u-boot binaries. > > Signed-off-by: Dasnavis Sabiya > Signed-off-by: Apurva Nandan > --- > arch/arm/dts/Makefile | 3 +- > arch/arm/dts/k3-am69-r5-sk.dts | 105 > arch/arm/dts/k3-am69-sk-u-boot.dtsi | 25 +++ > 3 files changed, 132 insertions(+), 1 deletion(-) > create mode 100644 arch/arm/dts/k3-am69-r5-sk.dts > create mode 100644 arch/arm/dts/k3-am69-sk-u-boot.dtsi > > diff --git a/arch/arm/dts/Makefile b/arch/arm/dts/Makefile > index 1bcdbea9e5..bb7ae79745 100644 > --- a/arch/arm/dts/Makefile > +++ b/arch/arm/dts/Makefile > @@ -1330,7 +1330,8 @@ dtb-$(CONFIG_SOC_K3_J721S2) += > k3-am68-sk-base-board.dtb\ > k3-am68-sk-r5-base-board.dtb\ > k3-j721s2-common-proc-board.dtb\ > k3-j721s2-r5-common-proc-board.dtb > -dtb-$(CONFIG_SOC_K3_J784S4) += k3-am69-sk.dtb\ > +dtb-$(CONFIG_SOC_K3_J784S4) += k3-am69-r5-sk.dtb\ > + k3-am69-sk.dtb\ > k3-j784s4-evm.dtb\ > k3-j784s4-r5-evm.dtb > dtb-$(CONFIG_SOC_K3_AM642) += k3-am642-evm.dtb \ > diff --git a/arch/arm/dts/k3-am69-r5-sk.dts b/arch/arm/dts/k3-am69-r5-sk.dts > new file mode 100644 > index 00..8c789c4f28valuation module (EVM) is a pl > --- /dev/null > +++ b/arch/arm/dts/k3-am69-r5-sk.dts > @@ -0,0 +1,105 @@ > +// SPDX-License-Identifier: GPL-2.0 Should be: GPL-2.0-only BTW: Why is TI not releasing their device trees with a more permissive license like GPL-2.0-or-later OR MIT like most others do? > +/* > + * Copyright (C) 2022-2023 Texas Instruments Incorporated - > https://www.ti.com/ > + */ > + > +/dts-v1/; > + > +#include "k3-am69-sk.dts" > +#include "k3-j784s4-ddr-evm-lp4-4266.dtsi" > +#include "k3-j784s4-ddr.dtsi" > +#include "k3-am69-sk-u-boot.dtsi" > + > +/ { > + chosen { > + tick-timer = &mcu_timer0; > + }; > + > + aliases { > + remoteproc0 = &sysctrler; > + remoteproc1 = &a72_0; > + }; > + > + a72_0: a72@0 { > + compatible = "ti,am654-rproc"; > + reg = <0x0 0x00a9 0x0 0x10>; > + power-domains = <&k3_pds 61 TI_SCI_PD_EXCLUSIVE>, > + <&k3_pds 202 TI_SCI_PD_EXCLUSIVE>; > + resets = <&k3_reset 202 0>; > + clocks = <&k3_clks 61 0>; > + assigned-clocks = <&k3_clks 61 0>, <&k3_clks 202 0>; > + assigned-clock-parents = <&k3_clks 61 2>; > + assigned-clock-rates = <2>, <20>; > + ti,sci = <&sms>; > + ti,sci-proc-id = <32>; > + ti,sci-host-id = <10>; > + bootph-pre-ram; > + }; > + > + dm_tifs: dm-tifs { > + compatible = "ti,j721e-dm-sci"; > + ti,host-id = <3>; > + ti,secure-host; > + mbox-names = "rx", "tx"; > + mboxes= <&secure_proxy_mcu 21>, <&secure_proxy_mcu 23>; > + bootph-pre-ram; > + }; > +}; > + > +&mcu_timer0 { > + status = "okay"; > + clock-frequency = <25000>; > + bootph-pre-ram; > +}; > + > +&secure_proxy_sa3 { > + status = "okay"; > + bootph-pre-ram; > +}; > + > +&secure_proxy_mcu { > + status = "okay"; > + bootph-pre-ram; > +}; > + > +&cbass_mcu_wakeup { > + sysctrler: sysctrler { > + compatible = "ti,am654-system-controller"; > + mboxes= <&secure_proxy_mcu 4>, > + <&secure_proxy_mcu 5>, > + <&secure_proxy_sa3 5>; > + mbox-names = "tx", "rx", "boot_notify"; > + bootph-pre-ram; > + }; > +}; > + > +&sms { > + mboxes= <&secure_proxy_mcu 8>, <&secure_proxy_mcu 6>, > <&secure_proxy_mcu 5>; > + mbox-names = "tx", "rx", "notify"; > + ti,host-id = <4>; > + ti,secure-host; > + bootph-pre-ram; > +}; > + > +&wkup_uart0 { > + bootph-pre-ram; > + status = "okay"; > +}; > + > +&ospi0 { > + reg = <0x0 0x4704 0x0 0x100>, > + <0x0 0x5000 0x0 0x800>; > +}; > + > +&ospi1 { > + reg = <0x0 0x4705 0x0 0x100>, > + <0x0 0x5800 0x0 0x800>; > +}; > + > +&mcu_ringacc { > + ti,sci = <&dm_tifs>; > +}; > + > +&mcu_udmap { > + ti,sci = <&dm_tifs>; > +}; > diff --git a/arch/arm/dts/k3-am69-sk-u-boot.dtsi > b/arch/arm/dts/k3-am69-sk-u-boot.dtsi > new file mode 100644 > index 00..c8944499e8 > --- /dev/null > +++ b/arch/arm/dts/k3-am69-sk-u-boot.dtsi > @@ -0,0 +1,25 @@ > +// SPDX-License-Identifier: GPL-2.0 Ditto. > +/* > + * Copyright (C) 2022 Texas Instruments Incorporated - ht
Re: [PATCH v3 16/16] doc: board: ti: k3: Add J784S4 EVM and AM69 SK documentation
On Fri, 2023-09-08 at 16:35 +0530, Apurva Nandan wrote: > TI K3 J784S4 and AM69 SK are new additions to the K3 SoC family. > Add documentation about the J784S4 EVM and AM69 SK. > > Signed-off-by: Dasnavis Sabiya > Signed-off-by: Apurva Nandan > --- > board/ti/j784s4/MAINTAINERS | 1 + > doc/board/ti/j784s4_evm.rst | 339 > doc/board/ti/k3.rst | 1 + > 3 files changed, 341 insertions(+) > create mode 100644 doc/board/ti/j784s4_evm.rst > > diff --git a/board/ti/j784s4/MAINTAINERS b/board/ti/j784s4/MAINTAINERS > index 7d3549dd31..be2f9a04b7 100644 > --- a/board/ti/j784s4/MAINTAINERS > +++ b/board/ti/j784s4/MAINTAINERS > @@ -18,3 +18,4 @@ F:arch/arm/dts/k3-j784s4-ddr-evm-lp4-4266.dtsi > F: arch/arm/dts/k3-am69-sk.dts > F: arch/arm/dts/k3-am69-sk-u-boot.dtsi > F: arch/arm/dts/k3-am69-r5-sk.dts > +F: doc/board/ti/j784s4_evm.rst > diff --git a/doc/board/ti/j784s4_evm.rst b/doc/board/ti/j784s4_evm.rst > new file mode 100644 > index 00..1e2b7f3820 > --- /dev/null > +++ b/doc/board/ti/j784s4_evm.rst > @@ -0,0 +1,339 @@ > +.. SPDX-License-Identifier: GPL-2.0+ OR BSD-3-Clause Should be: GPL-2.0-or-later OR BSD-3-Clause > +.. sectionauthor:: Apurva Nandan > + > +J784S4 and AM69 Platforms > += > + > +Introduction: > +- > +The J784S4 SoC belongs to the K3 Multicore SoC architecture > +platform, providing advanced system integration in automotive, > +ADAS and industrial applications requiring AI at the network edge. > +This SoC extends the K3 Jacinto 7 family of SoCs with focus on > +raising performance and integration while providing interfaces, > +memory architecture and compute performance for multi-sensor, high > +concurrency applications. > + > +The device is partitioned into three functional domains, each containing > +specific processing cores and peripherals: > + > +1. Wake-up (WKUP) domain: > + * ARM Cortex-M4F processor, runs TI Foundational Security (TIFS) > + > +2. Microcontroller (MCU) domain: > + * Dual core ARM Cortex-R5F processor, runs device management > + and SoC early boot > + > +3. MAIN domain: > + * Dual core 64-bit ARM Cortex-A72, runs HLOS > + > +More info can be found in TRM: http://www.ti.com/lit/zip/spruj52 > + > +Platform information: > + > +* https://www.ti.com/tool/J784S4XEVM > +* https://www.ti.com/tool/SK-AM69 > + > +Boot Flow: > +-- > +Below is the pictorial representation of boot flow: > + > +.. image:: img/boot_diagram_k3_current.svg > + > +- On this platform, "TI Foundational Security (TIFS)" functions as the > + security enclave master. While "Device Manager (DM)", also known as the > + "TISCI server" in TI terminology, offers all the essential services. > + > +- As illustrated in the diagram above, R5 SPL manages power and clock > + services independently before handing over control to DM. The A72 or > + the C7x (Aux core) software components request TIFS/DM to handle > + security or device management services. > + > +Sources: > + > + > +.. include:: k3.rst > + :start-after: .. k3_rst_include_start_boot_sources > + :end-before: .. k3_rst_include_end_boot_sources > + > +Build procedure: > + > +0. Setup the environment variables: > + > +.. include:: k3.rst > + :start-after: .. k3_rst_include_start_common_env_vars_desc > + :end-before: .. k3_rst_include_end_common_env_vars_desc > + > +.. include:: k3.rst > + :start-after: .. k3_rst_include_start_board_env_vars_desc > + :end-before: .. k3_rst_include_end_board_env_vars_desc > + > +Set the variables corresponding to this platform: > + > +.. include:: k3.rst > + :start-after: .. k3_rst_include_start_common_env_vars_defn > + :end-before: .. k3_rst_include_end_common_env_vars_defn > +.. code-block:: bash > + > + $ export UBOOT_CFG_CORTEXR=j784s4_evm_r5_defconfig > + $ export UBOOT_CFG_CORTEXA=j784s4_evm_a72_defconfig > + $ export TFA_BOARD=generic > + $ export TFA_EXTRA_ARGS="K3_USART=0x8" > + $ export OPTEE_PLATFORM=k3-j784s4 > + $ export OPTEE_EXTRA_ARGS="CFG_CONSOLE_UART=0x8" > + > +.. j784s4_evm_rst_include_start_build_steps > + > +1. Trusted Firmware-A: > + > +.. include:: k3.rst > + :start-after: .. k3_rst_include_start_build_steps_tfa > + :end-before: .. k3_rst_include_end_build_steps_tfa > + > + > +2. OP-TEE: > + > +.. include:: k3.rst > + :start-after: .. k3_rst_include_start_build_steps_optee > + :end-before: .. k3_rst_include_end_build_steps_optee > + > +3. U-Boot: > + > +.. _j784s4_evm_rst_u_boot_r5: > + > +* 3.1 R5: > + > +.. include:: k3.rst > + :start-after: .. k3_rst_include_start_build_steps_spl_r5 > + :end-before: .. k3_rst_include_end_build_steps_spl_r5 > + > +.. _j784s4_evm_rst_u_boot_a72: > + > +* 3.2 A72: > + > +.. include:: k3.rst > + :start-after: .. k3_rst_include_start_build_steps_uboot > + :end-before: .. k3_rst_include_end_build_steps_uboot > +.. j784s4_evm_rst_include_end_build_steps >
[PATCH v1] verdin-imx8mm: verdin-imx8mp: drop obsolete net/phy configs
From: Marcel Ziswiler Drop obsolete networking/PHY related configuration defines. Signed-off-by: Marcel Ziswiler --- include/configs/verdin-imx8mm.h | 3 --- include/configs/verdin-imx8mp.h | 8 2 files changed, 11 deletions(-) diff --git a/include/configs/verdin-imx8mm.h b/include/configs/verdin-imx8mm.h index 4d20b86591f..1dae9919789 100644 --- a/include/configs/verdin-imx8mm.h +++ b/include/configs/verdin-imx8mm.h @@ -67,9 +67,6 @@ #define PHYS_SDRAM 0x4000 #define PHYS_SDRAM_SIZESZ_2G /* 2GB DDR */ -/* ENET */ -#define CONFIG_FEC_MXC_PHYADDR 7 - /* USB Configs */ #define CONFIG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW) diff --git a/include/configs/verdin-imx8mp.h b/include/configs/verdin-imx8mp.h index 9b8db223bb2..69235cb42cb 100644 --- a/include/configs/verdin-imx8mp.h +++ b/include/configs/verdin-imx8mp.h @@ -25,14 +25,6 @@ #define CONFIG_SYS_I2C #endif /* CONFIG_SPL_BUILD */ -/* ENET Config */ -/* ENET1 */ -#if defined(CONFIG_CMD_NET) -#define CONFIG_FEC_MXC_PHYADDR 7 - -#define PHY_ANEG_TIMEOUT 2 -#endif /* CONFIG_CMD_NET */ - #define MEM_LAYOUT_ENV_SETTINGS \ "fdt_addr_r=0x5020\0" \ "kernel_addr_r=" __stringify(CONFIG_SYS_LOAD_ADDR) "\0" \ -- 2.35.1
Re: [PATCH v2 4/5] verdin-imx8mm: various config additions and improvements
Hi Stefano On Mon, 2022-09-19 at 14:39 +0200, Stefano Babic wrote: > On 18.09.22 22:41, sba...@denx.de wrote: > > > From: Marcel Ziswiler > > > - integrate bootcount using SNVS_LP general purpose register LPGPR0 > > > - enable link-time optimisation > > > - explicitly set a boot delay of one second > > > - enable CRC32 and MD5 > > > - enable command for low-level access to data in a partition > > > - enable time commands > > > - enable PMIC commands > > > - improve ETHPRIME configuration > > > - enable eMMC HS400 functionality > > > - enable fixed PHY and MDIO driver model > > > - remove stale PFUZE100 PMIC driver > > > - enable thermal management unit driver > > > - enable more USB host functionality > > > - enable hexdump > > > Signed-off-by: Marcel Ziswiler > > Applied to u-boot-imx, master, thanks ! > > > > Not yet: Patch 4/5 and 5/5 require a rebase, I avoid to do it myself as > I cannot then test if it is ok. These two patches are not in my PR, I > can pick them up if you repost them. Sure. Sorry, I missed this email as you missed CCing anybody else (e.g. like my work email). Plus you probably missed this: https://patchwork.ozlabs.org/project/uboot/cover/20220822130604.843081-1-mar...@ziswiler.com/#2953792 Anyway, I will send an additional series including Patch 4/5, Patch 5/5 and fixing v2 vs. v1 (and more). Thanks! > Best regards, > Stefano Babic Cheers Marcel
[PATCH v3 0/3] verdin-imx8mm: verdin-imx8mp: various additions and improvements
From: Marcel Ziswiler Various additions and improvements for the Verdin iMX8M Mini and Verdin iMX8M Plus: - updated env memory layout - verdin-imx8mm: prepare for optional job ring driver model (already applied) - verdin-imx8mm: improve and extend boot devices (already applied) - various config additions and improvements Changes in v3: - Moved loadaddr back by 0.5MB as I meanwhile found out that it is actually a property of the kernel binary whether or not any additional moving/relocation will (need) to be done. However, a pre-maturely applied v2 did not take that into account as of yet [1]. [1] https://patchwork.ozlabs.org/project/uboot/cover/20220822130604.843081-1-mar...@ziswiler.com/#2953792 - Drop SNVS_LP general purpose register LPGPR0 based bootcount integration in favour of using the environment based one as that is what our update system uses. - Update patch 1 again after wrong version got pre-maturely epplied. - Drop patches 2 and 3 which already got applied. - Drop SNVS_LP general purpose register LPGPR0 based bootcount integration in favour of using the environment based one as that is what our update system uses. Changes in v2: - Moved loadaddr by an additional 0.5MB to avoid "Moving Image from 0x4820 to 0x4828" during booti plus increasing kernel_comp_size by same 0.5MB. Marcel Ziswiler (3): verdin-imx8mm: verdin-imx8mp: update env memory layout (again) verdin-imx8mm: various config additions and improvements verdin-imx8mp: various config additions and improvements configs/verdin-imx8mm_defconfig | 7 ++- configs/verdin-imx8mp_defconfig | 30 ++ include/configs/verdin-imx8mm.h | 2 +- include/configs/verdin-imx8mp.h | 2 +- 4 files changed, 30 insertions(+), 11 deletions(-) -- 2.35.1
[PATCH v3 1/3] verdin-imx8mm: verdin-imx8mp: update env memory layout (again)
From: Marcel Ziswiler Update the distro config env memory layout for the Verdin iMX8M Mini and Verdin iMX8M Plus again: - loadaddr=0x4820 allows for 128MB area for uncompressing (ie FIT images, kernel_comp_addr_r, kernel_comp_size) - fdt_addr_r = loadaddr + 128MB - allows for 128MB kernel - scriptaddr = fdt_addr_r + 512KB - allows for 512KB fdt - ramdisk_addr_r = scriptaddr + 512KB - allows for 512KB script Memory layout taken from commit fd5c7173ade4 ("imx8m{m,n}_venice: update env memory layout"). Note that for our regular BSP Layers and Reference Images for Yocto Project an updated distro boot script is required (see meta-toradex-bsp-common/recipes-bsp/u-boot/u-boot-distro-boot). Note that this corrects a pre-maturely applied version 2 of the same patch set. Fixes: bbe0089d29e ("verdin-imx8mm: verdin-imx8mp: update env memory layout") Signed-off-by: Marcel Ziswiler --- Changes in v3: - Moved loadaddr back by 0.5MB as I meanwhile found out that it is actually a property of the kernel binary whether or not any additional moving/relocation will (need) to be done. However, a pre-maturely applied v2 did not take that into account as of yet [1]. [1] https://patchwork.ozlabs.org/project/uboot/cover/20220822130604.843081-1-mar...@ziswiler.com/#2953792 Changes in v2: - Moved loadaddr by an additional 0.5MB to avoid "Moving Image from 0x4820 to 0x4828" during booti plus increasing kernel_comp_size by same 0.5MB. configs/verdin-imx8mm_defconfig | 2 +- configs/verdin-imx8mp_defconfig | 2 +- include/configs/verdin-imx8mm.h | 2 +- include/configs/verdin-imx8mp.h | 2 +- 4 files changed, 4 insertions(+), 4 deletions(-) diff --git a/configs/verdin-imx8mm_defconfig b/configs/verdin-imx8mm_defconfig index f65b4a7f307..9b9b684ccbc 100644 --- a/configs/verdin-imx8mm_defconfig +++ b/configs/verdin-imx8mm_defconfig @@ -19,7 +19,7 @@ CONFIG_BOOTCOUNT_BOOTLIMIT=3 CONFIG_SYS_BOOTCOUNT_ADDR=0x30370090 CONFIG_SPL=y CONFIG_SYS_BOOTCOUNT_SINGLEWORD=y -CONFIG_SYS_LOAD_ADDR=0x4828 +CONFIG_SYS_LOAD_ADDR=0x4820 CONFIG_SYS_MEMTEST_START=0x4000 CONFIG_SYS_MEMTEST_END=0x8000 CONFIG_LTO=y diff --git a/configs/verdin-imx8mp_defconfig b/configs/verdin-imx8mp_defconfig index 5d0c57c52e4..071a2223d41 100644 --- a/configs/verdin-imx8mp_defconfig +++ b/configs/verdin-imx8mp_defconfig @@ -22,7 +22,7 @@ CONFIG_SPL_DRIVERS_MISC=y CONFIG_SPL=y CONFIG_IMX_BOOTAUX=y CONFIG_SPL_IMX_ROMAPI_LOADADDR=0x4800 -CONFIG_SYS_LOAD_ADDR=0x4828 +CONFIG_SYS_LOAD_ADDR=0x4820 CONFIG_SYS_MEMTEST_START=0x4000 CONFIG_SYS_MEMTEST_END=0x8000 CONFIG_DISTRO_DEFAULTS=y diff --git a/include/configs/verdin-imx8mm.h b/include/configs/verdin-imx8mm.h index 4d20b86591f..ec893763215 100644 --- a/include/configs/verdin-imx8mm.h +++ b/include/configs/verdin-imx8mm.h @@ -23,7 +23,7 @@ "fdt_addr_r=0x5020\0" \ "kernel_addr_r=" __stringify(CONFIG_SYS_LOAD_ADDR) "\0" \ "kernel_comp_addr_r=0x4020\0" \ - "kernel_comp_size=0x0808\0" \ + "kernel_comp_size=0x0800\0" \ "ramdisk_addr_r=0x5030\0" \ "scriptaddr=0x5028\0" diff --git a/include/configs/verdin-imx8mp.h b/include/configs/verdin-imx8mp.h index 9b8db223bb2..959c15f598e 100644 --- a/include/configs/verdin-imx8mp.h +++ b/include/configs/verdin-imx8mp.h @@ -37,7 +37,7 @@ "fdt_addr_r=0x5020\0" \ "kernel_addr_r=" __stringify(CONFIG_SYS_LOAD_ADDR) "\0" \ "kernel_comp_addr_r=0x4020\0" \ - "kernel_comp_size=0x0808\0" \ + "kernel_comp_size=0x0800\0" \ "ramdisk_addr_r=0x5030\0" \ "scriptaddr=0x5028\0" -- 2.35.1
[PATCH v3 2/3] verdin-imx8mm: various config additions and improvements
From: Marcel Ziswiler - enable bootcount command - integrate bootcount using SNVS_LP general purpose register LPGPR0 - enable link-time optimisation - explicitly set a boot delay of one second - enable CRC32 and MD5 - enable command for low-level access to data in a partition - enable time commands - enable PMIC commands - improve ETHPRIME configuration - enable eMMC HS400 functionality - enable fixed PHY and MDIO driver model - remove stale PFUZE100 PMIC driver - enable thermal management unit driver - enable more USB host functionality - enable hexdump Signed-off-by: Marcel Ziswiler --- Changes in v3: - Drop SNVS_LP general purpose register LPGPR0 based bootcount integration in favour of using the environment based one as that is what our update system uses. configs/verdin-imx8mm_defconfig | 5 + 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/configs/verdin-imx8mm_defconfig b/configs/verdin-imx8mm_defconfig index 9b9b684ccbc..25cd59b185e 100644 --- a/configs/verdin-imx8mm_defconfig +++ b/configs/verdin-imx8mm_defconfig @@ -15,10 +15,7 @@ CONFIG_SYS_PROMPT="Verdin iMX8MM # " CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL_DRIVERS_MISC=y -CONFIG_BOOTCOUNT_BOOTLIMIT=3 -CONFIG_SYS_BOOTCOUNT_ADDR=0x30370090 CONFIG_SPL=y -CONFIG_SYS_BOOTCOUNT_SINGLEWORD=y CONFIG_SYS_LOAD_ADDR=0x4820 CONFIG_SYS_MEMTEST_START=0x4000 CONFIG_SYS_MEMTEST_END=0x8000 @@ -92,7 +89,7 @@ CONFIG_IP_DEFRAG=y CONFIG_TFTP_BLOCKSIZE=4096 CONFIG_SPL_DM=y CONFIG_BOOTCOUNT_LIMIT=y -CONFIG_SYS_BOOTCOUNT_MAGIC=0xB0C4 +CONFIG_BOOTCOUNT_ENV=y CONFIG_SPL_CLK_COMPOSITE_CCF=y CONFIG_CLK_COMPOSITE_CCF=y CONFIG_SPL_CLK_IMX8MM=y -- 2.35.1
[PATCH v3 3/3] verdin-imx8mp: various config additions and improvements
From: Marcel Ziswiler - enable bootcount command - enable CRC32 and MD5 - enable time commands - enable GPIO LED support - enable further eMMC HS400 functionality - enable fixed PHY and MDIO driver model - enable USB host functionality - enable thermal management unit driver - enable hexdump Signed-off-by: Marcel Ziswiler --- Changes in v3: - Update patch 1 again after wrong version got pre-maturely epplied. - Drop patches 2 and 3 which already got applied. - Drop SNVS_LP general purpose register LPGPR0 based bootcount integration in favour of using the environment based one as that is what our update system uses. configs/verdin-imx8mp_defconfig | 28 +--- 1 file changed, 25 insertions(+), 3 deletions(-) diff --git a/configs/verdin-imx8mp_defconfig b/configs/verdin-imx8mp_defconfig index 071a2223d41..c476b734573 100644 --- a/configs/verdin-imx8mp_defconfig +++ b/configs/verdin-imx8mp_defconfig @@ -65,7 +65,9 @@ CONFIG_SYS_PBSIZE=2081 # CONFIG_BOOTM_NETBSD is not set CONFIG_CMD_ASKENV=y # CONFIG_CMD_EXPORTENV is not set -# CONFIG_CMD_CRC32 is not set +CONFIG_CRC32_VERIFY=y +CONFIG_CMD_MD5SUM=y +CONFIG_MD5SUM_VERIFY=y CONFIG_CMD_MEMTEST=y CONFIG_CMD_CLK=y CONFIG_CMD_FUSE=y @@ -74,12 +76,14 @@ CONFIG_CMD_I2C=y CONFIG_CMD_MMC=y CONFIG_CMD_READ=y CONFIG_CMD_USB=y +CONFIG_CMD_BOOTCOUNT=y CONFIG_CMD_CACHE=y +CONFIG_CMD_TIME=y CONFIG_CMD_UUID=y CONFIG_CMD_REGULATOR=y CONFIG_CMD_EXT4_WRITE=y # CONFIG_ISO_PARTITION is not set -# CONFIG_EFI_PARTITION is not set +# CONFIG_SPL_EFI_PARTITION is not set CONFIG_OF_CONTROL=y CONFIG_SPL_OF_CONTROL=y CONFIG_ENV_OVERWRITE=y @@ -106,29 +110,38 @@ CONFIG_DM_PCA953X=y CONFIG_DM_I2C=y # CONFIG_SPL_DM_I2C is not set CONFIG_SPL_SYS_I2C_LEGACY=y +CONFIG_LED=y +CONFIG_LED_GPIO=y CONFIG_MISC=y CONFIG_I2C_EEPROM=y CONFIG_SUPPORT_EMMC_BOOT=y CONFIG_MMC_IO_VOLTAGE=y +CONFIG_SPL_MMC_IO_VOLTAGE=y CONFIG_MMC_UHS_SUPPORT=y +CONFIG_SPL_MMC_UHS_SUPPORT=y CONFIG_MMC_HS400_ES_SUPPORT=y CONFIG_MMC_HS400_SUPPORT=y +CONFIG_SPL_MMC_HS400_SUPPORT=y CONFIG_FSL_USDHC=y CONFIG_PHY_ADDR_ENABLE=y CONFIG_PHY_MICREL=y CONFIG_PHY_MICREL_KSZ90X1=y +CONFIG_PHY_FIXED=y +CONFIG_DM_MDIO=y CONFIG_DM_ETH_PHY=y CONFIG_DWC_ETH_QOS=y CONFIG_DWC_ETH_QOS_IMX=y CONFIG_FEC_MXC=y CONFIG_RGMII=y CONFIG_MII=y +CONFIG_PHY_IMX8MQ_USB=y CONFIG_PINCTRL=y CONFIG_SPL_PINCTRL=y CONFIG_PINCTRL_IMX8M=y CONFIG_SPL_POWER_LEGACY=y CONFIG_POWER_DOMAIN=y CONFIG_IMX8M_POWER_DOMAIN=y +CONFIG_IMX8MP_HSIOMIX_BLKCTRL=y CONFIG_DM_REGULATOR=y CONFIG_DM_REGULATOR_FIXED=y CONFIG_DM_REGULATOR_GPIO=y @@ -140,8 +153,17 @@ CONFIG_SPL_SYSRESET=y CONFIG_SYSRESET_PSCI=y CONFIG_SYSRESET_WATCHDOG=y CONFIG_DM_THERMAL=y +CONFIG_IMX_TMU=y CONFIG_USB=y -# CONFIG_SPL_DM_USB is not set +CONFIG_USB_XHCI_HCD=y +CONFIG_USB_XHCI_DWC3=y +CONFIG_USB_XHCI_DWC3_OF_SIMPLE=y CONFIG_USB_EHCI_HCD=y +CONFIG_MXC_USB_OTG_HACTIVE=y +CONFIG_USB_DWC3=y +CONFIG_USB_DWC3_GENERIC=y +CONFIG_USB_KEYBOARD=y +CONFIG_USB_HOST_ETHER=y CONFIG_IMX_WATCHDOG=y +CONFIG_HEXDUMP=y CONFIG_OF_LIBFDT_OVERLAY=y -- 2.35.1
Re: [PATCH v2 4/5] verdin-imx8mm: various config additions and improvements
On Thu, 2022-09-22 at 17:36 +0200, Stefano Babic wrote: > On 22.09.22 17:03, Marcel Ziswiler wrote: > > Hi Stefano > > > > On Mon, 2022-09-19 at 14:39 +0200, Stefano Babic wrote: > > > On 18.09.22 22:41, sba...@denx.de wrote: > > > > > From: Marcel Ziswiler > > > > > - integrate bootcount using SNVS_LP general purpose register LPGPR0 > > > > > - enable link-time optimisation > > > > > - explicitly set a boot delay of one second > > > > > - enable CRC32 and MD5 > > > > > - enable command for low-level access to data in a partition > > > > > - enable time commands > > > > > - enable PMIC commands > > > > > - improve ETHPRIME configuration > > > > > - enable eMMC HS400 functionality > > > > > - enable fixed PHY and MDIO driver model > > > > > - remove stale PFUZE100 PMIC driver > > > > > - enable thermal management unit driver > > > > > - enable more USB host functionality > > > > > - enable hexdump > > > > > Signed-off-by: Marcel Ziswiler > > > > Applied to u-boot-imx, master, thanks ! > > > > > > > > > > Not yet: Patch 4/5 and 5/5 require a rebase, I avoid to do it myself as > > > I cannot then test if it is ok. These two patches are not in my PR, I > > > can pick them up if you repost them. > > > > Sure. > > > > Sorry, I missed this email as you missed CCing anybody else (e.g. like my > > work email). > > > > Sorry, you're right. > > > Plus you probably missed this: > > > > https://patchwork.ozlabs.org/project/uboot/cover/20220822130604.843081-1-mar...@ziswiler.com/#2953792 > > > > Anyway, I will send an additional series including Patch 4/5, Patch 5/5 and > > fixing v2 vs. v1 (and more). https://patchwork.ozlabs.org/project/uboot/cover/20220922212834.2419255-1-mar...@ziswiler.com/ > Thanks ! > > Regards, > Stefano > > > > > Thanks! > > > > > Best regards, > > > Stefano Babic > > > > Cheers > > > > Marcel
Re: [PATCH 1/2] board: verdin-imx8mm: add call to ft_common_board_setup
On Mon, 2022-08-29 at 19:59 +0200, Philippe Schenker wrote: > From: Philippe Schenker > > With this call the following attributes get set to the device-tree > and are then accessible from linux in /proc/device-tree/ > > serial-number: The serial number that is stored in config-block > toradex,board-rev: The version of the module (e.g. V1.1A) > toradex,product-id: The SKU number of the module running > > Fixes: commit 14d5aeff776b ("board: toradex: Add Verdin iMX8M Mini support") > Signed-off-by: Philippe Schenker Acked-by: Marcel Ziswiler > --- > > board/toradex/verdin-imx8mm/verdin-imx8mm.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/board/toradex/verdin-imx8mm/verdin-imx8mm.c > b/board/toradex/verdin-imx8mm/verdin-imx8mm.c > index 7597cd81f945..ffcb04fc31e8 100644 > --- a/board/toradex/verdin-imx8mm/verdin-imx8mm.c > +++ b/board/toradex/verdin-imx8mm/verdin-imx8mm.c > @@ -128,6 +128,6 @@ int board_phys_sdram_size(phys_size_t *size) > #if defined(CONFIG_OF_LIBFDT) && defined(CONFIG_OF_BOARD_SETUP) > int ft_board_setup(void *blob, struct bd_info *bd) > { > - return 0; > + return ft_common_board_setup(blob, bd); > } > #endif
Re: [PATCH 2/2] board: verdin-imx8mp: add call to ft_common_board_setup
On Mon, 2022-08-29 at 19:59 +0200, Philippe Schenker wrote: > From: Philippe Schenker > > With this call the following attributes get set to the device-tree > and are then accessible from linux in /proc/device-tree/ > > serial-number: The serial number that is stored in config-block > toradex,board-rev: The version of the module (e.g. V1.1A) > toradex,product-id: The SKU number of the module runnin > > Fixes: commit 2bc2f817cea7 ("board: toradex: add verdin imx8m plus support") > Signed-off-by: Philippe Schenker Acked-by: Marcel Ziswiler > --- > > board/toradex/verdin-imx8mp/verdin-imx8mp.c | 2 +- > 1 file changed, 1 insertion(+), 1 deletion(-) > > diff --git a/board/toradex/verdin-imx8mp/verdin-imx8mp.c > b/board/toradex/verdin-imx8mp/verdin-imx8mp.c > index e3c1a1201daa..086de96cf2c7 100644 > --- a/board/toradex/verdin-imx8mp/verdin-imx8mp.c > +++ b/board/toradex/verdin-imx8mp/verdin-imx8mp.c > @@ -124,6 +124,6 @@ int board_late_init(void) > #if IS_ENABLED(CONFIG_OF_LIBFDT) && IS_ENABLED(CONFIG_OF_BOARD_SETUP) > int ft_board_setup(void *blob, struct bd_info *bd) > { > - return 0; > + return ft_common_board_setup(blob, bd); > } > #endif
[PATCH] apalis/colibri_imx6/-imx6ull/_imx7: update env memory layout
From: Marcel Ziswiler Update the distro config env memory layout for the Apalis iMX6, Colibri iMX6, Colibri iMX6ULL and Colibri iMX7: - loadaddr=0x8420 allows for 64MB area for uncompressing (ie FIT images) - fdt_addr_r = loadaddr + 64MB : allows for 64MB kernel - scriptaddr = fdt_addr_r + 512KB : allows for 512KB fdt - pxefile_addr_r = scriptaddr + 512KB : allows for 512KB script - ramdisk_addr_r = pxefile_addr_r + 512KB : allows for 1MB extlinux.conf Memory layout analogous to 64-bit one from commit fd5c7173ade4 ("imx8m{m,n}_venice: update env memory layout") but left pxefile_addr_r updated according to doc/develop/distro.rst. This fixes a potential issue caused by the compressed kernel being relocated on top of the ramdisk causing its corruption. Signed-off-by: Marcel Ziswiler eries-version: 1 --- configs/apalis_imx6_defconfig | 1 + configs/colibri-imx6ull-emmc_defconfig | 1 + configs/colibri-imx6ull_defconfig | 1 + configs/colibri_imx6_defconfig | 1 + configs/colibri_imx7_defconfig | 1 + configs/colibri_imx7_emmc_defconfig| 1 + include/configs/apalis_imx6.h | 10 +- include/configs/colibri-imx6ull.h | 10 +- include/configs/colibri_imx6.h | 10 +- include/configs/colibri_imx7.h | 10 +- 10 files changed, 26 insertions(+), 20 deletions(-) diff --git a/configs/apalis_imx6_defconfig b/configs/apalis_imx6_defconfig index 5960aef698f..02a3e8337ca 100644 --- a/configs/apalis_imx6_defconfig +++ b/configs/apalis_imx6_defconfig @@ -22,6 +22,7 @@ CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL=y CONFIG_CMD_HDMIDETECT=y +CONFIG_SYS_LOAD_ADDR=0x8420 CONFIG_AHCI=y CONFIG_SYS_MEMTEST_START=0x1000 CONFIG_SYS_MEMTEST_END=0x1001 diff --git a/configs/colibri-imx6ull-emmc_defconfig b/configs/colibri-imx6ull-emmc_defconfig index e6ed9b5fd0f..02b6be0a2b4 100644 --- a/configs/colibri-imx6ull-emmc_defconfig +++ b/configs/colibri-imx6ull-emmc_defconfig @@ -10,6 +10,7 @@ CONFIG_DM_GPIO=y CONFIG_TARGET_COLIBRI_IMX6ULL_EMMC=y CONFIG_DEFAULT_DEVICE_TREE="imx6ull-colibri-emmc-eval-v3" CONFIG_SYS_PROMPT="Colibri iMX6ULL # " +CONFIG_SYS_LOAD_ADDR=0x8420 CONFIG_SYS_MEMTEST_START=0x8000 CONFIG_SYS_MEMTEST_END=0x8800 CONFIG_DISTRO_DEFAULTS=y diff --git a/configs/colibri-imx6ull_defconfig b/configs/colibri-imx6ull_defconfig index d65f2533ca2..cc0a3473941 100644 --- a/configs/colibri-imx6ull_defconfig +++ b/configs/colibri-imx6ull_defconfig @@ -11,6 +11,7 @@ CONFIG_DM_GPIO=y CONFIG_TARGET_COLIBRI_IMX6ULL_NAND=y CONFIG_DEFAULT_DEVICE_TREE="imx6ull-colibri-eval-v3" CONFIG_SYS_PROMPT="Colibri iMX6ULL # " +CONFIG_SYS_LOAD_ADDR=0x8420 CONFIG_SYS_MEMTEST_START=0x8000 CONFIG_SYS_MEMTEST_END=0x8800 CONFIG_DISTRO_DEFAULTS=y diff --git a/configs/colibri_imx6_defconfig b/configs/colibri_imx6_defconfig index 5cf398b09e2..ca3ec8b706d 100644 --- a/configs/colibri_imx6_defconfig +++ b/configs/colibri_imx6_defconfig @@ -22,6 +22,7 @@ CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL=y CONFIG_CMD_HDMIDETECT=y +CONFIG_SYS_LOAD_ADDR=0x8420 CONFIG_SYS_MEMTEST_START=0x1000 CONFIG_SYS_MEMTEST_END=0x1001 CONFIG_DISTRO_DEFAULTS=y diff --git a/configs/colibri_imx7_defconfig b/configs/colibri_imx7_defconfig index dfdb74f69b0..28872639b61 100644 --- a/configs/colibri_imx7_defconfig +++ b/configs/colibri_imx7_defconfig @@ -11,6 +11,7 @@ CONFIG_SYS_PROMPT="Colibri iMX7 # " CONFIG_IMX_RDC=y CONFIG_IMX_BOOTAUX=y CONFIG_IMX_HAB=y +CONFIG_SYS_LOAD_ADDR=0x8420 CONFIG_OF_BOARD_FIXUP=y CONFIG_SYS_MEMTEST_START=0x8000 CONFIG_SYS_MEMTEST_END=0x8c00 diff --git a/configs/colibri_imx7_emmc_defconfig b/configs/colibri_imx7_emmc_defconfig index 033ce1747bf..c12717b4f25 100644 --- a/configs/colibri_imx7_emmc_defconfig +++ b/configs/colibri_imx7_emmc_defconfig @@ -12,6 +12,7 @@ CONFIG_ARMV7_BOOT_SEC_DEFAULT=y CONFIG_IMX_RDC=y CONFIG_IMX_BOOTAUX=y CONFIG_IMX_HAB=y +CONFIG_SYS_LOAD_ADDR=0x8420 CONFIG_SYS_MEMTEST_START=0x8000 CONFIG_SYS_MEMTEST_END=0x8c00 CONFIG_DISTRO_DEFAULTS=y diff --git a/include/configs/apalis_imx6.h b/include/configs/apalis_imx6.h index 4922b063309..51ef4e3663c 100644 --- a/include/configs/apalis_imx6.h +++ b/include/configs/apalis_imx6.h @@ -70,11 +70,11 @@ #define MEM_LAYOUT_ENV_SETTINGS \ "bootm_size=0x2000\0" \ - "fdt_addr_r=0x1210\0" \ - "kernel_addr_r=0x1100\0" \ - "pxefile_addr_r=0x1710\0" \ - "ramdisk_addr_r=0x1220\0" \ - "scriptaddr=0x1700\0" + "fdt_addr_r=0x8820\0" \ + "kernel_addr_r=" __stringify(CONFIG_SYS_LOAD_ADDR) "\0" \ + "pxefile_addr_r=0x8830\0" \ + "ramdisk_addr_r=0x8840\0" \ + "scriptaddr=0x8828\0" #define CONFIG_EXTRA_ENV_
[PATCH v2] apalis/colibri_imx6/-imx6ull/_imx7: update env memory layout
From: Marcel Ziswiler Update the distro config env memory layout for the Apalis iMX6, Colibri iMX6, Colibri iMX6ULL and Colibri iMX7: - loadaddr=0x8420 (resp. 0x1420 on them i.MX 6) allows for 64MB area for uncompressing (ie FIT images) - fdt_addr_r = loadaddr + 64MB : allows for 64MB kernel - scriptaddr = fdt_addr_r + 512KB : allows for 512KB fdt - pxefile_addr_r = scriptaddr + 512KB : allows for 512KB script - ramdisk_addr_r = pxefile_addr_r + 512KB : allows for 1MB extlinux.conf Memory layout analogous to 64-bit one from commit fd5c7173ade4 ("imx8m{m,n}_venice: update env memory layout") but left pxefile_addr_r updated according to doc/develop/distro.rst. This fixes a potential issue caused by the compressed kernel being relocated on top of the ramdisk causing its corruption. Signed-off-by: Marcel Ziswiler --- Changes in v2: - Changed i.MX 6 addressing back to starting from 0x1000 instead of 0x8000. configs/apalis_imx6_defconfig | 1 + configs/colibri-imx6ull-emmc_defconfig | 1 + configs/colibri-imx6ull_defconfig | 1 + configs/colibri_imx6_defconfig | 1 + configs/colibri_imx7_defconfig | 1 + configs/colibri_imx7_emmc_defconfig| 1 + include/configs/apalis_imx6.h | 10 +- include/configs/colibri-imx6ull.h | 10 +- include/configs/colibri_imx6.h | 10 +- include/configs/colibri_imx7.h | 10 +- 10 files changed, 26 insertions(+), 20 deletions(-) diff --git a/configs/apalis_imx6_defconfig b/configs/apalis_imx6_defconfig index 5960aef698f..2689e8d9846 100644 --- a/configs/apalis_imx6_defconfig +++ b/configs/apalis_imx6_defconfig @@ -22,6 +22,7 @@ CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL=y CONFIG_CMD_HDMIDETECT=y +CONFIG_SYS_LOAD_ADDR=0x1420 CONFIG_AHCI=y CONFIG_SYS_MEMTEST_START=0x1000 CONFIG_SYS_MEMTEST_END=0x1001 diff --git a/configs/colibri-imx6ull-emmc_defconfig b/configs/colibri-imx6ull-emmc_defconfig index e6ed9b5fd0f..02b6be0a2b4 100644 --- a/configs/colibri-imx6ull-emmc_defconfig +++ b/configs/colibri-imx6ull-emmc_defconfig @@ -10,6 +10,7 @@ CONFIG_DM_GPIO=y CONFIG_TARGET_COLIBRI_IMX6ULL_EMMC=y CONFIG_DEFAULT_DEVICE_TREE="imx6ull-colibri-emmc-eval-v3" CONFIG_SYS_PROMPT="Colibri iMX6ULL # " +CONFIG_SYS_LOAD_ADDR=0x8420 CONFIG_SYS_MEMTEST_START=0x8000 CONFIG_SYS_MEMTEST_END=0x8800 CONFIG_DISTRO_DEFAULTS=y diff --git a/configs/colibri-imx6ull_defconfig b/configs/colibri-imx6ull_defconfig index d65f2533ca2..cc0a3473941 100644 --- a/configs/colibri-imx6ull_defconfig +++ b/configs/colibri-imx6ull_defconfig @@ -11,6 +11,7 @@ CONFIG_DM_GPIO=y CONFIG_TARGET_COLIBRI_IMX6ULL_NAND=y CONFIG_DEFAULT_DEVICE_TREE="imx6ull-colibri-eval-v3" CONFIG_SYS_PROMPT="Colibri iMX6ULL # " +CONFIG_SYS_LOAD_ADDR=0x8420 CONFIG_SYS_MEMTEST_START=0x8000 CONFIG_SYS_MEMTEST_END=0x8800 CONFIG_DISTRO_DEFAULTS=y diff --git a/configs/colibri_imx6_defconfig b/configs/colibri_imx6_defconfig index 5cf398b09e2..135095b275d 100644 --- a/configs/colibri_imx6_defconfig +++ b/configs/colibri_imx6_defconfig @@ -22,6 +22,7 @@ CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL=y CONFIG_CMD_HDMIDETECT=y +CONFIG_SYS_LOAD_ADDR=0x1420 CONFIG_SYS_MEMTEST_START=0x1000 CONFIG_SYS_MEMTEST_END=0x1001 CONFIG_DISTRO_DEFAULTS=y diff --git a/configs/colibri_imx7_defconfig b/configs/colibri_imx7_defconfig index dfdb74f69b0..28872639b61 100644 --- a/configs/colibri_imx7_defconfig +++ b/configs/colibri_imx7_defconfig @@ -11,6 +11,7 @@ CONFIG_SYS_PROMPT="Colibri iMX7 # " CONFIG_IMX_RDC=y CONFIG_IMX_BOOTAUX=y CONFIG_IMX_HAB=y +CONFIG_SYS_LOAD_ADDR=0x8420 CONFIG_OF_BOARD_FIXUP=y CONFIG_SYS_MEMTEST_START=0x8000 CONFIG_SYS_MEMTEST_END=0x8c00 diff --git a/configs/colibri_imx7_emmc_defconfig b/configs/colibri_imx7_emmc_defconfig index 033ce1747bf..c12717b4f25 100644 --- a/configs/colibri_imx7_emmc_defconfig +++ b/configs/colibri_imx7_emmc_defconfig @@ -12,6 +12,7 @@ CONFIG_ARMV7_BOOT_SEC_DEFAULT=y CONFIG_IMX_RDC=y CONFIG_IMX_BOOTAUX=y CONFIG_IMX_HAB=y +CONFIG_SYS_LOAD_ADDR=0x8420 CONFIG_SYS_MEMTEST_START=0x8000 CONFIG_SYS_MEMTEST_END=0x8c00 CONFIG_DISTRO_DEFAULTS=y diff --git a/include/configs/apalis_imx6.h b/include/configs/apalis_imx6.h index 4922b063309..8f338943475 100644 --- a/include/configs/apalis_imx6.h +++ b/include/configs/apalis_imx6.h @@ -70,11 +70,11 @@ #define MEM_LAYOUT_ENV_SETTINGS \ "bootm_size=0x2000\0" \ - "fdt_addr_r=0x1210\0" \ - "kernel_addr_r=0x1100\0" \ - "pxefile_addr_r=0x1710\0" \ - "ramdisk_addr_r=0x1220\0" \ - "scriptaddr=0x1700\0" + "fdt_addr_r=0x1820\0" \ + "kernel_addr_r=" __stringify(CONFIG_SYS_LOAD_ADDR) "\0" \ + "pxefile_addr_r=0x1830\0" \
Re: [PATCH v1 0/3] verdin-imx8mp: enable caam
Hi Andrejs On Tue, 2022-10-04 at 13:06 +0200, Andrejs Cainikovs wrote: > This patch series enables Cryptographic Accelerator and > Assurance Module (aka CAAM) on verdin-imx8mp SoM. > > Andrejs Cainikovs (3): > arm: dts: verdin-imx8mp: enable caam in SPL > verdin-imx8mp: spl: initialize caam > configs: verdin-imx8mp: enable caam Whole series Acked-by: Marcel Ziswiler > arch/arm/dts/imx8mp-verdin-wifi-dev-u-boot.dtsi | 16 > board/toradex/verdin-imx8mp/spl.c | 11 +++ > configs/verdin-imx8mp_defconfig | 1 + > 3 files changed, 28 insertions(+) Thanks! Cheers Marcel
Re: [PATCH v4] imx: support i.MX8QM DMSSE20 a1 board
Hi Oliver On Wed, 2022-10-05 at 16:22 +0200, oliver.gra...@kococonnector.com wrote: > On 13/07/22, Marcel Ziswiler wrote: [snip] > > > > + */ > > > + > > > +/dts-v1/; > > > + > > > +/* First 128KB is for PSCI ATF. */ > > > +/memreserve/ 0x8000 0x0002; > > > + > > > +#include "fsl-imx8qm.dtsi" > > > + > > > +/ { > > > + model = "Advantech iMX8QM DMSSE20"; > > > + compatible = "fsl,imx8qm-mek", "fsl,imx8qm"; > > > + > > > + aliases { > > > + mmc0 = &usdhc1; > > > + mmc2 = &usdhc3; > > > + }; > > > + > > > + chosen { > > > + bootargs = "console=ttyLP0,115200 > > > earlycon=lpuart32,0x5a06,115200"; > > > > This stuff is completely downstream bogus. > > I'am confused here because I see such statements in a lot of device > trees. What I meant is the part after earlycon. It is recommend to not have anything there https://www.kernel.org/doc/html/v4.14/admin-guide/kernel-parameters.html > When used with no options, the early console is > determined by the stdout-path property in device > tree's chosen node. > > > + stdout-path = &lpuart0; > > > + }; > > > + > > > + regulators { > > > > That grouping is also bogus. > > What do you mean exactly? What I meant is that this grouping does not make any sense at all and needs to go. Just leave "[tab]regulators {" and its closing "};" away and remove one "[tab]" of indentation for all them regulators. For reference e.g. see here https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git/tree/arch/arm64/boot/dts/freescale/imx8qm-mek.dts?h=v6.0#n30 > > > + compatible = "simple-bus"; > > > + #address-cells = <1>; > > > + #size-cells = <0>; > > > + > > > + reg_usb_otg1_vbus: regulator@0 { > > > + compatible = "regulator-fixed"; > > > + reg = <0>; > > > > Using any such is also bogus (same with above @0 notation, of course). > > I'am confused here too. What is the right notation now? There simply is no such register zero or anything. See also above linked example. > > > + regulator-name = "usb_otg1_vbus"; > > > + regulator-min-microvolt = <500>; > > > + regulator-max-microvolt = <500>; > > > + gpio = <&gpio4 3 GPIO_ACTIVE_HIGH>; > > > + enable-active-high; > > > + }; > > > + > > > + reg_usdhc2_vmmc: usdhc2_vmmc { > > > + compatible = "regulator-fixed"; > > > + regulator-name = "sw-3p3-sd1"; > > > + regulator-min-microvolt = <330>; > > > + regulator-max-microvolt = <330>; > > > + gpio = <&gpio4 7 GPIO_ACTIVE_HIGH>; > > > + enable-active-high; > > > + }; > > > + > > > + busfreq { > > > + status = "disabled"; > > > + }; > > > + }; > > > +}; [snip] > > > +&fec2 { > > > + pinctrl-names = "default"; > > > + pinctrl-0 = <&pinctrl_fec2>; > > > + phy-mode = "rgmii-id"; > > > + phy-handle = <ðphy1>; > > > + fsl,ar8031-phy-fixup; > > > + fsl,magic-packet; > > > + status = "okay"; > > > + fsl,mii-exclusive; > > > > That actually is just downstream only NXP bogus. > > you mean the `fsl,mii-exclusive`? so I should just drop it? Yes, you may grep the entire kernel sources for even "mii-exclusive". It does not exist anywhere so nothing will ever happen except confusing people. [snip] > > > > Otherwise looks great. Keep up the good work! > > > > thx for the review You are very welcome. > > Cheers > > > > Marcel > > Best Regards, > > Oliver Cheers Marcel
[PATCH v1 0/5] verdin-imx8mm: verdin-imx8mp: various additions and improvements
From: Marcel Ziswiler Various additions and improvements for the Verdin iMX8M Mini and Verdin iMX8M Plus: - updated env memory layout - verdin-imx8mm: prepare for optional job ring driver model - verdin-imx8mm: improve and extend boot devices - various config additions and improvements Marcel Ziswiler (5): verdin-imx8mm: verdin-imx8mp: update env memory layout verdin-imx8mm: prepare for optional job ring driver model verdin-imx8mm: improve and extend boot devices verdin-imx8mm: various config additions and improvements verdin-imx8mp: various config additions and improvements board/toradex/verdin-imx8mm/spl.c | 17 +- configs/verdin-imx8mm_defconfig | 37 +-- configs/verdin-imx8mp_defconfig | 35 - include/configs/verdin-imx8mm.h | 10 + include/configs/verdin-imx8mp.h | 10 + 5 files changed, 83 insertions(+), 26 deletions(-) -- 2.35.1
[PATCH v1 1/5] verdin-imx8mm: verdin-imx8mp: update env memory layout
From: Marcel Ziswiler Update the distro config env memory layout for the Verdin iMX8M Mini and Verdin iMX8M Plus: - loadaddr=0x4820 allows for 128MB area for uncompressing (ie FIT images, kernel_comp_addr_r, kernel_comp_size) - fdt_addr_r = loadaddr + 128MB - allows for 128MB kernel - scriptaddr = fdt_addr_r + 512KB - allows for 512KB fdt - ramdisk_addr_r = scriptaddr + 512KB - allows for 512KB script Memory layout taken from commit fd5c7173ade4 ("imx8m{m,n}_venice: update env memory layout"). Note that for our regular BSP Layers and Reference Images for Yocto Project an updated distro boot script is required (see meta-toradex-bsp-common/recipes-bsp/u-boot/u-boot-distro-boot). Signed-off-by: Marcel Ziswiler --- configs/verdin-imx8mm_defconfig | 2 +- configs/verdin-imx8mp_defconfig | 2 +- include/configs/verdin-imx8mm.h | 10 ++ include/configs/verdin-imx8mp.h | 10 ++ 4 files changed, 14 insertions(+), 10 deletions(-) diff --git a/configs/verdin-imx8mm_defconfig b/configs/verdin-imx8mm_defconfig index 275a29bf4f9..d1029371b6d 100644 --- a/configs/verdin-imx8mm_defconfig +++ b/configs/verdin-imx8mm_defconfig @@ -15,7 +15,7 @@ CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL_DRIVERS_MISC=y CONFIG_SPL=y -CONFIG_SYS_LOAD_ADDR=0x4048 +CONFIG_SYS_LOAD_ADDR=0x4820 CONFIG_SYS_MEMTEST_START=0x4000 CONFIG_SYS_MEMTEST_END=0x8000 CONFIG_DISTRO_DEFAULTS=y diff --git a/configs/verdin-imx8mp_defconfig b/configs/verdin-imx8mp_defconfig index 0804fbff915..8a6765fbf9d 100644 --- a/configs/verdin-imx8mp_defconfig +++ b/configs/verdin-imx8mp_defconfig @@ -21,7 +21,7 @@ CONFIG_SPL_DRIVERS_MISC=y CONFIG_SPL=y CONFIG_IMX_BOOTAUX=y CONFIG_SPL_IMX_ROMAPI_LOADADDR=0x4800 -CONFIG_SYS_LOAD_ADDR=0x4350 +CONFIG_SYS_LOAD_ADDR=0x4820 CONFIG_SYS_MEMTEST_START=0x4000 CONFIG_SYS_MEMTEST_END=0x8000 CONFIG_DISTRO_DEFAULTS=y diff --git a/include/configs/verdin-imx8mm.h b/include/configs/verdin-imx8mm.h index 5b5fce9bda1..ec893763215 100644 --- a/include/configs/verdin-imx8mm.h +++ b/include/configs/verdin-imx8mm.h @@ -20,10 +20,12 @@ #endif #define MEM_LAYOUT_ENV_SETTINGS \ - "fdt_addr_r=0x4400\0" \ - "kernel_addr_r=0x4200\0" \ - "ramdisk_addr_r=0x4640\0" \ - "scriptaddr=0x4600\0" + "fdt_addr_r=0x5020\0" \ + "kernel_addr_r=" __stringify(CONFIG_SYS_LOAD_ADDR) "\0" \ + "kernel_comp_addr_r=0x4020\0" \ + "kernel_comp_size=0x0800\0" \ + "ramdisk_addr_r=0x5030\0" \ + "scriptaddr=0x5028\0" /* Enable Distro Boot */ #define BOOT_TARGET_DEVICES(func) \ diff --git a/include/configs/verdin-imx8mp.h b/include/configs/verdin-imx8mp.h index fca40beba18..959c15f598e 100644 --- a/include/configs/verdin-imx8mp.h +++ b/include/configs/verdin-imx8mp.h @@ -34,10 +34,12 @@ #endif /* CONFIG_CMD_NET */ #define MEM_LAYOUT_ENV_SETTINGS \ - "fdt_addr_r=0x4300\0" \ - "kernel_addr_r=0x4000\0" \ - "ramdisk_addr_r=0x4640\0" \ - "scriptaddr=0x4600\0" + "fdt_addr_r=0x5020\0" \ + "kernel_addr_r=" __stringify(CONFIG_SYS_LOAD_ADDR) "\0" \ + "kernel_comp_addr_r=0x4020\0" \ + "kernel_comp_size=0x0800\0" \ + "ramdisk_addr_r=0x5030\0" \ + "scriptaddr=0x5028\0" /* Enable Distro Boot */ #define BOOT_TARGET_DEVICES(func) \ -- 2.35.1
[PATCH v1 2/5] verdin-imx8mm: prepare for optional job ring driver model
From: Marcel Ziswiler Prepare for optional job ring driver model. Sec may be initialized based on the job ring information processed from the device tree. Signed-off-by: Marcel Ziswiler --- board/toradex/verdin-imx8mm/spl.c | 9 + 1 file changed, 9 insertions(+) diff --git a/board/toradex/verdin-imx8mm/spl.c b/board/toradex/verdin-imx8mm/spl.c index 243c97e0ba0..685ac94f4ca 100644 --- a/board/toradex/verdin-imx8mm/spl.c +++ b/board/toradex/verdin-imx8mm/spl.c @@ -56,6 +56,15 @@ void spl_dram_init(void) void spl_board_init(void) { + if (IS_ENABLED(CONFIG_FSL_CAAM)) { + struct udevice *dev; + int ret; + + ret = uclass_get_device_by_driver(UCLASS_MISC, DM_DRIVER_GET(caam_jr), &dev); + if (ret) + printf("Failed to initialize %s: %d\n", dev->name, ret); + } + /* Serial download mode */ if (is_usb_boot()) { puts("Back to ROM, SDP\n"); -- 2.35.1
[PATCH v1 3/5] verdin-imx8mm: improve and extend boot devices
From: Marcel Ziswiler - Annotate boot devices available in spl_board_boot_device(). - Drop SD3_BOOT/MMC3_BOOT not available for boot on Verdin iMX8M Mini. Signed-off-by: Marcel Ziswiler --- board/toradex/verdin-imx8mm/spl.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/board/toradex/verdin-imx8mm/spl.c b/board/toradex/verdin-imx8mm/spl.c index 685ac94f4ca..fb9aae6c9c8 100644 --- a/board/toradex/verdin-imx8mm/spl.c +++ b/board/toradex/verdin-imx8mm/spl.c @@ -34,14 +34,11 @@ DECLARE_GLOBAL_DATA_PTR; int spl_board_boot_device(enum boot_device boot_dev_spl) { switch (boot_dev_spl) { - case MMC1_BOOT: + case MMC1_BOOT: /* eMMC */ return BOOT_DEVICE_MMC1; - case SD2_BOOT: + case SD2_BOOT: /* SD card */ case MMC2_BOOT: return BOOT_DEVICE_MMC2; - case SD3_BOOT: - case MMC3_BOOT: - return BOOT_DEVICE_MMC1; case USB_BOOT: return BOOT_DEVICE_BOARD; default: @@ -83,7 +80,6 @@ int board_fit_config_name_match(const char *name) } #endif - __weak void board_early_init(void) { init_uart_clk(0); -- 2.35.1
[PATCH v1 4/5] verdin-imx8mm: various config additions and improvements
From: Marcel Ziswiler - integrate bootcount using SNVS_LP general purpose register LPGPR0 - enable link-time optimisation - explicitly set a boot delay of one second - enable CRC32 and MD5 - enable command for low-level access to data in a partition - enable time commands - enable PMIC commands - improve ETHPRIME configuration - enable eMMC HS400 functionality - enable fixed PHY and MDIO driver model - remove stale PFUZE100 PMIC driver - enable thermal management unit driver - enable more USB host functionality - enable hexdump Signed-off-by: Marcel Ziswiler --- configs/verdin-imx8mm_defconfig | 35 +++-- 1 file changed, 29 insertions(+), 6 deletions(-) diff --git a/configs/verdin-imx8mm_defconfig b/configs/verdin-imx8mm_defconfig index d1029371b6d..e256e19f3a8 100644 --- a/configs/verdin-imx8mm_defconfig +++ b/configs/verdin-imx8mm_defconfig @@ -14,10 +14,14 @@ CONFIG_TARGET_VERDIN_IMX8MM=y CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL_DRIVERS_MISC=y +CONFIG_BOOTCOUNT_BOOTLIMIT=3 +CONFIG_SYS_BOOTCOUNT_ADDR=0x30370090 CONFIG_SPL=y +CONFIG_SYS_BOOTCOUNT_SINGLEWORD=y CONFIG_SYS_LOAD_ADDR=0x4820 CONFIG_SYS_MEMTEST_START=0x4000 CONFIG_SYS_MEMTEST_END=0x8000 +CONFIG_LTO=y CONFIG_DISTRO_DEFAULTS=y CONFIG_FIT=y CONFIG_FIT_EXTERNAL_OFFSET=0x3000 @@ -25,7 +29,7 @@ CONFIG_FIT_VERBOSE=y CONFIG_SPL_LOAD_FIT=y # CONFIG_USE_SPL_FIT_GENERATOR is not set CONFIG_OF_SYSTEM_SETUP=y -# CONFIG_USE_BOOTCOMMAND is not set +CONFIG_BOOTDELAY=1 CONFIG_USE_PREBOOT=y CONFIG_PREBOOT="test -n ${fdtfile} || setenv fdtfile imx8mm-verdin-${variant}-${fdt_board}.dtb" CONFIG_LOG=y @@ -54,20 +58,26 @@ CONFIG_SYS_PBSIZE=2081 # CONFIG_BOOTM_NETBSD is not set CONFIG_CMD_ASKENV=y # CONFIG_CMD_EXPORTENV is not set -# CONFIG_CMD_CRC32 is not set +CONFIG_CRC32_VERIFY=y +CONFIG_CMD_MD5SUM=y +CONFIG_MD5SUM_VERIFY=y CONFIG_CMD_MEMTEST=y CONFIG_CMD_CLK=y CONFIG_CMD_FUSE=y CONFIG_CMD_GPIO=y CONFIG_CMD_I2C=y CONFIG_CMD_MMC=y +CONFIG_CMD_READ=y CONFIG_CMD_USB=y +CONFIG_CMD_BOOTCOUNT=y CONFIG_CMD_CACHE=y +CONFIG_CMD_TIME=y CONFIG_CMD_UUID=y +CONFIG_CMD_PMIC=y CONFIG_CMD_REGULATOR=y CONFIG_CMD_EXT4_WRITE=y # CONFIG_ISO_PARTITION is not set -# CONFIG_EFI_PARTITION is not set +# CONFIG_SPL_EFI_PARTITION is not set CONFIG_OF_CONTROL=y CONFIG_SPL_OF_CONTROL=y CONFIG_ENV_OVERWRITE=y @@ -76,11 +86,13 @@ CONFIG_SYS_RELOC_GD_ENV_ADDR=y CONFIG_SYS_MMC_ENV_PART=1 CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y CONFIG_USE_ETHPRIME=y -CONFIG_ETHPRIME="FEC" +CONFIG_ETHPRIME="eth0" CONFIG_VERSION_VARIABLE=y CONFIG_IP_DEFRAG=y CONFIG_TFTP_BLOCKSIZE=4096 CONFIG_SPL_DM=y +CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_SYS_BOOTCOUNT_MAGIC=0xB0C4 CONFIG_SPL_CLK_COMPOSITE_CCF=y CONFIG_CLK_COMPOSITE_CCF=y CONFIG_SPL_CLK_IMX8MM=y @@ -91,12 +103,21 @@ CONFIG_DM_I2C=y CONFIG_MISC=y CONFIG_I2C_EEPROM=y CONFIG_SUPPORT_EMMC_BOOT=y +CONFIG_MMC_IO_VOLTAGE=y +CONFIG_SPL_MMC_IO_VOLTAGE=y +CONFIG_MMC_UHS_SUPPORT=y +CONFIG_SPL_MMC_UHS_SUPPORT=y +CONFIG_MMC_HS400_ES_SUPPORT=y +CONFIG_MMC_HS400_SUPPORT=y +CONFIG_SPL_MMC_HS400_SUPPORT=y CONFIG_FSL_USDHC=y CONFIG_PHYLIB=y CONFIG_PHY_ADDR_ENABLE=y CONFIG_PHY_MICREL=y CONFIG_PHY_MICREL_KSZ90X1=y +CONFIG_PHY_FIXED=y CONFIG_DM_ETH=y +CONFIG_DM_MDIO=y CONFIG_FEC_MXC=y CONFIG_MII=y CONFIG_PINCTRL=y @@ -106,7 +127,6 @@ CONFIG_POWER_DOMAIN=y CONFIG_IMX8M_POWER_DOMAIN=y CONFIG_DM_PMIC=y CONFIG_SPL_DM_PMIC_PCA9450=y -CONFIG_DM_PMIC_PFUZE100=y CONFIG_DM_REGULATOR=y CONFIG_DM_REGULATOR_FIXED=y CONFIG_DM_REGULATOR_GPIO=y @@ -117,8 +137,11 @@ CONFIG_SPL_SYSRESET=y CONFIG_SYSRESET_PSCI=y CONFIG_SYSRESET_WATCHDOG=y CONFIG_DM_THERMAL=y +CONFIG_IMX_TMU=y CONFIG_USB=y -# CONFIG_SPL_DM_USB is not set CONFIG_USB_EHCI_HCD=y +CONFIG_USB_KEYBOARD=y +CONFIG_USB_HOST_ETHER=y CONFIG_IMX_WATCHDOG=y +CONFIG_HEXDUMP=y CONFIG_OF_LIBFDT_OVERLAY=y -- 2.35.1
[PATCH v1 5/5] verdin-imx8mp: various config additions and improvements
From: Marcel Ziswiler - integrate bootcount using SNVS_LP general purpose register LPGPR0 - enable CRC32 and MD5 - enable time commands - enable GPIO LED support - enable further eMMC HS400 functionality - enable fixed PHY and MDIO driver model - enable USB host functionality - enable thermal management unit driver - enable hexdump Signed-off-by: Marcel Ziswiler --- configs/verdin-imx8mp_defconfig | 33 + 1 file changed, 29 insertions(+), 4 deletions(-) diff --git a/configs/verdin-imx8mp_defconfig b/configs/verdin-imx8mp_defconfig index 8a6765fbf9d..2e213d41860 100644 --- a/configs/verdin-imx8mp_defconfig +++ b/configs/verdin-imx8mp_defconfig @@ -18,7 +18,10 @@ CONFIG_TARGET_VERDIN_IMX8MP=y CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL_DRIVERS_MISC=y +CONFIG_BOOTCOUNT_BOOTLIMIT=3 +CONFIG_SYS_BOOTCOUNT_ADDR=0x30370090 CONFIG_SPL=y +CONFIG_SYS_BOOTCOUNT_SINGLEWORD=y CONFIG_IMX_BOOTAUX=y CONFIG_SPL_IMX_ROMAPI_LOADADDR=0x4800 CONFIG_SYS_LOAD_ADDR=0x4820 @@ -65,7 +68,9 @@ CONFIG_SYS_PBSIZE=2081 # CONFIG_BOOTM_NETBSD is not set CONFIG_CMD_ASKENV=y # CONFIG_CMD_EXPORTENV is not set -# CONFIG_CMD_CRC32 is not set +CONFIG_CRC32_VERIFY=y +CONFIG_CMD_MD5SUM=y +CONFIG_MD5SUM_VERIFY=y CONFIG_CMD_MEMTEST=y CONFIG_CMD_CLK=y CONFIG_CMD_FUSE=y @@ -74,12 +79,14 @@ CONFIG_CMD_I2C=y CONFIG_CMD_MMC=y CONFIG_CMD_READ=y CONFIG_CMD_USB=y +CONFIG_CMD_BOOTCOUNT=y CONFIG_CMD_CACHE=y +CONFIG_CMD_TIME=y CONFIG_CMD_UUID=y CONFIG_CMD_REGULATOR=y CONFIG_CMD_EXT4_WRITE=y # CONFIG_ISO_PARTITION is not set -# CONFIG_EFI_PARTITION is not set +# CONFIG_SPL_EFI_PARTITION is not set CONFIG_OF_CONTROL=y CONFIG_SPL_OF_CONTROL=y CONFIG_ENV_OVERWRITE=y @@ -97,7 +104,7 @@ CONFIG_SPL_DM=y CONFIG_REGMAP=y CONFIG_SYSCON=y CONFIG_BOOTCOUNT_LIMIT=y -CONFIG_BOOTCOUNT_ENV=y +CONFIG_SYS_BOOTCOUNT_MAGIC=0xB0C4 CONFIG_CLK_COMPOSITE_CCF=y CONFIG_CLK_IMX8MP=y CONFIG_GPIO_HOG=y @@ -106,30 +113,39 @@ CONFIG_DM_PCA953X=y CONFIG_DM_I2C=y # CONFIG_SPL_DM_I2C is not set CONFIG_SPL_SYS_I2C_LEGACY=y +CONFIG_LED=y +CONFIG_LED_GPIO=y CONFIG_MISC=y CONFIG_I2C_EEPROM=y CONFIG_SUPPORT_EMMC_BOOT=y CONFIG_MMC_IO_VOLTAGE=y +CONFIG_SPL_MMC_IO_VOLTAGE=y CONFIG_MMC_UHS_SUPPORT=y +CONFIG_SPL_MMC_UHS_SUPPORT=y CONFIG_MMC_HS400_ES_SUPPORT=y CONFIG_MMC_HS400_SUPPORT=y +CONFIG_SPL_MMC_HS400_SUPPORT=y CONFIG_FSL_USDHC=y CONFIG_PHY_ADDR_ENABLE=y CONFIG_PHY_MICREL=y CONFIG_PHY_MICREL_KSZ90X1=y +CONFIG_PHY_FIXED=y CONFIG_DM_ETH=y +CONFIG_DM_MDIO=y CONFIG_DM_ETH_PHY=y CONFIG_DWC_ETH_QOS=y CONFIG_DWC_ETH_QOS_IMX=y CONFIG_FEC_MXC=y CONFIG_RGMII=y CONFIG_MII=y +CONFIG_PHY_IMX8MQ_USB=y CONFIG_PINCTRL=y CONFIG_SPL_PINCTRL=y CONFIG_PINCTRL_IMX8M=y CONFIG_SPL_POWER_LEGACY=y CONFIG_POWER_DOMAIN=y CONFIG_IMX8M_POWER_DOMAIN=y +CONFIG_IMX8MP_HSIOMIX_BLKCTRL=y CONFIG_DM_REGULATOR=y CONFIG_DM_REGULATOR_FIXED=y CONFIG_DM_REGULATOR_GPIO=y @@ -141,8 +157,17 @@ CONFIG_SPL_SYSRESET=y CONFIG_SYSRESET_PSCI=y CONFIG_SYSRESET_WATCHDOG=y CONFIG_DM_THERMAL=y +CONFIG_IMX_TMU=y CONFIG_USB=y -# CONFIG_SPL_DM_USB is not set +CONFIG_USB_XHCI_HCD=y +CONFIG_USB_XHCI_DWC3=y +CONFIG_USB_XHCI_DWC3_OF_SIMPLE=y CONFIG_USB_EHCI_HCD=y +CONFIG_MXC_USB_OTG_HACTIVE=y +CONFIG_USB_DWC3=y +CONFIG_USB_DWC3_GENERIC=y +CONFIG_USB_KEYBOARD=y +CONFIG_USB_HOST_ETHER=y CONFIG_IMX_WATCHDOG=y +CONFIG_HEXDUMP=y CONFIG_OF_LIBFDT_OVERLAY=y -- 2.35.1
[PATCH v2 0/5] verdin-imx8mm: verdin-imx8mp: various additions and improvements
From: Marcel Ziswiler Various additions and improvements for the Verdin iMX8M Mini and Verdin iMX8M Plus: - updated env memory layout - verdin-imx8mm: prepare for optional job ring driver model - verdin-imx8mm: improve and extend boot devices - various config additions and improvements Changes in v2: - Moved loadaddr by an additional 0.5MB to avoid "Moving Image from 0x4820 to 0x4828" during booti plus increasing kernel_comp_size by same 0.5MB. Marcel Ziswiler (5): verdin-imx8mm: verdin-imx8mp: update env memory layout verdin-imx8mm: prepare for optional job ring driver model verdin-imx8mm: improve and extend boot devices verdin-imx8mm: various config additions and improvements verdin-imx8mp: various config additions and improvements board/toradex/verdin-imx8mm/spl.c | 17 +- configs/verdin-imx8mm_defconfig | 37 +-- configs/verdin-imx8mp_defconfig | 35 - include/configs/verdin-imx8mm.h | 10 + include/configs/verdin-imx8mp.h | 10 + 5 files changed, 83 insertions(+), 26 deletions(-) -- 2.35.1
[PATCH v2 2/5] verdin-imx8mm: prepare for optional job ring driver model
From: Marcel Ziswiler Prepare for optional job ring driver model. Sec may be initialized based on the job ring information processed from the device tree. Signed-off-by: Marcel Ziswiler --- (no changes since v1) board/toradex/verdin-imx8mm/spl.c | 9 + 1 file changed, 9 insertions(+) diff --git a/board/toradex/verdin-imx8mm/spl.c b/board/toradex/verdin-imx8mm/spl.c index 243c97e0ba0..685ac94f4ca 100644 --- a/board/toradex/verdin-imx8mm/spl.c +++ b/board/toradex/verdin-imx8mm/spl.c @@ -56,6 +56,15 @@ void spl_dram_init(void) void spl_board_init(void) { + if (IS_ENABLED(CONFIG_FSL_CAAM)) { + struct udevice *dev; + int ret; + + ret = uclass_get_device_by_driver(UCLASS_MISC, DM_DRIVER_GET(caam_jr), &dev); + if (ret) + printf("Failed to initialize %s: %d\n", dev->name, ret); + } + /* Serial download mode */ if (is_usb_boot()) { puts("Back to ROM, SDP\n"); -- 2.35.1
[PATCH v2 3/5] verdin-imx8mm: improve and extend boot devices
From: Marcel Ziswiler - Annotate boot devices available in spl_board_boot_device(). - Drop SD3_BOOT/MMC3_BOOT not available for boot on Verdin iMX8M Mini. Signed-off-by: Marcel Ziswiler --- (no changes since v1) board/toradex/verdin-imx8mm/spl.c | 8 ++-- 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/board/toradex/verdin-imx8mm/spl.c b/board/toradex/verdin-imx8mm/spl.c index 685ac94f4ca..fb9aae6c9c8 100644 --- a/board/toradex/verdin-imx8mm/spl.c +++ b/board/toradex/verdin-imx8mm/spl.c @@ -34,14 +34,11 @@ DECLARE_GLOBAL_DATA_PTR; int spl_board_boot_device(enum boot_device boot_dev_spl) { switch (boot_dev_spl) { - case MMC1_BOOT: + case MMC1_BOOT: /* eMMC */ return BOOT_DEVICE_MMC1; - case SD2_BOOT: + case SD2_BOOT: /* SD card */ case MMC2_BOOT: return BOOT_DEVICE_MMC2; - case SD3_BOOT: - case MMC3_BOOT: - return BOOT_DEVICE_MMC1; case USB_BOOT: return BOOT_DEVICE_BOARD; default: @@ -83,7 +80,6 @@ int board_fit_config_name_match(const char *name) } #endif - __weak void board_early_init(void) { init_uart_clk(0); -- 2.35.1
[PATCH v2 5/5] verdin-imx8mp: various config additions and improvements
From: Marcel Ziswiler - integrate bootcount using SNVS_LP general purpose register LPGPR0 - enable CRC32 and MD5 - enable time commands - enable GPIO LED support - enable further eMMC HS400 functionality - enable fixed PHY and MDIO driver model - enable USB host functionality - enable thermal management unit driver - enable hexdump Signed-off-by: Marcel Ziswiler --- (no changes since v1) configs/verdin-imx8mp_defconfig | 33 + 1 file changed, 29 insertions(+), 4 deletions(-) diff --git a/configs/verdin-imx8mp_defconfig b/configs/verdin-imx8mp_defconfig index 993153267a6..171d6a4c42b 100644 --- a/configs/verdin-imx8mp_defconfig +++ b/configs/verdin-imx8mp_defconfig @@ -18,7 +18,10 @@ CONFIG_TARGET_VERDIN_IMX8MP=y CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL_DRIVERS_MISC=y +CONFIG_BOOTCOUNT_BOOTLIMIT=3 +CONFIG_SYS_BOOTCOUNT_ADDR=0x30370090 CONFIG_SPL=y +CONFIG_SYS_BOOTCOUNT_SINGLEWORD=y CONFIG_IMX_BOOTAUX=y CONFIG_SPL_IMX_ROMAPI_LOADADDR=0x4800 CONFIG_SYS_LOAD_ADDR=0x4828 @@ -65,7 +68,9 @@ CONFIG_SYS_PBSIZE=2081 # CONFIG_BOOTM_NETBSD is not set CONFIG_CMD_ASKENV=y # CONFIG_CMD_EXPORTENV is not set -# CONFIG_CMD_CRC32 is not set +CONFIG_CRC32_VERIFY=y +CONFIG_CMD_MD5SUM=y +CONFIG_MD5SUM_VERIFY=y CONFIG_CMD_MEMTEST=y CONFIG_CMD_CLK=y CONFIG_CMD_FUSE=y @@ -74,12 +79,14 @@ CONFIG_CMD_I2C=y CONFIG_CMD_MMC=y CONFIG_CMD_READ=y CONFIG_CMD_USB=y +CONFIG_CMD_BOOTCOUNT=y CONFIG_CMD_CACHE=y +CONFIG_CMD_TIME=y CONFIG_CMD_UUID=y CONFIG_CMD_REGULATOR=y CONFIG_CMD_EXT4_WRITE=y # CONFIG_ISO_PARTITION is not set -# CONFIG_EFI_PARTITION is not set +# CONFIG_SPL_EFI_PARTITION is not set CONFIG_OF_CONTROL=y CONFIG_SPL_OF_CONTROL=y CONFIG_ENV_OVERWRITE=y @@ -97,7 +104,7 @@ CONFIG_SPL_DM=y CONFIG_REGMAP=y CONFIG_SYSCON=y CONFIG_BOOTCOUNT_LIMIT=y -CONFIG_BOOTCOUNT_ENV=y +CONFIG_SYS_BOOTCOUNT_MAGIC=0xB0C4 CONFIG_CLK_COMPOSITE_CCF=y CONFIG_CLK_IMX8MP=y CONFIG_GPIO_HOG=y @@ -106,30 +113,39 @@ CONFIG_DM_PCA953X=y CONFIG_DM_I2C=y # CONFIG_SPL_DM_I2C is not set CONFIG_SPL_SYS_I2C_LEGACY=y +CONFIG_LED=y +CONFIG_LED_GPIO=y CONFIG_MISC=y CONFIG_I2C_EEPROM=y CONFIG_SUPPORT_EMMC_BOOT=y CONFIG_MMC_IO_VOLTAGE=y +CONFIG_SPL_MMC_IO_VOLTAGE=y CONFIG_MMC_UHS_SUPPORT=y +CONFIG_SPL_MMC_UHS_SUPPORT=y CONFIG_MMC_HS400_ES_SUPPORT=y CONFIG_MMC_HS400_SUPPORT=y +CONFIG_SPL_MMC_HS400_SUPPORT=y CONFIG_FSL_USDHC=y CONFIG_PHY_ADDR_ENABLE=y CONFIG_PHY_MICREL=y CONFIG_PHY_MICREL_KSZ90X1=y +CONFIG_PHY_FIXED=y CONFIG_DM_ETH=y +CONFIG_DM_MDIO=y CONFIG_DM_ETH_PHY=y CONFIG_DWC_ETH_QOS=y CONFIG_DWC_ETH_QOS_IMX=y CONFIG_FEC_MXC=y CONFIG_RGMII=y CONFIG_MII=y +CONFIG_PHY_IMX8MQ_USB=y CONFIG_PINCTRL=y CONFIG_SPL_PINCTRL=y CONFIG_PINCTRL_IMX8M=y CONFIG_SPL_POWER_LEGACY=y CONFIG_POWER_DOMAIN=y CONFIG_IMX8M_POWER_DOMAIN=y +CONFIG_IMX8MP_HSIOMIX_BLKCTRL=y CONFIG_DM_REGULATOR=y CONFIG_DM_REGULATOR_FIXED=y CONFIG_DM_REGULATOR_GPIO=y @@ -141,8 +157,17 @@ CONFIG_SPL_SYSRESET=y CONFIG_SYSRESET_PSCI=y CONFIG_SYSRESET_WATCHDOG=y CONFIG_DM_THERMAL=y +CONFIG_IMX_TMU=y CONFIG_USB=y -# CONFIG_SPL_DM_USB is not set +CONFIG_USB_XHCI_HCD=y +CONFIG_USB_XHCI_DWC3=y +CONFIG_USB_XHCI_DWC3_OF_SIMPLE=y CONFIG_USB_EHCI_HCD=y +CONFIG_MXC_USB_OTG_HACTIVE=y +CONFIG_USB_DWC3=y +CONFIG_USB_DWC3_GENERIC=y +CONFIG_USB_KEYBOARD=y +CONFIG_USB_HOST_ETHER=y CONFIG_IMX_WATCHDOG=y +CONFIG_HEXDUMP=y CONFIG_OF_LIBFDT_OVERLAY=y -- 2.35.1
[PATCH v2 1/5] verdin-imx8mm: verdin-imx8mp: update env memory layout
From: Marcel Ziswiler Update the distro config env memory layout for the Verdin iMX8M Mini and Verdin iMX8M Plus: - loadaddr=0x4828 allows for 128.5MB area for uncompressing (ie FIT images, kernel_comp_addr_r, kernel_comp_size) - fdt_addr_r = loadaddr + 127.5MB : allows for 127.5MB kernel - scriptaddr = fdt_addr_r + 512KB : allows for 512KB fdt - ramdisk_addr_r = scriptaddr + 512KB : allows for 512KB script Memory layout taken from commit fd5c7173ade4 ("imx8m{m,n}_venice: update env memory layout") but moved loadaddr by an additional 0.5MB to avoid "Moving Image from 0x4820 to 0x4828" during booti plus actually defining kernel_comp_size to make booti work. Note that for our regular BSP Layers and Reference Images for Yocto Project an updated distro boot script is required (see meta-toradex-bsp-common/recipes-bsp/u-boot/u-boot-distro-boot). Signed-off-by: Marcel Ziswiler --- Changes in v2: - Moved loadaddr by an additional 0.5MB to avoid "Moving Image from 0x4820 to 0x4828" during booti plus increasing kernel_comp_size by same 0.5MB. configs/verdin-imx8mm_defconfig | 2 +- configs/verdin-imx8mp_defconfig | 2 +- include/configs/verdin-imx8mm.h | 10 ++ include/configs/verdin-imx8mp.h | 10 ++ 4 files changed, 14 insertions(+), 10 deletions(-) diff --git a/configs/verdin-imx8mm_defconfig b/configs/verdin-imx8mm_defconfig index 275a29bf4f9..336d3245988 100644 --- a/configs/verdin-imx8mm_defconfig +++ b/configs/verdin-imx8mm_defconfig @@ -15,7 +15,7 @@ CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL_DRIVERS_MISC=y CONFIG_SPL=y -CONFIG_SYS_LOAD_ADDR=0x4048 +CONFIG_SYS_LOAD_ADDR=0x4828 CONFIG_SYS_MEMTEST_START=0x4000 CONFIG_SYS_MEMTEST_END=0x8000 CONFIG_DISTRO_DEFAULTS=y diff --git a/configs/verdin-imx8mp_defconfig b/configs/verdin-imx8mp_defconfig index 0804fbff915..993153267a6 100644 --- a/configs/verdin-imx8mp_defconfig +++ b/configs/verdin-imx8mp_defconfig @@ -21,7 +21,7 @@ CONFIG_SPL_DRIVERS_MISC=y CONFIG_SPL=y CONFIG_IMX_BOOTAUX=y CONFIG_SPL_IMX_ROMAPI_LOADADDR=0x4800 -CONFIG_SYS_LOAD_ADDR=0x4350 +CONFIG_SYS_LOAD_ADDR=0x4828 CONFIG_SYS_MEMTEST_START=0x4000 CONFIG_SYS_MEMTEST_END=0x8000 CONFIG_DISTRO_DEFAULTS=y diff --git a/include/configs/verdin-imx8mm.h b/include/configs/verdin-imx8mm.h index 5b5fce9bda1..4d20b86591f 100644 --- a/include/configs/verdin-imx8mm.h +++ b/include/configs/verdin-imx8mm.h @@ -20,10 +20,12 @@ #endif #define MEM_LAYOUT_ENV_SETTINGS \ - "fdt_addr_r=0x4400\0" \ - "kernel_addr_r=0x4200\0" \ - "ramdisk_addr_r=0x4640\0" \ - "scriptaddr=0x4600\0" + "fdt_addr_r=0x5020\0" \ + "kernel_addr_r=" __stringify(CONFIG_SYS_LOAD_ADDR) "\0" \ + "kernel_comp_addr_r=0x4020\0" \ + "kernel_comp_size=0x0808\0" \ + "ramdisk_addr_r=0x5030\0" \ + "scriptaddr=0x5028\0" /* Enable Distro Boot */ #define BOOT_TARGET_DEVICES(func) \ diff --git a/include/configs/verdin-imx8mp.h b/include/configs/verdin-imx8mp.h index fca40beba18..9b8db223bb2 100644 --- a/include/configs/verdin-imx8mp.h +++ b/include/configs/verdin-imx8mp.h @@ -34,10 +34,12 @@ #endif /* CONFIG_CMD_NET */ #define MEM_LAYOUT_ENV_SETTINGS \ - "fdt_addr_r=0x4300\0" \ - "kernel_addr_r=0x4000\0" \ - "ramdisk_addr_r=0x4640\0" \ - "scriptaddr=0x4600\0" + "fdt_addr_r=0x5020\0" \ + "kernel_addr_r=" __stringify(CONFIG_SYS_LOAD_ADDR) "\0" \ + "kernel_comp_addr_r=0x4020\0" \ + "kernel_comp_size=0x0808\0" \ + "ramdisk_addr_r=0x5030\0" \ + "scriptaddr=0x5028\0" /* Enable Distro Boot */ #define BOOT_TARGET_DEVICES(func) \ -- 2.35.1
[PATCH v2 4/5] verdin-imx8mm: various config additions and improvements
From: Marcel Ziswiler - integrate bootcount using SNVS_LP general purpose register LPGPR0 - enable link-time optimisation - explicitly set a boot delay of one second - enable CRC32 and MD5 - enable command for low-level access to data in a partition - enable time commands - enable PMIC commands - improve ETHPRIME configuration - enable eMMC HS400 functionality - enable fixed PHY and MDIO driver model - remove stale PFUZE100 PMIC driver - enable thermal management unit driver - enable more USB host functionality - enable hexdump Signed-off-by: Marcel Ziswiler --- (no changes since v1) configs/verdin-imx8mm_defconfig | 35 +++-- 1 file changed, 29 insertions(+), 6 deletions(-) diff --git a/configs/verdin-imx8mm_defconfig b/configs/verdin-imx8mm_defconfig index 336d3245988..9e19c4f063b 100644 --- a/configs/verdin-imx8mm_defconfig +++ b/configs/verdin-imx8mm_defconfig @@ -14,10 +14,14 @@ CONFIG_TARGET_VERDIN_IMX8MM=y CONFIG_SPL_MMC=y CONFIG_SPL_SERIAL=y CONFIG_SPL_DRIVERS_MISC=y +CONFIG_BOOTCOUNT_BOOTLIMIT=3 +CONFIG_SYS_BOOTCOUNT_ADDR=0x30370090 CONFIG_SPL=y +CONFIG_SYS_BOOTCOUNT_SINGLEWORD=y CONFIG_SYS_LOAD_ADDR=0x4828 CONFIG_SYS_MEMTEST_START=0x4000 CONFIG_SYS_MEMTEST_END=0x8000 +CONFIG_LTO=y CONFIG_DISTRO_DEFAULTS=y CONFIG_FIT=y CONFIG_FIT_EXTERNAL_OFFSET=0x3000 @@ -25,7 +29,7 @@ CONFIG_FIT_VERBOSE=y CONFIG_SPL_LOAD_FIT=y # CONFIG_USE_SPL_FIT_GENERATOR is not set CONFIG_OF_SYSTEM_SETUP=y -# CONFIG_USE_BOOTCOMMAND is not set +CONFIG_BOOTDELAY=1 CONFIG_USE_PREBOOT=y CONFIG_PREBOOT="test -n ${fdtfile} || setenv fdtfile imx8mm-verdin-${variant}-${fdt_board}.dtb" CONFIG_LOG=y @@ -54,20 +58,26 @@ CONFIG_SYS_PBSIZE=2081 # CONFIG_BOOTM_NETBSD is not set CONFIG_CMD_ASKENV=y # CONFIG_CMD_EXPORTENV is not set -# CONFIG_CMD_CRC32 is not set +CONFIG_CRC32_VERIFY=y +CONFIG_CMD_MD5SUM=y +CONFIG_MD5SUM_VERIFY=y CONFIG_CMD_MEMTEST=y CONFIG_CMD_CLK=y CONFIG_CMD_FUSE=y CONFIG_CMD_GPIO=y CONFIG_CMD_I2C=y CONFIG_CMD_MMC=y +CONFIG_CMD_READ=y CONFIG_CMD_USB=y +CONFIG_CMD_BOOTCOUNT=y CONFIG_CMD_CACHE=y +CONFIG_CMD_TIME=y CONFIG_CMD_UUID=y +CONFIG_CMD_PMIC=y CONFIG_CMD_REGULATOR=y CONFIG_CMD_EXT4_WRITE=y # CONFIG_ISO_PARTITION is not set -# CONFIG_EFI_PARTITION is not set +# CONFIG_SPL_EFI_PARTITION is not set CONFIG_OF_CONTROL=y CONFIG_SPL_OF_CONTROL=y CONFIG_ENV_OVERWRITE=y @@ -76,11 +86,13 @@ CONFIG_SYS_RELOC_GD_ENV_ADDR=y CONFIG_SYS_MMC_ENV_PART=1 CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y CONFIG_USE_ETHPRIME=y -CONFIG_ETHPRIME="FEC" +CONFIG_ETHPRIME="eth0" CONFIG_VERSION_VARIABLE=y CONFIG_IP_DEFRAG=y CONFIG_TFTP_BLOCKSIZE=4096 CONFIG_SPL_DM=y +CONFIG_BOOTCOUNT_LIMIT=y +CONFIG_SYS_BOOTCOUNT_MAGIC=0xB0C4 CONFIG_SPL_CLK_COMPOSITE_CCF=y CONFIG_CLK_COMPOSITE_CCF=y CONFIG_SPL_CLK_IMX8MM=y @@ -91,12 +103,21 @@ CONFIG_DM_I2C=y CONFIG_MISC=y CONFIG_I2C_EEPROM=y CONFIG_SUPPORT_EMMC_BOOT=y +CONFIG_MMC_IO_VOLTAGE=y +CONFIG_SPL_MMC_IO_VOLTAGE=y +CONFIG_MMC_UHS_SUPPORT=y +CONFIG_SPL_MMC_UHS_SUPPORT=y +CONFIG_MMC_HS400_ES_SUPPORT=y +CONFIG_MMC_HS400_SUPPORT=y +CONFIG_SPL_MMC_HS400_SUPPORT=y CONFIG_FSL_USDHC=y CONFIG_PHYLIB=y CONFIG_PHY_ADDR_ENABLE=y CONFIG_PHY_MICREL=y CONFIG_PHY_MICREL_KSZ90X1=y +CONFIG_PHY_FIXED=y CONFIG_DM_ETH=y +CONFIG_DM_MDIO=y CONFIG_FEC_MXC=y CONFIG_MII=y CONFIG_PINCTRL=y @@ -106,7 +127,6 @@ CONFIG_POWER_DOMAIN=y CONFIG_IMX8M_POWER_DOMAIN=y CONFIG_DM_PMIC=y CONFIG_SPL_DM_PMIC_PCA9450=y -CONFIG_DM_PMIC_PFUZE100=y CONFIG_DM_REGULATOR=y CONFIG_DM_REGULATOR_FIXED=y CONFIG_DM_REGULATOR_GPIO=y @@ -117,8 +137,11 @@ CONFIG_SPL_SYSRESET=y CONFIG_SYSRESET_PSCI=y CONFIG_SYSRESET_WATCHDOG=y CONFIG_DM_THERMAL=y +CONFIG_IMX_TMU=y CONFIG_USB=y -# CONFIG_SPL_DM_USB is not set CONFIG_USB_EHCI_HCD=y +CONFIG_USB_KEYBOARD=y +CONFIG_USB_HOST_ETHER=y CONFIG_IMX_WATCHDOG=y +CONFIG_HEXDUMP=y CONFIG_OF_LIBFDT_OVERLAY=y -- 2.35.1
[PATCH v1 1/8] vf610: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1 plus the recent DDR pinmux addition still being in-flight. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/vf610-pinfunc.h | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/arch/arm/dts/vf610-pinfunc.h b/arch/arm/dts/vf610-pinfunc.h index 740276431aa..b7b7322a2d1 100644 --- a/arch/arm/dts/vf610-pinfunc.h +++ b/arch/arm/dts/vf610-pinfunc.h @@ -802,7 +802,6 @@ #define VF610_PAD_PTE28__EWM_OUT 0x214 0x000 ALT7 0x0 #define VF610_PAD_PTA7__GPIO_134 0x218 0x000 ALT0 0x0 #define VF610_PAD_PTA7__VIU_PIX_CLK0x218 0x3AC ALT1 0x1 - #define VF610_PAD_DDR_RESETB 0x21c 0x000 ALT0 0x0 #define VF610_PAD_DDR_A15__DDR_A_150x220 0x000 ALT0 0x0 #define VF610_PAD_DDR_A14__DDR_A_140x224 0x000 ALT0 0x0 @@ -853,4 +852,5 @@ #define VF610_PAD_DDR_ODT0__DDR_ODT_1 0x2d8 0x000 ALT0 0x0 #define VF610_PAD_DDR_DDRBYTE1__DDR_DDRBYTE1 0x2dc 0x000 ALT0 0x0 #define VF610_PAD_DDR_DDRBYTE2__DDR_DDRBYTE2 0x2e0 0x000 ALT0 0x0 + #endif -- 2.35.1
[PATCH v1 2/8] imxrt1020: fix lpuart issue in common u-boot device tree
From: Marcel Ziswiler Fix lpuart issue in common U-Boot device tree. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imxrt1020-evk-u-boot.dtsi | 7 --- arch/arm/dts/imxrt1020-evk.dts | 1 - 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/arch/arm/dts/imxrt1020-evk-u-boot.dtsi b/arch/arm/dts/imxrt1020-evk-u-boot.dtsi index 9e1b074d2e7..7cab486f5fa 100644 --- a/arch/arm/dts/imxrt1020-evk-u-boot.dtsi +++ b/arch/arm/dts/imxrt1020-evk-u-boot.dtsi @@ -67,9 +67,6 @@ imxrt1020-evk { u-boot,dm-spl; - pinctrl_lpuart1: lpuart1grp { - u-boot,dm-spl; - }; pinctrl_semc: semcgrp { u-boot,dm-spl; @@ -81,6 +78,10 @@ }; }; +&pinctrl_lpuart1 { + u-boot,dm-spl; +}; + &usdhc1 { u-boot,dm-spl; }; diff --git a/arch/arm/dts/imxrt1020-evk.dts b/arch/arm/dts/imxrt1020-evk.dts index 22ae5ed7359..d4d1de4ea84 100644 --- a/arch/arm/dts/imxrt1020-evk.dts +++ b/arch/arm/dts/imxrt1020-evk.dts @@ -6,7 +6,6 @@ /dts-v1/; #include "imxrt1020.dtsi" -#include "imxrt1020-evk-u-boot.dtsi" #include "imxrt1020-pinfunc.h" / { -- 2.35.1
[PATCH v1 3/8] imxrt1050: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imxrt1050-evk-u-boot.dtsi | 25 +- arch/arm/dts/imxrt1050-evk.dts | 257 +++- arch/arm/dts/imxrt1050-pinfunc.h| 2 +- arch/arm/dts/imxrt1050.dtsi | 168 ++--- include/dt-bindings/clock/imxrt1050-clock.h | 9 +- 5 files changed, 118 insertions(+), 343 deletions(-) diff --git a/arch/arm/dts/imxrt1050-evk-u-boot.dtsi b/arch/arm/dts/imxrt1050-evk-u-boot.dtsi index 617cece448a..0da24965b67 100644 --- a/arch/arm/dts/imxrt1050-evk-u-boot.dtsi +++ b/arch/arm/dts/imxrt1050-evk-u-boot.dtsi @@ -50,7 +50,7 @@ u-boot,dm-spl; }; -&gpt1 { +&gpt { u-boot,dm-spl; }; @@ -58,33 +58,26 @@ u-boot,dm-spl; }; -&semc { - u-boot,dm-spl; - - bank1: bank@0 { - u-boot,dm-spl; - }; -}; - &iomuxc { u-boot,dm-spl; imxrt1050-evk { u-boot,dm-spl; - pinctrl_lpuart1: lpuart1grp { - u-boot,dm-spl; - }; pinctrl_semc: semcgrp { u-boot,dm-spl; }; - - pinctrl_usdhc0: usdhc0grp { - u-boot,dm-spl; - }; }; }; +&pinctrl_lpuart1 { + u-boot,dm-spl; +}; + +&pinctrl_usdhc0 { + u-boot,dm-spl; +}; + &usdhc1 { u-boot,dm-spl; }; diff --git a/arch/arm/dts/imxrt1050-evk.dts b/arch/arm/dts/imxrt1050-evk.dts index fb2da3adfcf..6a9c10decf5 100644 --- a/arch/arm/dts/imxrt1050-evk.dts +++ b/arch/arm/dts/imxrt1050-evk.dts @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: (GPL-2.0+ OR BSD-3-Clause) +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) /* * Copyright (C) 2019 * Author(s): Giulio Benetti @@ -6,7 +6,6 @@ /dts-v1/; #include "imxrt1050.dtsi" -#include "imxrt1050-evk-u-boot.dtsi" #include "imxrt1050-pinfunc.h" / { @@ -14,210 +13,52 @@ compatible = "fsl,imxrt1050-evk", "fsl,imxrt1050"; chosen { - bootargs = "root=/dev/ram"; - stdout-path = "serial0:115200n8"; - tick-timer = &gpt1; + stdout-path = &lpuart1; }; - memory { + aliases { + gpio0 = &gpio1; + gpio1 = &gpio2; + gpio2 = &gpio3; + gpio3 = &gpio4; + gpio4 = &gpio5; + mmc0 = &usdhc1; + serial0 = &lpuart1; + }; + + memory@8000 { device_type = "memory"; reg = <0x8000 0x200>; }; }; -&lpuart1 { /* console */ +&lpuart1 { pinctrl-names = "default"; pinctrl-0 = <&pinctrl_lpuart1>; status = "okay"; }; -&semc { - /* -* Memory configuration from sdram datasheet IS42S16160J-6BLI -*/ - fsl,sdram-mux = /bits/ 8 ; - fsl,sdram-control = /bits/ 8 ; - fsl,sdram-timing = /bits/ 8 <0x2 -0x2 -0x9 -0x1 -0x5 -0x6 - -0x20 -0x09 -0x01 -0x00 - -0x04 -0x0A -0x21 -0x50>; - - bank1: bank@0 { - fsl,base-address = <0x8000>; - fsl,memory-size = ; - }; -}; - &iomuxc { pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_lpuart1>; - - imxrt1050-evk { - pinctrl_lpuart1: lpuart1grp { - fsl,pins = < - MXRT1050_IOMUXC_GPIO_AD_B0_12_LPUART1_TXD - 0xf1 - MXRT1050_IOMUXC_GPIO_AD_B0_13_LPUART1_RXD - 0xf1 - >; - }; - - pinctrl_semc: semcgrp { - fsl,pins = < - MXRT1050_IOMUXC_GPIO_EMC_00_SEMC_DA00 - 0xf1/* SEMC_D0 */ - MXRT1050_IOMUXC_GPIO_EMC_01_SEMC_DA01 - 0xf1/* SEMC_D1 */ - MXRT1050_IOMUXC_GPIO_EMC_02_SEMC_DA02 - 0xf1/* SEMC_D2 */ - MXRT1050_IOMUXC_GPIO_EMC_03_SEMC_DA03 -
[PATCH v1 0/8] arm: dts: imx: sync device trees with upstream linux kernel part 1
From: Marcel Ziswiler This series synchronises them imx device trees with the upstream Linux kernel (v6.0-rc1). I split it into two parts. This is part 1. It also fixes a few issues as discussed during/after the pre-mature application of my first series [1]. I am not touching kontron-sl-mx6ul as Frieder already took care of those [2]. Feedback welcome. Thanks! [1] https://patchwork.ozlabs.org/project/uboot/cover/20220721132748.1052244-1-mar...@ziswiler.com/ [2] https://patchwork.ozlabs.org/project/uboot/cover/20220823142917.306176-1-frie...@fris.de/ Marcel Ziswiler (8): vf610: synchronise device tree with linux imxrt1020: fix lpuart issue in common u-boot device tree imxrt1050: synchronise device tree with linux imx8ulp: synchronise device tree with linux imx8mq: synchronise device tree with linux imx8mp: synchronise device tree with linux imx8mn: synchronise device tree with linux imx8mm: synchronise device tree with linux arch/arm/dts/imx8mm-beacon-baseboard.dtsi | 4 +- arch/arm/dts/imx8mm-evk.dtsi | 43 ++ arch/arm/dts/imx8mm-icore-mx8mm.dtsi | 12 +- arch/arm/dts/imx8mm-mx8menlo.dts | 4 +- arch/arm/dts/imx8mm-u-boot.dtsi | 2 +- arch/arm/dts/imx8mm-venice-gw700x.dtsi| 24 +- arch/arm/dts/imx8mm-venice-gw7901.dts | 8 +- arch/arm/dts/imx8mm-venice-gw7902.dts | 10 +- arch/arm/dts/imx8mm-venice-gw7903.dts | 6 +- arch/arm/dts/imx8mm-verdin.dtsi | 10 +- arch/arm/dts/imx8mn-beacon-baseboard.dtsi | 4 +- arch/arm/dts/imx8mn-beacon-kit-u-boot.dtsi| 2 +- .../dts/imx8mn-bsh-smm-s2-u-boot-common.dtsi | 2 +- arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi | 2 +- arch/arm/dts/imx8mn-evk.dtsi | 45 +- .../dts/imx8mn-var-som-symphony-u-boot.dtsi | 2 +- arch/arm/dts/imx8mn-var-som-symphony.dts | 6 +- arch/arm/dts/imx8mn-venice-gw7902.dts | 8 +- arch/arm/dts/imx8mn-venice-u-boot.dtsi| 2 +- arch/arm/dts/imx8mn.dtsi | 13 +- arch/arm/dts/imx8mp-dhcom-pdk2.dts| 27 +- arch/arm/dts/imx8mp-dhcom-som.dtsi| 20 +- arch/arm/dts/imx8mp-evk.dts | 126 ++-- arch/arm/dts/imx8mp-phyboard-pollux-rdk.dts | 48 +- arch/arm/dts/imx8mp-u-boot.dtsi | 2 +- arch/arm/dts/imx8mp-venice-gw74xx.dts | 116 ++-- arch/arm/dts/imx8mp-verdin.dtsi | 14 +- arch/arm/dts/imx8mp.dtsi | 33 +- arch/arm/dts/imx8mq-evk.dts | 43 ++ arch/arm/dts/imx8mq-u-boot.dtsi | 10 +- arch/arm/dts/imx8mq.dtsi | 15 +- arch/arm/dts/imx8ulp-evk-u-boot.dtsi | 6 +- arch/arm/dts/imx8ulp-evk.dts | 191 +- arch/arm/dts/imx8ulp-pinfunc.h| 4 +- arch/arm/dts/imx8ulp.dtsi | 564 +- arch/arm/dts/imxrt1020-evk-u-boot.dtsi| 7 +- arch/arm/dts/imxrt1020-evk.dts| 1 - arch/arm/dts/imxrt1050-evk-u-boot.dtsi| 25 +- arch/arm/dts/imxrt1050-evk.dts| 257 +--- arch/arm/dts/imxrt1050-pinfunc.h | 2 +- arch/arm/dts/imxrt1050.dtsi | 168 +++--- arch/arm/dts/vf610-pinfunc.h | 2 +- include/dt-bindings/clock/imx8mp-clock.h | 13 +- include/dt-bindings/clock/imx8ulp-clock.h | 49 +- include/dt-bindings/clock/imxrt1050-clock.h | 9 +- include/dt-bindings/interconnect/imx8mm.h | 50 ++ include/dt-bindings/interconnect/imx8mn.h | 41 ++ include/dt-bindings/power/imx8mp-power.h | 15 +- include/dt-bindings/power/imx8ulp-power.h | 26 + include/dt-bindings/reset/imx8mp-reset.h | 50 ++ include/dt-bindings/reset/imx8mq-reset.h | 61 +- include/dt-bindings/reset/imx8ulp-pcc-reset.h | 59 ++ 52 files changed, 1007 insertions(+), 1256 deletions(-) create mode 100644 include/dt-bindings/interconnect/imx8mm.h create mode 100644 include/dt-bindings/interconnect/imx8mn.h create mode 100644 include/dt-bindings/power/imx8ulp-power.h create mode 100644 include/dt-bindings/reset/imx8mp-reset.h create mode 100644 include/dt-bindings/reset/imx8ulp-pcc-reset.h -- 2.35.1
[PATCH v1 5/8] imx8mq: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx8mq-evk.dts | 43 + arch/arm/dts/imx8mq-u-boot.dtsi | 10 ++-- arch/arm/dts/imx8mq.dtsi | 15 +++--- include/dt-bindings/reset/imx8mq-reset.h | 61 +--- 4 files changed, 88 insertions(+), 41 deletions(-) diff --git a/arch/arm/dts/imx8mq-evk.dts b/arch/arm/dts/imx8mq-evk.dts index 99fed35168e..82387b9cb80 100644 --- a/arch/arm/dts/imx8mq-evk.dts +++ b/arch/arm/dts/imx8mq-evk.dts @@ -71,12 +71,36 @@ linux,autosuspend-period = <125>; }; + audio_codec_bt_sco: audio-codec-bt-sco { + compatible = "linux,bt-sco"; + #sound-dai-cells = <1>; + }; + wm8524: audio-codec { #sound-dai-cells = <0>; compatible = "wlf,wm8524"; wlf,mute-gpios = <&gpio1 8 GPIO_ACTIVE_LOW>; }; + sound-bt-sco { + compatible = "simple-audio-card"; + simple-audio-card,name = "bt-sco-audio"; + simple-audio-card,format = "dsp_a"; + simple-audio-card,bitclock-inversion; + simple-audio-card,frame-master = <&btcpu>; + simple-audio-card,bitclock-master = <&btcpu>; + + btcpu: simple-audio-card,cpu { + sound-dai = <&sai3>; + dai-tdm-slot-num = <2>; + dai-tdm-slot-width = <16>; + }; + + simple-audio-card,codec { + sound-dai = <&audio_codec_bt_sco 1>; + }; + }; + sound-wm8524 { compatible = "simple-audio-card"; simple-audio-card,name = "wm8524-audio"; @@ -386,6 +410,16 @@ status = "okay"; }; +&sai3 { + #sound-dai-cells = <0>; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_sai3>; + assigned-clocks = <&clk IMX8MQ_CLK_SAI3>; + assigned-clock-parents = <&clk IMX8MQ_AUDIO_PLL1_OUT>; + assigned-clock-rates = <24576000>; + status = "okay"; +}; + &snvs_pwrkey { status = "okay"; }; @@ -548,6 +582,15 @@ >; }; + pinctrl_sai3: sai3grp { + fsl,pins = < + MX8MQ_IOMUXC_SAI3_TXFS_SAI3_TX_SYNC 0xd6 + MX8MQ_IOMUXC_SAI3_TXC_SAI3_TX_BCLK 0xd6 + MX8MQ_IOMUXC_SAI3_TXD_SAI3_TX_DATA0 0xd6 + MX8MQ_IOMUXC_SAI3_RXD_SAI3_RX_DATA0 0xd6 + >; + }; + pinctrl_spdif1: spdif1grp { fsl,pins = < MX8MQ_IOMUXC_SPDIF_TX_SPDIF1_OUT0xd6 diff --git a/arch/arm/dts/imx8mq-u-boot.dtsi b/arch/arm/dts/imx8mq-u-boot.dtsi index e8b5f83706e..e6448ab8ad3 100644 --- a/arch/arm/dts/imx8mq-u-boot.dtsi +++ b/arch/arm/dts/imx8mq-u-boot.dtsi @@ -10,23 +10,23 @@ }; -&{/soc@0} { +&soc { u-boot,dm-spl; }; -&{/soc@0/bus@3000} { +&aips1 { u-boot,dm-spl; }; -&{/soc@0/bus@3040} { +&aips2 { u-boot,dm-spl; }; -&{/soc@0/bus@3080} { +&aips3 { u-boot,dm-spl; }; -&{/soc@0/bus@32c0} { +&aips4 { u-boot,dm-spl; }; diff --git a/arch/arm/dts/imx8mq.dtsi b/arch/arm/dts/imx8mq.dtsi index 49eadb081b1..e9f0cdd10ab 100644 --- a/arch/arm/dts/imx8mq.dtsi +++ b/arch/arm/dts/imx8mq.dtsi @@ -94,7 +94,7 @@ clk_ext4: clock-ext4 { compatible = "fixed-clock"; #clock-cells = <0>; - clock-frequency= <13300>; + clock-frequency = <13300>; clock-output-names = "clk_ext4"; }; @@ -320,7 +320,7 @@ arm,no-tick-in-suspend; }; - soc@0 { + soc: soc@0 { compatible = "fsl,imx8mq-soc", "simple-bus"; #address-cells = <1>; #size-cells = <1>; @@ -329,7 +329,7 @@ nvmem-cells = <&imx8mq_uid>; nvmem-cell-names = "soc_unique_id"; - bus@3000 { /* AIPS1 */ + aips1: bus@3000 { /* AIPS1 */ compatible = "fsl,aips-bus", "simple-bus"; reg = <0x3000 0x40>; #address-cells = <1>; @@ -507,7 +507,7 @@ <0x00030005 0x0053>, <0x00030006 0x005f>,
[PATCH v1 4/8] imx8ulp: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx8ulp-evk-u-boot.dtsi | 6 +- arch/arm/dts/imx8ulp-evk.dts | 191 +- arch/arm/dts/imx8ulp-pinfunc.h| 4 +- arch/arm/dts/imx8ulp.dtsi | 564 +- include/dt-bindings/clock/imx8ulp-clock.h | 49 +- include/dt-bindings/power/imx8ulp-power.h | 26 + include/dt-bindings/reset/imx8ulp-pcc-reset.h | 59 ++ 7 files changed, 269 insertions(+), 630 deletions(-) create mode 100644 include/dt-bindings/power/imx8ulp-power.h create mode 100644 include/dt-bindings/reset/imx8ulp-pcc-reset.h diff --git a/arch/arm/dts/imx8ulp-evk-u-boot.dtsi b/arch/arm/dts/imx8ulp-evk-u-boot.dtsi index 7c1dab2acfc..2743521f415 100644 --- a/arch/arm/dts/imx8ulp-evk-u-boot.dtsi +++ b/arch/arm/dts/imx8ulp-evk-u-boot.dtsi @@ -3,7 +3,7 @@ * Copyright 2021 NXP */ -&{/soc@0} { +&soc { u-boot,dm-spl; }; @@ -23,10 +23,6 @@ u-boot,dm-spl; }; -&s400_mu { - u-boot,dm-spl; -}; - &lpuart5 { u-boot,dm-spl; }; diff --git a/arch/arm/dts/imx8ulp-evk.dts b/arch/arm/dts/imx8ulp-evk.dts index da09ff48ff8..33e84c4e9ed 100644 --- a/arch/arm/dts/imx8ulp-evk.dts +++ b/arch/arm/dts/imx8ulp-evk.dts @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: (GPL-2.0 OR MIT) +// SPDX-License-Identifier: (GPL-2.0+ OR MIT) /* * Copyright 2021 NXP */ @@ -8,17 +8,16 @@ #include "imx8ulp.dtsi" / { - model = "FSL i.MX8ULP EVK"; + model = "NXP i.MX8ULP EVK"; compatible = "fsl,imx8ulp-evk", "fsl,imx8ulp"; chosen { stdout-path = &lpuart5; - bootargs = "console=ttyLP1,115200 earlycon"; }; - usdhc2_pwrseq: usdhc2_pwrseq { - compatible = "mmc-pwrseq-simple"; - reset-gpios = <&pcal6408 2 GPIO_ACTIVE_LOW>; + memory@8000 { + device_type = "memory"; + reg = <0x0 0x8000 0 0x8000>; }; }; @@ -30,24 +29,25 @@ status = "okay"; }; +&usdhc0 { + pinctrl-names = "default", "sleep"; + pinctrl-0 = <&pinctrl_usdhc0>; + pinctrl-1 = <&pinctrl_usdhc0>; + non-removable; + bus-width = <8>; + status = "okay"; +}; + &iomuxc1 { pinctrl_lpuart5: lpuart5grp { fsl,pins = < - MX8ULP_PAD_PTF14__LPUART5_TX0x03 - MX8ULP_PAD_PTF15__LPUART5_RX0x03 - >; - }; - - pinctrl_lpi2c7: lpi2c7grp { - fsl,pins = < - MX8ULP_PAD_PTE12__LPI2C7_SCL0x27 - MX8ULP_PAD_PTE13__LPI2C7_SDA0x27 + MX8ULP_PAD_PTF14__LPUART5_TX0x3 + MX8ULP_PAD_PTF15__LPUART5_RX0x3 >; }; pinctrl_usdhc0: usdhc0grp { fsl,pins = < - MX8ULP_PAD_PTD0__SDHC0_RESET_B 0x43 MX8ULP_PAD_PTD1__SDHC0_CMD 0x43 MX8ULP_PAD_PTD2__SDHC0_CLK 0x10042 MX8ULP_PAD_PTD10__SDHC0_D0 0x43 @@ -61,163 +61,4 @@ MX8ULP_PAD_PTD11__SDHC0_DQS 0x10042 >; }; - - pinctrl_usdhc2_pte: usdhc2ptegrp { - fsl,pins = < - MX8ULP_PAD_PTE1__SDHC2_D0 0x43 - MX8ULP_PAD_PTE0__SDHC2_D1 0x43 - MX8ULP_PAD_PTE5__SDHC2_D2 0x43 - MX8ULP_PAD_PTE4__SDHC2_D3 0x43 - MX8ULP_PAD_PTE2__SDHC2_CLK 0x10042 - MX8ULP_PAD_PTE3__SDHC2_CMD 0x43 - MX8ULP_PAD_PTE7__PTE7 0x10003 - >; - }; - - pinctrl_fec: fecgrp { - fsl,pins = < - MX8ULP_PAD_PTE14__ENET0_MDIO0x43 - MX8ULP_PAD_PTE15__ENET0_MDC 0x43 - MX8ULP_PAD_PTE18__ENET0_CRS_DV 0x43 - MX8ULP_PAD_PTE17__ENET0_RXER0x43 - MX8ULP_PAD_PTF1__ENET0_RXD0 0x43 - MX8ULP_PAD_PTE20__ENET0_RXD10x43 - MX8ULP_PAD_PTE16__ENET0_TXEN0x43 - MX8ULP_PAD_PTE23__ENET0_TXD00x43 - MX8ULP_PAD_PTE22__ENET0_TXD10x43 - MX8ULP_PAD_PTE19__ENET0_REFCLK 0x10043 - MX8ULP_PAD_PTF10__ENET0_1588_CLKIN 0x10043 - >; - }; - - pinctrl_usbotg0_id: otg0idgrp { - fsl,pins = < - MX8ULP_PAD_PTF2__USB0_ID0x10003 -
[PATCH v1 7/8] imx8mn: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx8mn-beacon-baseboard.dtsi | 4 +- arch/arm/dts/imx8mn-beacon-kit-u-boot.dtsi| 2 +- .../dts/imx8mn-bsh-smm-s2-u-boot-common.dtsi | 2 +- arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi | 2 +- arch/arm/dts/imx8mn-evk.dtsi | 45 ++- .../dts/imx8mn-var-som-symphony-u-boot.dtsi | 2 +- arch/arm/dts/imx8mn-var-som-symphony.dts | 6 +-- arch/arm/dts/imx8mn-venice-gw7902.dts | 8 ++-- arch/arm/dts/imx8mn-venice-u-boot.dtsi| 2 +- arch/arm/dts/imx8mn.dtsi | 13 +++--- include/dt-bindings/interconnect/imx8mn.h | 41 + 11 files changed, 106 insertions(+), 21 deletions(-) create mode 100644 include/dt-bindings/interconnect/imx8mn.h diff --git a/arch/arm/dts/imx8mn-beacon-baseboard.dtsi b/arch/arm/dts/imx8mn-beacon-baseboard.dtsi index 02f37dcda7e..9e82069c941 100644 --- a/arch/arm/dts/imx8mn-beacon-baseboard.dtsi +++ b/arch/arm/dts/imx8mn-beacon-baseboard.dtsi @@ -146,7 +146,7 @@ }; &easrc { - fsl,asrc-rate = <48000>; + fsl,asrc-rate = <48000>; status = "okay"; }; @@ -182,7 +182,7 @@ &usbotg1 { vbus-supply = <®_usb_otg_vbus>; disable-over-current; - dr_mode="otg"; + dr_mode = "otg"; status = "okay"; }; diff --git a/arch/arm/dts/imx8mn-beacon-kit-u-boot.dtsi b/arch/arm/dts/imx8mn-beacon-kit-u-boot.dtsi index 5f839524028..6d8ba4c39af 100644 --- a/arch/arm/dts/imx8mn-beacon-kit-u-boot.dtsi +++ b/arch/arm/dts/imx8mn-beacon-kit-u-boot.dtsi @@ -15,7 +15,7 @@ }; }; -&{/soc@0} { +&soc { u-boot,dm-pre-reloc; u-boot,dm-spl; }; diff --git a/arch/arm/dts/imx8mn-bsh-smm-s2-u-boot-common.dtsi b/arch/arm/dts/imx8mn-bsh-smm-s2-u-boot-common.dtsi index c4ae7ca4f31..8312b64bcc0 100644 --- a/arch/arm/dts/imx8mn-bsh-smm-s2-u-boot-common.dtsi +++ b/arch/arm/dts/imx8mn-bsh-smm-s2-u-boot-common.dtsi @@ -16,7 +16,7 @@ }; }; -&{/soc@0} { +&soc { u-boot,dm-pre-reloc; u-boot,dm-spl; }; diff --git a/arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi b/arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi index 78773c198e4..edd9b959d09 100644 --- a/arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi +++ b/arch/arm/dts/imx8mn-ddr4-evk-u-boot.dtsi @@ -21,7 +21,7 @@ }; }; -&{/soc@0} { +&soc { u-boot,dm-pre-reloc; u-boot,dm-spl; }; diff --git a/arch/arm/dts/imx8mn-evk.dtsi b/arch/arm/dts/imx8mn-evk.dtsi index d1f6cccfa00..261c3654007 100644 --- a/arch/arm/dts/imx8mn-evk.dtsi +++ b/arch/arm/dts/imx8mn-evk.dtsi @@ -47,6 +47,11 @@ linux,autosuspend-period = <125>; }; + audio_codec_bt_sco: audio-codec-bt-sco { + compatible = "linux,bt-sco"; + #sound-dai-cells = <1>; + }; + wm8524: audio-codec { #sound-dai-cells = <0>; compatible = "wlf,wm8524"; @@ -57,6 +62,25 @@ clock-names = "mclk"; }; + sound-bt-sco { + compatible = "simple-audio-card"; + simple-audio-card,name = "bt-sco-audio"; + simple-audio-card,format = "dsp_a"; + simple-audio-card,bitclock-inversion; + simple-audio-card,frame-master = <&btcpu>; + simple-audio-card,bitclock-master = <&btcpu>; + + btcpu: simple-audio-card,cpu { + sound-dai = <&sai2>; + dai-tdm-slot-num = <2>; + dai-tdm-slot-width = <16>; + }; + + simple-audio-card,codec { + sound-dai = <&audio_codec_bt_sco 1>; + }; + }; + sound-wm8524 { compatible = "fsl,imx-audio-wm8524"; model = "wm8524-audio"; @@ -78,7 +102,7 @@ }; &easrc { - fsl,asrc-rate = <48000>; + fsl,asrc-rate = <48000>; status = "okay"; }; @@ -183,6 +207,16 @@ }; }; +&sai2 { + #sound-dai-cells = <0>; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_sai2>; + assigned-clocks = <&clk IMX8MN_CLK_SAI2>; + assigned-clock-parents = <&clk IMX8MN_AUDIO_PLL1_OUT>; + assigned-clock-rates = <24576000>; + status = "okay"; +}; + &sai3 { pinctrl-names = "default"; pinctrl-0 = <&pinctrl_sai3>; @@ -354,6 +388,15 @@ >; }; + pinctrl_sai2: sai2grp { + fsl,pins = < + MX8MN_IOMUXC_SAI2_TXC_SAI2_TX_BCLK 0x
[PATCH v1 6/8] imx8mp: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx8mp-dhcom-pdk2.dts | 27 +++-- arch/arm/dts/imx8mp-dhcom-som.dtsi | 20 +--- arch/arm/dts/imx8mp-evk.dts | 126 +++- arch/arm/dts/imx8mp-phyboard-pollux-rdk.dts | 48 arch/arm/dts/imx8mp-u-boot.dtsi | 2 +- arch/arm/dts/imx8mp-venice-gw74xx.dts | 116 +- arch/arm/dts/imx8mp-verdin.dtsi | 14 ++- arch/arm/dts/imx8mp.dtsi| 33 - include/dt-bindings/clock/imx8mp-clock.h| 13 +- include/dt-bindings/power/imx8mp-power.h| 15 ++- include/dt-bindings/reset/imx8mp-reset.h| 50 11 files changed, 284 insertions(+), 180 deletions(-) create mode 100644 include/dt-bindings/reset/imx8mp-reset.h diff --git a/arch/arm/dts/imx8mp-dhcom-pdk2.dts b/arch/arm/dts/imx8mp-dhcom-pdk2.dts index e95abfb3e89..2ca2ede2e94 100644 --- a/arch/arm/dts/imx8mp-dhcom-pdk2.dts +++ b/arch/arm/dts/imx8mp-dhcom-pdk2.dts @@ -19,7 +19,6 @@ }; gpio-keys { - #size-cells = <0>; compatible = "gpio-keys"; button-0 { @@ -62,7 +61,7 @@ led { compatible = "gpio-leds"; - led-5 { + led-0 { color = ; default-state = "off"; function = LED_FUNCTION_INDICATOR; @@ -71,7 +70,7 @@ pinctrl-names = "default"; }; - led-6 { + led-1 { color = ; default-state = "off"; function = LED_FUNCTION_INDICATOR; @@ -80,7 +79,7 @@ pinctrl-names = "default"; }; - led-7 { + led-2 { color = ; default-state = "off"; function = LED_FUNCTION_INDICATOR; @@ -89,7 +88,7 @@ pinctrl-names = "default"; }; - led-8 { + led-3 { color = ; default-state = "off"; function = LED_FUNCTION_INDICATOR; @@ -118,10 +117,11 @@ mdio { ethphypdk: ethernet-phy@7 { /* KSZ 9021 */ compatible = "ethernet-phy-ieee802.3-c22"; - interrupt-parent = <&gpio4>; - interrupts = <3 IRQ_TYPE_LEVEL_LOW>; pinctrl-0 = <&pinctrl_ethphy1>; pinctrl-names = "default"; + interrupt-parent = <&gpio4>; + interrupts = <3 IRQ_TYPE_LEVEL_LOW>; + max-speed = <100>; reg = <7>; reset-assert-us = <1000>; reset-deassert-us = <1000>; @@ -138,7 +138,6 @@ txd2-skew-ps = <0>; txd3-skew-ps = <0>; txen-skew-ps = <0>; - max-speed = <100>; }; }; }; @@ -150,3 +149,15 @@ &usb3_1 { fsl,over-current-active-low; }; + +&iomuxc { + /* +* GPIO_A,B,C,D are connected to buttons. +* GPIO_E,F,H,I are connected to LEDs. +* GPIO_M is connected to CLKOUT2. +*/ + pinctrl-0 = <&pinctrl_hog_base +&pinctrl_dhcom_g &pinctrl_dhcom_j +&pinctrl_dhcom_k &pinctrl_dhcom_l +&pinctrl_dhcom_int>; +}; diff --git a/arch/arm/dts/imx8mp-dhcom-som.dtsi b/arch/arm/dts/imx8mp-dhcom-som.dtsi index 63cc6c92c41..a616eb37800 100644 --- a/arch/arm/dts/imx8mp-dhcom-som.dtsi +++ b/arch/arm/dts/imx8mp-dhcom-som.dtsi @@ -1,4 +1,4 @@ -// SPDX-License-Identifier: (GPL-2.0+ OR MIT) +// SPDX-License-Identifier: GPL-2.0 /* * Copyright (C) 2021-2022 Marek Vasut */ @@ -224,10 +224,6 @@ }; &i2c3 { - /* -* iMX8MP 1P33A Errata ERR007805 -* I2C is limited to 384 kHz due to SoC bug. -*/ clock-frequency = <10>; pinctrl-names = "default", "gpio"; pinctrl-0 = <&pinctrl_i2c3>; @@ -393,10 +389,6 @@ }; &i2c4 { - /* -* iMX8MP 1P33A Errata ERR007805 -* I2C is limited to 384 kHz due to SoC bug. -*/ clock-frequency = <10>; pinctrl-names = "default", "gpio"; pinctrl-0 = <&pinctrl_i2c4>; @@ -407,10 +399,6 @@ }; &i2c5 {/* HDMI ED
[PATCH v1 8/8] imx8mm: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx8mm-beacon-baseboard.dtsi | 4 +- arch/arm/dts/imx8mm-evk.dtsi | 43 +++ arch/arm/dts/imx8mm-icore-mx8mm.dtsi | 12 +++--- arch/arm/dts/imx8mm-mx8menlo.dts | 4 +- arch/arm/dts/imx8mm-u-boot.dtsi | 2 +- arch/arm/dts/imx8mm-venice-gw700x.dtsi| 24 +-- arch/arm/dts/imx8mm-venice-gw7901.dts | 8 ++-- arch/arm/dts/imx8mm-venice-gw7902.dts | 10 ++--- arch/arm/dts/imx8mm-venice-gw7903.dts | 6 +-- arch/arm/dts/imx8mm-verdin.dtsi | 10 - include/dt-bindings/interconnect/imx8mm.h | 50 +++ 11 files changed, 137 insertions(+), 36 deletions(-) create mode 100644 include/dt-bindings/interconnect/imx8mm.h diff --git a/arch/arm/dts/imx8mm-beacon-baseboard.dtsi b/arch/arm/dts/imx8mm-beacon-baseboard.dtsi index f338a886d81..03266bd90a0 100644 --- a/arch/arm/dts/imx8mm-beacon-baseboard.dtsi +++ b/arch/arm/dts/imx8mm-beacon-baseboard.dtsi @@ -285,14 +285,14 @@ &usbotg1 { vbus-supply = <®_usbotg1>; disable-over-current; - dr_mode="otg"; + dr_mode = "otg"; status = "okay"; }; &usbotg2 { pinctrl-names = "default"; disable-over-current; - dr_mode="host"; + dr_mode = "host"; status = "okay"; }; diff --git a/arch/arm/dts/imx8mm-evk.dtsi b/arch/arm/dts/imx8mm-evk.dtsi index c42b966f7a6..7d6317d95b1 100644 --- a/arch/arm/dts/imx8mm-evk.dtsi +++ b/arch/arm/dts/imx8mm-evk.dtsi @@ -75,6 +75,11 @@ linux,autosuspend-period = <125>; }; + audio_codec_bt_sco: audio-codec-bt-sco { + compatible = "linux,bt-sco"; + #sound-dai-cells = <1>; + }; + wm8524: audio-codec { #sound-dai-cells = <0>; compatible = "wlf,wm8524"; @@ -83,6 +88,25 @@ wlf,mute-gpios = <&gpio5 21 GPIO_ACTIVE_LOW>; }; + sound-bt-sco { + compatible = "simple-audio-card"; + simple-audio-card,name = "bt-sco-audio"; + simple-audio-card,format = "dsp_a"; + simple-audio-card,bitclock-inversion; + simple-audio-card,frame-master = <&btcpu>; + simple-audio-card,bitclock-master = <&btcpu>; + + btcpu: simple-audio-card,cpu { + sound-dai = <&sai2>; + dai-tdm-slot-num = <2>; + dai-tdm-slot-width = <16>; + }; + + simple-audio-card,codec { + sound-dai = <&audio_codec_bt_sco 1>; + }; + }; + sound-wm8524 { compatible = "simple-audio-card"; simple-audio-card,name = "wm8524-audio"; @@ -346,6 +370,16 @@ status = "okay"; }; +&sai2 { + #sound-dai-cells = <0>; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_sai2>; + assigned-clocks = <&clk IMX8MM_CLK_SAI2>; + assigned-clock-parents = <&clk IMX8MM_AUDIO_PLL1_OUT>; + assigned-clock-rates = <24576000>; + status = "okay"; +}; + &sai3 { pinctrl-names = "default"; pinctrl-0 = <&pinctrl_sai3>; @@ -494,6 +528,15 @@ >; }; + pinctrl_sai2: sai2grp { + fsl,pins = < + MX8MM_IOMUXC_SAI2_TXC_SAI2_TX_BCLK 0xd6 + MX8MM_IOMUXC_SAI2_TXFS_SAI2_TX_SYNC 0xd6 + MX8MM_IOMUXC_SAI2_TXD0_SAI2_TX_DATA00xd6 + MX8MM_IOMUXC_SAI2_RXD0_SAI2_RX_DATA00xd6 + >; + }; + pinctrl_sai3: sai3grp { fsl,pins = < MX8MM_IOMUXC_SAI3_TXFS_SAI3_TX_SYNC 0xd6 diff --git a/arch/arm/dts/imx8mm-icore-mx8mm.dtsi b/arch/arm/dts/imx8mm-icore-mx8mm.dtsi index b40148d728e..9e6170d9394 100644 --- a/arch/arm/dts/imx8mm-icore-mx8mm.dtsi +++ b/arch/arm/dts/imx8mm-icore-mx8mm.dtsi @@ -84,42 +84,42 @@ }; reg_buck1: buck1 { - regulator-min-microvolt = <40>; + regulator-min-microvolt = <40>; regulator-max-microvolt = <180>; regulator-always-on; regulator-boot-on; }; reg_buck2: buck2 { - regulator-min-microvolt = <40>; +
[PATCH v1 02/16] imx7d: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- include/dt-bindings/reset/imx7-reset.h | 1 + 1 file changed, 1 insertion(+) diff --git a/include/dt-bindings/reset/imx7-reset.h b/include/dt-bindings/reset/imx7-reset.h index bb92452ffb8..a5b35b4754d 100644 --- a/include/dt-bindings/reset/imx7-reset.h +++ b/include/dt-bindings/reset/imx7-reset.h @@ -50,3 +50,4 @@ #define IMX7_RESET_NUM 26 #endif + -- 2.35.1
[PATCH v1 05/16] imx6ulz: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx6ulz.dtsi | 1 - 1 file changed, 1 deletion(-) diff --git a/arch/arm/dts/imx6ulz.dtsi b/arch/arm/dts/imx6ulz.dtsi index aeb2ddc540e..0b5f1a76356 100644 --- a/arch/arm/dts/imx6ulz.dtsi +++ b/arch/arm/dts/imx6ulz.dtsi @@ -16,7 +16,6 @@ /delete-property/ serial7; /delete-property/ spi2; /delete-property/ spi3; - /delete-property/ spi4; }; }; -- 2.35.1
[PATCH v1 03/16] imx6ul: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx6ul-14x14-evk-u-boot.dtsi | 2 +- arch/arm/dts/imx6ul-phytec-segin.dtsi | 5 arch/arm/dts/imx6ul.dtsi | 36 +++ 3 files changed, 19 insertions(+), 24 deletions(-) diff --git a/arch/arm/dts/imx6ul-14x14-evk-u-boot.dtsi b/arch/arm/dts/imx6ul-14x14-evk-u-boot.dtsi index 3bd6edb42e0..301838d2d04 100644 --- a/arch/arm/dts/imx6ul-14x14-evk-u-boot.dtsi +++ b/arch/arm/dts/imx6ul-14x14-evk-u-boot.dtsi @@ -8,7 +8,7 @@ display0 = &lcdif; }; -&{/soc} { +&soc { u-boot,dm-pre-reloc; }; diff --git a/arch/arm/dts/imx6ul-phytec-segin.dtsi b/arch/arm/dts/imx6ul-phytec-segin.dtsi index 0d4ba9494cf..38ea4dcfa22 100644 --- a/arch/arm/dts/imx6ul-phytec-segin.dtsi +++ b/arch/arm/dts/imx6ul-phytec-segin.dtsi @@ -83,11 +83,6 @@ pinctrl-names = "default"; pinctrl-0 = <&pinctrl_adc1>; vref-supply = <®_adc1_vref_3v3>; - /* -* driver can not separate a specific channel so we request 4 channels -* here - we need only the fourth channel -*/ - num-channels = <4>; status = "disabled"; }; diff --git a/arch/arm/dts/imx6ul.dtsi b/arch/arm/dts/imx6ul.dtsi index afeec01f652..c95efd1d8c2 100644 --- a/arch/arm/dts/imx6ul.dtsi +++ b/arch/arm/dts/imx6ul.dtsi @@ -64,20 +64,18 @@ clock-frequency = <69600>; clock-latency = <61036>; /* two CLK32 periods */ #cooling-cells = <2>; - operating-points = < + operating-points = /* kHz uV */ - 696000 1275000 - 528000 1175000 - 396000 1025000 - 198000 95 - >; - fsl,soc-operating-points = < + <696000 1275000>, + <528000 1175000>, + <396000 1025000>, + <198000 95>; + fsl,soc-operating-points = /* KHz uV */ - 696000 1275000 - 528000 1175000 - 396000 1175000 - 198000 1175000 - >; + <696000 1275000>, + <528000 1175000>, + <396000 1175000>, + <198000 1175000>; clocks = <&clks IMX6UL_CLK_ARM>, <&clks IMX6UL_CLK_PLL2_BUS>, <&clks IMX6UL_CLK_PLL2_PFD2>, @@ -139,7 +137,7 @@ interrupts = ; }; - soc { + soc: soc { #address-cells = <1>; #size-cells = <1>; compatible = "simple-bus"; @@ -149,6 +147,9 @@ ocram: sram@90 { compatible = "mmio-sram"; reg = <0x0090 0x2>; + ranges = <0 0x0090 0x2>; + #address-cells = <1>; + #size-cells = <1>; }; intc: interrupt-controller@a01000 { @@ -543,7 +544,7 @@ }; kpp: keypad@20b8000 { - compatible = "fsl,imx6ul-kpp", "fsl,imx6q-kpp", "fsl,imx21-kpp"; + compatible = "fsl,imx6ul-kpp", "fsl,imx21-kpp"; reg = <0x020b8000 0x4000>; interrupts = ; clocks = <&clks IMX6UL_CLK_KPP>; @@ -923,7 +924,6 @@ reg = <0x02198000 0x4000>; interrupts = ; clocks = <&clks IMX6UL_CLK_ADC1>; - num-channels = <2>; clock-names = "adc"; fsl,adck-max-frequency = <3000>, <4000>, <2000>; @@ -998,7 +998,7 @@ }; csi: csi@21c4000 { - compatible = "fsl,imx6ul-csi", "fsl,imx7-csi"; + compatible = "fsl,imx6u
[PATCH v1 04/16] imx6ull: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx6ull-colibri.dtsi | 10 +++--- arch/arm/dts/imx6ull.dtsi | 2 +- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/arch/arm/dts/imx6ull-colibri.dtsi b/arch/arm/dts/imx6ull-colibri.dtsi index 15621e03fa4..577a424b0e1 100644 --- a/arch/arm/dts/imx6ull-colibri.dtsi +++ b/arch/arm/dts/imx6ull-colibri.dtsi @@ -94,7 +94,6 @@ }; &adc1 { - num-channels = <10>; vref-supply = <®_module_3v3_avdd>; pinctrl-names = "default"; pinctrl-0 = <&pinctrl_adc1>; @@ -166,7 +165,7 @@ atmel_mxt_ts: touchscreen@4a { compatible = "atmel,maxtouch"; pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_atmel_conn>; + pinctrl-0 = <&pinctrl_atmel_conn &pinctrl_atmel_snvs_conn>; reg = <0x4a>; interrupt-parent = <&gpio5>; interrupts = <4 IRQ_TYPE_EDGE_FALLING>; /* SODIMM 107 / INT */ @@ -331,7 +330,6 @@ pinctrl_atmel_conn: atmelconngrp { fsl,pins = < MX6UL_PAD_JTAG_MOD__GPIO1_IO10 0xb0a0 /* SODIMM 106 */ - MX6ULL_PAD_SNVS_TAMPER4__GPIO5_IO04 0xb0a0 /* SODIMM 107 */ >; }; @@ -684,6 +682,12 @@ }; &iomuxc_snvs { + pinctrl_atmel_snvs_conn: atmelsnvsconngrp { + fsl,pins = < + MX6ULL_PAD_SNVS_TAMPER4__GPIO5_IO04 0xb0a0 /* SODIMM 107 */ + >; + }; + pinctrl_snvs_gpio1: snvsgpio1grp { fsl,pins = < MX6ULL_PAD_SNVS_TAMPER6__GPIO5_IO06 0x110a0 /* SODIMM 93 */ diff --git a/arch/arm/dts/imx6ull.dtsi b/arch/arm/dts/imx6ull.dtsi index 9bf67490ac4..2bccd45e9fc 100644 --- a/arch/arm/dts/imx6ull.dtsi +++ b/arch/arm/dts/imx6ull.dtsi @@ -50,7 +50,7 @@ }; / { - soc { + soc: soc { aips3: bus@220 { compatible = "fsl,aips-bus", "simple-bus"; #address-cells = <1>; -- 2.35.1
[PATCH v1 00/16] arm: dts: imx: sync device trees with upstream linux kernel part 2
From: Marcel Ziswiler This series synchronises them imx device trees with the upstream Linux kernel (v6.0-rc1). I split it into two parts. This is part 2. It also fixes a few issues as discussed during/after the pre-mature application of my first series [1]. I am not touching kontron-sl-mx6ul as Frieder already took care of those [2]. Feedback welcome. Thanks! [1] https://patchwork.ozlabs.org/project/uboot/cover/20220721132748.1052244-1-mar...@ziswiler.com/ [2] https://patchwork.ozlabs.org/project/uboot/cover/20220823142917.306176-1-frie...@fris.de/ Marcel Ziswiler (16): imx7ulp: synchronise device tree with linux imx7d: synchronise device tree with linux imx6ul: synchronise device tree with linux imx6ull: synchronise device tree with linux imx6ulz: synchronise device tree with linux imx6sx: synchronise device tree with linux imx6sll: synchronise device tree with linux imx6sl: synchronise device tree with linux imx6qp: synchronise device tree with linux imx6qdl: synchronise device tree with linux imx53: synchronise device tree with linux imx51: synchronise device tree with linux imx28: synchronise device tree with linux imx23: synchronise device tree with linux tbs2910: revert prepare to synchronise device trees with linux imx28: avoid num_cs and spi_max_frequency build errors arch/arm/dts/imx23-evk.dts | 1 - arch/arm/dts/imx23-pinfunc.h| 8 +- arch/arm/dts/imx23-u-boot.dtsi | 7 +- arch/arm/dts/imx23.dtsi | 2 +- arch/arm/dts/imx28-evk.dts | 2 +- arch/arm/dts/imx28-pinfunc.h| 8 +- arch/arm/dts/imx28-xea-u-boot.dtsi | 2 + arch/arm/dts/imx28-xea.dts | 188 ++-- arch/arm/dts/imx28.dtsi | 20 +- arch/arm/dts/imx51.dtsi | 24 +- arch/arm/dts/imx53-cx9020.dts | 414 arch/arm/dts/imx53-kp.dts | 2 + arch/arm/dts/imx53-m53menlo.dts | 306 -- arch/arm/dts/imx53-pinfunc.h| 11 +- arch/arm/dts/imx53-ppd.dts | 87 +- arch/arm/dts/imx53-usbarmory.dts| 1 - arch/arm/dts/imx53.dtsi | 39 +- arch/arm/dts/imx6q-sabrelite.dts| 11 +- arch/arm/dts/imx6q-tbs2910-u-boot.dtsi | 4 +- arch/arm/dts/imx6qdl-sabrelite.dtsi | 11 +- arch/arm/dts/imx6qp-sabreauto.dts | 7 +- arch/arm/dts/imx6qp-sabresd.dts | 10 +- arch/arm/dts/imx6qp.dtsi| 3 +- arch/arm/dts/imx6sl-evk.dts | 183 ++-- arch/arm/dts/imx6sl-pinfunc.h | 6 +- arch/arm/dts/imx6sl.dtsi| 362 --- arch/arm/dts/imx6sll-evk.dts| 879 +++-- arch/arm/dts/imx6sll-pinfunc.h | 6 +- arch/arm/dts/imx6sll.dtsi | 445 + arch/arm/dts/imx6sx-sabreauto.dts | 623 +--- arch/arm/dts/imx6sx-sdb.dts | 8 +- arch/arm/dts/imx6sx-sdb.dtsi| 56 +- arch/arm/dts/imx6sx-softing-vining-2000.dts | 50 +- arch/arm/dts/imx6sx-udoo-neo.dtsi | 86 +- arch/arm/dts/imx6sx.dtsi| 129 ++- arch/arm/dts/imx6ul-14x14-evk-u-boot.dtsi | 2 +- arch/arm/dts/imx6ul-phytec-segin.dtsi | 5 - arch/arm/dts/imx6ul.dtsi| 36 +- arch/arm/dts/imx6ull-colibri.dtsi | 10 +- arch/arm/dts/imx6ull.dtsi | 2 +- arch/arm/dts/imx6ulz.dtsi | 1 - arch/arm/dts/imx7ulp-com-u-boot.dtsi| 2 +- arch/arm/dts/imx7ulp-com.dts| 32 +- arch/arm/dts/imx7ulp-evk.dts| 430 ++--- arch/arm/dts/imx7ulp-pinfunc.h | 990 ++-- arch/arm/dts/imx7ulp.dtsi | 681 +- arch/arm/dts/mxs-pinfunc.h | 8 +- include/dt-bindings/clock/imx6sl-clock.h| 10 +- include/dt-bindings/clock/imx6sll-clock.h | 16 +- include/dt-bindings/clock/imx7ulp-clock.h | 170 ++-- include/dt-bindings/reset/imx7-reset.h | 1 + 51 files changed, 3027 insertions(+), 3370 deletions(-) -- 2.35.1
[PATCH v1 06/16] imx6sx: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx6sx-sabreauto.dts | 623 +++- arch/arm/dts/imx6sx-sdb.dts | 8 +- arch/arm/dts/imx6sx-sdb.dtsi| 56 +- arch/arm/dts/imx6sx-softing-vining-2000.dts | 50 +- arch/arm/dts/imx6sx-udoo-neo.dtsi | 86 ++- arch/arm/dts/imx6sx.dtsi| 129 ++-- 6 files changed, 709 insertions(+), 243 deletions(-) diff --git a/arch/arm/dts/imx6sx-sabreauto.dts b/arch/arm/dts/imx6sx-sabreauto.dts index 9643d1fe064..83ee97252ff 100644 --- a/arch/arm/dts/imx6sx-sabreauto.dts +++ b/arch/arm/dts/imx6sx-sabreauto.dts @@ -1,10 +1,6 @@ -/* - * Copyright (C) 2014 Freescale Semiconductor, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. - */ +// SPDX-License-Identifier: GPL-2.0 +// +// Copyright (C) 2014 Freescale Semiconductor, Inc. /dts-v1/; @@ -14,29 +10,171 @@ model = "Freescale i.MX6 SoloX Sabre Auto Board"; compatible = "fsl,imx6sx-sabreauto", "fsl,imx6sx"; - memory { + memory@8000 { + device_type = "memory"; reg = <0x8000 0x8000>; }; - regulators { - compatible = "simple-bus"; + leds { + compatible = "gpio-leds"; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_led>; + + user { + label = "debug"; + gpios = <&gpio1 24 GPIO_ACTIVE_HIGH>; + linux,default-trigger = "heartbeat"; + }; + }; + + vcc_sd3: regulator-vcc-sd3 { + compatible = "regulator-fixed"; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_vcc_sd3>; + regulator-name = "VCC_SD3"; + regulator-min-microvolt = <300>; + regulator-max-microvolt = <300>; + gpio = <&gpio2 11 GPIO_ACTIVE_HIGH>; + enable-active-high; + }; + + reg_can_wake: regulator-can-wake { + compatible = "regulator-fixed"; + regulator-name = "can-wake"; + regulator-min-microvolt = <330>; + regulator-max-microvolt = <330>; + gpio = <&max7310_b 7 GPIO_ACTIVE_HIGH>; + enable-active-high; + }; + + reg_can_en: regulator-can-en { + compatible = "regulator-fixed"; + regulator-name = "can-en"; + regulator-min-microvolt = <330>; + regulator-max-microvolt = <330>; + gpio = <&max7310_b 5 GPIO_ACTIVE_HIGH>; + enable-active-high; + vin-supply = <®_can_wake>; + }; + + reg_can_stby: regulator-can-stby { + compatible = "regulator-fixed"; + regulator-name = "can-stby"; + regulator-min-microvolt = <330>; + regulator-max-microvolt = <330>; + gpio = <&max7310_b 4 GPIO_ACTIVE_HIGH>; + enable-active-high; + vin-supply = <®_can_en>; + }; + + reg_cs42888: cs42888_supply { + compatible = "regulator-fixed"; + regulator-name = "cs42888_supply"; + regulator-min-microvolt = <330>; + regulator-max-microvolt = <330>; + regulator-always-on; + }; + + sound-cs42888 { + compatible = "fsl,imx6-sabreauto-cs42888", +"fsl,imx-audio-cs42888"; + model = "imx-cs42888"; + audio-cpu = <&esai>; + audio-asrc = <&asrc>; + audio-codec = <&cs42888>; + audio-routing = + "Line Out Jack", "AOUT1L", + "Line Out Jack", "AOUT1R", + "Line Out Jack", "AOUT2L", + "Line Out Jack", "AOUT2R", + "Line Out Jack", "AOUT3L", + "Line Out Jack", "AOUT3R", + "Line Out Jack", "AOUT4L", + "Line Out Jack", "AOUT4R", + "AIN1L", "
[PATCH v1 10/16] imx6qdl: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx6q-sabrelite.dts| 11 ++- arch/arm/dts/imx6qdl-sabrelite.dtsi | 11 ++- 2 files changed, 12 insertions(+), 10 deletions(-) diff --git a/arch/arm/dts/imx6q-sabrelite.dts b/arch/arm/dts/imx6q-sabrelite.dts index 434b1433e79..7c6a2f234cc 100644 --- a/arch/arm/dts/imx6q-sabrelite.dts +++ b/arch/arm/dts/imx6q-sabrelite.dts @@ -1,8 +1,9 @@ -// SPDX-License-Identifier: GPL-2.0+ -// -// Copyright 2013-2019 Boundary Devices, Inc. -// Copyright 2012 Freescale Semiconductor, Inc. -// Copyright 2011 Linaro Ltd. +// SPDX-License-Identifier: GPL-2.0 OR X11 +/* + * Copyright 2011 Freescale Semiconductor, Inc. + * Copyright 2011 Linaro Ltd. + * + */ /dts-v1/; #include "imx6q.dtsi" diff --git a/arch/arm/dts/imx6qdl-sabrelite.dtsi b/arch/arm/dts/imx6qdl-sabrelite.dtsi index a757817a3c2..22f8e2783cd 100644 --- a/arch/arm/dts/imx6qdl-sabrelite.dtsi +++ b/arch/arm/dts/imx6qdl-sabrelite.dtsi @@ -1,8 +1,9 @@ -// SPDX-License-Identifier: GPL-2.0+ -// -// Copyright 2013-2019 Boundary Devices, Inc. -// Copyright 2012 Freescale Semiconductor, Inc. -// Copyright 2011 Linaro Ltd. +// SPDX-License-Identifier: GPL-2.0 OR X11 +/* + * Copyright 2011 Freescale Semiconductor, Inc. + * Copyright 2011 Linaro Ltd. + * + */ #include #include -- 2.35.1
[PATCH v1 08/16] imx6sl: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx6sl-evk.dts | 183 ++-- arch/arm/dts/imx6sl-pinfunc.h| 6 +- arch/arm/dts/imx6sl.dtsi | 362 ++- include/dt-bindings/clock/imx6sl-clock.h | 10 +- 4 files changed, 325 insertions(+), 236 deletions(-) diff --git a/arch/arm/dts/imx6sl-evk.dts b/arch/arm/dts/imx6sl-evk.dts index 0a90eea1701..f16c830f1e9 100644 --- a/arch/arm/dts/imx6sl-evk.dts +++ b/arch/arm/dts/imx6sl-evk.dts @@ -1,10 +1,6 @@ -/* - * Copyright (C) 2013 Freescale Semiconductor, Inc. - * - * This program is free software; you can redistribute it and/or modify - * it under the terms of the GNU General Public License version 2 as - * published by the Free Software Foundation. - */ +// SPDX-License-Identifier: GPL-2.0 +// +//Copyright (C) 2013 Freescale Semiconductor, Inc. /dts-v1/; @@ -16,11 +12,16 @@ model = "Freescale i.MX6 SoloLite EVK Board"; compatible = "fsl,imx6sl-evk", "fsl,imx6sl"; - memory { + chosen { + stdout-path = &uart1; + }; + + memory@8000 { + device_type = "memory"; reg = <0x8000 0x4000>; }; - backlight { + backlight_display: backlight_display { compatible = "pwm-backlight"; pwms = <&pwm1 0 500>; brightness-levels = <0 4 8 16 32 64 128 255>; @@ -39,62 +40,62 @@ }; }; - regulators { - compatible = "simple-bus"; - #address-cells = <1>; - #size-cells = <0>; - - reg_usb_otg1_vbus: regulator@0 { - compatible = "regulator-fixed"; - reg = <0>; - regulator-name = "usb_otg1_vbus"; - regulator-min-microvolt = <500>; - regulator-max-microvolt = <500>; - gpio = <&gpio4 0 0>; - enable-active-high; - vin-supply = <&swbst_reg>; - }; + reg_usb_otg1_vbus: regulator-usb-otg1-vbus { + compatible = "regulator-fixed"; + regulator-name = "usb_otg1_vbus"; + regulator-min-microvolt = <500>; + regulator-max-microvolt = <500>; + gpio = <&gpio4 0 GPIO_ACTIVE_HIGH>; + enable-active-high; + vin-supply = <&swbst_reg>; + }; - reg_usb_otg2_vbus: regulator@1 { - compatible = "regulator-fixed"; - reg = <1>; - regulator-name = "usb_otg2_vbus"; - regulator-min-microvolt = <500>; - regulator-max-microvolt = <500>; - gpio = <&gpio4 2 0>; - enable-active-high; - vin-supply = <&swbst_reg>; - }; + reg_usb_otg2_vbus: regulator-usb-otg2-vbus { + compatible = "regulator-fixed"; + regulator-name = "usb_otg2_vbus"; + regulator-min-microvolt = <500>; + regulator-max-microvolt = <500>; + gpio = <&gpio4 2 GPIO_ACTIVE_HIGH>; + enable-active-high; + vin-supply = <&swbst_reg>; + }; - reg_aud3v: regulator@2 { - compatible = "regulator-fixed"; - reg = <2>; - regulator-name = "wm8962-supply-3v15"; - regulator-min-microvolt = <315>; - regulator-max-microvolt = <315>; - regulator-boot-on; - }; + reg_aud3v: regulator-aud3v { + compatible = "regulator-fixed"; + regulator-name = "wm8962-supply-3v15"; + regulator-min-microvolt = <315>; + regulator-max-microvolt = <315>; + regulator-boot-on; + }; - reg_aud4v: regulator@3 { - compatible = "regulator-fixed"; - reg = <3>; - regulator-name = "wm8962-supply-4v2"; - regulator-min-microvolt = <4325000>; - regulator-max-microvolt = <4325000>; - regulator-boot-on; - }; + reg_aud4v: regulator-aud4v { +
[PATCH v1 09/16] imx6qp: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx6qp-sabreauto.dts | 7 ++- arch/arm/dts/imx6qp-sabresd.dts | 10 +- arch/arm/dts/imx6qp.dtsi | 3 +-- 3 files changed, 16 insertions(+), 4 deletions(-) diff --git a/arch/arm/dts/imx6qp-sabreauto.dts b/arch/arm/dts/imx6qp-sabreauto.dts index d4caeeb0af7..2bb3bfb18ec 100644 --- a/arch/arm/dts/imx6qp-sabreauto.dts +++ b/arch/arm/dts/imx6qp-sabreauto.dts @@ -47,7 +47,12 @@ }; &pcie { - status = "disabled"; + reset-gpio = <&max7310_c 5 GPIO_ACTIVE_LOW>; + status = "okay"; +}; + +&sata { + status = "okay"; }; &vgen3_reg { diff --git a/arch/arm/dts/imx6qp-sabresd.dts b/arch/arm/dts/imx6qp-sabresd.dts index f1b9cb104fd..f69eec18d86 100644 --- a/arch/arm/dts/imx6qp-sabresd.dts +++ b/arch/arm/dts/imx6qp-sabresd.dts @@ -50,6 +50,14 @@ }; }; +&vgen3_reg { + regulator-always-on; +}; + &pcie { - status = "disabled"; + status = "okay"; +}; + +&sata { + status = "okay"; }; diff --git a/arch/arm/dts/imx6qp.dtsi b/arch/arm/dts/imx6qp.dtsi index 93b89dc1f53..05036551383 100644 --- a/arch/arm/dts/imx6qp.dtsi +++ b/arch/arm/dts/imx6qp.dtsi @@ -77,7 +77,6 @@ }; &fec { - /delete-property/interrupts-extended; interrupts = <0 118 IRQ_TYPE_LEVEL_HIGH>, <0 119 IRQ_TYPE_LEVEL_HIGH>; }; @@ -111,5 +110,5 @@ }; &pcie { - compatible = "fsl,imx6qp-pcie", "snps,dw-pcie"; + compatible = "fsl,imx6qp-pcie"; }; -- 2.35.1
[PATCH v1 12/16] imx51: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx51.dtsi | 24 +++- 1 file changed, 15 insertions(+), 9 deletions(-) diff --git a/arch/arm/dts/imx51.dtsi b/arch/arm/dts/imx51.dtsi index 7ebb46ce9e3..592d9c23a44 100644 --- a/arch/arm/dts/imx51.dtsi +++ b/arch/arm/dts/imx51.dtsi @@ -48,25 +48,25 @@ clocks { ckil { - compatible = "fsl,imx-ckil", "fixed-clock"; + compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <32768>; }; ckih1 { - compatible = "fsl,imx-ckih1", "fixed-clock"; + compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <0>; }; ckih2 { - compatible = "fsl,imx-ckih2", "fixed-clock"; + compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <0>; }; osc { - compatible = "fsl,imx-osc", "fixed-clock"; + compatible = "fixed-clock"; #clock-cells = <0>; clock-frequency = <2400>; }; @@ -114,7 +114,7 @@ ports = <&ipu_di0>, <&ipu_di1>; }; - soc { + soc: soc { #address-cells = <1>; #size-cells = <1>; compatible = "simple-bus"; @@ -171,14 +171,14 @@ }; }; - bus@7000 { /* AIPS1 */ + aips1: bus@7000 { /* AIPS1 */ compatible = "fsl,aips-bus", "simple-bus"; #address-cells = <1>; #size-cells = <1>; reg = <0x7000 0x1000>; ranges; - spba@7000 { + spba-bus@7000 { compatible = "fsl,spba-bus", "simple-bus"; #address-cells = <1>; #size-cells = <1>; @@ -215,6 +215,8 @@ clocks = <&clks IMX5_CLK_UART3_IPG_GATE>, <&clks IMX5_CLK_UART3_PER_GATE>; clock-names = "ipg", "per"; + dmas = <&sdma 43 5 1>, <&sdma 44 5 2>; + dma-names = "rx", "tx"; status = "disabled"; }; @@ -426,6 +428,8 @@ clocks = <&clks IMX5_CLK_UART1_IPG_GATE>, <&clks IMX5_CLK_UART1_PER_GATE>; clock-names = "ipg", "per"; + dmas = <&sdma 18 4 1>, <&sdma 19 4 2>; + dma-names = "rx", "tx"; status = "disabled"; }; @@ -436,6 +440,8 @@ clocks = <&clks IMX5_CLK_UART2_IPG_GATE>, <&clks IMX5_CLK_UART2_PER_GATE>; clock-names = "ipg", "per"; + dmas = <&sdma 16 4 1>, <&sdma 17 4 2>; + dma-names = "rx", "tx"; status = "disabled"; }; @@ -454,7 +460,7 @@ }; }; - bus@8000 { /* AIPS2 */ + aips2: bus@8000 { /* AIPS2 */ compatible = "fsl,aips-bus", "simple-bus"; #address-cells = <1>; #size-cells = <1>; @@ -467,7 +473,7 @@ }; iim: efuse@83f98000 { - compatible = "fsl,imx51-iim", "fsl,imx27-iim"; + compatible = "fsl,imx51-iim", "fsl,imx27-iim", "syscon"; reg = <0x83f98000 0x4000>; interrupts = <69>; clocks = <&clks IMX5_CLK_IIM_GATE>; -- 2.35.1
[PATCH v1 14/16] imx23: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx23-evk.dts | 1 - arch/arm/dts/imx23-pinfunc.h | 8 +--- arch/arm/dts/imx23-u-boot.dtsi | 7 +++ arch/arm/dts/imx23.dtsi| 2 +- 4 files changed, 5 insertions(+), 13 deletions(-) diff --git a/arch/arm/dts/imx23-evk.dts b/arch/arm/dts/imx23-evk.dts index 8cbaf1c8117..3b609d987d8 100644 --- a/arch/arm/dts/imx23-evk.dts +++ b/arch/arm/dts/imx23-evk.dts @@ -79,7 +79,6 @@ MX23_PAD_LCD_RESET__GPIO_1_18 MX23_PAD_PWM3__GPIO_1_29 MX23_PAD_PWM4__GPIO_1_30 - MX23_PAD_SSP1_DETECT__SSP1_DETECT >; fsl,drive-strength = ; fsl,voltage = ; diff --git a/arch/arm/dts/imx23-pinfunc.h b/arch/arm/dts/imx23-pinfunc.h index 5c0f32ca3a9..468c079f3c2 100644 --- a/arch/arm/dts/imx23-pinfunc.h +++ b/arch/arm/dts/imx23-pinfunc.h @@ -1,14 +1,8 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ /* * Header providing constants for i.MX23 pinctrl bindings. * * Copyright (C) 2013 Lothar Waßmann - * - * The code contained herein is licensed under the GNU General Public - * License. You may obtain a copy of the GNU General Public License - * Version 2 at the following locations: - * - * http://www.opensource.org/licenses/gpl-license.html - * http://www.gnu.org/copyleft/gpl.html */ #ifndef __DT_BINDINGS_MX23_PINCTRL_H__ diff --git a/arch/arm/dts/imx23-u-boot.dtsi b/arch/arm/dts/imx23-u-boot.dtsi index 5e87aca61b7..5de62bbb907 100644 --- a/arch/arm/dts/imx23-u-boot.dtsi +++ b/arch/arm/dts/imx23-u-boot.dtsi @@ -1,14 +1,13 @@ // SPDX-License-Identifier: GPL-2.0+ &gpio0 { - gpio-ranges = <&pinctrl 0 0 32>; + gpio-ranges = <&{/apb@8000/apbh@8000/pinctrl@80018000} 0 0 32>; }; &gpio1 { - gpio-ranges = <&pinctrl 0 32 31>; + gpio-ranges = <&{/apb@8000/apbh@8000/pinctrl@80018000} 0 32 31>; }; &gpio2 { - gpio-ranges = <&pinctrl 0 63 32>; + gpio-ranges = <&{/apb@8000/apbh@8000/pinctrl@80018000} 0 63 32>; }; - diff --git a/arch/arm/dts/imx23.dtsi b/arch/arm/dts/imx23.dtsi index 4cfec778492..7f4c602454a 100644 --- a/arch/arm/dts/imx23.dtsi +++ b/arch/arm/dts/imx23.dtsi @@ -105,7 +105,7 @@ status = "disabled"; }; - pinctrl: pinctrl@80018000 { + pinctrl@80018000 { #address-cells = <1>; #size-cells = <0>; compatible = "fsl,imx23-pinctrl", "simple-bus"; -- 2.35.1
[PATCH v1 13/16] imx28: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx28-evk.dts | 2 +- arch/arm/dts/imx28-pinfunc.h | 8 +- arch/arm/dts/imx28-xea.dts | 188 ++- arch/arm/dts/imx28.dtsi | 20 +++- arch/arm/dts/mxs-pinfunc.h | 8 +- 5 files changed, 91 insertions(+), 135 deletions(-) diff --git a/arch/arm/dts/imx28-evk.dts b/arch/arm/dts/imx28-evk.dts index 7e2b0f198df..1053b7c584d 100644 --- a/arch/arm/dts/imx28-evk.dts +++ b/arch/arm/dts/imx28-evk.dts @@ -129,7 +129,7 @@ pinctrl-0 = <&spi2_pins_a>; status = "okay"; - flash: m25p80@0 { + flash: flash@0 { #address-cells = <1>; #size-cells = <1>; compatible = "sst,sst25vf016b", "jedec,spi-nor"; diff --git a/arch/arm/dts/imx28-pinfunc.h b/arch/arm/dts/imx28-pinfunc.h index e11f69ba0fe..d427e6c2fa7 100644 --- a/arch/arm/dts/imx28-pinfunc.h +++ b/arch/arm/dts/imx28-pinfunc.h @@ -1,14 +1,8 @@ +/* SPDX-License-Identifier: GPL-2.0-only */ /* * Header providing constants for i.MX28 pinctrl bindings. * * Copyright (C) 2013 Lothar Waßmann - * - * The code contained herein is licensed under the GNU General Public - * License. You may obtain a copy of the GNU General Public License - * Version 2 at the following locations: - * - * http://www.opensource.org/licenses/gpl-license.html - * http://www.gnu.org/copyleft/gpl.html */ #ifndef __DT_BINDINGS_MX28_PINCTRL_H__ diff --git a/arch/arm/dts/imx28-xea.dts b/arch/arm/dts/imx28-xea.dts index f4b503cf650..a400c108f66 100644 --- a/arch/arm/dts/imx28-xea.dts +++ b/arch/arm/dts/imx28-xea.dts @@ -1,143 +1,99 @@ -// SPDX-License-Identifier: GPL-2.0+ +// SPDX-License-Identifier: GPL-2.0-or-later OR MIT /* - * Copyright 2019 + * Copyright 2021 * Lukasz Majewski, DENX Software Engineering, lu...@denx.de - * - * SPDX-License-Identifier: GPL-2.0+ or X11 - * */ /dts-v1/; - -#include "imx28.dtsi" +#include "imx28-lwe.dtsi" / { - model = "Liebherr (LWE) XEA i.MX28 Board"; - compatible = "lwe,xea", "fsl,imx28"; - - aliases { - spi3 = &ssp3; - }; - - memory@4000 { - device_type = "memory"; - reg = <0x4000 0x1000>; - }; - - reg_3p3v: regulator-3p3v { - compatible = "regulator-fixed"; - regulator-name = "3P3V"; - regulator-min-microvolt = <330>; - regulator-max-microvolt = <330>; - regulator-always-on; - }; - - reg_fec_3v3: regulator-fec-3v3 { - compatible = "regulator-fixed"; - regulator-name = "fec-3v3"; - regulator-min-microvolt = <330>; - regulator-max-microvolt = <330>; - gpio = <&gpio0 0 GPIO_ACTIVE_HIGH>; - enable-active-high; - regulator-boot-on; - }; - - reg_usb_5v: regulator-usb-5v { - compatible = "regulator-fixed"; - regulator-name = "usb_vbus"; - regulator-min-microvolt = <500>; - regulator-max-microvolt = <500>; - gpio = <&gpio1 28 GPIO_ACTIVE_HIGH>; - enable-active-high; - }; + compatible = "lwn,imx28-xea", "fsl,imx28"; }; -&mac0 { - phy-mode = "rmii"; +&can0 { pinctrl-names = "default"; - pinctrl-0 = <&mac0_pins_a>; - phy-supply = <®_fec_3v3>; - phy-reset-gpios = <&gpio2 13 GPIO_ACTIVE_LOW>; - phy-reset-duration = <1>; - phy-reset-post-delay = <1>; + pinctrl-0 = <&can1_pins_a>; status = "okay"; - - fixed-link { - speed = <100>; - full-duplex; - }; }; -&ssp0 { - compatible = "fsl,imx28-mmc"; +&i2c1 { pinctrl-names = "default"; - pinctrl-0 = <&mmc0_8bit_pins_a>; - bus-width = <8>; - vmmc-supply = <®_3p3v>; - non-removable; + pinctrl-0 = <&i2c1_pins_b>; status = "okay"; }; -&ssp3 { - #address-cells = <1>; - #size-cells = <0>; - compatible = "fsl,imx28-spi"; +&pinctrl { pinctrl-names = "default"; - pinctrl-0 = <&spi3_pins_b>; - status = "okay"; - spi-max-frequenc
[PATCH v1 11/16] imx53: synchronise device tree with linux
From: Marcel Ziswiler Synchronise device tree with linux v6.0-rc1. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx53-cx9020.dts| 414 ++- arch/arm/dts/imx53-kp.dts| 2 + arch/arm/dts/imx53-m53menlo.dts | 306 ++- arch/arm/dts/imx53-pinfunc.h | 11 +- arch/arm/dts/imx53-ppd.dts | 87 +-- arch/arm/dts/imx53-usbarmory.dts | 1 - arch/arm/dts/imx53.dtsi | 39 +-- 7 files changed, 577 insertions(+), 283 deletions(-) diff --git a/arch/arm/dts/imx53-cx9020.dts b/arch/arm/dts/imx53-cx9020.dts index e08850999b1..cfb18849a92 100644 --- a/arch/arm/dts/imx53-cx9020.dts +++ b/arch/arm/dts/imx53-cx9020.dts @@ -1,195 +1,133 @@ -// SPDX-License-Identifier: GPL-2.0+ OR X11 +// SPDX-License-Identifier: GPL-2.0-or-later /* - * Copyright 2016 Beckhoff Automation - * Copyright 2011 Freescale Semiconductor, Inc. - * Copyright 2011 Linaro Ltd. + * Copyright 2017 Beckhoff Automation GmbH & Co. KG + * based on imx53-qsb.dts */ /dts-v1/; #include "imx53.dtsi" -#define MX53_PAD_EIM_D26__UART2_RXD_MUX0x144 0x48c 0x880 0x2 0x0 -#define MX53_PAD_EIM_D27__UART2_TXD_MUX0x148 0x490 0x000 0x2 0x0 -#define MX53_PAD_EIM_D28__UART2_RTS0x14c 0x494 0x87c 0x2 0x0 -#define MX53_PAD_EIM_D29__UART2_CTS0x150 0x498 0x000 0x2 0x0 - / { - model = "Beckhoff CX9020-0100 i.MX53"; - compatible = "fsl,imx53-qsb", "fsl,imx53"; + model = "Beckhoff CX9020 Embedded PC"; + compatible = "bhf,cx9020", "fsl,imx53"; chosen { stdout-path = &uart2; }; -}; -&iomuxc { - pinctrl-names = "default"; - pinctrl-0 = <&pinctrl_hog>; + memory@7000 { + device_type = "memory"; + reg = <0x7000 0x2000>, + <0xb000 0x2000>; + }; + + display-0 { + #address-cells =<1>; + #size-cells = <0>; + compatible = "fsl,imx-parallel-display"; + interface-pix-fmt = "rgb24"; + pinctrl-names = "default"; + pinctrl-0 = <&pinctrl_ipu_disp0>; + + port@0 { + reg = <0>; + + display0_in: endpoint { + remote-endpoint = <&ipu_di0_disp0>; + }; + }; + + port@1 { + reg = <1>; + + display0_out: endpoint { + remote-endpoint = <&tfp410_in>; + }; + }; + }; + + dvi-connector { + compatible = "dvi-connector"; + ddc-i2c-bus = <&i2c2>; + digital; + + port { + dvi_connector_in: endpoint { + remote-endpoint = <&tfp410_out>; + }; + }; + }; - imx53-qsb { - pinctrl_hog: hoggrp { - fsl,pins = < - MX53_PAD_GPIO_0__CCM_SSI_EXT1_CLK 0x8000 - MX53_PAD_GPIO_8__GPIO1_8 0x8000 - MX53_PAD_PATA_DATA14__GPIO2_140x8000 - MX53_PAD_PATA_DATA15__GPIO2_150x8000 - MX53_PAD_GPIO_1__GPIO1_1 0x8000 - MX53_PAD_GPIO_4__GPIO1_4 0x8000 - MX53_PAD_PATA_DA_0__GPIO7_6 0x8000 - MX53_PAD_GPIO_16__GPIO7_110x8000 - - MX53_PAD_EIM_OE__EMI_WEIM_OE 0x8000 - MX53_PAD_EIM_WAIT__EMI_WEIM_WAIT 0x8000 - MX53_PAD_EIM_LBA__EMI_WEIM_LBA 0x8000 - MX53_PAD_EIM_RW__EMI_WEIM_RW 0x8000 - MX53_PAD_EIM_EB0__EMI_WEIM_EB_0 0x8000 - MX53_PAD_EIM_EB1__EMI_WEIM_EB_1 0x8000 - MX53_PAD_EIM_EB2__EMI_WEIM_EB_2 0x8000 - MX53_PAD_EIM_EB3__EMI_WEIM_EB_3 0x8000 - MX53_PAD_EIM_CS0__EMI_WEIM_CS_0 0x8000 - MX53_PAD_EIM_CS1__EMI_WEIM_CS_1 0x8000 - MX53_PAD_EIM_A16__EMI_WEIM_A_16 0x8000 - MX53_PAD_EIM_A17__EMI_WEIM_A_17 0x8000 - MX53_PAD_EIM_A18__EMI_WEIM_A_18 0
[PATCH v1 15/16] tbs2910: revert prepare to synchronise device trees with linux
From: Marcel Ziswiler Now with all synchonised revert "tbs2910: prepare to synchronise device trees with linux". This reverts commit 50b229523bbc5511e1bace34df779f84950bf872. Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx6q-tbs2910-u-boot.dtsi | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/arm/dts/imx6q-tbs2910-u-boot.dtsi b/arch/arm/dts/imx6q-tbs2910-u-boot.dtsi index d48719e7d59..65ab052ac2c 100644 --- a/arch/arm/dts/imx6q-tbs2910-u-boot.dtsi +++ b/arch/arm/dts/imx6q-tbs2910-u-boot.dtsi @@ -1,6 +1,6 @@ // SPDX-License-Identifier: GPL-2.0+ -&{/soc/bus@200} { /* AIPS1 */ +&aips1 { u-boot,dm-pre-reloc; }; @@ -8,7 +8,7 @@ u-boot,dm-pre-reloc; }; -&{/soc} { +&soc { u-boot,dm-pre-reloc; }; -- 2.35.1
[PATCH v1 16/16] imx28: avoid num_cs and spi_max_frequency build errors
From: Marcel Ziswiler Avoid the following build errors after the device tree sync: drivers/spi/mxs_spi.c: In function ‘mxs_spi_probe’: drivers/spi/mxs_spi.c:327:25: error: ‘struct dtd_fsl_imx23_spi’ has no member named ‘spi_max_frequency’ 327 | priv->max_freq = dtplat->spi_max_frequency; | ^~ drivers/spi/mxs_spi.c:328:23: error: ‘struct dtd_fsl_imx23_spi’ has no member named ‘num_cs’ 328 | plat->num_cs = dtplat->num_cs; | ^~ Signed-off-by: Marcel Ziswiler --- arch/arm/dts/imx28-xea-u-boot.dtsi | 2 ++ 1 file changed, 2 insertions(+) diff --git a/arch/arm/dts/imx28-xea-u-boot.dtsi b/arch/arm/dts/imx28-xea-u-boot.dtsi index cc2ced5d2d4..8b5d7e10b3b 100644 --- a/arch/arm/dts/imx28-xea-u-boot.dtsi +++ b/arch/arm/dts/imx28-xea-u-boot.dtsi @@ -42,5 +42,7 @@ }; &ssp3 { + num-cs = <2>; + spi-max-frequency = <4000>; u-boot,dm-spl; }; -- 2.35.1