mirror of
https://github.com/AsahiLinux/u-boot
synced 2024-11-10 23:24:38 +00:00
u-boot-imx-20210502
------------------- - mx6: fixes for Ventana - local fixes from maintainer - imx7d: Ronetix's iMX7-CM - imx8: Ronetix iMX8MQ-CM Engicam i.Core MX8M Compulab iot-gate-imx8 - Fixes i.MX8 documentation - Fixes phy usage with fec -----BEGIN PGP SIGNATURE----- iG0EABECAC0WIQS2TmnA27QKhpKSZe309WXkmmjvpgUCYJqX/Q8cc2JhYmljQGRl bnguZGUACgkQ9PVl5Jpo76aACgCfYnzkeOHsKM6i9J6bdxIwwnU5NycAniDYksOG IT8LzFNHf0ECCj26S9mI =wVb3 -----END PGP SIGNATURE----- Merge tag 'u-boot-imx-20210502' of https://gitlab.denx.de/u-boot/custodians/u-boot-imx u-boot-imx-20210502 ------------------- - mx6: fixes for Ventana - local fixes from maintainer - imx7d: Ronetix's iMX7-CM - imx8: Ronetix iMX8MQ-CM Engicam i.Core MX8M Compulab iot-gate-imx8 - Fixes i.MX8 documentation - Fixes phy usage with fec
This commit is contained in:
commit
59a2b9e605
79 changed files with 16163 additions and 260 deletions
6
Makefile
6
Makefile
|
@ -1491,10 +1491,16 @@ u-boot.cnt: u-boot.bin FORCE
|
|||
flash.bin: spl/u-boot-spl.bin u-boot.cnt FORCE
|
||||
$(Q)$(MAKE) $(build)=arch/arm/mach-imx $@
|
||||
else
|
||||
ifeq ($(CONFIG_BINMAN),y)
|
||||
flash.bin: spl/u-boot-spl.bin $(INPUTS-y) FORCE
|
||||
$(call if_changed,binman)
|
||||
$(Q)$(MAKE) $(build)=arch/arm/mach-imx $@
|
||||
else
|
||||
flash.bin: spl/u-boot-spl.bin u-boot.itb FORCE
|
||||
$(Q)$(MAKE) $(build)=arch/arm/mach-imx $@
|
||||
endif
|
||||
endif
|
||||
endif
|
||||
|
||||
u-boot.uim: u-boot.bin FORCE
|
||||
$(Q)$(MAKE) $(build)=arch/arm/mach-imx $@
|
||||
|
|
|
@ -811,6 +811,7 @@ dtb-$(CONFIG_ARCH_MX6) += \
|
|||
|
||||
dtb-$(CONFIG_MX7) += imx7d-sdb.dtb \
|
||||
imx7d-sdb-qspi.dtb \
|
||||
imx7-cm.dtb \
|
||||
imx7-colibri-emmc.dtb \
|
||||
imx7-colibri-rawnand.dtb \
|
||||
imx7s-warp.dtb \
|
||||
|
@ -835,6 +836,8 @@ dtb-$(CONFIG_ARCH_IMX8) += \
|
|||
|
||||
dtb-$(CONFIG_ARCH_IMX8M) += \
|
||||
imx8mm-evk.dtb \
|
||||
imx8mm-icore-mx8mm-ctouch2.dtb \
|
||||
imx8mm-icore-mx8mm-edimm2.2.dtb \
|
||||
imx8mm-venice.dtb \
|
||||
imx8mm-venice-gw71xx-0x.dtb \
|
||||
imx8mm-venice-gw72xx-0x.dtb \
|
||||
|
@ -842,6 +845,7 @@ dtb-$(CONFIG_ARCH_IMX8M) += \
|
|||
imx8mm-verdin.dtb \
|
||||
phycore-imx8mm.dtb \
|
||||
imx8mn-ddr4-evk.dtb \
|
||||
imx8mq-cm.dtb \
|
||||
imx8mn-evk.dtb \
|
||||
imx8mq-evk.dtb \
|
||||
imx8mm-beacon-kit.dtb \
|
||||
|
@ -1083,6 +1087,8 @@ dtb-$(CONFIG_TARGET_DURIAN) += phytium-durian.dtb
|
|||
|
||||
dtb-$(CONFIG_TARGET_PRESIDIO_ASIC) += ca-presidio-engboard.dtb
|
||||
|
||||
dtb-$(CONFIG_TARGET_IMX8MM_CL_IOT_GATE) += imx8mm-cl-iot-gate.dtb
|
||||
|
||||
targets += $(dtb-y)
|
||||
|
||||
# Add any required device tree compiler flags here
|
||||
|
|
|
@ -35,3 +35,15 @@
|
|||
};
|
||||
};
|
||||
};
|
||||
|
||||
/*
|
||||
* This is not done in imx6q-ba16.dtsi, since that file is shared
|
||||
* with the kernel and the kernel should not reset the PHY, since
|
||||
* it lacks support for configuring the reserved registeres to
|
||||
* avoid a board specific voltage peak issue.
|
||||
*/
|
||||
&fec {
|
||||
phy-reset-gpios = <&gpio1 28 GPIO_ACTIVE_LOW>;
|
||||
phy-reset-duration = <1>;
|
||||
phy-reset-post-delay = <0>;
|
||||
};
|
||||
|
|
|
@ -120,7 +120,6 @@
|
|||
regulator-name = "5P0V";
|
||||
regulator-min-microvolt = <5000000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
};
|
||||
|
||||
|
|
17
arch/arm/dts/imx7-cm-u-boot.dtsi
Normal file
17
arch/arm/dts/imx7-cm-u-boot.dtsi
Normal file
|
@ -0,0 +1,17 @@
|
|||
/{
|
||||
aliases {
|
||||
mmc0 = &usdhc1;
|
||||
};
|
||||
};
|
||||
|
||||
&usdhc1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&i2c1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_i2c1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
432
arch/arm/dts/imx7-cm.dts
Normal file
432
arch/arm/dts/imx7-cm.dts
Normal file
|
@ -0,0 +1,432 @@
|
|||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
//
|
||||
// Copyright 2021 Ronetix GmbH
|
||||
|
||||
/dts-v1/;
|
||||
|
||||
#include "imx7d.dtsi"
|
||||
|
||||
/ {
|
||||
model = "Ronetix iMX7-CM Board";
|
||||
compatible = "ronetix,imx7-cm", "fsl,imx7d";
|
||||
|
||||
chosen {
|
||||
stdout-path = &uart1;
|
||||
};
|
||||
|
||||
/* DRAM size runtime extracted from the DDRC registers */
|
||||
memory@80000000 {
|
||||
device_type = "memory";
|
||||
reg = <0x80000000 0>;
|
||||
};
|
||||
|
||||
leds {
|
||||
compatible = "gpio-leds";
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_gpio_leds>;
|
||||
|
||||
led {
|
||||
label = "gpio-led";
|
||||
gpios = <&gpio2 7 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
};
|
||||
|
||||
reg_sd1_vmmc: regulator-sd1-vmmc {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "VDD_SD1";
|
||||
regulator-min-microvolt = <3300000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
gpio = <&gpio5 2 GPIO_ACTIVE_HIGH>;
|
||||
startup-delay-us = <200000>;
|
||||
off-on-delay-us = <20000>;
|
||||
enable-active-high;
|
||||
};
|
||||
|
||||
reg_usb_otg1_vbus: regulator-usb-otg1-vbus {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_usbotg1_pwr>;
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "usb_otg1_vbus";
|
||||
regulator-min-microvolt = <5000000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
gpio = <&gpio1 5 GPIO_ACTIVE_HIGH>;
|
||||
enable-active-high;
|
||||
};
|
||||
|
||||
reg_usb_otg2_vbus: regulator-usb-otg2-vbus {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_usbotg2_pwr>;
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "usb_otg2_vbus";
|
||||
regulator-min-microvolt = <5000000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
gpio = <&gpio1 7 GPIO_ACTIVE_HIGH>;
|
||||
enable-active-high;
|
||||
};
|
||||
};
|
||||
|
||||
&clks {
|
||||
assigned-clocks = <&clks IMX7D_CLKO2_ROOT_SRC>,
|
||||
<&clks IMX7D_CLKO2_ROOT_DIV>;
|
||||
assigned-clock-parents = <&clks IMX7D_CKIL>;
|
||||
assigned-clock-rates = <0>, <32768>;
|
||||
};
|
||||
|
||||
&fec1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_enet1>;
|
||||
phy-mode = "rgmii-id";
|
||||
phy-handle = <ðphy0>;
|
||||
fsl,magic-packet;
|
||||
status = "okay";
|
||||
|
||||
mdio {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
ethphy0: ethernet-phy@1 {
|
||||
compatible = "ethernet-phy-ieee802.3-c22";
|
||||
reg = <1>;
|
||||
reset-gpios = <&gpio2 4 GPIO_ACTIVE_LOW>;
|
||||
reset-assert-us = <10000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&qspi1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_qspi1_1>;
|
||||
status = "okay";
|
||||
ddrsmp=<0>;
|
||||
|
||||
flash0: mx25l25645g@0 {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
compatible = "jedec,spi-nor";
|
||||
spi-max-frequency = <29000000>;
|
||||
reg = <0>;
|
||||
};
|
||||
};
|
||||
|
||||
&i2c1 {
|
||||
clock-frequency = <100000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c1>;
|
||||
status = "okay";
|
||||
|
||||
pmic@8 {
|
||||
compatible = "fsl,pfuze3000";
|
||||
reg = <0x08>;
|
||||
|
||||
regulators {
|
||||
sw1a_reg: sw1a {
|
||||
regulator-min-microvolt = <700000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
regulator-ramp-delay = <6250>;
|
||||
};
|
||||
/* use sw1c_reg to align with pfuze100/pfuze200 */
|
||||
sw1c_reg: sw1b {
|
||||
regulator-min-microvolt = <700000>;
|
||||
regulator-max-microvolt = <1475000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
regulator-ramp-delay = <6250>;
|
||||
};
|
||||
|
||||
sw2_reg: sw2 {
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <1850000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
sw3a_reg: sw3 {
|
||||
regulator-min-microvolt = <900000>;
|
||||
regulator-max-microvolt = <1650000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
swbst_reg: swbst {
|
||||
regulator-min-microvolt = <5000000>;
|
||||
regulator-max-microvolt = <5150000>;
|
||||
};
|
||||
|
||||
snvs_reg: vsnvs {
|
||||
regulator-min-microvolt = <1000000>;
|
||||
regulator-max-microvolt = <3000000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
vref_reg: vrefddr {
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
vgen1_reg: vldo1 {
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
vgen2_reg: vldo2 {
|
||||
regulator-min-microvolt = <800000>;
|
||||
regulator-max-microvolt = <1550000>;
|
||||
};
|
||||
|
||||
vgen3_reg: vccsd {
|
||||
regulator-min-microvolt = <2850000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
vgen4_reg: v33 {
|
||||
regulator-min-microvolt = <2850000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
vgen5_reg: vldo3 {
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
vgen6_reg: vldo4 {
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c2>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&uart1 { /* console */
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_uart1>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbotg1 {
|
||||
vbus-supply = <®_usb_otg1_vbus>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbotg2 {
|
||||
vbus-supply = <®_usb_otg2_vbus>;
|
||||
dr_mode = "host";
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
/* SD card */
|
||||
&usdhc1 {
|
||||
pinctrl-names = "default", "state_100mhz", "state_200mhz";
|
||||
pinctrl-0 = <&pinctrl_usdhc1>, <&pinctrl_usdhc1_gpio>;
|
||||
pinctrl-1 = <&pinctrl_usdhc1_100mhz>, <&pinctrl_usdhc1_gpio>;
|
||||
pinctrl-2 = <&pinctrl_usdhc1_200mhz>, <&pinctrl_usdhc1_gpio>;
|
||||
cd-gpios = <&gpio5 0 GPIO_ACTIVE_HIGH>;
|
||||
bus-width = <4>;
|
||||
tuning-step = <2>;
|
||||
vmmc-supply = <®_sd1_vmmc>;
|
||||
wakeup-source;
|
||||
no-1-8-v;
|
||||
keep-power-in-suspend;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
/* eMMC */
|
||||
&usdhc3 {
|
||||
pinctrl-names = "default", "state_100mhz", "state_200mhz";
|
||||
pinctrl-0 = <&pinctrl_usdhc3>;
|
||||
pinctrl-1 = <&pinctrl_usdhc3_100mhz>;
|
||||
pinctrl-2 = <&pinctrl_usdhc3_200mhz>;
|
||||
assigned-clocks = <&clks IMX7D_USDHC3_ROOT_CLK>;
|
||||
assigned-clock-rates = <400000000>;
|
||||
bus-width = <8>;
|
||||
no-1-8-v;
|
||||
fsl,tuning-step = <2>;
|
||||
non-removable;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&wdog1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_wdog>;
|
||||
fsl,ext-reset-output;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
pinctrl_i2c1: i2c1grp {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_I2C1_SCL__I2C1_SCL 0x4000007f
|
||||
MX7D_PAD_I2C1_SDA__I2C1_SDA 0x4000007f
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_i2c2: i2c2grp {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_I2C2_SCL__I2C2_SCL 0x4000007f
|
||||
MX7D_PAD_I2C2_SDA__I2C2_SDA 0x4000007f
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_enet1: enet1grp {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_GPIO1_IO10__ENET1_MDIO 0x3
|
||||
MX7D_PAD_GPIO1_IO11__ENET1_MDC 0x3
|
||||
MX7D_PAD_ENET1_RGMII_TXC__ENET1_RGMII_TXC 0x1
|
||||
MX7D_PAD_ENET1_RGMII_TD0__ENET1_RGMII_TD0 0x1
|
||||
MX7D_PAD_ENET1_RGMII_TD1__ENET1_RGMII_TD1 0x1
|
||||
MX7D_PAD_ENET1_RGMII_TD2__ENET1_RGMII_TD2 0x1
|
||||
MX7D_PAD_ENET1_RGMII_TD3__ENET1_RGMII_TD3 0x1
|
||||
MX7D_PAD_ENET1_RGMII_TX_CTL__ENET1_RGMII_TX_CTL 0x1
|
||||
MX7D_PAD_ENET1_RGMII_RXC__ENET1_RGMII_RXC 0x1
|
||||
MX7D_PAD_ENET1_RGMII_RD0__ENET1_RGMII_RD0 0x1
|
||||
MX7D_PAD_ENET1_RGMII_RD1__ENET1_RGMII_RD1 0x1
|
||||
MX7D_PAD_ENET1_RGMII_RD2__ENET1_RGMII_RD2 0x1
|
||||
MX7D_PAD_ENET1_RGMII_RD3__ENET1_RGMII_RD3 0x1
|
||||
MX7D_PAD_ENET1_RGMII_RX_CTL__ENET1_RGMII_RX_CTL 0x1
|
||||
MX7D_PAD_EPDC_DATA04__GPIO2_IO4 0x14 /* ETH_RESET */
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_gpio_leds: gpioledsgrp {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_EPDC_DATA07__GPIO2_IO7 0x14
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_uart1: uart1grp {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_UART1_RX_DATA__UART1_DCE_RX 0x59
|
||||
MX7D_PAD_UART1_TX_DATA__UART1_DCE_TX 0x59
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usbotg1_pwr: usbotg_pwr {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_LPSR_GPIO1_IO05__GPIO1_IO5 0x14
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usbotg2_pwr: usbotg_pwr {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_LPSR_GPIO1_IO07__GPIO1_IO7 0x14
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc1_gpio: usdhc1_gpiogrp {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_SD1_CD_B__GPIO5_IO0 0x15 /* CD */
|
||||
MX7D_PAD_SD1_RESET_B__GPIO5_IO2 0x59 /* Vmmc */
|
||||
MX7D_PAD_GPIO1_IO08__SD1_VSELECT 0x59 /* VSELECT */
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc1: usdhc1grp {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_SD1_CMD__SD1_CMD 0x59
|
||||
MX7D_PAD_SD1_CLK__SD1_CLK 0x19
|
||||
MX7D_PAD_SD1_DATA0__SD1_DATA0 0x59
|
||||
MX7D_PAD_SD1_DATA1__SD1_DATA1 0x59
|
||||
MX7D_PAD_SD1_DATA2__SD1_DATA2 0x59
|
||||
MX7D_PAD_SD1_DATA3__SD1_DATA3 0x59
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc1_100mhz: usdhc1grp_100mhz {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_SD1_CMD__SD1_CMD 0x5a
|
||||
MX7D_PAD_SD1_CLK__SD1_CLK 0x1a
|
||||
MX7D_PAD_SD1_DATA0__SD1_DATA0 0x5a
|
||||
MX7D_PAD_SD1_DATA1__SD1_DATA1 0x5a
|
||||
MX7D_PAD_SD1_DATA2__SD1_DATA2 0x5a
|
||||
MX7D_PAD_SD1_DATA3__SD1_DATA3 0x5a
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc1_200mhz: usdhc1grp_200mhz {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_SD1_CMD__SD1_CMD 0x5b
|
||||
MX7D_PAD_SD1_CLK__SD1_CLK 0x1b
|
||||
MX7D_PAD_SD1_DATA0__SD1_DATA0 0x5b
|
||||
MX7D_PAD_SD1_DATA1__SD1_DATA1 0x5b
|
||||
MX7D_PAD_SD1_DATA2__SD1_DATA2 0x5b
|
||||
MX7D_PAD_SD1_DATA3__SD1_DATA3 0x5b
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc3: usdhc3grp {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_SD3_CMD__SD3_CMD 0x59
|
||||
MX7D_PAD_SD3_CLK__SD3_CLK 0x19
|
||||
MX7D_PAD_SD3_DATA0__SD3_DATA0 0x59
|
||||
MX7D_PAD_SD3_DATA1__SD3_DATA1 0x59
|
||||
MX7D_PAD_SD3_DATA2__SD3_DATA2 0x59
|
||||
MX7D_PAD_SD3_DATA3__SD3_DATA3 0x59
|
||||
MX7D_PAD_SD3_DATA4__SD3_DATA4 0x59
|
||||
MX7D_PAD_SD3_DATA5__SD3_DATA5 0x59
|
||||
MX7D_PAD_SD3_DATA6__SD3_DATA6 0x59
|
||||
MX7D_PAD_SD3_DATA7__SD3_DATA7 0x59
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc3_100mhz: usdhc3grp_100mhz {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_SD3_CMD__SD3_CMD 0x5a
|
||||
MX7D_PAD_SD3_CLK__SD3_CLK 0x1a
|
||||
MX7D_PAD_SD3_DATA0__SD3_DATA0 0x5a
|
||||
MX7D_PAD_SD3_DATA1__SD3_DATA1 0x5a
|
||||
MX7D_PAD_SD3_DATA2__SD3_DATA2 0x5a
|
||||
MX7D_PAD_SD3_DATA3__SD3_DATA3 0x5a
|
||||
MX7D_PAD_SD3_DATA4__SD3_DATA4 0x5a
|
||||
MX7D_PAD_SD3_DATA5__SD3_DATA5 0x5a
|
||||
MX7D_PAD_SD3_DATA6__SD3_DATA6 0x5a
|
||||
MX7D_PAD_SD3_DATA7__SD3_DATA7 0x5a
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc3_200mhz: usdhc3grp_200mhz {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_SD3_CMD__SD3_CMD 0x5b
|
||||
MX7D_PAD_SD3_CLK__SD3_CLK 0x1b
|
||||
MX7D_PAD_SD3_DATA0__SD3_DATA0 0x5b
|
||||
MX7D_PAD_SD3_DATA1__SD3_DATA1 0x5b
|
||||
MX7D_PAD_SD3_DATA2__SD3_DATA2 0x5b
|
||||
MX7D_PAD_SD3_DATA3__SD3_DATA3 0x5b
|
||||
MX7D_PAD_SD3_DATA4__SD3_DATA4 0x5b
|
||||
MX7D_PAD_SD3_DATA5__SD3_DATA5 0x5b
|
||||
MX7D_PAD_SD3_DATA6__SD3_DATA6 0x5b
|
||||
MX7D_PAD_SD3_DATA7__SD3_DATA7 0x5b
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_qspi1_1: qspi1grp_1 {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_EPDC_DATA00__QSPI_A_DATA0 0x51
|
||||
MX7D_PAD_EPDC_DATA01__QSPI_A_DATA1 0x51
|
||||
MX7D_PAD_EPDC_DATA02__QSPI_A_DATA2 0x51
|
||||
MX7D_PAD_EPDC_DATA03__QSPI_A_DATA3 0x51
|
||||
MX7D_PAD_EPDC_DATA05__QSPI_A_SCLK 0x51
|
||||
MX7D_PAD_EPDC_DATA06__QSPI_A_SS0_B 0x51
|
||||
>;
|
||||
};
|
||||
};
|
||||
|
||||
&iomuxc_lpsr {
|
||||
pinctrl_wdog: wdoggrp {
|
||||
fsl,pins = <
|
||||
MX7D_PAD_LPSR_GPIO1_IO00__WDOG1_WDOG_B 0x74
|
||||
>;
|
||||
};
|
||||
};
|
|
@ -3,6 +3,8 @@
|
|||
* Copyright 2020 Compass Electronics Group, LLC
|
||||
*/
|
||||
|
||||
#include "imx8mm-u-boot.dtsi"
|
||||
|
||||
/ {
|
||||
wdt-reboot {
|
||||
compatible = "wdt-reboot";
|
||||
|
@ -11,32 +13,6 @@
|
|||
};
|
||||
};
|
||||
|
||||
&{/soc@0} {
|
||||
u-boot,dm-pre-reloc;
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&aips1 {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&aips3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&clk {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
/delete-property/ assigned-clocks;
|
||||
/delete-property/ assigned-clock-parents;
|
||||
/delete-property/ assigned-clock-rates;
|
||||
};
|
||||
|
||||
®_usdhc2_vmmc {
|
||||
u-boot,off-on-delay-us = <20000>;
|
||||
};
|
||||
|
@ -65,15 +41,6 @@
|
|||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&osc_24m {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&pca6416_0 {
|
||||
compatible = "ti,tca6416";
|
||||
};
|
||||
|
|
255
arch/arm/dts/imx8mm-cl-iot-gate-u-boot.dtsi
Normal file
255
arch/arm/dts/imx8mm-cl-iot-gate-u-boot.dtsi
Normal file
|
@ -0,0 +1,255 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright 2019 NXP
|
||||
*/
|
||||
|
||||
/ {
|
||||
binman: binman {
|
||||
multiple-images;
|
||||
};
|
||||
|
||||
wdt-reboot {
|
||||
compatible = "wdt-reboot";
|
||||
wdt = <&wdog1>;
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
firmware {
|
||||
optee {
|
||||
compatible = "linaro,optee-tz";
|
||||
method = "smc";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&{/soc@0} {
|
||||
u-boot,dm-pre-reloc;
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&clk {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
/delete-property/ assigned-clocks;
|
||||
/delete-property/ assigned-clock-parents;
|
||||
/delete-property/ assigned-clock-rates;
|
||||
};
|
||||
|
||||
&osc_24m {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips1 {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&aips3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_uart3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_usdhc2_gpio {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_usdhc2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_usdhc3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&gpio1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&gpio2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&gpio3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&gpio4 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&gpio5 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&uart3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&usdhc1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&usdhc2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&usdhc3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&i2c1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&{/soc@0/bus@30800000/i2c@30a30000/pmic@4b} {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&{/soc@0/bus@30800000/i2c@30a30000/pmic@4b/regulators} {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_i2c2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_pmic {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&fec1 {
|
||||
phy-reset-gpios = <&gpio4 22 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
&wdog1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&binman {
|
||||
u-boot-spl-ddr {
|
||||
filename = "u-boot-spl-ddr.bin";
|
||||
pad-byte = <0xff>;
|
||||
align-size = <4>;
|
||||
align = <4>;
|
||||
|
||||
u-boot-spl {
|
||||
align-end = <4>;
|
||||
};
|
||||
|
||||
blob_1: blob-ext@1 {
|
||||
filename = "lpddr4_pmu_train_1d_imem.bin";
|
||||
size = <0x8000>;
|
||||
};
|
||||
|
||||
blob_2: blob-ext@2 {
|
||||
filename = "lpddr4_pmu_train_1d_dmem.bin";
|
||||
size = <0x4000>;
|
||||
};
|
||||
|
||||
blob_3: blob-ext@3 {
|
||||
filename = "lpddr4_pmu_train_2d_imem.bin";
|
||||
size = <0x8000>;
|
||||
};
|
||||
|
||||
blob_4: blob-ext@4 {
|
||||
filename = "lpddr4_pmu_train_2d_dmem.bin";
|
||||
size = <0x4000>;
|
||||
};
|
||||
};
|
||||
|
||||
flash {
|
||||
mkimage {
|
||||
args = "-n spl/u-boot-spl.cfgout -T imx8mimage -e 0x7e1000";
|
||||
|
||||
blob {
|
||||
filename = "u-boot-spl-ddr.bin";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
itb {
|
||||
filename = "u-boot.itb";
|
||||
|
||||
fit {
|
||||
description = "Configuration to load ATF before U-Boot";
|
||||
#address-cells = <1>;
|
||||
fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
|
||||
|
||||
images {
|
||||
uboot {
|
||||
description = "U-Boot (64-bit)";
|
||||
type = "standalone";
|
||||
arch = "arm64";
|
||||
compression = "none";
|
||||
load = <CONFIG_SYS_TEXT_BASE>;
|
||||
|
||||
uboot_blob: blob-ext {
|
||||
filename = "u-boot-nodtb.bin";
|
||||
};
|
||||
};
|
||||
|
||||
atf {
|
||||
description = "ARM Trusted Firmware";
|
||||
type = "firmware";
|
||||
arch = "arm64";
|
||||
compression = "none";
|
||||
load = <0x920000>;
|
||||
entry = <0x920000>;
|
||||
|
||||
atf_blob: blob-ext {
|
||||
filename = "bl31.bin";
|
||||
};
|
||||
};
|
||||
|
||||
fip {
|
||||
description = "Trusted Firmware FIP";
|
||||
type = "firmware";
|
||||
arch = "arm64";
|
||||
compression = "none";
|
||||
load = <0x40310000>;
|
||||
|
||||
fip_blob: blob-ext{
|
||||
filename = "fip.bin";
|
||||
};
|
||||
};
|
||||
|
||||
fdt {
|
||||
description = "NAME";
|
||||
type = "flat_dt";
|
||||
compression = "none";
|
||||
|
||||
uboot_fdt_blob: blob-ext {
|
||||
filename = "u-boot.dtb";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
configurations {
|
||||
default = "conf";
|
||||
|
||||
conf {
|
||||
description = "NAME";
|
||||
firmware = "uboot";
|
||||
loadables = "atf", "fip";
|
||||
fdt = "fdt";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
553
arch/arm/dts/imx8mm-cl-iot-gate.dts
Normal file
553
arch/arm/dts/imx8mm-cl-iot-gate.dts
Normal file
|
@ -0,0 +1,553 @@
|
|||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
/*
|
||||
* Copyright 2019 NXP
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
|
||||
#include <dt-bindings/usb/pd.h>
|
||||
#include "imx8mm.dtsi"
|
||||
|
||||
/ {
|
||||
model = "CompuLab IOT-GATE-iMX8";
|
||||
compatible = "sb-iotgimx8", "cpl,ucm-imx8m-mini", "fsl,imx8mm-evk", "fsl,imx8mm";
|
||||
|
||||
chosen {
|
||||
bootargs = "console=ttymxc2,115200 earlycon=ec_imx6q,0x30880000,115200";
|
||||
stdout-path = &uart3;
|
||||
};
|
||||
|
||||
reg_vusb_5v: regulator-usdhc2 {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "VUSB_5V";
|
||||
regulator-min-microvolt = <5000000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
gpio = <&gpio4 28 GPIO_ACTIVE_HIGH>;
|
||||
regulator-boot-on;
|
||||
enable-active-high;
|
||||
};
|
||||
|
||||
reg_usdhc2_vqmmc: regulator-usdhc2_1v8 {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "usdhc2_1v8";
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
reg_usdhc2_vmmc: regulator-usdhc2-vmmc {
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "VSD_3V3";
|
||||
regulator-min-microvolt = <3300000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
gpio = <&gpio2 19 GPIO_ACTIVE_HIGH>;
|
||||
enable-active-high;
|
||||
startup-delay-us = <100>;
|
||||
off-on-delay-us = <12000>;
|
||||
};
|
||||
};
|
||||
|
||||
&A53_0 {
|
||||
cpu-supply = <&buck2_reg>;
|
||||
};
|
||||
|
||||
&fec1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_fec1>;
|
||||
phy-mode = "rgmii-id";
|
||||
phy-handle = <ðphy0>;
|
||||
fsl,magic-packet;
|
||||
status = "okay";
|
||||
|
||||
mdio {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
ethphy0: ethernet-phy@0 {
|
||||
compatible = "ethernet-phy-ieee802.3-c22";
|
||||
reg = <0>;
|
||||
at803x,led-act-blind-workaround;
|
||||
at803x,eee-okay;
|
||||
at803x,vddio-1p8v;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c1 {
|
||||
clock-frequency = <400000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c1>;
|
||||
status = "okay";
|
||||
|
||||
eeprom@54 {
|
||||
compatible = "atmel,24c08";
|
||||
reg = <0x54>;
|
||||
pagesize = <16>;
|
||||
};
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
clock-frequency = <400000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c2>;
|
||||
status = "okay";
|
||||
|
||||
rtc@69 {
|
||||
compatible = "abracon,ab1805";
|
||||
reg = <0x69>;
|
||||
pagesize = <16>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
pmic@4b {
|
||||
compatible = "rohm,bd71837";
|
||||
reg = <0x4b>;
|
||||
pinctrl-0 = <&pinctrl_pmic>;
|
||||
gpio_intr = <&gpio1 3 GPIO_ACTIVE_LOW>;
|
||||
interrupt-parent = <&gpio1>;
|
||||
interrupts = <3 GPIO_ACTIVE_LOW>;
|
||||
|
||||
gpo {
|
||||
rohm,drv = <0x0C>; /* 0b0000_1100 all gpos with cmos output mode */
|
||||
};
|
||||
|
||||
regulators {
|
||||
bd71837,pmic-buck2-uses-i2c-dvs;
|
||||
bd71837,pmic-buck2-dvs-voltage = <1000000>,
|
||||
<900000>,
|
||||
<0>; /* VDD_ARM: Run-Idle */
|
||||
buck1_reg: BUCK1 {
|
||||
regulator-name = "BUCK1";
|
||||
regulator-min-microvolt = <700000>;
|
||||
regulator-max-microvolt = <1300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
regulator-ramp-delay = <1250>;
|
||||
};
|
||||
|
||||
buck2_reg: BUCK2 {
|
||||
regulator-name = "BUCK2";
|
||||
regulator-min-microvolt = <700000>;
|
||||
regulator-max-microvolt = <1300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
regulator-ramp-delay = <1250>;
|
||||
};
|
||||
|
||||
buck3_reg: BUCK3 {
|
||||
regulator-name = "BUCK3";
|
||||
regulator-min-microvolt = <700000>;
|
||||
regulator-max-microvolt = <1350000>;
|
||||
};
|
||||
|
||||
buck4_reg: BUCK4 {
|
||||
regulator-name = "BUCK4";
|
||||
regulator-min-microvolt = <700000>;
|
||||
regulator-max-microvolt = <1350000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
buck5_reg: BUCK5 {
|
||||
regulator-name = "BUCK5";
|
||||
regulator-min-microvolt = <700000>;
|
||||
regulator-max-microvolt = <1350000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
buck6_reg: BUCK6 {
|
||||
regulator-name = "BUCK6";
|
||||
regulator-min-microvolt = <3000000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
buck7_reg: BUCK7 {
|
||||
regulator-name = "BUCK7";
|
||||
regulator-min-microvolt = <1605000>;
|
||||
regulator-max-microvolt = <1995000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
buck8_reg: BUCK8 {
|
||||
regulator-name = "BUCK8";
|
||||
regulator-min-microvolt = <800000>;
|
||||
regulator-max-microvolt = <1400000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo1_reg: LDO1 {
|
||||
regulator-name = "LDO1";
|
||||
regulator-min-microvolt = <3000000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo2_reg: LDO2 {
|
||||
regulator-name = "LDO2";
|
||||
regulator-min-microvolt = <900000>;
|
||||
regulator-max-microvolt = <900000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo3_reg: LDO3 {
|
||||
regulator-name = "LDO3";
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo4_reg: LDO4 {
|
||||
regulator-name = "LDO4";
|
||||
regulator-min-microvolt = <900000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo5_reg: LDO5 {
|
||||
regulator-name = "LDO5";
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo6_reg: LDO6 {
|
||||
regulator-name = "LDO6";
|
||||
regulator-min-microvolt = <900000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo7_reg: LDO7 {
|
||||
regulator-name = "LDO7";
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
ptn5110: tcpc@50 {
|
||||
compatible = "nxp,ptn5110";
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_typec1>;
|
||||
reg = <0x50>;
|
||||
interrupt-parent = <&gpio2>;
|
||||
interrupts = <11 8>;
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
typec1_dr_sw: endpoint {
|
||||
remote-endpoint = <&usb1_drd_sw>;
|
||||
};
|
||||
};
|
||||
|
||||
typec1_con: connector {
|
||||
compatible = "usb-c-connector";
|
||||
label = "USB-C";
|
||||
power-role = "dual";
|
||||
data-role = "dual";
|
||||
try-power-role = "sink";
|
||||
source-pdos = <PDO_FIXED(5000, 3000, PDO_FIXED_USB_COMM)>;
|
||||
sink-pdos = <PDO_FIXED(5000, 3000, PDO_FIXED_USB_COMM)
|
||||
PDO_VAR(5000, 20000, 3000)>;
|
||||
op-sink-microwatt = <15000000>;
|
||||
self-powered;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c3 {
|
||||
clock-frequency = <400000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c3>;
|
||||
status = "disabled";
|
||||
};
|
||||
|
||||
&i2c4 {/* Expansion connector I2C */
|
||||
clock-frequency = <100000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c4>;
|
||||
status = "okay";
|
||||
|
||||
pca9555: gpio@22 {
|
||||
compatible = "nxp,pca9555";
|
||||
reg = <0x22>;
|
||||
gpio-controller;
|
||||
#gpio-cells = <2>;
|
||||
};
|
||||
};
|
||||
|
||||
&snvs_pwrkey {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&uart3 { /* console */
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_uart3>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usbotg1 {
|
||||
dr_mode = "host";
|
||||
hnp-disable;
|
||||
srp-disable;
|
||||
adp-disable;
|
||||
usb-role-switch;
|
||||
vbus-supply = <®_vusb_5v>;
|
||||
status = "okay";
|
||||
|
||||
port {
|
||||
usb1_drd_sw: endpoint {
|
||||
remote-endpoint = <&typec1_dr_sw>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&usbotg2 {
|
||||
dr_mode = "host";
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usdhc2 {
|
||||
pinctrl-names = "default", "state_100mhz", "state_200mhz";
|
||||
pinctrl-0 = <&pinctrl_usdhc2>, <&pinctrl_usdhc2_gpio>;
|
||||
pinctrl-1 = <&pinctrl_usdhc2_100mhz>, <&pinctrl_usdhc2_gpio>;
|
||||
pinctrl-2 = <&pinctrl_usdhc2_200mhz>, <&pinctrl_usdhc2_gpio>;
|
||||
cd-gpios = <&gpio2 12 GPIO_ACTIVE_LOW>;
|
||||
bus-width = <4>;
|
||||
fsl,wp-controller;
|
||||
vmmc-supply = <®_usdhc2_vmmc>;
|
||||
no-1-8-v;
|
||||
mmc-ddr-1_8v;
|
||||
non-removable;
|
||||
vqmmc-supply = <®_usdhc2_vqmmc>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usdhc3 {
|
||||
pinctrl-names = "default", "state_100mhz";
|
||||
pinctrl-0 = <&pinctrl_usdhc3>;
|
||||
pinctrl-1 = <&pinctrl_usdhc3_100mhz>;
|
||||
bus-width = <8>;
|
||||
non-removable;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&wdog1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_wdog>;
|
||||
fsl,ext-reset-output;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
pinctrl-names = "default";
|
||||
|
||||
pinctrl_hog: hoggrp {
|
||||
fsl,pins = <
|
||||
/* USB VBUS enable GPIO */
|
||||
MX8MM_IOMUXC_SAI3_RXFS_GPIO4_IO28 0x00
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_hog_1: hoggrp-1 {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_GPIO1_IO08_GPIO1_IO8 0x19
|
||||
MX8MM_IOMUXC_GPIO1_IO00_GPIO1_IO0 0x140
|
||||
MX8MM_IOMUXC_GPIO1_IO15_GPIO1_IO15 0x140
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_fec1: fec1grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_ENET_MDC_ENET1_MDC 0x3
|
||||
MX8MM_IOMUXC_ENET_MDIO_ENET1_MDIO 0x3
|
||||
MX8MM_IOMUXC_ENET_TD3_ENET1_RGMII_TD3 0x1f
|
||||
MX8MM_IOMUXC_ENET_TD2_ENET1_RGMII_TD2 0x1f
|
||||
MX8MM_IOMUXC_ENET_TD1_ENET1_RGMII_TD1 0x1f
|
||||
MX8MM_IOMUXC_ENET_TD0_ENET1_RGMII_TD0 0x1f
|
||||
MX8MM_IOMUXC_ENET_RD3_ENET1_RGMII_RD3 0x91
|
||||
MX8MM_IOMUXC_ENET_RD2_ENET1_RGMII_RD2 0x91
|
||||
MX8MM_IOMUXC_ENET_RD1_ENET1_RGMII_RD1 0x91
|
||||
MX8MM_IOMUXC_ENET_RD0_ENET1_RGMII_RD0 0x91
|
||||
MX8MM_IOMUXC_ENET_TXC_ENET1_RGMII_TXC 0x1f
|
||||
MX8MM_IOMUXC_ENET_RXC_ENET1_RGMII_RXC 0x91
|
||||
MX8MM_IOMUXC_ENET_RX_CTL_ENET1_RGMII_RX_CTL 0x91
|
||||
MX8MM_IOMUXC_ENET_TX_CTL_ENET1_RGMII_TX_CTL 0x1f
|
||||
MX8MM_IOMUXC_SAI2_RXC_GPIO4_IO22 0x19
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_flexspi0: flexspi0grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_NAND_ALE_QSPI_A_SCLK 0x1c4
|
||||
MX8MM_IOMUXC_NAND_CE0_B_QSPI_A_SS0_B 0x84
|
||||
MX8MM_IOMUXC_NAND_DATA00_QSPI_A_DATA0 0x84
|
||||
MX8MM_IOMUXC_NAND_DATA01_QSPI_A_DATA1 0x84
|
||||
MX8MM_IOMUXC_NAND_DATA02_QSPI_A_DATA2 0x84
|
||||
MX8MM_IOMUXC_NAND_DATA03_QSPI_A_DATA3 0x84
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_i2c1: i2c1grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_I2C1_SCL_I2C1_SCL 0x400001c3
|
||||
MX8MM_IOMUXC_I2C1_SDA_I2C1_SDA 0x400001c3
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_i2c2: i2c2grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_I2C2_SCL_I2C2_SCL 0x400001c3
|
||||
MX8MM_IOMUXC_I2C2_SDA_I2C2_SDA 0x400001c3
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_i2c3: i2c3grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_I2C3_SCL_I2C3_SCL 0x400001c3
|
||||
MX8MM_IOMUXC_I2C3_SDA_I2C3_SDA 0x400001c3
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_i2c4: i2c4grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_I2C4_SCL_I2C4_SCL 0x400001c3
|
||||
MX8MM_IOMUXC_I2C4_SDA_I2C4_SDA 0x400001c3
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_pmic: pmicirq {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_GPIO1_IO03_GPIO1_IO3 0x41
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_typec1: typec1grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_SD1_STROBE_GPIO2_IO11 0x159
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_uart3: uart1grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_UART3_RXD_UART3_DCE_RX 0x49
|
||||
MX8MM_IOMUXC_UART3_TXD_UART3_DCE_TX 0x49
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_uart4: uart4grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_ECSPI2_MISO_UART4_DCE_CTS_B 0x49
|
||||
MX8MM_IOMUXC_ECSPI2_MOSI_UART4_DCE_TX 0x49
|
||||
MX8MM_IOMUXC_ECSPI2_SS0_UART4_DCE_RTS_B 0x49
|
||||
MX8MM_IOMUXC_ECSPI2_SCLK_UART4_DCE_RX 0x49
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc2_gpio: usdhc2grpgpio {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_SD2_RESET_B_GPIO2_IO19 0x41
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc2: usdhc2grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_SD2_CLK_USDHC2_CLK 0x190
|
||||
MX8MM_IOMUXC_SD2_CMD_USDHC2_CMD 0x1d0
|
||||
MX8MM_IOMUXC_SD2_DATA0_USDHC2_DATA0 0x1d0
|
||||
MX8MM_IOMUXC_SD2_DATA1_USDHC2_DATA1 0x1d0
|
||||
MX8MM_IOMUXC_SD2_DATA2_USDHC2_DATA2 0x1d0
|
||||
MX8MM_IOMUXC_SD2_DATA3_USDHC2_DATA3 0x1d0
|
||||
MX8MM_IOMUXC_GPIO1_IO04_USDHC2_VSELECT 0x1d0
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc2_100mhz: usdhc2grp100mhz {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_SD2_CLK_USDHC2_CLK 0x194
|
||||
MX8MM_IOMUXC_SD2_CMD_USDHC2_CMD 0x1d4
|
||||
MX8MM_IOMUXC_SD2_DATA0_USDHC2_DATA0 0x1d4
|
||||
MX8MM_IOMUXC_SD2_DATA1_USDHC2_DATA1 0x1d4
|
||||
MX8MM_IOMUXC_SD2_DATA2_USDHC2_DATA2 0x1d4
|
||||
MX8MM_IOMUXC_SD2_DATA3_USDHC2_DATA3 0x1d4
|
||||
MX8MM_IOMUXC_GPIO1_IO04_USDHC2_VSELECT 0x1d0
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc2_200mhz: usdhc2grp200mhz {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_SD2_CLK_USDHC2_CLK 0x196
|
||||
MX8MM_IOMUXC_SD2_CMD_USDHC2_CMD 0x1d6
|
||||
MX8MM_IOMUXC_SD2_DATA0_USDHC2_DATA0 0x1d6
|
||||
MX8MM_IOMUXC_SD2_DATA1_USDHC2_DATA1 0x1d6
|
||||
MX8MM_IOMUXC_SD2_DATA2_USDHC2_DATA2 0x1d6
|
||||
MX8MM_IOMUXC_SD2_DATA3_USDHC2_DATA3 0x1d6
|
||||
MX8MM_IOMUXC_GPIO1_IO04_USDHC2_VSELECT 0x1d0
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc3: usdhc3grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_NAND_WE_B_USDHC3_CLK 0x40000190
|
||||
MX8MM_IOMUXC_NAND_WP_B_USDHC3_CMD 0x1d0
|
||||
MX8MM_IOMUXC_NAND_DATA04_USDHC3_DATA0 0x1d0
|
||||
MX8MM_IOMUXC_NAND_DATA05_USDHC3_DATA1 0x1d0
|
||||
MX8MM_IOMUXC_NAND_DATA06_USDHC3_DATA2 0x1d0
|
||||
MX8MM_IOMUXC_NAND_DATA07_USDHC3_DATA3 0x1d0
|
||||
MX8MM_IOMUXC_NAND_RE_B_USDHC3_DATA4 0x1d0
|
||||
MX8MM_IOMUXC_NAND_CE2_B_USDHC3_DATA5 0x1d0
|
||||
MX8MM_IOMUXC_NAND_CE3_B_USDHC3_DATA6 0x1d0
|
||||
MX8MM_IOMUXC_NAND_CLE_USDHC3_DATA7 0x1d0
|
||||
MX8MM_IOMUXC_NAND_CE1_B_USDHC3_STROBE 0x190
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc3_100mhz: usdhc3grp100mhz {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_NAND_WE_B_USDHC3_CLK 0x40000194
|
||||
MX8MM_IOMUXC_NAND_WP_B_USDHC3_CMD 0x1d4
|
||||
MX8MM_IOMUXC_NAND_DATA04_USDHC3_DATA0 0x1d4
|
||||
MX8MM_IOMUXC_NAND_DATA05_USDHC3_DATA1 0x1d4
|
||||
MX8MM_IOMUXC_NAND_DATA06_USDHC3_DATA2 0x1d4
|
||||
MX8MM_IOMUXC_NAND_DATA07_USDHC3_DATA3 0x1d4
|
||||
MX8MM_IOMUXC_NAND_RE_B_USDHC3_DATA4 0x1d4
|
||||
MX8MM_IOMUXC_NAND_CE2_B_USDHC3_DATA5 0x1d4
|
||||
MX8MM_IOMUXC_NAND_CE3_B_USDHC3_DATA6 0x1d4
|
||||
MX8MM_IOMUXC_NAND_CLE_USDHC3_DATA7 0x1d4
|
||||
MX8MM_IOMUXC_NAND_CE1_B_USDHC3_STROBE 0x194
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc3_200mhz: usdhc3grp200mhz {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_NAND_WE_B_USDHC3_CLK 0x40000196
|
||||
MX8MM_IOMUXC_NAND_WP_B_USDHC3_CMD 0x1d6
|
||||
MX8MM_IOMUXC_NAND_DATA04_USDHC3_DATA0 0x1d6
|
||||
MX8MM_IOMUXC_NAND_DATA05_USDHC3_DATA1 0x1d6
|
||||
MX8MM_IOMUXC_NAND_DATA06_USDHC3_DATA2 0x1d6
|
||||
MX8MM_IOMUXC_NAND_DATA07_USDHC3_DATA3 0x1d6
|
||||
MX8MM_IOMUXC_NAND_RE_B_USDHC3_DATA4 0x1d6
|
||||
MX8MM_IOMUXC_NAND_CE2_B_USDHC3_DATA5 0x1d6
|
||||
MX8MM_IOMUXC_NAND_CE3_B_USDHC3_DATA6 0x1d6
|
||||
MX8MM_IOMUXC_NAND_CLE_USDHC3_DATA7 0x1d6
|
||||
MX8MM_IOMUXC_NAND_CE1_B_USDHC3_STROBE 0x196
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_wdog: wdoggrp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_GPIO1_IO02_WDOG1_WDOG_B 0xc6
|
||||
>;
|
||||
};
|
||||
};
|
|
@ -3,6 +3,8 @@
|
|||
* Copyright 2019 NXP
|
||||
*/
|
||||
|
||||
#include "imx8mm-u-boot.dtsi"
|
||||
|
||||
/ {
|
||||
binman: binman {
|
||||
multiple-images;
|
||||
|
@ -22,41 +24,6 @@
|
|||
};
|
||||
};
|
||||
|
||||
&{/soc@0} {
|
||||
u-boot,dm-pre-reloc;
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&clk {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
/delete-property/ assigned-clocks;
|
||||
/delete-property/ assigned-clock-parents;
|
||||
/delete-property/ assigned-clock-rates;
|
||||
};
|
||||
|
||||
&osc_24m {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips1 {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&aips3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
®_usdhc2_vmmc {
|
||||
u-boot,off-on-delay-us = <20000>;
|
||||
};
|
||||
|
|
31
arch/arm/dts/imx8mm-icore-mx8mm-ctouch2-u-boot.dtsi
Normal file
31
arch/arm/dts/imx8mm-icore-mx8mm-ctouch2-u-boot.dtsi
Normal file
|
@ -0,0 +1,31 @@
|
|||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
/*
|
||||
* Copyright (c) 2020 Engicam srl
|
||||
* Copyright (c) 2020 Amarula Solutions(India)
|
||||
*/
|
||||
|
||||
#include "imx8mm-icore-mx8mm-u-boot.dtsi"
|
||||
|
||||
&gpio1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_uart2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_usdhc1_gpio {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_usdhc1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&uart2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&usdhc1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
97
arch/arm/dts/imx8mm-icore-mx8mm-ctouch2.dts
Normal file
97
arch/arm/dts/imx8mm-icore-mx8mm-ctouch2.dts
Normal file
|
@ -0,0 +1,97 @@
|
|||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
/*
|
||||
* Copyright (c) 2019 NXP
|
||||
* Copyright (c) 2019 Engicam srl
|
||||
* Copyright (c) 2020 Amarula Solutions(India)
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
#include "imx8mm.dtsi"
|
||||
#include "imx8mm-icore-mx8mm.dtsi"
|
||||
|
||||
/ {
|
||||
model = "Engicam i.Core MX8M Mini C.TOUCH 2.0";
|
||||
compatible = "engicam,icore-mx8mm-ctouch2", "engicam,icore-mx8mm",
|
||||
"fsl,imx8mm";
|
||||
|
||||
chosen {
|
||||
stdout-path = &uart2;
|
||||
};
|
||||
};
|
||||
|
||||
&fec1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
clock-frequency = <400000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c2>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&i2c4 {
|
||||
clock-frequency = <100000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c4>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
pinctrl_i2c2: i2c2grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_I2C2_SCL_I2C2_SCL 0x400001c3
|
||||
MX8MM_IOMUXC_I2C2_SDA_I2C2_SDA 0x400001c3
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_i2c4: i2c4grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_I2C4_SCL_I2C4_SCL 0x400001c3
|
||||
MX8MM_IOMUXC_I2C4_SDA_I2C4_SDA 0x400001c3
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_uart2: uart2grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_UART2_RXD_UART2_DCE_RX 0x140
|
||||
MX8MM_IOMUXC_UART2_TXD_UART2_DCE_TX 0x140
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc1_gpio: usdhc1gpiogrp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_GPIO1_IO06_GPIO1_IO6 0x41
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc1: usdhc1grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_SD1_CLK_USDHC1_CLK 0x190
|
||||
MX8MM_IOMUXC_SD1_CMD_USDHC1_CMD 0x1d0
|
||||
MX8MM_IOMUXC_SD1_DATA0_USDHC1_DATA0 0x1d0
|
||||
MX8MM_IOMUXC_SD1_DATA1_USDHC1_DATA1 0x1d0
|
||||
MX8MM_IOMUXC_SD1_DATA2_USDHC1_DATA2 0x1d0
|
||||
MX8MM_IOMUXC_SD1_DATA3_USDHC1_DATA3 0x1d0
|
||||
>;
|
||||
};
|
||||
};
|
||||
|
||||
&uart2 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_uart2>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
/* SD */
|
||||
&usdhc1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_usdhc1>, <&pinctrl_usdhc1_gpio>;
|
||||
cd-gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
|
||||
max-frequency = <50000000>;
|
||||
bus-width = <4>;
|
||||
no-1-8-v;
|
||||
pm-ignore-notify;
|
||||
keep-power-in-suspend;
|
||||
status = "okay";
|
||||
};
|
31
arch/arm/dts/imx8mm-icore-mx8mm-edimm2.2-u-boot.dtsi
Normal file
31
arch/arm/dts/imx8mm-icore-mx8mm-edimm2.2-u-boot.dtsi
Normal file
|
@ -0,0 +1,31 @@
|
|||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
/*
|
||||
* Copyright (c) 2020 Engicam srl
|
||||
* Copyright (c) 2020 Amarula Solutions(India)
|
||||
*/
|
||||
|
||||
#include "imx8mm-icore-mx8mm-u-boot.dtsi"
|
||||
|
||||
&gpio1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_uart2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_usdhc1_gpio {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_usdhc1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&uart2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&usdhc1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
97
arch/arm/dts/imx8mm-icore-mx8mm-edimm2.2.dts
Normal file
97
arch/arm/dts/imx8mm-icore-mx8mm-edimm2.2.dts
Normal file
|
@ -0,0 +1,97 @@
|
|||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
/*
|
||||
* Copyright (c) 2019 NXP
|
||||
* Copyright (c) 2019 Engicam srl
|
||||
* Copyright (c) 2020 Amarula Solutions(India)
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
#include "imx8mm.dtsi"
|
||||
#include "imx8mm-icore-mx8mm.dtsi"
|
||||
|
||||
/ {
|
||||
model = "Engicam i.Core MX8M Mini EDIMM2.2 Starter Kit";
|
||||
compatible = "engicam,icore-mx8mm-edimm2.2", "engicam,icore-mx8mm",
|
||||
"fsl,imx8mm";
|
||||
|
||||
chosen {
|
||||
stdout-path = &uart2;
|
||||
};
|
||||
};
|
||||
|
||||
&fec1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
clock-frequency = <400000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c2>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&i2c4 {
|
||||
clock-frequency = <100000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c4>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
pinctrl_i2c2: i2c2grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_I2C2_SCL_I2C2_SCL 0x400001c3
|
||||
MX8MM_IOMUXC_I2C2_SDA_I2C2_SDA 0x400001c3
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_i2c4: i2c4grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_I2C4_SCL_I2C4_SCL 0x400001c3
|
||||
MX8MM_IOMUXC_I2C4_SDA_I2C4_SDA 0x400001c3
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_uart2: uart2grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_UART2_RXD_UART2_DCE_RX 0x140
|
||||
MX8MM_IOMUXC_UART2_TXD_UART2_DCE_TX 0x140
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc1_gpio: usdhc1gpiogrp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_GPIO1_IO06_GPIO1_IO6 0x41
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc1: usdhc1grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_SD1_CLK_USDHC1_CLK 0x190
|
||||
MX8MM_IOMUXC_SD1_CMD_USDHC1_CMD 0x1d0
|
||||
MX8MM_IOMUXC_SD1_DATA0_USDHC1_DATA0 0x1d0
|
||||
MX8MM_IOMUXC_SD1_DATA1_USDHC1_DATA1 0x1d0
|
||||
MX8MM_IOMUXC_SD1_DATA2_USDHC1_DATA2 0x1d0
|
||||
MX8MM_IOMUXC_SD1_DATA3_USDHC1_DATA3 0x1d0
|
||||
>;
|
||||
};
|
||||
};
|
||||
|
||||
&uart2 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_uart2>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
/* SD */
|
||||
&usdhc1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_usdhc1>, <&pinctrl_usdhc1_gpio>;
|
||||
cd-gpios = <&gpio1 6 GPIO_ACTIVE_LOW>;
|
||||
max-frequency = <50000000>;
|
||||
bus-width = <4>;
|
||||
no-1-8-v;
|
||||
pm-ignore-notify;
|
||||
keep-power-in-suspend;
|
||||
status = "okay";
|
||||
};
|
27
arch/arm/dts/imx8mm-icore-mx8mm-u-boot.dtsi
Normal file
27
arch/arm/dts/imx8mm-icore-mx8mm-u-boot.dtsi
Normal file
|
@ -0,0 +1,27 @@
|
|||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
/*
|
||||
* Copyright (c) 2020 Engicam srl
|
||||
* Copyright (c) 2020 Amarula Solutions(India)
|
||||
*/
|
||||
|
||||
#include "imx8mm-u-boot.dtsi"
|
||||
|
||||
&iomuxc {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_usdhc3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_usdhc3_100mhz {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_usdhc3_200mhz {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&usdhc3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
232
arch/arm/dts/imx8mm-icore-mx8mm.dtsi
Normal file
232
arch/arm/dts/imx8mm-icore-mx8mm.dtsi
Normal file
|
@ -0,0 +1,232 @@
|
|||
// SPDX-License-Identifier: (GPL-2.0+ OR MIT)
|
||||
/*
|
||||
* Copyright (c) 2018 NXP
|
||||
* Copyright (c) 2019 Engicam srl
|
||||
* Copyright (c) 2020 Amarula Solutons(India)
|
||||
*/
|
||||
|
||||
/ {
|
||||
compatible = "engicam,icore-mx8mm", "fsl,imx8mm";
|
||||
};
|
||||
|
||||
&A53_0 {
|
||||
cpu-supply = <®_buck4>;
|
||||
};
|
||||
|
||||
&A53_1 {
|
||||
cpu-supply = <®_buck4>;
|
||||
};
|
||||
|
||||
&A53_2 {
|
||||
cpu-supply = <®_buck4>;
|
||||
};
|
||||
|
||||
&A53_3 {
|
||||
cpu-supply = <®_buck4>;
|
||||
};
|
||||
|
||||
&fec1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_fec1>;
|
||||
phy-mode = "rgmii-id";
|
||||
phy-handle = <ðphy>;
|
||||
|
||||
mdio {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
ethphy: ethernet-phy@3 {
|
||||
compatible = "ethernet-phy-ieee802.3-c22";
|
||||
reg = <3>;
|
||||
reset-gpios = <&gpio3 7 GPIO_ACTIVE_LOW>;
|
||||
reset-assert-us = <10000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c1 {
|
||||
clock-frequency = <400000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c1>;
|
||||
status = "okay";
|
||||
|
||||
pmic@8 {
|
||||
compatible = "nxp,pf8121a";
|
||||
reg = <0x08>;
|
||||
|
||||
regulators {
|
||||
reg_ldo1: ldo1 {
|
||||
regulator-min-microvolt = <1500000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
reg_ldo2: ldo2 {
|
||||
regulator-min-microvolt = <1500000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
reg_ldo3: ldo3 {
|
||||
regulator-min-microvolt = <1500000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
reg_ldo4: ldo4 {
|
||||
regulator-min-microvolt = <1500000>;
|
||||
regulator-max-microvolt = <5000000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
reg_buck1: buck1 {
|
||||
regulator-min-microvolt = <400000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
reg_buck2: buck2 {
|
||||
regulator-min-microvolt = <400000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
reg_buck3: buck3 {
|
||||
regulator-min-microvolt = <400000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
reg_buck4: buck4 {
|
||||
regulator-min-microvolt = <400000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
reg_buck5: buck5 {
|
||||
regulator-min-microvolt = <400000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
reg_buck6: buck6 {
|
||||
regulator-min-microvolt = <400000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
reg_buck7: buck7 {
|
||||
regulator-min-microvolt = <3300000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
reg_vsnvs: vsnvs {
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-always-on;
|
||||
regulator-boot-on;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
pinctrl_fec1: fec1grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_ENET_MDC_ENET1_MDC 0x3
|
||||
MX8MM_IOMUXC_ENET_MDIO_ENET1_MDIO 0x3
|
||||
MX8MM_IOMUXC_ENET_TD3_ENET1_RGMII_TD3 0x1f
|
||||
MX8MM_IOMUXC_ENET_TD2_ENET1_RGMII_TD2 0x1f
|
||||
MX8MM_IOMUXC_ENET_TD1_ENET1_RGMII_TD1 0x1f
|
||||
MX8MM_IOMUXC_ENET_TD0_ENET1_RGMII_TD0 0x1f
|
||||
MX8MM_IOMUXC_ENET_RD3_ENET1_RGMII_RD3 0x91
|
||||
MX8MM_IOMUXC_ENET_RD2_ENET1_RGMII_RD2 0x91
|
||||
MX8MM_IOMUXC_ENET_RD1_ENET1_RGMII_RD1 0x91
|
||||
MX8MM_IOMUXC_ENET_RD0_ENET1_RGMII_RD0 0x91
|
||||
MX8MM_IOMUXC_ENET_TXC_ENET1_RGMII_TXC 0x1f
|
||||
MX8MM_IOMUXC_ENET_RXC_ENET1_RGMII_RXC 0x91
|
||||
MX8MM_IOMUXC_ENET_RX_CTL_ENET1_RGMII_RX_CTL 0x91
|
||||
MX8MM_IOMUXC_ENET_TX_CTL_ENET1_RGMII_TX_CTL 0x1f
|
||||
MX8MM_IOMUXC_NAND_DATA01_GPIO3_IO7 0x19
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_i2c1: i2c1grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_I2C1_SCL_I2C1_SCL 0x400001c3
|
||||
MX8MM_IOMUXC_I2C1_SDA_I2C1_SDA 0x400001c3
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc3: usdhc3grp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_NAND_WE_B_USDHC3_CLK 0x190
|
||||
MX8MM_IOMUXC_NAND_WP_B_USDHC3_CMD 0x1d0
|
||||
MX8MM_IOMUXC_NAND_DATA04_USDHC3_DATA0 0x1d0
|
||||
MX8MM_IOMUXC_NAND_DATA05_USDHC3_DATA1 0x1d0
|
||||
MX8MM_IOMUXC_NAND_DATA06_USDHC3_DATA2 0x1d0
|
||||
MX8MM_IOMUXC_NAND_DATA06_USDHC3_DATA2 0x1d0
|
||||
MX8MM_IOMUXC_NAND_DATA07_USDHC3_DATA3 0x1d0
|
||||
MX8MM_IOMUXC_NAND_RE_B_USDHC3_DATA4 0x1d0
|
||||
MX8MM_IOMUXC_NAND_CE2_B_USDHC3_DATA5 0x1d0
|
||||
MX8MM_IOMUXC_NAND_CE3_B_USDHC3_DATA6 0x1d0
|
||||
MX8MM_IOMUXC_NAND_CLE_USDHC3_DATA7 0x1d0
|
||||
MX8MM_IOMUXC_NAND_CE1_B_USDHC3_STROBE 0x190
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc3_100mhz: usdhc3-100mhzgrp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_NAND_WE_B_USDHC3_CLK 0x194
|
||||
MX8MM_IOMUXC_NAND_WP_B_USDHC3_CMD 0x1d4
|
||||
MX8MM_IOMUXC_NAND_DATA04_USDHC3_DATA0 0x1d4
|
||||
MX8MM_IOMUXC_NAND_DATA05_USDHC3_DATA1 0x1d4
|
||||
MX8MM_IOMUXC_NAND_DATA06_USDHC3_DATA2 0x1d4
|
||||
MX8MM_IOMUXC_NAND_DATA07_USDHC3_DATA3 0x1d4
|
||||
MX8MM_IOMUXC_NAND_RE_B_USDHC3_DATA4 0x1d4
|
||||
MX8MM_IOMUXC_NAND_CE2_B_USDHC3_DATA5 0x1d4
|
||||
MX8MM_IOMUXC_NAND_CE3_B_USDHC3_DATA6 0x1d4
|
||||
MX8MM_IOMUXC_NAND_CLE_USDHC3_DATA7 0x1d4
|
||||
MX8MM_IOMUXC_NAND_CE1_B_USDHC3_STROBE 0x194
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc3_200mhz: usdhc3-200mhzgrp {
|
||||
fsl,pins = <
|
||||
MX8MM_IOMUXC_NAND_WE_B_USDHC3_CLK 0x196
|
||||
MX8MM_IOMUXC_NAND_WP_B_USDHC3_CMD 0x1d6
|
||||
MX8MM_IOMUXC_NAND_DATA04_USDHC3_DATA0 0x1d6
|
||||
MX8MM_IOMUXC_NAND_DATA05_USDHC3_DATA1 0x1d6
|
||||
MX8MM_IOMUXC_NAND_DATA06_USDHC3_DATA2 0x1d6
|
||||
MX8MM_IOMUXC_NAND_DATA07_USDHC3_DATA3 0x1d6
|
||||
MX8MM_IOMUXC_NAND_RE_B_USDHC3_DATA4 0x1d6
|
||||
MX8MM_IOMUXC_NAND_CE2_B_USDHC3_DATA5 0x1d6
|
||||
MX8MM_IOMUXC_NAND_CE3_B_USDHC3_DATA6 0x1d6
|
||||
MX8MM_IOMUXC_NAND_CLE_USDHC3_DATA7 0x1d6
|
||||
MX8MM_IOMUXC_NAND_CE1_B_USDHC3_STROBE 0x196
|
||||
>;
|
||||
};
|
||||
};
|
||||
|
||||
/* eMMC */
|
||||
&usdhc3 {
|
||||
pinctrl-names = "default", "state_100mhz", "state_200mhz";
|
||||
pinctrl-0 = <&pinctrl_usdhc3>;
|
||||
pinctrl-1 = <&pinctrl_usdhc3_100mhz>;
|
||||
pinctrl-2 = <&pinctrl_usdhc3_200mhz>;
|
||||
bus-width = <8>;
|
||||
non-removable;
|
||||
status = "okay";
|
||||
};
|
39
arch/arm/dts/imx8mm-u-boot.dtsi
Normal file
39
arch/arm/dts/imx8mm-u-boot.dtsi
Normal file
|
@ -0,0 +1,39 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright (C) 2020 Jagan Teki <jagan@amarulasolutions.com>
|
||||
*/
|
||||
|
||||
&{/soc@0} {
|
||||
u-boot,dm-pre-reloc;
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&aips1 {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&aips3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&clk {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
/delete-property/ assigned-clocks;
|
||||
/delete-property/ assigned-clock-parents;
|
||||
/delete-property/ assigned-clock-rates;
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&osc_24m {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
|
@ -3,40 +3,7 @@
|
|||
* Copyright 2021 Gateworks Corporation
|
||||
*/
|
||||
|
||||
&{/soc@0} {
|
||||
u-boot,dm-pre-reloc;
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&clk {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
/delete-property/ assigned-clocks;
|
||||
/delete-property/ assigned-clock-parents;
|
||||
/delete-property/ assigned-clock-rates;
|
||||
};
|
||||
|
||||
&osc_24m {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips1 {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&aips3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
#include "imx8mm-u-boot.dtsi"
|
||||
|
||||
&gpio1 {
|
||||
u-boot,dm-spl;
|
||||
|
|
|
@ -3,6 +3,8 @@
|
|||
* Copyright 2021 Gateworks Corporation
|
||||
*/
|
||||
|
||||
#include "imx8mm-u-boot.dtsi"
|
||||
|
||||
/ {
|
||||
wdt-reboot {
|
||||
compatible = "wdt-reboot";
|
||||
|
@ -11,41 +13,6 @@
|
|||
};
|
||||
};
|
||||
|
||||
&{/soc@0} {
|
||||
u-boot,dm-pre-reloc;
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&clk {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
/delete-property/ assigned-clocks;
|
||||
/delete-property/ assigned-clock-parents;
|
||||
/delete-property/ assigned-clock-rates;
|
||||
};
|
||||
|
||||
&osc_24m {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips1 {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&aips3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&gpio1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
|
|
@ -2,6 +2,9 @@
|
|||
/*
|
||||
* Copyright 2020 Toradex
|
||||
*/
|
||||
|
||||
#include "imx8mm-u-boot.dtsi"
|
||||
|
||||
/ {
|
||||
wdt-reboot {
|
||||
compatible = "wdt-reboot";
|
||||
|
@ -10,27 +13,6 @@
|
|||
};
|
||||
};
|
||||
|
||||
&aips1 {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&aips3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&clk {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
/delete-property/ assigned-clocks;
|
||||
/delete-property/ assigned-clock-parents;
|
||||
/delete-property/ assigned-clock-rates;
|
||||
};
|
||||
|
||||
&gpio1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
@ -55,15 +37,6 @@
|
|||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&osc_24m {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&pinctrl_i2c1 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
@ -84,11 +57,6 @@
|
|||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&{/soc@0} {
|
||||
u-boot,dm-pre-reloc;
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&{/soc@0/bus@30800000/i2c@30a20000/pmic} {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
|
111
arch/arm/dts/imx8mq-cm-u-boot.dtsi
Normal file
111
arch/arm/dts/imx8mq-cm-u-boot.dtsi
Normal file
|
@ -0,0 +1,111 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright 2019 NXP
|
||||
*/
|
||||
|
||||
/ {
|
||||
binman: binman {
|
||||
multiple-images;
|
||||
};
|
||||
};
|
||||
|
||||
&binman {
|
||||
u-boot-spl-ddr {
|
||||
filename = "u-boot-spl-ddr.bin";
|
||||
pad-byte = <0xff>;
|
||||
align-size = <4>;
|
||||
align = <4>;
|
||||
|
||||
u-boot-spl {
|
||||
align-end = <4>;
|
||||
};
|
||||
|
||||
blob_1: blob-ext@1 {
|
||||
filename = "lpddr4_pmu_train_1d_imem.bin";
|
||||
size = <0x8000>;
|
||||
};
|
||||
|
||||
blob_2: blob-ext@2 {
|
||||
filename = "lpddr4_pmu_train_1d_dmem.bin";
|
||||
size = <0x4000>;
|
||||
};
|
||||
|
||||
blob_3: blob-ext@3 {
|
||||
filename = "lpddr4_pmu_train_2d_imem.bin";
|
||||
size = <0x8000>;
|
||||
};
|
||||
|
||||
blob_4: blob-ext@4 {
|
||||
filename = "lpddr4_pmu_train_2d_dmem.bin";
|
||||
size = <0x4000>;
|
||||
};
|
||||
};
|
||||
|
||||
flash {
|
||||
mkimage {
|
||||
args = "-n spl/u-boot-spl.cfgout -T imx8mimage -e 0x7e1000";
|
||||
|
||||
blob {
|
||||
filename = "u-boot-spl-ddr.bin";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
itb {
|
||||
filename = "u-boot.itb";
|
||||
|
||||
fit {
|
||||
description = "Configuration to load ATF before U-Boot";
|
||||
#address-cells = <1>;
|
||||
fit,external-offset = <CONFIG_FIT_EXTERNAL_OFFSET>;
|
||||
|
||||
images {
|
||||
uboot {
|
||||
description = "U-Boot (64-bit)";
|
||||
type = "standalone";
|
||||
arch = "arm64";
|
||||
compression = "none";
|
||||
load = <CONFIG_SYS_TEXT_BASE>;
|
||||
|
||||
uboot_blob: blob-ext {
|
||||
filename = "u-boot-nodtb.bin";
|
||||
};
|
||||
};
|
||||
|
||||
atf {
|
||||
description = "ARM Trusted Firmware";
|
||||
type = "firmware";
|
||||
arch = "arm64";
|
||||
compression = "none";
|
||||
load = <0x910000>;
|
||||
entry = <0x910000>;
|
||||
|
||||
atf_blob: blob-ext {
|
||||
filename = "bl31.bin";
|
||||
};
|
||||
};
|
||||
|
||||
fdt {
|
||||
description = "NAME";
|
||||
type = "flat_dt";
|
||||
compression = "none";
|
||||
|
||||
uboot_fdt_blob: blob-ext {
|
||||
filename = "u-boot.dtb";
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
configurations {
|
||||
default = "conf";
|
||||
|
||||
conf {
|
||||
description = "NAME";
|
||||
firmware = "uboot";
|
||||
loadables = "atf";
|
||||
fdt = "fdt";
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
535
arch/arm/dts/imx8mq-cm.dts
Normal file
535
arch/arm/dts/imx8mq-cm.dts
Normal file
|
@ -0,0 +1,535 @@
|
|||
// SPDX-License-Identifier: (GPL-2.0 OR MIT)
|
||||
/*
|
||||
* Copyright 2017 NXP
|
||||
* Copyright (C) 2021 Ronetix, Ilko Iliev <iliev@ronetix.at>
|
||||
*/
|
||||
|
||||
/dts-v1/;
|
||||
|
||||
#include "imx8mq.dtsi"
|
||||
|
||||
/ {
|
||||
model = "Ronetix iMX8M-CM SoM";
|
||||
compatible = "ronetix,imx8mq-cm", "fsl,imx8mq";
|
||||
|
||||
chosen {
|
||||
stdout-path = &uart1;
|
||||
};
|
||||
|
||||
memory@40000000 {
|
||||
device_type = "memory";
|
||||
reg = <0x00000000 0x40000000 0 0x40000000>;
|
||||
};
|
||||
|
||||
pcie0_refclk: pcie0-refclk {
|
||||
compatible = "fixed-clock";
|
||||
#clock-cells = <0>;
|
||||
clock-frequency = <100000000>;
|
||||
};
|
||||
|
||||
pmic_osc: clock-pmic {
|
||||
compatible = "fixed-clock";
|
||||
#clock-cells = <0>;
|
||||
clock-frequency = <32768>;
|
||||
clock-output-names = "pmic_osc";
|
||||
};
|
||||
|
||||
osc_32k: clock-osc-32k {
|
||||
compatible = "fixed-clock";
|
||||
#clock-cells = <0>;
|
||||
clock-frequency = <32768>;
|
||||
clock-output-names = "osc_32k";
|
||||
};
|
||||
|
||||
reg_usdhc2_vmmc: regulator-vsd-3v3 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_reg_usdhc2>;
|
||||
compatible = "regulator-fixed";
|
||||
regulator-name = "VSD_3V3";
|
||||
regulator-min-microvolt = <3300000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
gpio = <&gpio2 19 GPIO_ACTIVE_HIGH>;
|
||||
enable-active-high;
|
||||
};
|
||||
};
|
||||
|
||||
&A53_0 {
|
||||
cpu-supply = <&buck2_reg>;
|
||||
};
|
||||
|
||||
&A53_1 {
|
||||
cpu-supply = <&buck2_reg>;
|
||||
};
|
||||
|
||||
&A53_2 {
|
||||
cpu-supply = <&buck2_reg>;
|
||||
};
|
||||
|
||||
&A53_3 {
|
||||
cpu-supply = <&buck2_reg>;
|
||||
};
|
||||
|
||||
&ddrc {
|
||||
operating-points-v2 = <&ddrc_opp_table>;
|
||||
|
||||
ddrc_opp_table: opp-table {
|
||||
compatible = "operating-points-v2";
|
||||
|
||||
opp-25M {
|
||||
opp-hz = /bits/ 64 <25000000>;
|
||||
};
|
||||
|
||||
opp-100M {
|
||||
opp-hz = /bits/ 64 <100000000>;
|
||||
};
|
||||
|
||||
/*
|
||||
* On imx8mq B0 PLL can't be bypassed so low bus is 166M
|
||||
*/
|
||||
opp-166M {
|
||||
opp-hz = /bits/ 64 <166935483>;
|
||||
};
|
||||
|
||||
opp-800M {
|
||||
opp-hz = /bits/ 64 <800000000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&dphy {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&fec1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_fec1>;
|
||||
phy-mode = "rgmii-id";
|
||||
phy-handle = <ðphy0>;
|
||||
fsl,magic-packet;
|
||||
status = "okay";
|
||||
|
||||
mdio {
|
||||
#address-cells = <1>;
|
||||
#size-cells = <0>;
|
||||
|
||||
ethphy0: ethernet-phy@0 {
|
||||
compatible = "ethernet-phy-ieee802.3-c22";
|
||||
reg = <0>;
|
||||
reset-gpios = <&gpio1 9 GPIO_ACTIVE_LOW>;
|
||||
reset-assert-us = <10000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&i2c1 {
|
||||
clock-frequency = <100000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c1>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&i2c2 {
|
||||
clock-frequency = <100000>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_i2c2>;
|
||||
status = "okay";
|
||||
|
||||
pmic@4b {
|
||||
compatible = "rohm,bd71837";
|
||||
reg = <0x4b>;
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_pmic>;
|
||||
interrupt-parent = <&gpio1>;
|
||||
interrupts = <3 IRQ_TYPE_LEVEL_LOW>;
|
||||
rohm,reset-snvs-powered;
|
||||
|
||||
#clock-cells = <0>;
|
||||
clocks = <&osc_32k 0>;
|
||||
clock-output-names = "clk-32k-out";
|
||||
|
||||
regulators {
|
||||
buck1_reg: BUCK1 {
|
||||
regulator-name = "buck1";
|
||||
regulator-min-microvolt = <700000>;
|
||||
regulator-max-microvolt = <1300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
regulator-ramp-delay = <1250>;
|
||||
};
|
||||
|
||||
buck2_reg: BUCK2 {
|
||||
regulator-name = "buck2";
|
||||
regulator-min-microvolt = <700000>;
|
||||
regulator-max-microvolt = <1300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
regulator-ramp-delay = <1250>;
|
||||
rohm,dvs-run-voltage = <1000000>;
|
||||
rohm,dvs-idle-voltage = <900000>;
|
||||
};
|
||||
|
||||
buck3_reg: BUCK3 {
|
||||
// BUCK5 in datasheet
|
||||
regulator-name = "buck3";
|
||||
regulator-min-microvolt = <700000>;
|
||||
regulator-max-microvolt = <1350000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
buck4_reg: BUCK4 {
|
||||
// BUCK6 in datasheet
|
||||
regulator-name = "buck4";
|
||||
regulator-min-microvolt = <3000000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
buck5_reg: BUCK5 {
|
||||
// BUCK7 in datasheet
|
||||
regulator-name = "buck5";
|
||||
regulator-min-microvolt = <1605000>;
|
||||
regulator-max-microvolt = <1995000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
buck6_reg: BUCK6 {
|
||||
// BUCK8 in datasheet
|
||||
regulator-name = "buck6";
|
||||
regulator-min-microvolt = <800000>;
|
||||
regulator-max-microvolt = <1400000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
buck7_reg: BUCK7 {
|
||||
regulator-name = "buck7";
|
||||
regulator-min-microvolt = <1605000>;
|
||||
regulator-max-microvolt = <1995000>;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
buck8_reg: BUCK8 {
|
||||
regulator-name = "buck8";
|
||||
regulator-min-microvolt = <800000>;
|
||||
regulator-max-microvolt = <1400000>;
|
||||
regulator-boot-on;
|
||||
};
|
||||
|
||||
ldo1_reg: LDO1 {
|
||||
regulator-name = "ldo1";
|
||||
regulator-min-microvolt = <1600000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo2_reg: LDO2 {
|
||||
regulator-name = "ldo2";
|
||||
regulator-min-microvolt = <800000>;
|
||||
regulator-max-microvolt = <900000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo3_reg: LDO3 {
|
||||
regulator-name = "ldo3";
|
||||
regulator-min-microvolt = <1800000>;
|
||||
regulator-max-microvolt = <3300000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo4_reg: LDO4 {
|
||||
regulator-name = "ldo4";
|
||||
regulator-min-microvolt = <900000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
|
||||
ldo6_reg: LDO6 {
|
||||
regulator-name = "ldo6";
|
||||
regulator-min-microvolt = <900000>;
|
||||
regulator-max-microvolt = <1800000>;
|
||||
regulator-boot-on;
|
||||
regulator-always-on;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
i2c_eeprom: i2c_eeprom@50 {
|
||||
compatible = "microchip,24lc512";
|
||||
reg = <0x50>;
|
||||
pagesize = <128>;
|
||||
};
|
||||
};
|
||||
|
||||
&lcdif {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&pcie0 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_pcie0>;
|
||||
reset-gpio = <&gpio5 28 GPIO_ACTIVE_LOW>;
|
||||
clocks = <&clk IMX8MQ_CLK_PCIE1_ROOT>,
|
||||
<&clk IMX8MQ_CLK_PCIE1_AUX>,
|
||||
<&clk IMX8MQ_CLK_PCIE1_PHY>,
|
||||
<&pcie0_refclk>;
|
||||
clock-names = "pcie", "pcie_aux", "pcie_phy", "pcie_bus";
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&pgc_gpu {
|
||||
power-supply = <&buck3_reg>;
|
||||
};
|
||||
|
||||
&qspi0 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_qspi>;
|
||||
status = "okay";
|
||||
|
||||
mx25l51245g: flash@0 {
|
||||
reg = <0>;
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
compatible = "jedec,spi-nor";
|
||||
spi-max-frequency = <29000000>;
|
||||
};
|
||||
};
|
||||
|
||||
&snvs_pwrkey {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&uart1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_uart1>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usb3_phy1 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usb_dwc3_1 {
|
||||
dr_mode = "host";
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usdhc1 {
|
||||
assigned-clocks = <&clk IMX8MQ_CLK_USDHC1>;
|
||||
assigned-clock-rates = <400000000>;
|
||||
pinctrl-names = "default", "state_100mhz", "state_200mhz";
|
||||
pinctrl-0 = <&pinctrl_usdhc1>;
|
||||
pinctrl-1 = <&pinctrl_usdhc1_100mhz>;
|
||||
pinctrl-2 = <&pinctrl_usdhc1_200mhz>;
|
||||
vqmmc-supply = <&buck7_reg>;
|
||||
bus-width = <8>;
|
||||
non-removable;
|
||||
no-sd;
|
||||
no-sdio;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usdhc2 {
|
||||
assigned-clocks = <&clk IMX8MQ_CLK_USDHC2>;
|
||||
assigned-clock-rates = <200000000>;
|
||||
pinctrl-names = "default", "state_100mhz", "state_200mhz";
|
||||
pinctrl-0 = <&pinctrl_usdhc2>, <&pinctrl_usdhc2_gpio>;
|
||||
pinctrl-1 = <&pinctrl_usdhc2_100mhz>, <&pinctrl_usdhc2_gpio>;
|
||||
pinctrl-2 = <&pinctrl_usdhc2_200mhz>, <&pinctrl_usdhc2_gpio>;
|
||||
cd-gpios = <&gpio2 12 GPIO_ACTIVE_HIGH>;
|
||||
vmmc-supply = <®_usdhc2_vmmc>;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&wdog1 {
|
||||
pinctrl-names = "default";
|
||||
pinctrl-0 = <&pinctrl_wdog>;
|
||||
fsl,ext-reset-output;
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
pinctrl_buck2: vddarmgrp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_GPIO1_IO13_GPIO1_IO13 0x19
|
||||
>;
|
||||
|
||||
};
|
||||
|
||||
pinctrl_fec1: fec1grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_ENET_MDC_ENET1_MDC 0x3
|
||||
MX8MQ_IOMUXC_ENET_MDIO_ENET1_MDIO 0x23
|
||||
MX8MQ_IOMUXC_ENET_TD3_ENET1_RGMII_TD3 0x1f
|
||||
MX8MQ_IOMUXC_ENET_TD2_ENET1_RGMII_TD2 0x1f
|
||||
MX8MQ_IOMUXC_ENET_TD1_ENET1_RGMII_TD1 0x1f
|
||||
MX8MQ_IOMUXC_ENET_TD0_ENET1_RGMII_TD0 0x1f
|
||||
MX8MQ_IOMUXC_ENET_RD3_ENET1_RGMII_RD3 0x91
|
||||
MX8MQ_IOMUXC_ENET_RD2_ENET1_RGMII_RD2 0x91
|
||||
MX8MQ_IOMUXC_ENET_RD1_ENET1_RGMII_RD1 0x91
|
||||
MX8MQ_IOMUXC_ENET_RD0_ENET1_RGMII_RD0 0x91
|
||||
MX8MQ_IOMUXC_ENET_TXC_ENET1_RGMII_TXC 0x1f
|
||||
MX8MQ_IOMUXC_ENET_RXC_ENET1_RGMII_RXC 0x91
|
||||
MX8MQ_IOMUXC_ENET_RX_CTL_ENET1_RGMII_RX_CTL 0x91
|
||||
MX8MQ_IOMUXC_ENET_TX_CTL_ENET1_RGMII_TX_CTL 0x1f
|
||||
MX8MQ_IOMUXC_GPIO1_IO09_GPIO1_IO9 0x19
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_i2c1: i2c1grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_I2C1_SCL_I2C1_SCL 0x4000007f
|
||||
MX8MQ_IOMUXC_I2C1_SDA_I2C1_SDA 0x4000007f
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_i2c2: i2c2grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_I2C2_SCL_I2C2_SCL 0x40000067
|
||||
MX8MQ_IOMUXC_I2C2_SDA_I2C2_SDA 0x40000067
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_pcie0: pcie0grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_I2C4_SCL_PCIE1_CLKREQ_B 0x76
|
||||
MX8MQ_IOMUXC_UART4_RXD_GPIO5_IO28 0x16
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_pmic: pmicgrp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_GPIO1_IO07_GPIO1_IO7 0x80 /* PMIC intr */
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_qspi: qspigrp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_NAND_ALE_QSPI_A_SCLK 0x82
|
||||
MX8MQ_IOMUXC_NAND_CE0_B_QSPI_A_SS0_B 0x82
|
||||
MX8MQ_IOMUXC_NAND_DATA00_QSPI_A_DATA0 0x82
|
||||
MX8MQ_IOMUXC_NAND_DATA01_QSPI_A_DATA1 0x82
|
||||
MX8MQ_IOMUXC_NAND_DATA02_QSPI_A_DATA2 0x82
|
||||
MX8MQ_IOMUXC_NAND_DATA03_QSPI_A_DATA3 0x82
|
||||
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_reg_usdhc2: regusdhc2gpiogrp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_SD2_RESET_B_GPIO2_IO19 0x41
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_uart1: uart1grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_UART1_RXD_UART1_DCE_RX 0x49
|
||||
MX8MQ_IOMUXC_UART1_TXD_UART1_DCE_TX 0x49
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc1: usdhc1grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_SD1_CLK_USDHC1_CLK 0x83
|
||||
MX8MQ_IOMUXC_SD1_CMD_USDHC1_CMD 0xc3
|
||||
MX8MQ_IOMUXC_SD1_DATA0_USDHC1_DATA0 0xc3
|
||||
MX8MQ_IOMUXC_SD1_DATA1_USDHC1_DATA1 0xc3
|
||||
MX8MQ_IOMUXC_SD1_DATA2_USDHC1_DATA2 0xc3
|
||||
MX8MQ_IOMUXC_SD1_DATA3_USDHC1_DATA3 0xc3
|
||||
MX8MQ_IOMUXC_SD1_DATA4_USDHC1_DATA4 0xc3
|
||||
MX8MQ_IOMUXC_SD1_DATA5_USDHC1_DATA5 0xc3
|
||||
MX8MQ_IOMUXC_SD1_DATA6_USDHC1_DATA6 0xc3
|
||||
MX8MQ_IOMUXC_SD1_DATA7_USDHC1_DATA7 0xc3
|
||||
MX8MQ_IOMUXC_SD1_STROBE_USDHC1_STROBE 0x83
|
||||
MX8MQ_IOMUXC_SD1_RESET_B_USDHC1_RESET_B 0xc1
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc1_100mhz: usdhc1-100grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_SD1_CLK_USDHC1_CLK 0x8d
|
||||
MX8MQ_IOMUXC_SD1_CMD_USDHC1_CMD 0xcd
|
||||
MX8MQ_IOMUXC_SD1_DATA0_USDHC1_DATA0 0xcd
|
||||
MX8MQ_IOMUXC_SD1_DATA1_USDHC1_DATA1 0xcd
|
||||
MX8MQ_IOMUXC_SD1_DATA2_USDHC1_DATA2 0xcd
|
||||
MX8MQ_IOMUXC_SD1_DATA3_USDHC1_DATA3 0xcd
|
||||
MX8MQ_IOMUXC_SD1_DATA4_USDHC1_DATA4 0xcd
|
||||
MX8MQ_IOMUXC_SD1_DATA5_USDHC1_DATA5 0xcd
|
||||
MX8MQ_IOMUXC_SD1_DATA6_USDHC1_DATA6 0xcd
|
||||
MX8MQ_IOMUXC_SD1_DATA7_USDHC1_DATA7 0xcd
|
||||
MX8MQ_IOMUXC_SD1_STROBE_USDHC1_STROBE 0x8d
|
||||
MX8MQ_IOMUXC_SD1_RESET_B_USDHC1_RESET_B 0xc1
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc1_200mhz: usdhc1-200grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_SD1_CLK_USDHC1_CLK 0x9f
|
||||
MX8MQ_IOMUXC_SD1_CMD_USDHC1_CMD 0xdf
|
||||
MX8MQ_IOMUXC_SD1_DATA0_USDHC1_DATA0 0xdf
|
||||
MX8MQ_IOMUXC_SD1_DATA1_USDHC1_DATA1 0xdf
|
||||
MX8MQ_IOMUXC_SD1_DATA2_USDHC1_DATA2 0xdf
|
||||
MX8MQ_IOMUXC_SD1_DATA3_USDHC1_DATA3 0xdf
|
||||
MX8MQ_IOMUXC_SD1_DATA4_USDHC1_DATA4 0xdf
|
||||
MX8MQ_IOMUXC_SD1_DATA5_USDHC1_DATA5 0xdf
|
||||
MX8MQ_IOMUXC_SD1_DATA6_USDHC1_DATA6 0xdf
|
||||
MX8MQ_IOMUXC_SD1_DATA7_USDHC1_DATA7 0xdf
|
||||
MX8MQ_IOMUXC_SD1_STROBE_USDHC1_STROBE 0x9f
|
||||
MX8MQ_IOMUXC_SD1_RESET_B_USDHC1_RESET_B 0xc1
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc2_gpio: usdhc2grpgpiogrp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_SD2_CD_B_GPIO2_IO12 0x41
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc2: usdhc2grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_SD2_CLK_USDHC2_CLK 0x83
|
||||
MX8MQ_IOMUXC_SD2_CMD_USDHC2_CMD 0xc3
|
||||
MX8MQ_IOMUXC_SD2_DATA0_USDHC2_DATA0 0xc3
|
||||
MX8MQ_IOMUXC_SD2_DATA1_USDHC2_DATA1 0xc3
|
||||
MX8MQ_IOMUXC_SD2_DATA2_USDHC2_DATA2 0xc3
|
||||
MX8MQ_IOMUXC_SD2_DATA3_USDHC2_DATA3 0xc3
|
||||
MX8MQ_IOMUXC_GPIO1_IO04_USDHC2_VSELECT 0xc1
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc2_100mhz: usdhc2-100grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_SD2_CLK_USDHC2_CLK 0x85
|
||||
MX8MQ_IOMUXC_SD2_CMD_USDHC2_CMD 0xc5
|
||||
MX8MQ_IOMUXC_SD2_DATA0_USDHC2_DATA0 0xc5
|
||||
MX8MQ_IOMUXC_SD2_DATA1_USDHC2_DATA1 0xc5
|
||||
MX8MQ_IOMUXC_SD2_DATA2_USDHC2_DATA2 0xc5
|
||||
MX8MQ_IOMUXC_SD2_DATA3_USDHC2_DATA3 0xc5
|
||||
MX8MQ_IOMUXC_GPIO1_IO04_USDHC2_VSELECT 0xc1
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_usdhc2_200mhz: usdhc2-200grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_SD2_CLK_USDHC2_CLK 0x87
|
||||
MX8MQ_IOMUXC_SD2_CMD_USDHC2_CMD 0xc7
|
||||
MX8MQ_IOMUXC_SD2_DATA0_USDHC2_DATA0 0xc7
|
||||
MX8MQ_IOMUXC_SD2_DATA1_USDHC2_DATA1 0xc7
|
||||
MX8MQ_IOMUXC_SD2_DATA2_USDHC2_DATA2 0xc7
|
||||
MX8MQ_IOMUXC_SD2_DATA3_USDHC2_DATA3 0xc7
|
||||
MX8MQ_IOMUXC_GPIO1_IO04_USDHC2_VSELECT 0xc1
|
||||
>;
|
||||
};
|
||||
|
||||
pinctrl_wdog: wdog1grp {
|
||||
fsl,pins = <
|
||||
MX8MQ_IOMUXC_GPIO1_IO02_WDOG1_WDOG_B 0xc6
|
||||
>;
|
||||
};
|
||||
};
|
|
@ -4,6 +4,8 @@
|
|||
* Author: Teresa Remmet <t.remmet@phytec.de>
|
||||
*/
|
||||
|
||||
#include "imx8mm-u-boot.dtsi"
|
||||
|
||||
/ {
|
||||
wdt-reboot {
|
||||
compatible = "wdt-reboot";
|
||||
|
@ -12,41 +14,6 @@
|
|||
};
|
||||
};
|
||||
|
||||
&{/soc@0} {
|
||||
u-boot,dm-pre-reloc;
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&clk {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
/delete-property/ assigned-clocks;
|
||||
/delete-property/ assigned-clock-parents;
|
||||
/delete-property/ assigned-clock-rates;
|
||||
};
|
||||
|
||||
&osc_24m {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips1 {
|
||||
u-boot,dm-spl;
|
||||
u-boot,dm-pre-reloc;
|
||||
};
|
||||
|
||||
&aips2 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&aips3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&iomuxc {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
||||
&pinctrl_uart3 {
|
||||
u-boot,dm-spl;
|
||||
};
|
||||
|
|
|
@ -28,6 +28,12 @@ choice
|
|||
prompt "NXP i.MX8M board select"
|
||||
optional
|
||||
|
||||
config TARGET_IMX8MQ_CM
|
||||
bool "Ronetix iMX8MQ-CM SoM"
|
||||
select BINMAN
|
||||
select IMX8MQ
|
||||
select IMX8M_LPDDR4
|
||||
|
||||
config TARGET_IMX8MQ_EVK
|
||||
bool "imx8mq_evk"
|
||||
select IMX8MQ
|
||||
|
@ -45,6 +51,24 @@ config TARGET_IMX8MM_EVK
|
|||
select SUPPORT_SPL
|
||||
select IMX8M_LPDDR4
|
||||
|
||||
config TARGET_IMX8MM_ICORE_MX8MM
|
||||
bool "Engicam i.Core MX8M Mini SOM"
|
||||
select IMX8MM
|
||||
select SUPPORT_SPL
|
||||
select IMX8M_LPDDR4
|
||||
help
|
||||
i.Core MX8M Mini is an EDIMM SOM based on NXP i.MX8MM.
|
||||
|
||||
i.Core MX8M Mini EDIMM2.2:
|
||||
* EDIMM2.2 is a Form Factor Capacitive Evaluation Board.
|
||||
* i.Core MX8M Mini needs to mount on top of EDIMM2.2 for
|
||||
creating complete i.Core MX8M Mini EDIMM2.2 Starter Kit.
|
||||
|
||||
i.Core MX8M Mini C.TOUCH 2.0
|
||||
* C.TOUCH 2.0 is a general purpose Carrier board.
|
||||
* i.Core MX8M Mini needs to mount on top of this Carrier board
|
||||
for creating complete i.Core MX8M Mini C.TOUCH 2.0 board.
|
||||
|
||||
config TARGET_IMX8MM_VENICE
|
||||
bool "Support Gateworks Venice iMX8M Mini module"
|
||||
select IMX8MM
|
||||
|
@ -106,19 +130,29 @@ config TARGET_PHYCORE_IMX8MP
|
|||
select IMX8MP
|
||||
select SUPPORT_SPL
|
||||
select IMX8M_LPDDR4
|
||||
|
||||
config TARGET_IMX8MM_CL_IOT_GATE
|
||||
bool "CompuLab iot-gate-imx8"
|
||||
select BINMAN
|
||||
select IMX8MM
|
||||
select SUPPORT_SPL
|
||||
select IMX8M_LPDDR4
|
||||
endchoice
|
||||
|
||||
source "board/beacon/imx8mm/Kconfig"
|
||||
source "board/beacon/imx8mn/Kconfig"
|
||||
source "board/compulab/imx8mm-cl-iot-gate/Kconfig"
|
||||
source "board/engicam/imx8mm/Kconfig"
|
||||
source "board/freescale/imx8mq_evk/Kconfig"
|
||||
source "board/freescale/imx8mm_evk/Kconfig"
|
||||
source "board/freescale/imx8mn_evk/Kconfig"
|
||||
source "board/freescale/imx8mp_evk/Kconfig"
|
||||
source "board/gateworks/venice/Kconfig"
|
||||
source "board/google/imx8mq_phanbell/Kconfig"
|
||||
source "board/technexion/pico-imx8mq/Kconfig"
|
||||
source "board/toradex/verdin-imx8mm/Kconfig"
|
||||
source "board/beacon/imx8mm/Kconfig"
|
||||
source "board/beacon/imx8mn/Kconfig"
|
||||
source "board/phytec/phycore_imx8mm/Kconfig"
|
||||
source "board/phytec/phycore_imx8mp/Kconfig"
|
||||
source "board/ronetix/imx8mq-cm/Kconfig"
|
||||
source "board/technexion/pico-imx8mq/Kconfig"
|
||||
source "board/toradex/verdin-imx8mm/Kconfig"
|
||||
|
||||
endif
|
||||
|
|
|
@ -16,7 +16,7 @@ if [ ! -f $BL31 ]; then
|
|||
exit 0
|
||||
else
|
||||
echo "$BL31 size: " >&2
|
||||
ls -lct $BL31 | awk '{print $5}' >&2
|
||||
stat -c %s $BL31 >&2
|
||||
fi
|
||||
|
||||
BL32="tee.bin"
|
||||
|
@ -26,7 +26,7 @@ if [ ! -f $BL32 ]; then
|
|||
else
|
||||
echo "Building with TEE support, make sure your $BL31 is compiled with spd. If you do not want tee, please delete $BL31" >&2
|
||||
echo "$BL32 size: " >&2
|
||||
ls -lct $BL32 | awk '{print $5}' >&2
|
||||
stat -c %s $BL32 >&2
|
||||
fi
|
||||
|
||||
BL33="u-boot-nodtb.bin"
|
||||
|
@ -36,13 +36,13 @@ if [ ! -f $BL33 ]; then
|
|||
exit 0
|
||||
else
|
||||
echo "u-boot-nodtb.bin size: " >&2
|
||||
ls -lct u-boot-nodtb.bin | awk '{print $5}' >&2
|
||||
stat -c %s u-boot-nodtb.bin >&2
|
||||
fi
|
||||
|
||||
for dtname in $*
|
||||
do
|
||||
echo "$dtname size: " >&2
|
||||
ls -lct $dtname | awk '{print $5}' >&2
|
||||
stat -c %s $dtname >&2
|
||||
done
|
||||
|
||||
|
||||
|
|
|
@ -35,6 +35,15 @@ config TARGET_CL_SOM_IMX7
|
|||
select SUPPORT_SPL
|
||||
imply CMD_DM
|
||||
|
||||
config TARGET_IMX7_CM
|
||||
bool "Ronetix iMX7-CM"
|
||||
select BOARD_LATE_INIT
|
||||
select DM
|
||||
select DM_THERMAL
|
||||
select MX7D
|
||||
select SUPPORT_SPL
|
||||
imply CMD_DM
|
||||
|
||||
config TARGET_MEERKAT96
|
||||
bool "NovTech Meerkat96 board"
|
||||
select BOARD_LATE_INIT
|
||||
|
@ -82,6 +91,7 @@ config SYS_SOC
|
|||
default "mx7"
|
||||
|
||||
source "board/compulab/cl-som-imx7/Kconfig"
|
||||
source "board/ronetix/imx7-cm/Kconfig"
|
||||
source "board/freescale/mx7dsabresd/Kconfig"
|
||||
source "board/novtech/meerkat96/Kconfig"
|
||||
source "board/technexion/pico-imx7d/Kconfig"
|
||||
|
|
12
board/compulab/imx8mm-cl-iot-gate/Kconfig
Normal file
12
board/compulab/imx8mm-cl-iot-gate/Kconfig
Normal file
|
@ -0,0 +1,12 @@
|
|||
if TARGET_IMX8MM_CL_IOT_GATE
|
||||
|
||||
config SYS_BOARD
|
||||
default "imx8mm-cl-iot-gate"
|
||||
|
||||
config SYS_VENDOR
|
||||
default "compulab"
|
||||
|
||||
config SYS_CONFIG_NAME
|
||||
default "imx8mm-cl-iot-gate"
|
||||
|
||||
endif
|
6
board/compulab/imx8mm-cl-iot-gate/MAINTAINERS
Normal file
6
board/compulab/imx8mm-cl-iot-gate/MAINTAINERS
Normal file
|
@ -0,0 +1,6 @@
|
|||
Compulab IOT-GATE-iMX8 BOARD
|
||||
M: Ying-Chun Liu (PaulLiu) <paul.liu@linaro.org>
|
||||
S: Maintained
|
||||
F: board/compulab/imx8mm-cl-iot-gate/
|
||||
F: include/configs/imx8mm-cl-iot-gate.h
|
||||
F: configs/imx8mm-cl-iot-gate_defconfig
|
13
board/compulab/imx8mm-cl-iot-gate/Makefile
Normal file
13
board/compulab/imx8mm-cl-iot-gate/Makefile
Normal file
|
@ -0,0 +1,13 @@
|
|||
#
|
||||
# Copyright 2018 NXP
|
||||
# Copyright 2020 Linaro
|
||||
#
|
||||
# SPDX-License-Identifier: GPL-2.0+
|
||||
#
|
||||
|
||||
obj-y += imx8mm-cl-iot-gate.o
|
||||
|
||||
ifdef CONFIG_SPL_BUILD
|
||||
obj-y += spl.o
|
||||
obj-y += ddr/
|
||||
endif
|
8
board/compulab/imx8mm-cl-iot-gate/ddr/Makefile
Normal file
8
board/compulab/imx8mm-cl-iot-gate/ddr/Makefile
Normal file
|
@ -0,0 +1,8 @@
|
|||
obj-y += ddr.o
|
||||
obj-y += lpddr4_timing_ff020008.o
|
||||
obj-y += lpddr4_timing_ff000110.o
|
||||
ifdef CONFIG_TARGET_MCM_IMX8M_MINI
|
||||
obj-y += lpddr4_timing_01061010.o
|
||||
else
|
||||
obj-y += lpddr4_timing_01061010.1_2.o
|
||||
endif
|
211
board/compulab/imx8mm-cl-iot-gate/ddr/ddr.c
Normal file
211
board/compulab/imx8mm-cl-iot-gate/ddr/ddr.c
Normal file
|
@ -0,0 +1,211 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright 2017 NXP
|
||||
* Copyright 2020 Linaro
|
||||
*
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <spl.h>
|
||||
#include <asm/io.h>
|
||||
#include <errno.h>
|
||||
#include <command.h>
|
||||
#include <asm/io.h>
|
||||
#include <asm/arch/lpddr4_define.h>
|
||||
#include <asm/mach-imx/iomux-v3.h>
|
||||
#include <asm/mach-imx/gpio.h>
|
||||
#include <asm-generic/gpio.h>
|
||||
#include <asm/arch/ddr.h>
|
||||
#include <asm/arch/imx8mq_pins.h>
|
||||
#include <asm/arch/sys_proto.h>
|
||||
#include <asm/arch/clock.h>
|
||||
#include <asm/mach-imx/gpio.h>
|
||||
#include "ddr.h"
|
||||
|
||||
static unsigned int lpddr4_mr_read(unsigned int mr_rank, unsigned int mr_addr)
|
||||
{
|
||||
unsigned int tmp;
|
||||
|
||||
reg32_write(DRC_PERF_MON_MRR0_DAT(0), 0x1);
|
||||
do {
|
||||
tmp = reg32_read(DDRC_MRSTAT(0));
|
||||
} while (tmp & 0x1);
|
||||
|
||||
reg32_write(DDRC_MRCTRL0(0), (mr_rank << 4) | 0x1);
|
||||
reg32_write(DDRC_MRCTRL1(0), (mr_addr << 8));
|
||||
reg32setbit(DDRC_MRCTRL0(0), 31);
|
||||
do {
|
||||
tmp = reg32_read(DRC_PERF_MON_MRR0_DAT(0));
|
||||
} while ((tmp & 0x8) == 0);
|
||||
tmp = reg32_read(DRC_PERF_MON_MRR1_DAT(0));
|
||||
reg32_write(DRC_PERF_MON_MRR0_DAT(0), 0x4);
|
||||
while (tmp) { //try to find a significant byte in the word
|
||||
if (tmp & 0xff) {
|
||||
tmp &= 0xff;
|
||||
break;
|
||||
}
|
||||
tmp >>= 8;
|
||||
}
|
||||
return tmp;
|
||||
}
|
||||
|
||||
struct lpddr4_desc {
|
||||
char name[16];
|
||||
unsigned int id;
|
||||
unsigned int size;
|
||||
unsigned int count;
|
||||
/* an optional field
|
||||
* use it if default is not the
|
||||
* 1-st array entry
|
||||
*/
|
||||
unsigned int _default;
|
||||
/* An optional field to distiguish DRAM chips that
|
||||
* have different geometry, though return the same MRR.
|
||||
* Default value 0xff
|
||||
*/
|
||||
u8 subind;
|
||||
struct dram_timing_info *timing;
|
||||
char *desc[4];
|
||||
};
|
||||
|
||||
#define DEFAULT (('D' << 24) + ('E' << 16) + ('F' << 8) + 'A')
|
||||
static const struct lpddr4_desc lpddr4_array[] = {
|
||||
{ .name = "Nanya", .id = 0x05000010, .subind = 0xff,
|
||||
.size = 2048, .count = 1, .timing = &ucm_dram_timing_01061010},
|
||||
{ .name = "Samsung", .id = 0x01061010, .subind = 0xff,
|
||||
.size = 2048, .count = 1, .timing = &ucm_dram_timing_01061010},
|
||||
{ .name = "Kingston", .id = 0xff000010, .subind = 0x04,
|
||||
.size = 4096, .count = 1, .timing = &ucm_dram_timing_ff000110},
|
||||
{ .name = "Kingston", .id = 0xff000010, .subind = 0x02,
|
||||
.size = 2048, .count = 1, .timing = &ucm_dram_timing_01061010},
|
||||
{ .name = "Micron", .id = 0xff020008, .subind = 0xff,
|
||||
.size = 2048, .count = 1, .timing = &ucm_dram_timing_ff020008},
|
||||
{ .name = "Micron", .id = 0xff000110, .subind = 0xff,
|
||||
.size = 4096, .count = 1, .timing = &ucm_dram_timing_ff000110},
|
||||
};
|
||||
|
||||
static unsigned int lpddr4_get_mr(void)
|
||||
{
|
||||
int i = 0, attempts = 5;
|
||||
unsigned int ddr_info = 0;
|
||||
unsigned int regs[] = { 5, 6, 7, 8 };
|
||||
|
||||
do {
|
||||
for (i = 0 ; i < ARRAY_SIZE(regs) ; i++) {
|
||||
unsigned int data = 0;
|
||||
|
||||
data = lpddr4_mr_read(0xF, regs[i]);
|
||||
ddr_info <<= 8;
|
||||
ddr_info += (data & 0xFF);
|
||||
}
|
||||
if (ddr_info != 0xFFFFFFFF && ddr_info != 0)
|
||||
break; // The attempt was successful
|
||||
} while (--attempts);
|
||||
return ddr_info;
|
||||
}
|
||||
|
||||
static void spl_tcm_init(struct lpddr4_tcm_desc *lpddr4_tcm_desc)
|
||||
{
|
||||
if (lpddr4_tcm_desc->sign == DEFAULT)
|
||||
return;
|
||||
|
||||
lpddr4_tcm_desc->sign = DEFAULT;
|
||||
lpddr4_tcm_desc->index = 0;
|
||||
}
|
||||
|
||||
static void spl_tcm_fini(struct lpddr4_tcm_desc *lpddr4_tcm_desc)
|
||||
{
|
||||
if (lpddr4_tcm_desc->sign != DEFAULT)
|
||||
return;
|
||||
|
||||
lpddr4_tcm_desc->sign = ~DEFAULT;
|
||||
lpddr4_tcm_desc->index = 0;
|
||||
}
|
||||
|
||||
#define SPL_TCM_DATA 0x7e0000
|
||||
#define SPL_TCM_INIT spl_tcm_init(lpddr4_tcm_desc)
|
||||
#define SPL_TCM_FINI spl_tcm_fini(lpddr4_tcm_desc)
|
||||
|
||||
void spl_dram_init_compulab(void)
|
||||
{
|
||||
unsigned int ddr_info = 0xdeadbeef;
|
||||
unsigned int ddr_info_mrr = 0xdeadbeef;
|
||||
unsigned int ddr_found = 0;
|
||||
int i = 0;
|
||||
|
||||
struct lpddr4_tcm_desc *lpddr4_tcm_desc =
|
||||
(struct lpddr4_tcm_desc *)SPL_TCM_DATA;
|
||||
|
||||
if (lpddr4_tcm_desc->sign != DEFAULT) {
|
||||
/* if not in tcm scan mode */
|
||||
for (i = 0; i < ARRAY_SIZE(lpddr4_array); i++) {
|
||||
if (lpddr4_array[i].id == ddr_info &&
|
||||
lpddr4_array[i].subind == 0xff) {
|
||||
ddr_found = 1;
|
||||
break;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
/* Walk trought all available ddr ids and apply
|
||||
* one by one. Save the index at the tcm memory that
|
||||
* persists after the reset.
|
||||
*/
|
||||
if (ddr_found == 0) {
|
||||
SPL_TCM_INIT;
|
||||
|
||||
if (lpddr4_tcm_desc->index < ARRAY_SIZE(lpddr4_array)) {
|
||||
printf("DDRINFO: Cfg attempt: [ %d/%lu ]\n",
|
||||
lpddr4_tcm_desc->index + 1,
|
||||
ARRAY_SIZE(lpddr4_array));
|
||||
i = lpddr4_tcm_desc->index;
|
||||
lpddr4_tcm_desc->index += 1;
|
||||
} else {
|
||||
/* Ran out all available ddr setings */
|
||||
printf("DDRINFO: Ran out all [ %lu ] cfg attempts. A non supported configuration.\n",
|
||||
ARRAY_SIZE(lpddr4_array));
|
||||
while (1)
|
||||
;
|
||||
}
|
||||
ddr_info = lpddr4_array[i].id;
|
||||
} else {
|
||||
printf("DDRINFO(%s): %s %dG\n", (ddr_found ? "D" : "?"),
|
||||
lpddr4_array[i].name,
|
||||
lpddr4_array[i].size);
|
||||
}
|
||||
|
||||
if (ddr_init(lpddr4_array[i].timing)) {
|
||||
SPL_TCM_INIT;
|
||||
do_reset(NULL, 0, 0, NULL);
|
||||
}
|
||||
|
||||
ddr_info_mrr = lpddr4_get_mr();
|
||||
if (ddr_info_mrr == 0xFFFFFFFF) {
|
||||
printf("DDRINFO(M): mr5-8 [ 0x%x ] is invalid; reset\n",
|
||||
ddr_info_mrr);
|
||||
SPL_TCM_INIT;
|
||||
do_reset(NULL, 0, 0, NULL);
|
||||
}
|
||||
|
||||
printf("DDRINFO(M): mr5-8 [ 0x%x ]\n", ddr_info_mrr);
|
||||
printf("DDRINFO(%s): mr5-8 [ 0x%x ]\n", (ddr_found ? "E" : "T"),
|
||||
ddr_info);
|
||||
|
||||
if (ddr_info_mrr != ddr_info) {
|
||||
SPL_TCM_INIT;
|
||||
do_reset(NULL, 0, 0, NULL);
|
||||
}
|
||||
|
||||
SPL_TCM_FINI;
|
||||
|
||||
/* Pass the dram size to th U-Boot through the tcm memory */
|
||||
{ /* To figure out what to store into the TCM buffer */
|
||||
/* For debug purpouse only. To override the real memsize */
|
||||
unsigned int ddr_tcm_size = 0;
|
||||
|
||||
if (ddr_tcm_size == 0 || ddr_tcm_size == -1)
|
||||
ddr_tcm_size = lpddr4_array[i].size;
|
||||
|
||||
lpddr4_tcm_desc->size = ddr_tcm_size;
|
||||
}
|
||||
}
|
26
board/compulab/imx8mm-cl-iot-gate/ddr/ddr.h
Normal file
26
board/compulab/imx8mm-cl-iot-gate/ddr/ddr.h
Normal file
|
@ -0,0 +1,26 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0+ */
|
||||
/*
|
||||
* Copyright 2017 NXP
|
||||
* Copyright 2020 Linaro
|
||||
*
|
||||
*/
|
||||
|
||||
#ifndef __COMPULAB_DDR_H__
|
||||
#define __COMPULAB_DDR_H__
|
||||
|
||||
extern struct dram_timing_info ucm_dram_timing_ff020008;
|
||||
extern struct dram_timing_info ucm_dram_timing_ff000110;
|
||||
extern struct dram_timing_info ucm_dram_timing_01061010;
|
||||
|
||||
void spl_dram_init_compulab(void);
|
||||
|
||||
#define TCM_DATA_CFG 0x7e0000
|
||||
|
||||
struct lpddr4_tcm_desc {
|
||||
unsigned int size;
|
||||
unsigned int sign;
|
||||
unsigned int index;
|
||||
unsigned int count;
|
||||
};
|
||||
|
||||
#endif
|
1848
board/compulab/imx8mm-cl-iot-gate/ddr/lpddr4_timing_01061010.1_2.c
Normal file
1848
board/compulab/imx8mm-cl-iot-gate/ddr/lpddr4_timing_01061010.1_2.c
Normal file
File diff suppressed because it is too large
Load diff
1847
board/compulab/imx8mm-cl-iot-gate/ddr/lpddr4_timing_01061010.c
Normal file
1847
board/compulab/imx8mm-cl-iot-gate/ddr/lpddr4_timing_01061010.c
Normal file
File diff suppressed because it is too large
Load diff
1847
board/compulab/imx8mm-cl-iot-gate/ddr/lpddr4_timing_ff000110.c
Normal file
1847
board/compulab/imx8mm-cl-iot-gate/ddr/lpddr4_timing_ff000110.c
Normal file
File diff suppressed because it is too large
Load diff
1847
board/compulab/imx8mm-cl-iot-gate/ddr/lpddr4_timing_ff020008.c
Normal file
1847
board/compulab/imx8mm-cl-iot-gate/ddr/lpddr4_timing_ff020008.c
Normal file
File diff suppressed because it is too large
Load diff
71
board/compulab/imx8mm-cl-iot-gate/imx8mm-cl-iot-gate.c
Normal file
71
board/compulab/imx8mm-cl-iot-gate/imx8mm-cl-iot-gate.c
Normal file
|
@ -0,0 +1,71 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright 2018 NXP
|
||||
* Copyright 2020 Linaro
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <env.h>
|
||||
#include <init.h>
|
||||
#include <miiphy.h>
|
||||
#include <netdev.h>
|
||||
|
||||
#include <asm/arch/clock.h>
|
||||
#include <asm/arch/sys_proto.h>
|
||||
#include <asm/io.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
static int setup_fec(void)
|
||||
{
|
||||
if (IS_ENABLED(CONFIG_FEC_MXC)) {
|
||||
struct iomuxc_gpr_base_regs *gpr =
|
||||
(struct iomuxc_gpr_base_regs *)IOMUXC_GPR_BASE_ADDR;
|
||||
|
||||
/* Use 125M anatop REF_CLK1 for ENET1, not from external */
|
||||
clrsetbits_le32(&gpr->gpr[1], 0x2000, 0);
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int board_phy_config(struct phy_device *phydev)
|
||||
{
|
||||
if (IS_ENABLED(CONFIG_FEC_MXC)) {
|
||||
/* enable rgmii rxc skew and phy mode select to RGMII copper */
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1d, 0x1f);
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1e, 0x8);
|
||||
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1d, 0x00);
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1e, 0x82ee);
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1d, 0x05);
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1e, 0x100);
|
||||
|
||||
if (phydev->drv->config)
|
||||
phydev->drv->config(phydev);
|
||||
}
|
||||
return 0;
|
||||
}
|
||||
|
||||
int board_init(void)
|
||||
{
|
||||
if (IS_ENABLED(CONFIG_FEC_MXC))
|
||||
setup_fec();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int board_mmc_get_env_dev(int devno)
|
||||
{
|
||||
return devno;
|
||||
}
|
||||
|
||||
int board_late_init(void)
|
||||
{
|
||||
if (IS_ENABLED(CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG)) {
|
||||
env_set("board_name", "IOT-GATE-IMX8");
|
||||
env_set("board_rev", "SBC-IOTMX8");
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
|
@ -0,0 +1,9 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0+ */
|
||||
/*
|
||||
* Copyright 2021 NXP
|
||||
*/
|
||||
|
||||
#define __ASSEMBLY__
|
||||
|
||||
BOOT_FROM sd
|
||||
LOADER mkimage.flash.mkimage 0x7E1000
|
187
board/compulab/imx8mm-cl-iot-gate/spl.c
Normal file
187
board/compulab/imx8mm-cl-iot-gate/spl.c
Normal file
|
@ -0,0 +1,187 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright 2019 NXP
|
||||
* Copyright 2020 Linaro
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <command.h>
|
||||
#include <cpu_func.h>
|
||||
#include <hang.h>
|
||||
#include <image.h>
|
||||
#include <init.h>
|
||||
#include <log.h>
|
||||
#include <spl.h>
|
||||
#include <asm/io.h>
|
||||
#include <asm/mach-imx/iomux-v3.h>
|
||||
#include <asm/arch/clock.h>
|
||||
#include <asm/arch/imx8mm_pins.h>
|
||||
#include <asm/arch/sys_proto.h>
|
||||
#include <asm/mach-imx/boot_mode.h>
|
||||
#include <asm/mach-imx/mxc_i2c.h>
|
||||
#include <asm/mach-imx/gpio.h>
|
||||
#include <asm/arch/ddr.h>
|
||||
|
||||
#include <dm/uclass.h>
|
||||
#include <dm/device.h>
|
||||
#include <dm/uclass-internal.h>
|
||||
#include <dm/device-internal.h>
|
||||
|
||||
#include <power/pmic.h>
|
||||
#include <power/bd71837.h>
|
||||
|
||||
#include "ddr/ddr.h"
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
int spl_board_boot_device(enum boot_device boot_dev_spl)
|
||||
{
|
||||
switch (boot_dev_spl) {
|
||||
case SD2_BOOT:
|
||||
case MMC2_BOOT:
|
||||
return BOOT_DEVICE_MMC1;
|
||||
case SD3_BOOT:
|
||||
case MMC3_BOOT:
|
||||
return BOOT_DEVICE_MMC2;
|
||||
default:
|
||||
return BOOT_DEVICE_NONE;
|
||||
}
|
||||
}
|
||||
|
||||
#define I2C_PAD_CTRL (PAD_CTL_DSE6 | PAD_CTL_HYS | PAD_CTL_PUE | PAD_CTL_PE)
|
||||
#define PC MUX_PAD_CTRL(I2C_PAD_CTRL)
|
||||
struct i2c_pads_info i2c_pad_info1 = {
|
||||
.scl = {
|
||||
.i2c_mode = IMX8MM_PAD_I2C2_SCL_I2C2_SCL | PC,
|
||||
.gpio_mode = IMX8MM_PAD_I2C2_SCL_GPIO5_IO16 | PC,
|
||||
.gp = IMX_GPIO_NR(5, 16),
|
||||
},
|
||||
.sda = {
|
||||
.i2c_mode = IMX8MM_PAD_I2C2_SDA_I2C2_SDA | PC,
|
||||
.gpio_mode = IMX8MM_PAD_I2C2_SDA_GPIO5_IO17 | PC,
|
||||
.gp = IMX_GPIO_NR(5, 17),
|
||||
},
|
||||
};
|
||||
|
||||
static void spl_dram_init(void)
|
||||
{
|
||||
spl_dram_init_compulab();
|
||||
}
|
||||
|
||||
void spl_board_init(void)
|
||||
{
|
||||
puts("Normal Boot\n");
|
||||
}
|
||||
|
||||
#ifdef CONFIG_SPL_LOAD_FIT
|
||||
int board_fit_config_name_match(const char *name)
|
||||
{
|
||||
/* Just empty function now - can't decide what to choose */
|
||||
debug("%s: %s\n", __func__, name);
|
||||
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
#define UART_PAD_CTRL (PAD_CTL_DSE6 | PAD_CTL_FSEL1)
|
||||
#define WDOG_PAD_CTRL (PAD_CTL_DSE6 | PAD_CTL_ODE | PAD_CTL_PUE | PAD_CTL_PE)
|
||||
|
||||
static iomux_v3_cfg_t const uart_pads[] = {
|
||||
IMX8MM_PAD_UART3_RXD_UART3_RX | MUX_PAD_CTRL(UART_PAD_CTRL),
|
||||
IMX8MM_PAD_UART3_TXD_UART3_TX | MUX_PAD_CTRL(UART_PAD_CTRL),
|
||||
};
|
||||
|
||||
static iomux_v3_cfg_t const wdog_pads[] = {
|
||||
IMX8MM_PAD_GPIO1_IO02_WDOG1_WDOG_B | MUX_PAD_CTRL(WDOG_PAD_CTRL),
|
||||
};
|
||||
|
||||
int board_early_init_f(void)
|
||||
{
|
||||
struct wdog_regs *wdog = (struct wdog_regs *)WDOG1_BASE_ADDR;
|
||||
|
||||
imx_iomux_v3_setup_multiple_pads(wdog_pads, ARRAY_SIZE(wdog_pads));
|
||||
|
||||
set_wdog_reset(wdog);
|
||||
|
||||
imx_iomux_v3_setup_multiple_pads(uart_pads, ARRAY_SIZE(uart_pads));
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int power_init_board(void)
|
||||
{
|
||||
struct udevice *dev;
|
||||
int ret;
|
||||
|
||||
ret = pmic_get("pmic@4b", &dev);
|
||||
if (ret == -ENODEV) {
|
||||
puts("No pmic\n");
|
||||
return 0;
|
||||
}
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
|
||||
/* decrease RESET key long push time from the default 10s to 10ms */
|
||||
pmic_reg_write(dev, BD718XX_PWRONCONFIG1, 0x0);
|
||||
|
||||
/* unlock the PMIC regs */
|
||||
pmic_reg_write(dev, BD718XX_REGLOCK, 0x1);
|
||||
|
||||
/* increase VDD_SOC to typical value 0.85v before first DRAM access */
|
||||
pmic_reg_write(dev, BD718XX_BUCK1_VOLT_RUN, 0x0f);
|
||||
|
||||
/* increase VDD_DRAM to 0.975v for 3Ghz DDR */
|
||||
pmic_reg_write(dev, BD718XX_1ST_NODVS_BUCK_VOLT, 0x83);
|
||||
|
||||
/* increase NVCC_DRAM_1V2 to 1.2v for DDR4 */
|
||||
pmic_reg_write(dev, BD718XX_4TH_NODVS_BUCK_VOLT, 0x28);
|
||||
|
||||
/* lock the PMIC regs */
|
||||
pmic_reg_write(dev, BD718XX_REGLOCK, 0x11);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void board_init_f(ulong dummy)
|
||||
{
|
||||
struct udevice *dev;
|
||||
int ret;
|
||||
|
||||
arch_cpu_init();
|
||||
|
||||
board_early_init_f();
|
||||
|
||||
init_uart_clk(2);
|
||||
|
||||
timer_init();
|
||||
|
||||
preloader_console_init();
|
||||
|
||||
/* Clear the BSS. */
|
||||
memset(__bss_start, 0, __bss_end - __bss_start);
|
||||
|
||||
ret = spl_early_init();
|
||||
if (ret) {
|
||||
debug("spl_early_init() failed: %d\n", ret);
|
||||
hang();
|
||||
}
|
||||
|
||||
ret = uclass_get_device_by_name(UCLASS_CLK,
|
||||
"clock-controller@30380000",
|
||||
&dev);
|
||||
if (ret < 0) {
|
||||
printf("Failed to find clock node. Check device tree\n");
|
||||
hang();
|
||||
}
|
||||
|
||||
enable_tzc380();
|
||||
|
||||
setup_i2c(1, CONFIG_SYS_I2C_SPEED, 0x7f, &i2c_pad_info1);
|
||||
|
||||
power_init_board();
|
||||
|
||||
/* DDR initialization */
|
||||
spl_dram_init();
|
||||
|
||||
board_init_r(NULL, 0);
|
||||
}
|
14
board/engicam/imx8mm/Kconfig
Normal file
14
board/engicam/imx8mm/Kconfig
Normal file
|
@ -0,0 +1,14 @@
|
|||
if TARGET_IMX8MM_ICORE_MX8MM
|
||||
|
||||
config SYS_BOARD
|
||||
default "imx8mm"
|
||||
|
||||
config SYS_VENDOR
|
||||
default "engicam"
|
||||
|
||||
config SYS_CONFIG_NAME
|
||||
default "imx8mm_icore_mx8mm"
|
||||
|
||||
source "board/freescale/common/Kconfig"
|
||||
|
||||
endif
|
13
board/engicam/imx8mm/MAINTAINERS
Normal file
13
board/engicam/imx8mm/MAINTAINERS
Normal file
|
@ -0,0 +1,13 @@
|
|||
i.Core-MX8M-Mini-CTOUCH2.0
|
||||
M: Jagan Teki <jagan@amarulasolutions.com>
|
||||
M: Matteo Lisi <matteo.lisi@engicam.com>
|
||||
S: Maintained
|
||||
F: configs/imx8mm-icore-mx8mm-ctouch2_defconfig
|
||||
|
||||
i.Core-MX8M-Mini-EDIMM2.2
|
||||
M: Jagan Teki <jagan@amarulasolutions.com>
|
||||
M: Matteo Lisi <matteo.lisi@engicam.com>
|
||||
S: Maintained
|
||||
F: board/engicam/imx8mm
|
||||
F: include/configs/imx8mm_icore_mx8mm.h
|
||||
F: configs/imx8mm-icore-mx8mm-edimm2.2_defconfig
|
12
board/engicam/imx8mm/Makefile
Normal file
12
board/engicam/imx8mm/Makefile
Normal file
|
@ -0,0 +1,12 @@
|
|||
#
|
||||
# Copyright (C) 2020 Amarula Solutions(India)
|
||||
#
|
||||
# SPDX-License-Identifier: GPL-2.0+
|
||||
#
|
||||
|
||||
obj-y += icore_mx8mm.o
|
||||
|
||||
ifdef CONFIG_SPL_BUILD
|
||||
obj-y += spl.o
|
||||
obj-y += lpddr4_timing.o
|
||||
endif
|
85
board/engicam/imx8mm/icore_mx8mm.c
Normal file
85
board/engicam/imx8mm/icore_mx8mm.c
Normal file
|
@ -0,0 +1,85 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright (C) 2016 Amarula Solutions B.V.
|
||||
* Copyright (C) 2016 Engicam S.r.l.
|
||||
* Author: Jagan Teki <jagan@amarulasolutions.com>
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <miiphy.h>
|
||||
#include <netdev.h>
|
||||
|
||||
#include <asm/io.h>
|
||||
#include <asm-generic/gpio.h>
|
||||
|
||||
#include <linux/delay.h>
|
||||
|
||||
#include <asm/arch/clock.h>
|
||||
#include <asm/arch/imx8mm_pins.h>
|
||||
#include <asm/arch/sys_proto.h>
|
||||
#include <asm/mach-imx/gpio.h>
|
||||
#include <asm/mach-imx/iomux-v3.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#if IS_ENABLED(CONFIG_FEC_MXC)
|
||||
|
||||
#define FEC_RST_PAD IMX_GPIO_NR(3, 7)
|
||||
static iomux_v3_cfg_t const fec1_rst_pads[] = {
|
||||
IMX8MM_PAD_NAND_DATA01_GPIO3_IO7 | MUX_PAD_CTRL(NO_PAD_CTRL),
|
||||
};
|
||||
|
||||
static void setup_iomux_fec(void)
|
||||
{
|
||||
imx_iomux_v3_setup_multiple_pads(fec1_rst_pads,
|
||||
ARRAY_SIZE(fec1_rst_pads));
|
||||
|
||||
gpio_request(FEC_RST_PAD, "fec1_rst");
|
||||
gpio_direction_output(FEC_RST_PAD, 0);
|
||||
udelay(500);
|
||||
gpio_direction_output(FEC_RST_PAD, 1);
|
||||
}
|
||||
|
||||
static int setup_fec(void)
|
||||
{
|
||||
struct iomuxc_gpr_base_regs *gpr =
|
||||
(struct iomuxc_gpr_base_regs *)IOMUXC_GPR_BASE_ADDR;
|
||||
|
||||
setup_iomux_fec();
|
||||
|
||||
/* Use 125M anatop REF_CLK1 for ENET1, not from external */
|
||||
clrsetbits_le32(&gpr->gpr[1], 13, 0);
|
||||
|
||||
return set_clk_enet(ENET_125MHZ);
|
||||
}
|
||||
|
||||
int board_phy_config(struct phy_device *phydev)
|
||||
{
|
||||
/* enable rgmii rxc skew and phy mode select to RGMII copper */
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1d, 0x1f);
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1e, 0x8);
|
||||
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1d, 0x00);
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1e, 0x82ee);
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1d, 0x05);
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1e, 0x100);
|
||||
|
||||
if (phydev->drv->config)
|
||||
phydev->drv->config(phydev);
|
||||
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
int board_init(void)
|
||||
{
|
||||
if (IS_ENABLED(CONFIG_FEC_MXC))
|
||||
setup_fec();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int board_mmc_get_env_dev(int devno)
|
||||
{
|
||||
return devno;
|
||||
}
|
1846
board/engicam/imx8mm/lpddr4_timing.c
Normal file
1846
board/engicam/imx8mm/lpddr4_timing.c
Normal file
File diff suppressed because it is too large
Load diff
101
board/engicam/imx8mm/spl.c
Normal file
101
board/engicam/imx8mm/spl.c
Normal file
|
@ -0,0 +1,101 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright (C) 2020 Engicam s.r.l.
|
||||
* Copyright (C) 2020 Amarula Solutions(India)
|
||||
* Author: Jagan Teki <jagan@amarulasolutions.com>
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <hang.h>
|
||||
#include <init.h>
|
||||
#include <log.h>
|
||||
#include <spl.h>
|
||||
#include <asm/mach-imx/iomux-v3.h>
|
||||
#include <asm/arch/clock.h>
|
||||
#include <asm/arch/imx8mm_pins.h>
|
||||
#include <asm/arch/sys_proto.h>
|
||||
#include <asm/mach-imx/boot_mode.h>
|
||||
#include <asm/arch/ddr.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
int spl_board_boot_device(enum boot_device boot_dev_spl)
|
||||
{
|
||||
switch (boot_dev_spl) {
|
||||
case SD1_BOOT:
|
||||
case SD2_BOOT:
|
||||
case MMC2_BOOT:
|
||||
return BOOT_DEVICE_MMC1;
|
||||
case SD3_BOOT:
|
||||
case MMC3_BOOT:
|
||||
return BOOT_DEVICE_MMC2;
|
||||
default:
|
||||
return BOOT_DEVICE_NONE;
|
||||
}
|
||||
}
|
||||
|
||||
static void spl_dram_init(void)
|
||||
{
|
||||
ddr_init(&dram_timing);
|
||||
}
|
||||
|
||||
void spl_board_init(void)
|
||||
{
|
||||
debug("Normal Boot\n");
|
||||
}
|
||||
|
||||
#ifdef CONFIG_SPL_LOAD_FIT
|
||||
int board_fit_config_name_match(const char *name)
|
||||
{
|
||||
/* Just empty function now - can't decide what to choose */
|
||||
debug("%s: %s\n", __func__, name);
|
||||
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
#define UART_PAD_CTRL (PAD_CTL_DSE6 | PAD_CTL_FSEL1)
|
||||
#define WDOG_PAD_CTRL (PAD_CTL_DSE6 | PAD_CTL_ODE | PAD_CTL_PUE | PAD_CTL_PE)
|
||||
|
||||
static iomux_v3_cfg_t const uart_pads[] = {
|
||||
IMX8MM_PAD_UART2_RXD_UART2_RX | MUX_PAD_CTRL(UART_PAD_CTRL),
|
||||
IMX8MM_PAD_UART2_TXD_UART2_TX | MUX_PAD_CTRL(UART_PAD_CTRL),
|
||||
};
|
||||
|
||||
int board_early_init_f(void)
|
||||
{
|
||||
imx_iomux_v3_setup_multiple_pads(uart_pads, ARRAY_SIZE(uart_pads));
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void board_init_f(ulong dummy)
|
||||
{
|
||||
int ret;
|
||||
|
||||
arch_cpu_init();
|
||||
|
||||
init_uart_clk(1);
|
||||
|
||||
board_early_init_f();
|
||||
|
||||
timer_init();
|
||||
|
||||
preloader_console_init();
|
||||
|
||||
/* Clear the BSS. */
|
||||
memset(__bss_start, 0, __bss_end - __bss_start);
|
||||
|
||||
ret = spl_early_init();
|
||||
if (ret) {
|
||||
debug("spl_early_init() failed: %d\n", ret);
|
||||
hang();
|
||||
}
|
||||
|
||||
enable_tzc380();
|
||||
|
||||
/* DDR initialization */
|
||||
spl_dram_init();
|
||||
|
||||
board_init_r(NULL, 0);
|
||||
}
|
|
@ -17,8 +17,12 @@ $ cd imx-atf/
|
|||
$ git checkout origin/imx_4.14.78_1.0.0_ga -b imx_4.14.78_1.0.0_ga
|
||||
$ make PLAT=imx8qm bl31
|
||||
|
||||
And copy the resulting bl31.bin to u-boot directory:
|
||||
|
||||
$ cp build/imx8qm/release/bl31.bin path/to/u-boot/
|
||||
|
||||
Get scfw_tcm.bin and ahab-container.img
|
||||
==============================
|
||||
=======================================
|
||||
|
||||
$ wget https://www.nxp.com/lgfiles/NMG/MAD/YOCTO/imx-sc-firmware-1.1.bin
|
||||
$ chmod +x imx-sc-firmware-1.1.bin
|
||||
|
@ -27,15 +31,11 @@ $ wget https://www.nxp.com/lgfiles/NMG/MAD/YOCTO/firmware-imx-8.0.bin
|
|||
$ chmod +x firmware-imx-8.0.bin
|
||||
$ ./firmware-imx-8.0.bin
|
||||
|
||||
Copy the following binaries to U-Boot folder:
|
||||
|
||||
$ cp imx-atf/build/imx8qm/release/bl31.bin .
|
||||
$ cp u-boot/u-boot.bin .
|
||||
And copy the following firmwares to U-Boot folder:
|
||||
|
||||
Copy the following firmwares U-Boot folder :
|
||||
|
||||
$ cp firmware-imx-7.6/firmware/seco/ahab-container.img .
|
||||
$ cp imx-sc-firmware-0.7/mx8qm-mek-scfw-tcm.bin .
|
||||
* `imx-sc-firmware-1.1/mx8qm-mek-scfw-tcm.bin`
|
||||
* `firmware-imx-8.0/firmware/seco/mx8qm-ahab-container.img`
|
||||
|
||||
Build U-Boot
|
||||
============
|
||||
|
@ -51,4 +51,4 @@ $ sudo dd if=flash.bin of=/dev/sd[x] bs=1024 seek=32
|
|||
|
||||
Boot
|
||||
====
|
||||
Set Boot switch SW2: 1100.
|
||||
Set Boot switch SW2: 001100.
|
||||
|
|
|
@ -42,6 +42,7 @@ read_eeprom(int bus, struct ventana_board_info *info)
|
|||
}
|
||||
|
||||
/* read eeprom config section */
|
||||
mdelay(10);
|
||||
if (gsc_i2c_read(GSC_EEPROM_ADDR, 0x00, 1, buf, sizeof(*info))) {
|
||||
puts("EEPROM: Failed to read EEPROM\n");
|
||||
return GW_UNKNOWN;
|
||||
|
|
|
@ -31,6 +31,7 @@
|
|||
#include <asm/arch/sys_proto.h>
|
||||
#include <power/regulator.h>
|
||||
#include <power/da9063_pmic.h>
|
||||
#include <power/pmic.h>
|
||||
#include <input.h>
|
||||
#include <pwm.h>
|
||||
#include <version.h>
|
||||
|
@ -432,6 +433,29 @@ static const struct boot_mode board_boot_modes[] = {
|
|||
};
|
||||
#endif
|
||||
|
||||
|
||||
/*
|
||||
* The SoM used by these boards has XTAL not connected despite datasheet
|
||||
* suggesting connecting unused XTAL pins to ground. Without explicitly
|
||||
* clearing the CRYSTAL bit the system runs unstable and sometimes reboots
|
||||
* unexpectedly.
|
||||
*/
|
||||
static void pmic_crystal_fix(void)
|
||||
{
|
||||
struct udevice *pmic;
|
||||
static const uint EN_32K_CRYSTAL = (1 << 3);
|
||||
|
||||
if (pmic_get("pmic@58", &pmic)) {
|
||||
puts("failed to get device for PMIC\n");
|
||||
return;
|
||||
}
|
||||
|
||||
if (pmic_clrsetbits(pmic, DA9063_REG_EN_32K, EN_32K_CRYSTAL, 0) < 0) {
|
||||
puts("failed to clear CRYSTAL bit\n");
|
||||
return;
|
||||
}
|
||||
}
|
||||
|
||||
void pmic_init(void)
|
||||
{
|
||||
struct udevice *reg;
|
||||
|
@ -445,6 +469,8 @@ void pmic_init(void)
|
|||
"bperi",
|
||||
};
|
||||
|
||||
pmic_crystal_fix();
|
||||
|
||||
for (i = 0; i < ARRAY_SIZE(bucks); i++) {
|
||||
ret = regulator_get_by_devname(bucks[i], ®);
|
||||
if (reg < 0) {
|
||||
|
|
15
board/ronetix/imx7-cm/Kconfig
Normal file
15
board/ronetix/imx7-cm/Kconfig
Normal file
|
@ -0,0 +1,15 @@
|
|||
if TARGET_IMX7_CM
|
||||
|
||||
config SYS_BOARD
|
||||
default "imx7-cm"
|
||||
|
||||
config SYS_VENDOR
|
||||
default "ronetix"
|
||||
|
||||
config SYS_SOC
|
||||
default "mx7"
|
||||
|
||||
config SYS_CONFIG_NAME
|
||||
default "imx7-cm"
|
||||
|
||||
endif
|
6
board/ronetix/imx7-cm/MAINTAINERS
Normal file
6
board/ronetix/imx7-cm/MAINTAINERS
Normal file
|
@ -0,0 +1,6 @@
|
|||
i.MX7-CM BOARD
|
||||
M: Ilko Iliev <iliev@ronetix.com>
|
||||
S: Maintained
|
||||
F: board/ronetix/imx7_cm/
|
||||
F: include/configs/imx7_cm.h
|
||||
F: configs/imx7_cm_defconfig
|
8
board/ronetix/imx7-cm/Makefile
Normal file
8
board/ronetix/imx7-cm/Makefile
Normal file
|
@ -0,0 +1,8 @@
|
|||
# SPDX-License-Identifier: GPL-2.0+
|
||||
# (C) Copyright 2017 NXP Semiconductors
|
||||
|
||||
ifdef CONFIG_SPL_BUILD
|
||||
obj-y += spl.o
|
||||
else
|
||||
obj-y += imx7-cm.o
|
||||
endif
|
11
board/ronetix/imx7-cm/README
Normal file
11
board/ronetix/imx7-cm/README
Normal file
|
@ -0,0 +1,11 @@
|
|||
U-Boot for the Ronetix i.MX7-CM board
|
||||
|
||||
Build U-Boot
|
||||
============
|
||||
$ make imx7_cm_defconfig
|
||||
$ make
|
||||
|
||||
Burn the images to a SD card
|
||||
============================
|
||||
$ sudo dd if=SPL of=/dev/sdX bs=1k seek=1; sync
|
||||
$ sudo dd if=u-boot-dtb.img of=/dev/sdX bs=1k seek=69; sync
|
98
board/ronetix/imx7-cm/imx7-cm.c
Normal file
98
board/ronetix/imx7-cm/imx7-cm.c
Normal file
|
@ -0,0 +1,98 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright (C) 2021 Ronetix GmbH
|
||||
*/
|
||||
|
||||
#include <init.h>
|
||||
#include <net.h>
|
||||
#include <asm/arch/clock.h>
|
||||
#include <asm/arch/crm_regs.h>
|
||||
#include <asm/arch/imx-regs.h>
|
||||
#include <asm/arch/mx7-pins.h>
|
||||
#include <asm/arch/sys_proto.h>
|
||||
#include <asm/global_data.h>
|
||||
#include <asm/gpio.h>
|
||||
#include <asm/mach-imx/iomux-v3.h>
|
||||
#include <asm/mach-imx/mxc_i2c.h>
|
||||
#include <asm/io.h>
|
||||
#include <common.h>
|
||||
#include <i2c.h>
|
||||
#include <miiphy.h>
|
||||
#include <power/pmic.h>
|
||||
#include <power/pfuze3000_pmic.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
int dram_init(void)
|
||||
{
|
||||
gd->ram_size = imx_ddr_size();
|
||||
return 0;
|
||||
}
|
||||
|
||||
int power_init_board(void)
|
||||
{
|
||||
struct udevice *dev;
|
||||
int ret;
|
||||
unsigned int reg, rev;
|
||||
|
||||
ret = pmic_get("pmic@8", &dev);
|
||||
if (ret == -ENODEV) {
|
||||
puts("No pmic\n");
|
||||
return 0;
|
||||
}
|
||||
if (ret != 0)
|
||||
return ret;
|
||||
|
||||
reg = pmic_reg_read(dev, PFUZE3000_DEVICEID);
|
||||
rev = pmic_reg_read(dev, PFUZE3000_REVID);
|
||||
printf("PMIC: PFUZE3000 DEV_ID=0x%x REV_ID=0x%x\n", reg, rev);
|
||||
|
||||
/* disable Low Power Mode during standby mode */
|
||||
reg = pmic_reg_read(dev, PFUZE3000_LDOGCTL);
|
||||
reg |= 0x1;
|
||||
pmic_reg_write(dev, PFUZE3000_LDOGCTL, reg);
|
||||
|
||||
/* SW1A/1B mode set to APS/APS */
|
||||
reg = 0x8;
|
||||
pmic_reg_write(dev, PFUZE3000_SW1AMODE, reg);
|
||||
pmic_reg_write(dev, PFUZE3000_SW1BMODE, reg);
|
||||
|
||||
/* SW1A/1B standby voltage set to 1.025V */
|
||||
reg = 0xd;
|
||||
pmic_reg_write(dev, PFUZE3000_SW1ASTBY, reg);
|
||||
pmic_reg_write(dev, PFUZE3000_SW1BSTBY, reg);
|
||||
|
||||
/* decrease SW1B normal voltage to 0.975V */
|
||||
reg = pmic_reg_read(dev, PFUZE3000_SW1BVOLT);
|
||||
reg &= ~0x1f;
|
||||
reg |= PFUZE3000_SW1AB_SETP(975);
|
||||
pmic_reg_write(dev, PFUZE3000_SW1BVOLT, reg);
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int setup_fec(void)
|
||||
{
|
||||
return set_clk_enet(ENET_125MHZ);
|
||||
}
|
||||
|
||||
int board_init(void)
|
||||
{
|
||||
/* address of boot parameters */
|
||||
gd->bd->bi_boot_params = PHYS_SDRAM + 0x100;
|
||||
|
||||
setup_fec();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int board_late_init(void)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
|
||||
int checkboard(void)
|
||||
{
|
||||
puts("Board: iMX7-CM\n");
|
||||
return 0;
|
||||
}
|
156
board/ronetix/imx7-cm/spl.c
Normal file
156
board/ronetix/imx7-cm/spl.c
Normal file
|
@ -0,0 +1,156 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright (C) 2021 Ronetix GmbH
|
||||
*
|
||||
* Author: Ilko Iliev <iliev@ronetix.at>
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <cpu_func.h>
|
||||
#include <init.h>
|
||||
#include <asm/arch/clock.h>
|
||||
#include <asm/arch/imx-regs.h>
|
||||
#include <asm/arch/crm_regs.h>
|
||||
#include <asm/arch/mx7-pins.h>
|
||||
#include <asm/arch/sys_proto.h>
|
||||
#include <asm/arch-mx7/mx7-ddr.h>
|
||||
#include <asm/mach-imx/iomux-v3.h>
|
||||
#include <asm/gpio.h>
|
||||
#include <fsl_esdhc_imx.h>
|
||||
#include <spl.h>
|
||||
|
||||
static struct ddrc ddrc_regs_val = {
|
||||
.mstr = 0x01040001,
|
||||
.rfshtmg = 0x00400046,
|
||||
.init1 = 0x00690000,
|
||||
.init0 = 0x00020083,
|
||||
.init3 = 0x09300004,
|
||||
.init4 = 0x04080000,
|
||||
.init5 = 0x00100004,
|
||||
.rankctl = 0x0000033F,
|
||||
.dramtmg0 = 0x09081109,
|
||||
.dramtmg1 = 0x0007020d,
|
||||
.dramtmg2 = 0x03040407,
|
||||
.dramtmg3 = 0x00002006,
|
||||
.dramtmg4 = 0x04020205,
|
||||
.dramtmg5 = 0x03030202,
|
||||
.dramtmg8 = 0x00000803,
|
||||
.zqctl0 = 0x00800020,
|
||||
.dfitmg0 = 0x02098204,
|
||||
.dfitmg1 = 0x00030303,
|
||||
.dfiupd0 = 0x80400003,
|
||||
.dfiupd1 = 0x00100020,
|
||||
.dfiupd2 = 0x80100004,
|
||||
.addrmap4 = 0x00000F0F,
|
||||
.odtcfg = 0x06000604,
|
||||
.odtmap = 0x00000001,
|
||||
.rfshtmg = 0x00400046,
|
||||
.dramtmg0 = 0x09081109,
|
||||
.addrmap0 = 0x0000001f,
|
||||
.addrmap1 = 0x00080808,
|
||||
.addrmap4 = 0x00000f0f,
|
||||
.addrmap5 = 0x07070707,
|
||||
.addrmap6 = 0x0f0f0707,
|
||||
};
|
||||
|
||||
static struct ddrc_mp ddrc_mp_val = {
|
||||
.pctrl_0 = 0x00000001,
|
||||
};
|
||||
|
||||
static struct ddr_phy ddr_phy_regs_val = {
|
||||
.phy_con0 = 0x17420f40,
|
||||
.phy_con1 = 0x10210100,
|
||||
.phy_con4 = 0x00060807,
|
||||
.mdll_con0 = 0x1010007e,
|
||||
.drvds_con0 = 0x00000d6e,
|
||||
.cmd_sdll_con0 = 0x00000010,
|
||||
.offset_lp_con0 = 0x0000000f,
|
||||
.offset_rd_con0 = 0x0a0a0a0a,
|
||||
.offset_wr_con0 = 0x06060606,
|
||||
};
|
||||
|
||||
static struct mx7_calibration calib_param = {
|
||||
.num_val = 5,
|
||||
.values = {
|
||||
0x0E407304,
|
||||
0x0E447304,
|
||||
0x0E447306,
|
||||
0x0E447304,
|
||||
0x0E447304,
|
||||
},
|
||||
};
|
||||
|
||||
static void ddr_init(void)
|
||||
{
|
||||
mx7_dram_cfg(&ddrc_regs_val, &ddrc_mp_val, &ddr_phy_regs_val, &calib_param);
|
||||
}
|
||||
|
||||
#define UART_PAD_CTRL (PAD_CTL_DSE_3P3V_49OHM | \
|
||||
PAD_CTL_PUS_PU100KOHM | PAD_CTL_HYS)
|
||||
|
||||
static iomux_v3_cfg_t const uart1_pads[] = {
|
||||
MX7D_PAD_UART1_TX_DATA__UART1_DCE_TX | MUX_PAD_CTRL(UART_PAD_CTRL),
|
||||
MX7D_PAD_UART1_RX_DATA__UART1_DCE_RX | MUX_PAD_CTRL(UART_PAD_CTRL),
|
||||
};
|
||||
|
||||
void uart1_pads_set(void)
|
||||
{
|
||||
imx_iomux_v3_setup_multiple_pads(uart1_pads, ARRAY_SIZE(uart1_pads));
|
||||
}
|
||||
|
||||
void board_init_f(ulong dummy)
|
||||
{
|
||||
arch_cpu_init();
|
||||
|
||||
uart1_pads_set();
|
||||
|
||||
timer_init();
|
||||
|
||||
preloader_console_init();
|
||||
|
||||
ddr_init();
|
||||
|
||||
memset(__bss_start, 0, __bss_end - __bss_start);
|
||||
|
||||
board_init_r(NULL, 0);
|
||||
}
|
||||
|
||||
void reset_cpu(void)
|
||||
{
|
||||
}
|
||||
|
||||
#define USDHC_PAD_CTRL (PAD_CTL_DSE_3P3V_32OHM | PAD_CTL_SRE_SLOW | \
|
||||
PAD_CTL_HYS | PAD_CTL_PUE | \
|
||||
PAD_CTL_PUS_PU47KOHM)
|
||||
|
||||
static iomux_v3_cfg_t const usdhc1_pads[] = {
|
||||
MX7D_PAD_SD1_CLK__SD1_CLK | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
MX7D_PAD_SD1_CMD__SD1_CMD | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
MX7D_PAD_SD1_DATA0__SD1_DATA0 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
MX7D_PAD_SD1_DATA1__SD1_DATA1 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
MX7D_PAD_SD1_DATA2__SD1_DATA2 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
MX7D_PAD_SD1_DATA3__SD1_DATA3 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
|
||||
MX7D_PAD_SD1_CD_B__GPIO5_IO0 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
};
|
||||
|
||||
void usdhc1_pads_set(void)
|
||||
{
|
||||
imx_iomux_v3_setup_multiple_pads(usdhc1_pads, ARRAY_SIZE(usdhc1_pads));
|
||||
}
|
||||
|
||||
static struct fsl_esdhc_cfg usdhc_cfg = {
|
||||
USDHC1_BASE_ADDR, 0, 4
|
||||
};
|
||||
|
||||
int board_mmc_init(struct bd_info *bis)
|
||||
{
|
||||
usdhc1_pads_set();
|
||||
usdhc_cfg.sdhc_clk = mxc_get_clock(MXC_ESDHC_CLK);
|
||||
return fsl_esdhc_initialize(bis, &usdhc_cfg);
|
||||
}
|
||||
|
||||
int board_mmc_getcd(struct mmc *mmc)
|
||||
{
|
||||
return 1;
|
||||
}
|
12
board/ronetix/imx8mq-cm/Kconfig
Normal file
12
board/ronetix/imx8mq-cm/Kconfig
Normal file
|
@ -0,0 +1,12 @@
|
|||
if TARGET_IMX8MQ_CM
|
||||
|
||||
config SYS_BOARD
|
||||
default "imx8mq-cm"
|
||||
|
||||
config SYS_VENDOR
|
||||
default "ronetix"
|
||||
|
||||
config SYS_CONFIG_NAME
|
||||
default "imx8mq_cm"
|
||||
|
||||
endif
|
6
board/ronetix/imx8mq-cm/MAINTAINERS
Normal file
6
board/ronetix/imx8mq-cm/MAINTAINERS
Normal file
|
@ -0,0 +1,6 @@
|
|||
i.MX8MQ-CM BOARD
|
||||
M: Ilko Iliev <iliev@ronetix.at>
|
||||
S: Maintained
|
||||
F: board/ronetix/imx8mq-cm/
|
||||
F: include/configs/imx8mq_cm.h
|
||||
F: configs/imx8mq_cm_defconfig
|
12
board/ronetix/imx8mq-cm/Makefile
Normal file
12
board/ronetix/imx8mq-cm/Makefile
Normal file
|
@ -0,0 +1,12 @@
|
|||
#
|
||||
# Copyright 2017 NXP
|
||||
#
|
||||
# SPDX-License-Identifier: GPL-2.0+
|
||||
#
|
||||
|
||||
obj-y += imx8mq_cm.o
|
||||
|
||||
ifdef CONFIG_SPL_BUILD
|
||||
obj-y += spl.o
|
||||
obj-$(CONFIG_IMX8M_LPDDR4) += lpddr4_timing.o
|
||||
endif
|
42
board/ronetix/imx8mq-cm/README
Normal file
42
board/ronetix/imx8mq-cm/README
Normal file
|
@ -0,0 +1,42 @@
|
|||
U-Boot for the Ronetix i.MX8MQ-CM board
|
||||
|
||||
Quick Start
|
||||
===========
|
||||
- Build the ARM Trusted firmware binary
|
||||
- Get ddr firmware
|
||||
- Build U-Boot
|
||||
- Boot
|
||||
|
||||
Get and Build the ARM Trusted firmware
|
||||
======================================
|
||||
$ git clone https://source.codeaurora.org/external/imx/imx-atf
|
||||
$ cd imx-atf
|
||||
$ git checkout imx_4.19.35_1.0.0
|
||||
$ make PLAT=imx8mq bl31
|
||||
$ cd ..
|
||||
$ cp imx-atf/build/imx8mq/release/bl31.bin .
|
||||
|
||||
Get the ddr firmware
|
||||
====================
|
||||
$ wget https://www.nxp.com/lgfiles/NMG/MAD/YOCTO/firmware-imx-8.9.bin
|
||||
$ chmod +x firmware-imx-8.9.bin
|
||||
$ ./firmware-imx-8.9.bin
|
||||
$ cp firmware-imx-8.9/firmware/ddr/synopsys/lpddr4*.bin .
|
||||
|
||||
Build U-Boot
|
||||
============
|
||||
$ /opt/cross/aarch64-ronetix-linux-9.2/bin/aarch64-ronetix-linux-gnu-
|
||||
$ make imx8mq_cm_defconfig
|
||||
$ make
|
||||
|
||||
Burn the flash.bin to MicroSD card offset 33KB
|
||||
==============================================
|
||||
$sudo dd if=flash.bin of=/dev/sd[x] bs=1024 seek=33 conv=sync
|
||||
$sudo dd if=u-boot.itb of=/dev/sd[x] bs=1024 seek=384 conv=sync
|
||||
|
||||
Boot
|
||||
====
|
||||
Set Boot switch on base board iMX8M-MB to SD boot:
|
||||
SW1[8:1]: OFF OFF OFF ON - OFF ON OFF OFF
|
||||
SW4[2:1]: OFF OFF
|
||||
J4: 1,2 - open; 3,4 - close; 5,6 - open
|
84
board/ronetix/imx8mq-cm/imx8mq_cm.c
Normal file
84
board/ronetix/imx8mq-cm/imx8mq_cm.c
Normal file
|
@ -0,0 +1,84 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright 2018 NXP
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <miiphy.h>
|
||||
#include <asm-generic/gpio.h>
|
||||
#include <asm/arch/imx8mq_pins.h>
|
||||
#include <asm/arch/sys_proto.h>
|
||||
#include <asm/arch/clock.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
#define UART_PAD_CTRL (PAD_CTL_DSE6 | PAD_CTL_FSEL1)
|
||||
|
||||
#define WDOG_PAD_CTRL (PAD_CTL_DSE6 | PAD_CTL_HYS | PAD_CTL_PUE)
|
||||
|
||||
static iomux_v3_cfg_t const wdog_pads[] = {
|
||||
IMX8MQ_PAD_GPIO1_IO02__WDOG1_WDOG_B | MUX_PAD_CTRL(WDOG_PAD_CTRL),
|
||||
};
|
||||
|
||||
static iomux_v3_cfg_t const uart_pads[] = {
|
||||
IMX8MQ_PAD_UART1_RXD__UART1_RX | MUX_PAD_CTRL(UART_PAD_CTRL),
|
||||
IMX8MQ_PAD_UART1_TXD__UART1_TX | MUX_PAD_CTRL(UART_PAD_CTRL),
|
||||
};
|
||||
|
||||
int board_early_init_f(void)
|
||||
{
|
||||
struct wdog_regs *wdog = (struct wdog_regs *)WDOG1_BASE_ADDR;
|
||||
|
||||
imx_iomux_v3_setup_multiple_pads(wdog_pads, ARRAY_SIZE(wdog_pads));
|
||||
set_wdog_reset(wdog);
|
||||
|
||||
imx_iomux_v3_setup_multiple_pads(uart_pads, ARRAY_SIZE(uart_pads));
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
static int setup_fec(void)
|
||||
{
|
||||
struct iomuxc_gpr_base_regs *gpr =
|
||||
(struct iomuxc_gpr_base_regs *)IOMUXC_GPR_BASE_ADDR;
|
||||
|
||||
/* Use 125M anatop REF_CLK1 for ENET1, not from external */
|
||||
clrsetbits_le32(&gpr->gpr[1], BIT(13) | BIT(17), 0);
|
||||
return set_clk_enet(ENET_125MHZ);
|
||||
}
|
||||
|
||||
int board_phy_config(struct phy_device *phydev)
|
||||
{
|
||||
/* enable rgmii rxc skew and phy mode select to RGMII copper */
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1d, 0x1f);
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1e, 0x8);
|
||||
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1d, 0x05);
|
||||
phy_write(phydev, MDIO_DEVAD_NONE, 0x1e, 0x100);
|
||||
|
||||
if (phydev->drv->config)
|
||||
phydev->drv->config(phydev);
|
||||
return 0;
|
||||
}
|
||||
|
||||
int board_init(void)
|
||||
{
|
||||
setup_fec();
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
int board_mmc_get_env_dev(int devno)
|
||||
{
|
||||
return devno;
|
||||
}
|
||||
|
||||
int board_late_init(void)
|
||||
{
|
||||
if (IS_ENABLED(CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG)) {
|
||||
env_set("board_name", "imx8mq-cm");
|
||||
env_set("board_rev", "v2.0");
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
9
board/ronetix/imx8mq-cm/imximage-8mq-lpddr4.cfg
Normal file
9
board/ronetix/imx8mq-cm/imximage-8mq-lpddr4.cfg
Normal file
|
@ -0,0 +1,9 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0+ */
|
||||
/*
|
||||
* Copyright 2021 NXP
|
||||
*/
|
||||
|
||||
#define __ASSEMBLY__
|
||||
|
||||
BOOT_FROM sd
|
||||
LOADER mkimage.flash.mkimage 0x7E1000
|
1866
board/ronetix/imx8mq-cm/lpddr4_timing.c
Normal file
1866
board/ronetix/imx8mq-cm/lpddr4_timing.c
Normal file
File diff suppressed because it is too large
Load diff
165
board/ronetix/imx8mq-cm/spl.c
Normal file
165
board/ronetix/imx8mq-cm/spl.c
Normal file
|
@ -0,0 +1,165 @@
|
|||
// SPDX-License-Identifier: GPL-2.0+
|
||||
/*
|
||||
* Copyright 2018 NXP
|
||||
*
|
||||
*/
|
||||
|
||||
#include <common.h>
|
||||
#include <hang.h>
|
||||
#include <init.h>
|
||||
#include <asm/arch/ddr.h>
|
||||
#include <asm/arch/imx8mq_pins.h>
|
||||
#include <asm/arch/sys_proto.h>
|
||||
#include <asm/arch/clock.h>
|
||||
#include <asm/mach-imx/gpio.h>
|
||||
#include <asm/mach-imx/mxc_i2c.h>
|
||||
#include <fsl_esdhc_imx.h>
|
||||
#include <linux/delay.h>
|
||||
#include <spl.h>
|
||||
|
||||
DECLARE_GLOBAL_DATA_PTR;
|
||||
|
||||
static void spl_dram_init(void)
|
||||
{
|
||||
/* ddr init */
|
||||
ddr_init(&dram_timing);
|
||||
}
|
||||
|
||||
#define USDHC2_CD_GPIO IMX_GPIO_NR(2, 12)
|
||||
#define USDHC1_PWR_GPIO IMX_GPIO_NR(2, 10)
|
||||
#define USDHC2_PWR_GPIO IMX_GPIO_NR(2, 19)
|
||||
|
||||
int board_mmc_getcd(struct mmc *mmc)
|
||||
{
|
||||
struct fsl_esdhc_cfg *cfg = (struct fsl_esdhc_cfg *)mmc->priv;
|
||||
int ret = 0;
|
||||
|
||||
switch (cfg->esdhc_base) {
|
||||
case USDHC1_BASE_ADDR:
|
||||
ret = 1;
|
||||
break;
|
||||
case USDHC2_BASE_ADDR:
|
||||
ret = gpio_get_value(USDHC2_CD_GPIO);
|
||||
return ret;
|
||||
}
|
||||
|
||||
return 1;
|
||||
}
|
||||
|
||||
#define USDHC_PAD_CTRL (PAD_CTL_DSE6 | PAD_CTL_HYS | PAD_CTL_PUE | \
|
||||
PAD_CTL_FSEL2)
|
||||
#define USDHC_GPIO_PAD_CTRL (PAD_CTL_PUE | PAD_CTL_DSE1)
|
||||
|
||||
static iomux_v3_cfg_t const usdhc1_pads[] = {
|
||||
IMX8MQ_PAD_SD1_CLK__USDHC1_CLK | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD1_CMD__USDHC1_CMD | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD1_DATA0__USDHC1_DATA0 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD1_DATA1__USDHC1_DATA1 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD1_DATA2__USDHC1_DATA2 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD1_DATA3__USDHC1_DATA3 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD1_DATA4__USDHC1_DATA4 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD1_DATA5__USDHC1_DATA5 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD1_DATA6__USDHC1_DATA6 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD1_DATA7__USDHC1_DATA7 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD1_RESET_B__GPIO2_IO10 | MUX_PAD_CTRL(NO_PAD_CTRL),
|
||||
};
|
||||
|
||||
static iomux_v3_cfg_t const usdhc2_pads[] = {
|
||||
IMX8MQ_PAD_SD2_CLK__USDHC2_CLK | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD2_CMD__USDHC2_CMD | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD2_DATA0__USDHC2_DATA0 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD2_DATA1__USDHC2_DATA1 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD2_DATA2__USDHC2_DATA2 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD2_DATA3__USDHC2_DATA3 | MUX_PAD_CTRL(USDHC_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD2_CD_B__GPIO2_IO12 | MUX_PAD_CTRL(USDHC_GPIO_PAD_CTRL),
|
||||
IMX8MQ_PAD_SD2_RESET_B__GPIO2_IO19 | MUX_PAD_CTRL(USDHC_GPIO_PAD_CTRL),
|
||||
};
|
||||
|
||||
static struct fsl_esdhc_cfg usdhc_cfg[2] = {
|
||||
{USDHC1_BASE_ADDR, 0, 8},
|
||||
{USDHC2_BASE_ADDR, 0, 4},
|
||||
};
|
||||
|
||||
int board_mmc_init(struct bd_info *bis)
|
||||
{
|
||||
int i, ret;
|
||||
/*
|
||||
* According to the board_mmc_init() the following map is done:
|
||||
* (U-Boot device node) (Physical Port)
|
||||
* mmc0 USDHC1
|
||||
* mmc1 USDHC2
|
||||
*/
|
||||
for (i = 0; i < CONFIG_SYS_FSL_USDHC_NUM; i++) {
|
||||
switch (i) {
|
||||
case 0:
|
||||
init_clk_usdhc(0);
|
||||
usdhc_cfg[0].sdhc_clk = mxc_get_clock(USDHC1_CLK_ROOT);
|
||||
imx_iomux_v3_setup_multiple_pads(usdhc1_pads,
|
||||
ARRAY_SIZE(usdhc1_pads));
|
||||
gpio_request(USDHC1_PWR_GPIO, "usdhc1_reset");
|
||||
gpio_direction_output(USDHC1_PWR_GPIO, 0);
|
||||
udelay(500);
|
||||
gpio_direction_output(USDHC1_PWR_GPIO, 1);
|
||||
break;
|
||||
case 1:
|
||||
init_clk_usdhc(1);
|
||||
usdhc_cfg[1].sdhc_clk = mxc_get_clock(USDHC2_CLK_ROOT);
|
||||
imx_iomux_v3_setup_multiple_pads(usdhc2_pads,
|
||||
ARRAY_SIZE(usdhc2_pads));
|
||||
gpio_request(USDHC2_PWR_GPIO, "usdhc2_reset");
|
||||
gpio_direction_output(USDHC2_PWR_GPIO, 0);
|
||||
udelay(500);
|
||||
gpio_direction_output(USDHC2_PWR_GPIO, 1);
|
||||
break;
|
||||
default:
|
||||
printf("Warning: you configured more USDHC controllers(%d)"
|
||||
" than supported by the board\n", i + 1);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
ret = fsl_esdhc_initialize(bis, &usdhc_cfg[i]);
|
||||
if (ret)
|
||||
return ret;
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
void spl_board_init(void)
|
||||
{
|
||||
puts("Normal Boot\n");
|
||||
}
|
||||
|
||||
void board_init_f(ulong dummy)
|
||||
{
|
||||
int ret;
|
||||
|
||||
/* Clear global data */
|
||||
memset((void *)gd, 0, sizeof(gd_t));
|
||||
|
||||
arch_cpu_init();
|
||||
|
||||
init_uart_clk(0);
|
||||
|
||||
board_early_init_f();
|
||||
|
||||
timer_init();
|
||||
|
||||
preloader_console_init();
|
||||
|
||||
/* Clear the BSS. */
|
||||
memset(__bss_start, 0, __bss_end - __bss_start);
|
||||
|
||||
ret = spl_init();
|
||||
if (ret) {
|
||||
debug("spl_init() failed: %d\n", ret);
|
||||
hang();
|
||||
}
|
||||
|
||||
enable_tzc380();
|
||||
|
||||
/* DDR initialization */
|
||||
spl_dram_init();
|
||||
|
||||
board_init_r(NULL, 0);
|
||||
}
|
|
@ -44,7 +44,6 @@ CONFIG_OF_LIST="imx6q-bx50v3 imx6q-b850v3 imx6q-b650v3 imx6q-b450v3"
|
|||
CONFIG_DTB_RESELECT=y
|
||||
CONFIG_MULTI_DTB_FIT=y
|
||||
CONFIG_ENV_OVERWRITE=y
|
||||
CONFIG_ENV_IS_IN_SPI_FLASH=y
|
||||
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
|
||||
CONFIG_DM=y
|
||||
CONFIG_BOUNCE_BUFFER=y
|
||||
|
@ -98,7 +97,8 @@ CONFIG_DM_VIDEO=y
|
|||
# CONFIG_VIDEO_BPP32 is not set
|
||||
CONFIG_SYS_WHITE_ON_BLACK=y
|
||||
CONFIG_VIDEO_IPUV3=y
|
||||
CONFIG_WATCHDOG_TIMEOUT_MSECS=6000
|
||||
CONFIG_WATCHDOG_TIMEOUT_MSECS=8000
|
||||
CONFIG_IMX_WATCHDOG=y
|
||||
CONFIG_BCH=y
|
||||
# CONFIG_EFI_LOADER is not set
|
||||
CONFIG_ENV_IS_NOWHERE=y
|
||||
|
|
110
configs/imx7_cm_defconfig
Normal file
110
configs/imx7_cm_defconfig
Normal file
|
@ -0,0 +1,110 @@
|
|||
CONFIG_ARM=y
|
||||
CONFIG_ARCH_MX7=y
|
||||
CONFIG_SPL_GPIO_SUPPORT=y
|
||||
CONFIG_SPL_LIBCOMMON_SUPPORT=y
|
||||
CONFIG_SPL_LIBGENERIC_SUPPORT=y
|
||||
CONFIG_NR_DRAM_BANKS=1
|
||||
CONFIG_ENV_SIZE=0x2000
|
||||
CONFIG_ENV_OFFSET=0xC0000
|
||||
CONFIG_SYS_I2C_MXC_I2C1=y
|
||||
CONFIG_SYS_I2C_MXC_I2C2=y
|
||||
CONFIG_SYS_I2C_MXC_I2C3=y
|
||||
CONFIG_SYS_I2C_MXC_I2C4=y
|
||||
CONFIG_DM_GPIO=y
|
||||
CONFIG_TARGET_IMX7_CM=y
|
||||
CONFIG_SPL_MMC_SUPPORT=y
|
||||
CONFIG_SPL_SERIAL_SUPPORT=y
|
||||
CONFIG_SPL=y
|
||||
CONFIG_ARMV7_BOOT_SEC_DEFAULT=y
|
||||
CONFIG_IMX_RDC=y
|
||||
CONFIG_IMX_BOOTAUX=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="imx7-cm"
|
||||
CONFIG_DISTRO_DEFAULTS=y
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=arch/arm/mach-imx/spl_sd.cfg"
|
||||
CONFIG_BOOTCOMMAND="run findfdt; run finduuid; run distro_bootcmd"
|
||||
CONFIG_DEFAULT_FDT_FILE="ask"
|
||||
# CONFIG_BOARD_EARLY_INIT_F is not set
|
||||
CONFIG_SPL_I2C_SUPPORT=y
|
||||
CONFIG_SPL_USB_HOST_SUPPORT=y
|
||||
CONFIG_SPL_USB_GADGET=y
|
||||
CONFIG_SPL_USB_SDP_SUPPORT=y
|
||||
# CONFIG_CMD_BOOTD is not set
|
||||
CONFIG_CMD_BOOTMENU=y
|
||||
# CONFIG_CMD_IMI is not set
|
||||
# CONFIG_CMD_XIMG is not set
|
||||
CONFIG_CMD_SPL=y
|
||||
CONFIG_CMD_SPL_WRITE_SIZE=0x20000
|
||||
CONFIG_CMD_MEMTEST=y
|
||||
CONFIG_SYS_ALT_MEMTEST=y
|
||||
CONFIG_CMD_DFU=y
|
||||
CONFIG_CMD_GPIO=y
|
||||
CONFIG_CMD_GPT=y
|
||||
CONFIG_CMD_I2C=y
|
||||
CONFIG_CMD_MMC=y
|
||||
CONFIG_CMD_USB=y
|
||||
CONFIG_CMD_USB_SDP=y
|
||||
CONFIG_CMD_USB_MASS_STORAGE=y
|
||||
# CONFIG_CMD_SETEXPR is not set
|
||||
CONFIG_CMD_BMP=y
|
||||
CONFIG_CMD_CACHE=y
|
||||
CONFIG_CMD_PMIC=y
|
||||
CONFIG_CMD_EXT4_WRITE=y
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_ENV_OVERWRITE=y
|
||||
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
|
||||
CONFIG_NET_RANDOM_ETHADDR=y
|
||||
CONFIG_BOUNCE_BUFFER=y
|
||||
CONFIG_DFU_MMC=y
|
||||
CONFIG_USB_FUNCTION_FASTBOOT=y
|
||||
CONFIG_FASTBOOT_BUF_ADDR=0x82000000
|
||||
CONFIG_FASTBOOT_BUF_SIZE=0x10000000
|
||||
CONFIG_FASTBOOT_FLASH=y
|
||||
CONFIG_FASTBOOT_FLASH_MMC_DEV=0
|
||||
CONFIG_FASTBOOT_CMD_OEM_FORMAT=y
|
||||
CONFIG_DM_I2C=y
|
||||
CONFIG_SYS_I2C_MXC=y
|
||||
CONFIG_DM_MMC=y
|
||||
CONFIG_SUPPORT_EMMC_BOOT=y
|
||||
CONFIG_FSL_USDHC=y
|
||||
CONFIG_MTD=y
|
||||
CONFIG_DM_SPI_FLASH=y
|
||||
# CONFIG_SPI_FLASH_BAR is not set
|
||||
CONFIG_SPI_FLASH_EON=y
|
||||
CONFIG_SPI_FLASH_MACRONIX=y
|
||||
CONFIG_SPI_FLASH_SPANSION=y
|
||||
CONFIG_SPI_FLASH_STMICRO=y
|
||||
CONFIG_PHYLIB=y
|
||||
CONFIG_PHY_MICREL=y
|
||||
CONFIG_PHY_MICREL_KSZ90X1=y
|
||||
CONFIG_DM_ETH=y
|
||||
CONFIG_DM_MDIO=y
|
||||
CONFIG_DM_MDIO_MUX=y
|
||||
CONFIG_DM_ETH_PHY=y
|
||||
CONFIG_FEC_MXC=y
|
||||
CONFIG_RGMII=y
|
||||
CONFIG_MII=y
|
||||
CONFIG_PINCTRL=y
|
||||
CONFIG_PINCTRL_IMX7=y
|
||||
CONFIG_DM_PMIC=y
|
||||
CONFIG_DM_PMIC_PFUZE100=y
|
||||
CONFIG_MXC_UART=y
|
||||
CONFIG_SPI=y
|
||||
CONFIG_DM_SPI=y
|
||||
CONFIG_FSL_QSPI=y
|
||||
# CONFIG_FSL_QSPI_AHB_FULL_MAP is not set
|
||||
CONFIG_IMX_THERMAL=y
|
||||
CONFIG_USB=y
|
||||
CONFIG_DM_USB=y
|
||||
CONFIG_USB_EHCI_HCD=y
|
||||
CONFIG_MXC_USB_OTG_HACTIVE=y
|
||||
CONFIG_USB_GADGET=y
|
||||
CONFIG_USB_GADGET_MANUFACTURER="FSL"
|
||||
CONFIG_USB_GADGET_VENDOR_NUM=0x0525
|
||||
CONFIG_USB_GADGET_PRODUCT_NUM=0xa4a5
|
||||
CONFIG_CI_UDC=y
|
||||
CONFIG_DM_VIDEO=y
|
||||
CONFIG_SYS_WHITE_ON_BLACK=y
|
||||
CONFIG_SPLASH_SCREEN=y
|
||||
CONFIG_SPLASH_SCREEN_ALIGN=y
|
||||
CONFIG_VIDEO_BMP_RLE8=y
|
||||
CONFIG_BMP_16BPP=y
|
153
configs/imx8mm-cl-iot-gate_defconfig
Normal file
153
configs/imx8mm-cl-iot-gate_defconfig
Normal file
|
@ -0,0 +1,153 @@
|
|||
CONFIG_ARM=y
|
||||
CONFIG_SPL_SYS_ICACHE_OFF=y
|
||||
CONFIG_SPL_SYS_DCACHE_OFF=y
|
||||
CONFIG_ARCH_IMX8M=y
|
||||
CONFIG_SYS_TEXT_BASE=0x40200000
|
||||
CONFIG_SPL_GPIO_SUPPORT=y
|
||||
CONFIG_SPL_LIBCOMMON_SUPPORT=y
|
||||
CONFIG_SPL_LIBGENERIC_SUPPORT=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x10000
|
||||
CONFIG_ENV_SIZE=0x4000
|
||||
CONFIG_ENV_OFFSET=0x4400
|
||||
CONFIG_SYS_I2C_MXC_I2C1=y
|
||||
CONFIG_SYS_I2C_MXC_I2C2=y
|
||||
CONFIG_SYS_I2C_MXC_I2C3=y
|
||||
CONFIG_DM_GPIO=y
|
||||
CONFIG_SPL_TEXT_BASE=0x7E1000
|
||||
CONFIG_TARGET_IMX8MM_CL_IOT_GATE=y
|
||||
CONFIG_SPL_MMC_SUPPORT=y
|
||||
CONFIG_SPL_SERIAL_SUPPORT=y
|
||||
CONFIG_SPL_DRIVERS_MISC_SUPPORT=y
|
||||
CONFIG_SPL=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="imx8mm-cl-iot-gate"
|
||||
CONFIG_DISTRO_DEFAULTS=y
|
||||
CONFIG_FIT=y
|
||||
CONFIG_FIT_EXTERNAL_OFFSET=0x3000
|
||||
CONFIG_FIT_SIGNATURE=y
|
||||
CONFIG_SPL_LOAD_FIT=y
|
||||
# CONFIG_USE_SPL_FIT_GENERATOR is not set
|
||||
CONFIG_OF_SYSTEM_SETUP=y
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/compulab/imx8mm-cl-iot-gate/imximage-8mm-lpddr4.cfg"
|
||||
CONFIG_BOARD_LATE_INIT=y
|
||||
CONFIG_SPL_BOARD_INIT=y
|
||||
CONFIG_SPL_SEPARATE_BSS=y
|
||||
CONFIG_SPL_I2C_SUPPORT=y
|
||||
CONFIG_SPL_POWER_SUPPORT=y
|
||||
CONFIG_SPL_WATCHDOG_SUPPORT=y
|
||||
CONFIG_SYS_PROMPT="u-boot=> "
|
||||
CONFIG_CMD_BOOTEFI_SELFTEST=y
|
||||
CONFIG_CMD_NVEDIT_EFI=y
|
||||
CONFIG_CMD_EEPROM=y
|
||||
CONFIG_CMD_SHA1SUM=y
|
||||
CONFIG_CMD_BIND=y
|
||||
CONFIG_CMD_CLK=y
|
||||
CONFIG_CMD_DFU=y
|
||||
CONFIG_CMD_FUSE=y
|
||||
CONFIG_CMD_GPIO=y
|
||||
CONFIG_CMD_GPT=y
|
||||
CONFIG_CMD_I2C=y
|
||||
CONFIG_CMD_MMC=y
|
||||
CONFIG_CMD_USB=y
|
||||
CONFIG_CMD_USB_MASS_STORAGE=y
|
||||
CONFIG_CMD_SNTP=y
|
||||
CONFIG_CMD_CACHE=y
|
||||
CONFIG_CMD_EFIDEBUG=y
|
||||
CONFIG_CMD_RTC=y
|
||||
CONFIG_CMD_TIME=y
|
||||
CONFIG_CMD_GETTIME=y
|
||||
CONFIG_CMD_TIMER=y
|
||||
CONFIG_CMD_REGULATOR=y
|
||||
CONFIG_CMD_TPM=y
|
||||
CONFIG_CMD_EXT4_WRITE=y
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_SPL_OF_CONTROL=y
|
||||
CONFIG_ENV_OVERWRITE=y
|
||||
CONFIG_ENV_IS_IN_MMC=y
|
||||
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
|
||||
CONFIG_SYS_MMC_ENV_DEV=2
|
||||
CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
|
||||
CONFIG_NET_RANDOM_ETHADDR=y
|
||||
CONFIG_SPL_DM=y
|
||||
CONFIG_SPL_CLK_COMPOSITE_CCF=y
|
||||
CONFIG_CLK_COMPOSITE_CCF=y
|
||||
CONFIG_SPL_CLK_IMX8MM=y
|
||||
CONFIG_CLK_IMX8MM=y
|
||||
CONFIG_DFU_TFTP=y
|
||||
CONFIG_DFU_MMC=y
|
||||
CONFIG_DFU_RAM=y
|
||||
CONFIG_DFU_SF=y
|
||||
CONFIG_UDP_FUNCTION_FASTBOOT=y
|
||||
CONFIG_FASTBOOT_BUF_ADDR=0x44000000
|
||||
CONFIG_FASTBOOT_BUF_SIZE=0x5000000
|
||||
CONFIG_FASTBOOT_FLASH=y
|
||||
CONFIG_FASTBOOT_FLASH_MMC_DEV=2
|
||||
CONFIG_MXC_GPIO=y
|
||||
CONFIG_DM_I2C=y
|
||||
CONFIG_SYS_I2C_MXC=y
|
||||
CONFIG_DM_KEYBOARD=y
|
||||
CONFIG_DM_MMC=y
|
||||
CONFIG_SUPPORT_EMMC_RPMB=y
|
||||
CONFIG_SUPPORT_EMMC_BOOT=y
|
||||
CONFIG_FSL_ESDHC_IMX=y
|
||||
CONFIG_DM_SPI_FLASH=y
|
||||
CONFIG_PHYLIB=y
|
||||
CONFIG_PHY_ATHEROS=y
|
||||
CONFIG_DM_ETH=y
|
||||
CONFIG_PHY_GIGE=y
|
||||
CONFIG_FEC_MXC=y
|
||||
CONFIG_MII=y
|
||||
CONFIG_PCI_ENDPOINT=y
|
||||
CONFIG_PINCTRL=y
|
||||
CONFIG_SPL_PINCTRL=y
|
||||
CONFIG_PINCTRL_IMX8M=y
|
||||
CONFIG_POWER_DOMAIN=y
|
||||
CONFIG_IMX8M_POWER_DOMAIN=y
|
||||
CONFIG_DM_PMIC=y
|
||||
CONFIG_DM_PMIC_BD71837=y
|
||||
CONFIG_SPL_DM_PMIC_BD71837=y
|
||||
CONFIG_DM_REGULATOR=y
|
||||
CONFIG_DM_REGULATOR_BD71837=y
|
||||
CONFIG_DM_REGULATOR_FIXED=y
|
||||
CONFIG_DM_REGULATOR_GPIO=y
|
||||
CONFIG_DM_RTC=y
|
||||
CONFIG_RTC_ABX80X=y
|
||||
CONFIG_MXC_UART=y
|
||||
CONFIG_SPI=y
|
||||
CONFIG_DM_SPI=y
|
||||
CONFIG_SYSRESET=y
|
||||
CONFIG_SPL_SYSRESET=y
|
||||
CONFIG_SYSRESET_PSCI=y
|
||||
CONFIG_SYSRESET_WATCHDOG=y
|
||||
CONFIG_TEE=y
|
||||
CONFIG_OPTEE=y
|
||||
CONFIG_DM_THERMAL=y
|
||||
CONFIG_TPM2_TIS_SPI=y
|
||||
CONFIG_TPM2_FTPM_TEE=y
|
||||
CONFIG_USB=y
|
||||
CONFIG_DM_USB=y
|
||||
CONFIG_USB_EHCI_HCD=y
|
||||
CONFIG_USB_EHCI_GENERIC=y
|
||||
CONFIG_USB_GADGET=y
|
||||
CONFIG_USB_GADGET_MANUFACTURER="FSL"
|
||||
CONFIG_USB_GADGET_VENDOR_NUM=0x0525
|
||||
CONFIG_USB_GADGET_PRODUCT_NUM=0xa4a5
|
||||
CONFIG_CI_UDC=y
|
||||
CONFIG_SDP_LOADADDR=0x40400000
|
||||
CONFIG_USB_GADGET_DOWNLOAD=y
|
||||
CONFIG_USB_HOST_ETHER=y
|
||||
CONFIG_USB_ETHER_ASIX88179=y
|
||||
CONFIG_IMX_WATCHDOG=y
|
||||
CONFIG_SPL_TINY_MEMSET=y
|
||||
CONFIG_TPM=y
|
||||
CONFIG_SHA512_ALGO=y
|
||||
CONFIG_SHA512=y
|
||||
CONFIG_SHA384=y
|
||||
CONFIG_LZO=y
|
||||
CONFIG_BZIP2=y
|
||||
CONFIG_OF_LIBFDT_OVERLAY=y
|
||||
CONFIG_EFI_SET_TIME=y
|
||||
CONFIG_EFI_RUNTIME_UPDATE_CAPSULE=y
|
||||
CONFIG_EFI_CAPSULE_ON_DISK=y
|
||||
CONFIG_EFI_CAPSULE_FIRMWARE_FIT=y
|
||||
CONFIG_EFI_TCG2_PROTOCOL=y
|
||||
CONFIG_EFI_SECURE_BOOT=y
|
92
configs/imx8mm-icore-mx8mm-ctouch2_defconfig
Normal file
92
configs/imx8mm-icore-mx8mm-ctouch2_defconfig
Normal file
|
@ -0,0 +1,92 @@
|
|||
CONFIG_ARM=y
|
||||
CONFIG_ARCH_IMX8M=y
|
||||
CONFIG_SYS_TEXT_BASE=0x40200000
|
||||
CONFIG_SPL_GPIO_SUPPORT=y
|
||||
CONFIG_SPL_LIBCOMMON_SUPPORT=y
|
||||
CONFIG_SPL_LIBGENERIC_SUPPORT=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x10000
|
||||
CONFIG_ENV_SIZE=0x1000
|
||||
CONFIG_ENV_OFFSET=0x400000
|
||||
CONFIG_DM_GPIO=y
|
||||
CONFIG_SPL_TEXT_BASE=0x7E1000
|
||||
CONFIG_TARGET_IMX8MM_ICORE_MX8MM=y
|
||||
CONFIG_SPL_MMC_SUPPORT=y
|
||||
CONFIG_SPL_SERIAL_SUPPORT=y
|
||||
CONFIG_SPL_DRIVERS_MISC_SUPPORT=y
|
||||
CONFIG_SPL=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="imx8mm-icore-mx8mm-ctouch2"
|
||||
CONFIG_DISTRO_DEFAULTS=y
|
||||
CONFIG_FIT=y
|
||||
CONFIG_FIT_EXTERNAL_OFFSET=0x3000
|
||||
CONFIG_SPL_LOAD_FIT=y
|
||||
CONFIG_SPL_FIT_GENERATOR="arch/arm/mach-imx/mkimage_fit_atf.sh"
|
||||
CONFIG_OF_SYSTEM_SETUP=y
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=arch/arm/mach-imx/imx8m/imximage-8mm-lpddr4.cfg"
|
||||
CONFIG_DEFAULT_FDT_FILE="imx8mm-icore-mx8mm-ctouch2.dtb"
|
||||
CONFIG_SPL_BOARD_INIT=y
|
||||
CONFIG_SPL_SEPARATE_BSS=y
|
||||
CONFIG_SPL_POWER_SUPPORT=y
|
||||
CONFIG_HUSH_PARSER=y
|
||||
CONFIG_SYS_PROMPT="u-boot=> "
|
||||
# CONFIG_CMD_EXPORTENV is not set
|
||||
# CONFIG_CMD_IMPORTENV is not set
|
||||
# CONFIG_CMD_CRC32 is not set
|
||||
CONFIG_CMD_CLK=y
|
||||
CONFIG_CMD_FUSE=y
|
||||
CONFIG_CMD_GPIO=y
|
||||
CONFIG_CMD_I2C=y
|
||||
CONFIG_CMD_MMC=y
|
||||
CONFIG_CMD_PART=y
|
||||
CONFIG_CMD_DHCP=y
|
||||
CONFIG_CMD_MII=y
|
||||
CONFIG_CMD_PING=y
|
||||
CONFIG_CMD_CACHE=y
|
||||
CONFIG_CMD_REGULATOR=y
|
||||
CONFIG_CMD_EXT2=y
|
||||
CONFIG_CMD_EXT4=y
|
||||
CONFIG_CMD_EXT4_WRITE=y
|
||||
CONFIG_CMD_FAT=y
|
||||
# CONFIG_ISO_PARTITION is not set
|
||||
# CONFIG_EFI_PARTITION is not set
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_SPL_OF_CONTROL=y
|
||||
CONFIG_ENV_OVERWRITE=y
|
||||
CONFIG_ENV_IS_IN_MMC=y
|
||||
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
|
||||
CONFIG_SYS_MMC_ENV_DEV=2
|
||||
CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
|
||||
CONFIG_NET_RANDOM_ETHADDR=y
|
||||
CONFIG_SPL_DM=y
|
||||
CONFIG_SPL_CLK_COMPOSITE_CCF=y
|
||||
CONFIG_CLK_COMPOSITE_CCF=y
|
||||
CONFIG_SPL_CLK_IMX8MM=y
|
||||
CONFIG_CLK_IMX8MM=y
|
||||
CONFIG_MXC_GPIO=y
|
||||
CONFIG_DM_PCA953X=y
|
||||
CONFIG_DM_I2C=y
|
||||
CONFIG_SYS_I2C_MXC=y
|
||||
CONFIG_DM_MMC=y
|
||||
CONFIG_SUPPORT_EMMC_BOOT=y
|
||||
CONFIG_FSL_USDHC=y
|
||||
CONFIG_PHYLIB=y
|
||||
CONFIG_PHY_ATHEROS=y
|
||||
CONFIG_DM_ETH=y
|
||||
CONFIG_PHY_GIGE=y
|
||||
CONFIG_FEC_MXC=y
|
||||
CONFIG_MII=y
|
||||
CONFIG_PINCTRL=y
|
||||
CONFIG_SPL_PINCTRL=y
|
||||
CONFIG_PINCTRL_IMX8M=y
|
||||
CONFIG_DM_REGULATOR=y
|
||||
CONFIG_SPL_DM_REGULATOR=y
|
||||
CONFIG_DM_REGULATOR_FIXED=y
|
||||
CONFIG_DM_REGULATOR_GPIO=y
|
||||
CONFIG_CONS_INDEX=2
|
||||
CONFIG_DM_SERIAL=y
|
||||
# CONFIG_SPL_DM_SERIAL is not set
|
||||
CONFIG_MXC_UART=y
|
||||
CONFIG_SYSRESET=y
|
||||
CONFIG_SPL_SYSRESET=y
|
||||
CONFIG_SYSRESET_PSCI=y
|
||||
CONFIG_DM_THERMAL=y
|
||||
CONFIG_IMX_TMU=y
|
92
configs/imx8mm-icore-mx8mm-edimm2.2_defconfig
Normal file
92
configs/imx8mm-icore-mx8mm-edimm2.2_defconfig
Normal file
|
@ -0,0 +1,92 @@
|
|||
CONFIG_ARM=y
|
||||
CONFIG_ARCH_IMX8M=y
|
||||
CONFIG_SYS_TEXT_BASE=0x40200000
|
||||
CONFIG_SPL_GPIO_SUPPORT=y
|
||||
CONFIG_SPL_LIBCOMMON_SUPPORT=y
|
||||
CONFIG_SPL_LIBGENERIC_SUPPORT=y
|
||||
CONFIG_SYS_MALLOC_F_LEN=0x10000
|
||||
CONFIG_ENV_SIZE=0x1000
|
||||
CONFIG_ENV_OFFSET=0x400000
|
||||
CONFIG_DM_GPIO=y
|
||||
CONFIG_SPL_TEXT_BASE=0x7E1000
|
||||
CONFIG_TARGET_IMX8MM_ICORE_MX8MM=y
|
||||
CONFIG_SPL_MMC_SUPPORT=y
|
||||
CONFIG_SPL_SERIAL_SUPPORT=y
|
||||
CONFIG_SPL_DRIVERS_MISC_SUPPORT=y
|
||||
CONFIG_SPL=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="imx8mm-icore-mx8mm-edimm2.2"
|
||||
CONFIG_DISTRO_DEFAULTS=y
|
||||
CONFIG_FIT=y
|
||||
CONFIG_FIT_EXTERNAL_OFFSET=0x3000
|
||||
CONFIG_SPL_LOAD_FIT=y
|
||||
CONFIG_SPL_FIT_GENERATOR="arch/arm/mach-imx/mkimage_fit_atf.sh"
|
||||
CONFIG_OF_SYSTEM_SETUP=y
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=arch/arm/mach-imx/imx8m/imximage-8mm-lpddr4.cfg"
|
||||
CONFIG_DEFAULT_FDT_FILE="imx8mm-icore-mx8mm-edimm2.2.dtb"
|
||||
CONFIG_SPL_BOARD_INIT=y
|
||||
CONFIG_SPL_SEPARATE_BSS=y
|
||||
CONFIG_SPL_POWER_SUPPORT=y
|
||||
CONFIG_HUSH_PARSER=y
|
||||
CONFIG_SYS_PROMPT="u-boot=> "
|
||||
# CONFIG_CMD_EXPORTENV is not set
|
||||
# CONFIG_CMD_IMPORTENV is not set
|
||||
# CONFIG_CMD_CRC32 is not set
|
||||
CONFIG_CMD_CLK=y
|
||||
CONFIG_CMD_FUSE=y
|
||||
CONFIG_CMD_GPIO=y
|
||||
CONFIG_CMD_I2C=y
|
||||
CONFIG_CMD_MMC=y
|
||||
CONFIG_CMD_PART=y
|
||||
CONFIG_CMD_DHCP=y
|
||||
CONFIG_CMD_MII=y
|
||||
CONFIG_CMD_PING=y
|
||||
CONFIG_CMD_CACHE=y
|
||||
CONFIG_CMD_REGULATOR=y
|
||||
CONFIG_CMD_EXT2=y
|
||||
CONFIG_CMD_EXT4=y
|
||||
CONFIG_CMD_EXT4_WRITE=y
|
||||
CONFIG_CMD_FAT=y
|
||||
# CONFIG_ISO_PARTITION is not set
|
||||
# CONFIG_EFI_PARTITION is not set
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_SPL_OF_CONTROL=y
|
||||
CONFIG_ENV_OVERWRITE=y
|
||||
CONFIG_ENV_IS_IN_MMC=y
|
||||
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
|
||||
CONFIG_SYS_MMC_ENV_DEV=2
|
||||
CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
|
||||
CONFIG_NET_RANDOM_ETHADDR=y
|
||||
CONFIG_SPL_DM=y
|
||||
CONFIG_SPL_CLK_COMPOSITE_CCF=y
|
||||
CONFIG_CLK_COMPOSITE_CCF=y
|
||||
CONFIG_SPL_CLK_IMX8MM=y
|
||||
CONFIG_CLK_IMX8MM=y
|
||||
CONFIG_MXC_GPIO=y
|
||||
CONFIG_DM_PCA953X=y
|
||||
CONFIG_DM_I2C=y
|
||||
CONFIG_SYS_I2C_MXC=y
|
||||
CONFIG_DM_MMC=y
|
||||
CONFIG_SUPPORT_EMMC_BOOT=y
|
||||
CONFIG_FSL_USDHC=y
|
||||
CONFIG_PHYLIB=y
|
||||
CONFIG_PHY_ATHEROS=y
|
||||
CONFIG_DM_ETH=y
|
||||
CONFIG_PHY_GIGE=y
|
||||
CONFIG_FEC_MXC=y
|
||||
CONFIG_MII=y
|
||||
CONFIG_PINCTRL=y
|
||||
CONFIG_SPL_PINCTRL=y
|
||||
CONFIG_PINCTRL_IMX8M=y
|
||||
CONFIG_DM_REGULATOR=y
|
||||
CONFIG_SPL_DM_REGULATOR=y
|
||||
CONFIG_DM_REGULATOR_FIXED=y
|
||||
CONFIG_DM_REGULATOR_GPIO=y
|
||||
CONFIG_CONS_INDEX=2
|
||||
CONFIG_DM_SERIAL=y
|
||||
# CONFIG_SPL_DM_SERIAL is not set
|
||||
CONFIG_MXC_UART=y
|
||||
CONFIG_SYSRESET=y
|
||||
CONFIG_SPL_SYSRESET=y
|
||||
CONFIG_SYSRESET_PSCI=y
|
||||
CONFIG_DM_THERMAL=y
|
||||
CONFIG_IMX_TMU=y
|
82
configs/imx8mq_cm_defconfig
Normal file
82
configs/imx8mq_cm_defconfig
Normal file
|
@ -0,0 +1,82 @@
|
|||
CONFIG_ARM=y
|
||||
CONFIG_ARCH_IMX8M=y
|
||||
CONFIG_SYS_TEXT_BASE=0x40200000
|
||||
CONFIG_SPL_GPIO_SUPPORT=y
|
||||
CONFIG_SPL_LIBCOMMON_SUPPORT=y
|
||||
CONFIG_SPL_LIBGENERIC_SUPPORT=y
|
||||
CONFIG_ENV_SIZE=0x1000
|
||||
CONFIG_ENV_OFFSET=0x400000
|
||||
CONFIG_SYS_I2C_MXC_I2C1=y
|
||||
CONFIG_SYS_I2C_MXC_I2C2=y
|
||||
CONFIG_SYS_I2C_MXC_I2C3=y
|
||||
CONFIG_DM_GPIO=y
|
||||
CONFIG_SPL_TEXT_BASE=0x7E1000
|
||||
CONFIG_TARGET_IMX8MQ_CM=y
|
||||
CONFIG_SPL_MMC_SUPPORT=y
|
||||
CONFIG_SPL_SERIAL_SUPPORT=y
|
||||
CONFIG_SPL=y
|
||||
CONFIG_DEFAULT_DEVICE_TREE="imx8mq-cm"
|
||||
CONFIG_DISTRO_DEFAULTS=y
|
||||
CONFIG_FIT=y
|
||||
CONFIG_SPL_FIT_PRINT=y
|
||||
CONFIG_SPL_LOAD_FIT=y
|
||||
# CONFIG_USE_SPL_FIT_GENERATOR is not set
|
||||
CONFIG_OF_SYSTEM_SETUP=y
|
||||
CONFIG_SYS_EXTRA_OPTIONS="IMX_CONFIG=board/ronetix/imx8mq-cm/imximage-8mq-lpddr4.cfg"
|
||||
CONFIG_BOARD_LATE_INIT=y
|
||||
CONFIG_SPL_BOARD_INIT=y
|
||||
CONFIG_SPL_SEPARATE_BSS=y
|
||||
CONFIG_SPL_I2C_SUPPORT=y
|
||||
CONFIG_SYS_PROMPT="u-boot=> "
|
||||
CONFIG_CMD_FUSE=y
|
||||
CONFIG_CMD_GPIO=y
|
||||
CONFIG_CMD_I2C=y
|
||||
CONFIG_CMD_MMC=y
|
||||
CONFIG_CMD_CACHE=y
|
||||
CONFIG_CMD_REGULATOR=y
|
||||
CONFIG_CMD_EXT4_WRITE=y
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_SPL_OF_CONTROL=y
|
||||
CONFIG_ENV_OVERWRITE=y
|
||||
CONFIG_ENV_IS_IN_MMC=y
|
||||
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
|
||||
CONFIG_SYS_MMC_ENV_DEV=1
|
||||
CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
|
||||
CONFIG_NET_RANDOM_ETHADDR=y
|
||||
CONFIG_SAVED_DRAM_TIMING_BASE=0x40000000
|
||||
CONFIG_MXC_GPIO=y
|
||||
CONFIG_DM_I2C=y
|
||||
CONFIG_SYS_I2C_MXC=y
|
||||
CONFIG_DM_MMC=y
|
||||
CONFIG_SUPPORT_EMMC_BOOT=y
|
||||
CONFIG_MMC_IO_VOLTAGE=y
|
||||
CONFIG_MMC_UHS_SUPPORT=y
|
||||
CONFIG_MMC_HS400_ES_SUPPORT=y
|
||||
CONFIG_MMC_HS400_SUPPORT=y
|
||||
CONFIG_FSL_USDHC=y
|
||||
CONFIG_MTD=y
|
||||
CONFIG_DM_MTD=y
|
||||
CONFIG_DM_SPI_FLASH=y
|
||||
CONFIG_SPI_FLASH_MACRONIX=y
|
||||
CONFIG_SPI_FLASH_SPANSION=y
|
||||
CONFIG_SPI_FLASH_STMICRO=y
|
||||
CONFIG_PHYLIB=y
|
||||
CONFIG_PHY_ATHEROS=y
|
||||
CONFIG_DM_ETH=y
|
||||
CONFIG_PHY_GIGE=y
|
||||
CONFIG_FEC_MXC=y
|
||||
CONFIG_MII=y
|
||||
CONFIG_PINCTRL=y
|
||||
CONFIG_PINCTRL_IMX8M=y
|
||||
CONFIG_DM_PMIC=y
|
||||
CONFIG_DM_PMIC_BD71837=y
|
||||
CONFIG_DM_REGULATOR=y
|
||||
CONFIG_DM_REGULATOR_FIXED=y
|
||||
CONFIG_DM_REGULATOR_GPIO=y
|
||||
CONFIG_MXC_UART=y
|
||||
CONFIG_SPI=y
|
||||
CONFIG_DM_SPI=y
|
||||
CONFIG_FSL_QSPI=y
|
||||
CONFIG_DM_THERMAL=y
|
||||
CONFIG_IMX_WATCHDOG=y
|
||||
CONFIG_WDT=y
|
|
@ -38,7 +38,6 @@ CONFIG_CMD_FAT=y
|
|||
CONFIG_CMD_FS_GENERIC=y
|
||||
CONFIG_OF_CONTROL=y
|
||||
CONFIG_ENV_OVERWRITE=y
|
||||
CONFIG_ENV_IS_IN_MMC=y
|
||||
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
|
||||
CONFIG_DM=y
|
||||
CONFIG_BOOTCOUNT_LIMIT=y
|
||||
|
@ -78,3 +77,4 @@ CONFIG_VIDEO_IPUV3=y
|
|||
CONFIG_WATCHDOG_TIMEOUT_MSECS=8000
|
||||
CONFIG_IMX_WATCHDOG=y
|
||||
CONFIG_BCH=y
|
||||
CONFIG_ENV_IS_NOWHERE=y
|
||||
|
|
|
@ -1299,16 +1299,19 @@ static const struct eth_ops fecmxc_ops = {
|
|||
static int device_get_phy_addr(struct fec_priv *priv, struct udevice *dev)
|
||||
{
|
||||
struct ofnode_phandle_args phandle_args;
|
||||
int reg;
|
||||
int reg, ret;
|
||||
|
||||
if (dev_read_phandle_with_args(dev, "phy-handle", NULL, 0, 0,
|
||||
&phandle_args)) {
|
||||
debug("Failed to find phy-handle");
|
||||
return -ENODEV;
|
||||
ret = dev_read_phandle_with_args(dev, "phy-handle", NULL, 0, 0,
|
||||
&phandle_args);
|
||||
if (ret) {
|
||||
debug("Failed to find phy-handle (err = %d\n)", ret);
|
||||
return ret;
|
||||
}
|
||||
|
||||
priv->phy_of_node = phandle_args.node;
|
||||
if (!ofnode_is_available(phandle_args.node))
|
||||
return -ENOENT;
|
||||
|
||||
priv->phy_of_node = phandle_args.node;
|
||||
reg = ofnode_read_u32_default(phandle_args.node, "reg", 0);
|
||||
|
||||
return reg;
|
||||
|
@ -1352,6 +1355,7 @@ static void fec_gpio_reset(struct fec_priv *priv)
|
|||
|
||||
static int fecmxc_probe(struct udevice *dev)
|
||||
{
|
||||
bool dm_mii_bus = true;
|
||||
struct eth_pdata *pdata = dev_get_plat(dev);
|
||||
struct fec_priv *priv = dev_get_priv(dev);
|
||||
struct mii_dev *bus = NULL;
|
||||
|
@ -1459,6 +1463,7 @@ static int fecmxc_probe(struct udevice *dev)
|
|||
#endif
|
||||
|
||||
if (!bus) {
|
||||
dm_mii_bus = false;
|
||||
#ifdef CONFIG_FEC_MXC_MDIO_BASE
|
||||
bus = fec_get_miibus((ulong)CONFIG_FEC_MXC_MDIO_BASE,
|
||||
dev_seq(dev));
|
||||
|
@ -1504,8 +1509,10 @@ static int fecmxc_probe(struct udevice *dev)
|
|||
return 0;
|
||||
|
||||
err_phy:
|
||||
mdio_unregister(bus);
|
||||
free(bus);
|
||||
if (!dm_mii_bus) {
|
||||
mdio_unregister(bus);
|
||||
free(bus);
|
||||
}
|
||||
err_mii:
|
||||
err_timeout:
|
||||
fec_free_descs(priv);
|
||||
|
|
|
@ -646,6 +646,9 @@ int dm_pci_hose_probe_bus(struct udevice *bus)
|
|||
return log_msg_ret("probe", ret);
|
||||
}
|
||||
|
||||
if (!ea_pos)
|
||||
sub_bus = pci_get_bus_max();
|
||||
|
||||
dm_pciauto_postscan_setup_bridge(bus, sub_bus);
|
||||
|
||||
return sub_bus;
|
||||
|
@ -787,6 +790,10 @@ error:
|
|||
return ret;
|
||||
}
|
||||
|
||||
__weak extern void board_pci_fixup_dev(struct udevice *bus, struct udevice *dev)
|
||||
{
|
||||
}
|
||||
|
||||
int pci_bind_bus_devices(struct udevice *bus)
|
||||
{
|
||||
ulong vendor, device;
|
||||
|
@ -892,6 +899,8 @@ int pci_bind_bus_devices(struct udevice *bus)
|
|||
}
|
||||
}
|
||||
}
|
||||
|
||||
board_pci_fixup_dev(bus, dev);
|
||||
}
|
||||
|
||||
return 0;
|
||||
|
|
|
@ -473,7 +473,7 @@ static int imx6_pcie_assert_core_reset(struct imx_pcie_priv *priv,
|
|||
* If both LTSSM_ENABLE and REF_SSP_ENABLE are active we have a strong
|
||||
* indication that the bootloader activated the link.
|
||||
*/
|
||||
if (is_mx6dq() && prepare_for_boot) {
|
||||
if ((is_mx6dq() || is_mx6sdl()) && prepare_for_boot) {
|
||||
u32 val, gpr1, gpr12;
|
||||
|
||||
gpr1 = readl(&iomuxc_regs->gpr[1]);
|
||||
|
|
|
@ -92,12 +92,12 @@
|
|||
"swappartitions=" \
|
||||
"setexpr partnum 3 - ${partnum}\0" \
|
||||
"failbootcmd=" \
|
||||
"echo reached failbootcmd; " \
|
||||
"cls; " \
|
||||
"setcurs 5 4; " \
|
||||
"lcdputs \"Monitor failed to start. " \
|
||||
"Try again, or contact GE Service for support.\"; " \
|
||||
"bootcount reset; \0" \
|
||||
"bootcount reset; " \
|
||||
"while true; do sleep 1; done; \0" \
|
||||
"altbootcmd=" \
|
||||
"run doquiet; " \
|
||||
"setenv partnum 1; run hasfirstboot || setenv partnum 2; " \
|
||||
|
@ -115,23 +115,16 @@
|
|||
"tryboot=" \
|
||||
"setenv partnum 1; run hasfirstboot || setenv partnum 2; " \
|
||||
"run loadimage || run swappartitions && run loadimage || " \
|
||||
"setenv partnum 0 && echo MISSING IMAGE;" \
|
||||
"setenv partnum 0 && echo MISSING IMAGE;" \
|
||||
"run doboot; " \
|
||||
"run failbootcmd\0" \
|
||||
|
||||
#define CONFIG_MMCBOOTCOMMAND \
|
||||
"if mmc dev ${devnum}; then " \
|
||||
"run doquiet; " \
|
||||
"run tryboot; " \
|
||||
"fi; " \
|
||||
|
||||
#define CONFIG_USBBOOTCOMMAND \
|
||||
"echo Unsupported; " \
|
||||
"run doquiet; " \
|
||||
"run tryboot; " \
|
||||
|
||||
#ifdef CONFIG_CMD_NFS
|
||||
#define CONFIG_BOOTCOMMAND CONFIG_NETWORKBOOTCOMMAND
|
||||
#elif CONFIG_CMD_USB
|
||||
#define CONFIG_BOOTCOMMAND CONFIG_USBBOOTCOMMAND
|
||||
#else
|
||||
#define CONFIG_BOOTCOMMAND CONFIG_MMCBOOTCOMMAND
|
||||
#endif
|
||||
|
|
110
include/configs/imx7-cm.h
Normal file
110
include/configs/imx7-cm.h
Normal file
|
@ -0,0 +1,110 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0+ */
|
||||
/*
|
||||
* Copyright (C) 2021 Ronetix GmbH
|
||||
*
|
||||
* Configuration settings for the Ronetix's iMX7-CM System-on-Module.
|
||||
*/
|
||||
|
||||
#ifndef __IMX7_CM_CONFIG_H
|
||||
#define __IMX7_CM_CONFIG_H
|
||||
|
||||
#include "mx7_common.h"
|
||||
|
||||
#define CONFIG_MXC_UART_BASE UART1_IPS_BASE_ADDR
|
||||
|
||||
/* Size of malloc() pool */
|
||||
#define CONFIG_SYS_MALLOC_LEN (32 * SZ_1M)
|
||||
|
||||
#define CONFIG_ETHPRIME "FEC"
|
||||
|
||||
#undef CONFIG_SYS_AUTOLOAD
|
||||
#undef CONFIG_EXTRA_ENV_SETTINGS
|
||||
#undef CONFIG_BOOTCOMMAND
|
||||
|
||||
/*
|
||||
* Use:
|
||||
* boot-mode=mix
|
||||
* boot-mode=sd
|
||||
* boot-mode=net
|
||||
*/
|
||||
#define MY_CONFIG_BOOT_MODE "boot-mode=sd\0"
|
||||
|
||||
#define CONFIG_EXTRA_ENV_SETTINGS \
|
||||
MY_CONFIG_BOOT_MODE \
|
||||
"image=zImage\0" \
|
||||
"console=ttymxc0\0" \
|
||||
"fdt_file=imx7-cm.dtb\0" \
|
||||
"fdt_addr=0x83000000\0" \
|
||||
"mmcdev="__stringify(CONFIG_SYS_MMC_ENV_DEV)"\0" \
|
||||
"mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \
|
||||
"mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \
|
||||
"mmcargs=setenv bootargs console=${console},${baudrate} " \
|
||||
"root=${mmcroot}\0" \
|
||||
"loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
|
||||
"loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
|
||||
\
|
||||
"bootsd=" \
|
||||
"echo Booting from SD card ...; " \
|
||||
"run mmcargs; " \
|
||||
"mmc dev ${mmcdev};" \
|
||||
"run loadimage; " \
|
||||
"run loadfdt; " \
|
||||
"bootz ${loadaddr} - ${fdt_addr}; " \
|
||||
"\0" \
|
||||
\
|
||||
"bootmix=" \
|
||||
"echo Boot Kernel and FDT from TFTP, RootFs from SD card ...; " \
|
||||
"run mmcargs; " \
|
||||
"mmc dev ${mmcdev};" \
|
||||
"tftp ${fdt_addr} ${fdt_file}; " \
|
||||
"tftp ${image}; " \
|
||||
"bootz ${loadaddr} - ${fdt_addr}; " \
|
||||
"\0" \
|
||||
\
|
||||
"netargs=setenv bootargs console=${console},${baudrate} " \
|
||||
"root=/dev/nfs " \
|
||||
"ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp" \
|
||||
"\0" \
|
||||
"bootnet=" \
|
||||
"echo Booting from net ...; " \
|
||||
"run netargs; " \
|
||||
"tftp ${image}; " \
|
||||
"tftp ${fdt_addr} ${fdt_file}; " \
|
||||
"bootz ${loadaddr} - ${fdt_addr}; " \
|
||||
"\0"
|
||||
|
||||
#define CONFIG_BOOTCOMMAND "run boot${boot-mode}"
|
||||
|
||||
#define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
|
||||
#define CONFIG_SYS_HZ 1000
|
||||
|
||||
/* Physical Memory Map */
|
||||
#define PHYS_SDRAM MMDC0_ARB_BASE_ADDR
|
||||
|
||||
#define CONFIG_SYS_SDRAM_BASE PHYS_SDRAM
|
||||
#define CONFIG_SYS_INIT_RAM_ADDR IRAM_BASE_ADDR
|
||||
#define CONFIG_SYS_INIT_RAM_SIZE IRAM_SIZE
|
||||
|
||||
#define CONFIG_SYS_INIT_SP_OFFSET \
|
||||
(CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
|
||||
#define CONFIG_SYS_INIT_SP_ADDR \
|
||||
(CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
|
||||
|
||||
/* MMC Config*/
|
||||
#define CONFIG_SYS_FSL_ESDHC_ADDR USDHC1_BASE_ADDR
|
||||
#define CONFIG_SYS_FSL_USDHC_NUM 2
|
||||
|
||||
#define CONFIG_SYS_MMC_ENV_DEV 0 /* USDHC1 */
|
||||
#define CONFIG_SYS_MMC_ENV_PART 0 /* user area */
|
||||
#define CONFIG_SYS_MMC_IMG_LOAD_PART 1
|
||||
#define CONFIG_MMCROOT "/dev/mmcblk0p2" /* USDHC1 */
|
||||
|
||||
/* USB Configs */
|
||||
#define CONFIG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW)
|
||||
|
||||
#define CONFIG_USBD_HS
|
||||
|
||||
/* SPL */
|
||||
#include "imx7_spl.h"
|
||||
|
||||
#endif /* __CONFIG_H */
|
196
include/configs/imx8mm-cl-iot-gate.h
Normal file
196
include/configs/imx8mm-cl-iot-gate.h
Normal file
|
@ -0,0 +1,196 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0+ */
|
||||
/*
|
||||
* Copyright 2019 NXP
|
||||
*/
|
||||
|
||||
#ifndef __IMX8MM_CL_IOT_GATE_H
|
||||
#define __IMX8MM_CL_IOT_GATE_H
|
||||
|
||||
#include <linux/sizes.h>
|
||||
#include <linux/stringify.h>
|
||||
#include <asm/arch/imx-regs.h>
|
||||
#include <config_distro_bootcmd.h>
|
||||
|
||||
#define CONFIG_SYS_BOOTM_LEN (32 * SZ_1M)
|
||||
#define CONFIG_SPL_MAX_SIZE (148 * 1024)
|
||||
#define CONFIG_SYS_MONITOR_LEN SZ_512K
|
||||
#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR
|
||||
#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300
|
||||
#define CONFIG_SYS_UBOOT_BASE \
|
||||
(QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512)
|
||||
|
||||
#ifdef CONFIG_SPL_BUILD
|
||||
#define CONFIG_SPL_STACK 0x920000
|
||||
#define CONFIG_SPL_BSS_START_ADDR 0x910000
|
||||
#define CONFIG_SPL_BSS_MAX_SIZE SZ_8K /* 8 KB */
|
||||
#define CONFIG_SYS_SPL_MALLOC_START 0x42200000
|
||||
#define CONFIG_SYS_SPL_MALLOC_SIZE SZ_512K /* 512 KB */
|
||||
|
||||
/* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
|
||||
#define CONFIG_MALLOC_F_ADDR 0x912000
|
||||
/* For RAW image gives a error info not panic */
|
||||
#define CONFIG_SPL_ABORT_ON_RAW_IMAGE
|
||||
|
||||
#endif
|
||||
|
||||
#if CONFIG_IS_ENABLED(CMD_MMC)
|
||||
# define BOOT_TARGET_MMC(func) \
|
||||
func(MMC, mmc, 2) \
|
||||
func(MMC, mmc, 0)
|
||||
#else
|
||||
# define BOOT_TARGET_MMC(func)
|
||||
#endif
|
||||
|
||||
#if CONFIG_IS_ENABLED(CMD_USB)
|
||||
# define BOOT_TARGET_USB(func) func(USB, usb, 0)
|
||||
#else
|
||||
# define BOOT_TARGET_USB(func)
|
||||
#endif
|
||||
|
||||
#if CONFIG_IS_ENABLED(CMD_PXE)
|
||||
# define BOOT_TARGET_PXE(func) func(PXE, pxe, na)
|
||||
#else
|
||||
# define BOOT_TARGET_PXE(func)
|
||||
#endif
|
||||
|
||||
#if CONFIG_IS_ENABLED(CMD_DHCP)
|
||||
# define BOOT_TARGET_DHCP(func) func(DHCP, dhcp, na)
|
||||
#else
|
||||
# define BOOT_TARGET_DHCP(func)
|
||||
#endif
|
||||
|
||||
#define BOOT_TARGET_DEVICES(func) \
|
||||
BOOT_TARGET_USB(func) \
|
||||
BOOT_TARGET_MMC(func) \
|
||||
BOOT_TARGET_PXE(func) \
|
||||
BOOT_TARGET_DHCP(func)
|
||||
|
||||
/* Initial environment variables */
|
||||
#define CONFIG_EXTRA_ENV_SETTINGS \
|
||||
BOOTENV \
|
||||
"script=boot.scr\0" \
|
||||
"image=Image\0" \
|
||||
"console=ttymxc2,115200 earlycon=ec_imx6q,0x30880000,115200\0" \
|
||||
"fdt_addr=0x43000000\0" \
|
||||
"fdt_addr_r=0x43000000\0" \
|
||||
"boot_fit=no\0" \
|
||||
"dfu_alt_info=mmc 2=flash-bin raw 0x42 0x250 mmcpart 1;" \
|
||||
"u-boot-itb raw 0x300 0x1B00 mmcpart 1\0" \
|
||||
"fdt_file=sb-iotgimx8.dtb\0" \
|
||||
"fdtfile=sb-iotgimx8.dtb\0" \
|
||||
"initrd_addr=0x43800000\0" \
|
||||
"bootm_size=0x10000000\0" \
|
||||
"mmcdev=" __stringify(CONFIG_SYS_MMC_ENV_DEV) "\0" \
|
||||
"mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \
|
||||
"mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \
|
||||
"mmcautodetect=yes\0" \
|
||||
"mmcargs=setenv bootargs console=${console} root=${mmcroot}\0 " \
|
||||
"loadbootscript=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${script};\0" \
|
||||
"bootscript=echo Running bootscript from mmc ...; " \
|
||||
"source\0" \
|
||||
"loadimage=fatload mmc ${mmcdev}:${mmcpart} ${loadaddr} ${image}\0" \
|
||||
"loadfdt=fatload mmc ${mmcdev}:${mmcpart} ${fdt_addr} ${fdt_file}\0" \
|
||||
"kernel_addr_r=0x40480000\0" \
|
||||
"pxefile_addr_r=0x40480000\0" \
|
||||
"ramdisk_addr_r=0x43800000\0" \
|
||||
"mmcboot=echo Booting from mmc ...; " \
|
||||
"run mmcargs; " \
|
||||
"if test ${boot_fit} = yes || test ${boot_fit} = try; then " \
|
||||
"bootm ${loadaddr}; " \
|
||||
"else " \
|
||||
"if run loadfdt; then " \
|
||||
"booti ${loadaddr} - ${fdt_addr}; " \
|
||||
"else " \
|
||||
"echo WARN: Cannot load the DT; " \
|
||||
"fi; " \
|
||||
"fi;\0" \
|
||||
"netargs=setenv bootargs console=${console} " \
|
||||
"root=/dev/nfs " \
|
||||
"ip=dhcp nfsroot=${serverip}:${nfsroot},v3,tcp\0" \
|
||||
"netboot=echo Booting from net ...; " \
|
||||
"run netargs; " \
|
||||
"if test ${ip_dyn} = yes; then " \
|
||||
"setenv get_cmd dhcp; " \
|
||||
"else " \
|
||||
"setenv get_cmd tftp; " \
|
||||
"fi; " \
|
||||
"${get_cmd} ${loadaddr} ${image}; " \
|
||||
"if test ${boot_fit} = yes || test ${boot_fit} = try; then " \
|
||||
"bootm ${loadaddr}; " \
|
||||
"else " \
|
||||
"if ${get_cmd} ${fdt_addr} ${fdt_file}; then " \
|
||||
"booti ${loadaddr} - ${fdt_addr}; " \
|
||||
"else " \
|
||||
"echo WARN: Cannot load the DT; " \
|
||||
"fi; " \
|
||||
"fi;\0"
|
||||
|
||||
#ifndef CONFIG_BOOTCOMMAND
|
||||
#define CONFIG_BOOTCOMMAND \
|
||||
"mmc dev ${mmcdev}; if mmc rescan; then " \
|
||||
"if run loadbootscript; then " \
|
||||
"run bootscript; " \
|
||||
"else " \
|
||||
"if run loadimage; then " \
|
||||
"run mmcboot; " \
|
||||
"else run netboot; " \
|
||||
"fi; " \
|
||||
"fi; " \
|
||||
"fi;"
|
||||
#endif
|
||||
|
||||
/* Link Definitions */
|
||||
#define CONFIG_LOADADDR 0x40480000
|
||||
|
||||
#define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
|
||||
|
||||
#define CONFIG_SYS_INIT_RAM_ADDR 0x40000000
|
||||
#define CONFIG_SYS_INIT_RAM_SIZE 0x80000
|
||||
#define CONFIG_SYS_INIT_SP_OFFSET \
|
||||
(CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
|
||||
#define CONFIG_SYS_INIT_SP_ADDR \
|
||||
(CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
|
||||
|
||||
#define CONFIG_MMCROOT "/dev/mmcblk1p2" /* USDHC2 */
|
||||
|
||||
/* Size of malloc() pool */
|
||||
#define CONFIG_SYS_MALLOC_LEN SZ_32M
|
||||
|
||||
#define CONFIG_SYS_SDRAM_BASE 0x40000000
|
||||
#define PHYS_SDRAM 0x40000000
|
||||
#define PHYS_SDRAM_SIZE 0x80000000 /* 2GB DDR */
|
||||
|
||||
#define CONFIG_MXC_UART_BASE UART3_BASE_ADDR
|
||||
|
||||
/* Monitor Command Prompt */
|
||||
#define CONFIG_SYS_PROMPT_HUSH_PS2 "> "
|
||||
#define CONFIG_SYS_CBSIZE 2048
|
||||
#define CONFIG_SYS_MAXARGS 64
|
||||
#define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE
|
||||
#define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + \
|
||||
sizeof(CONFIG_SYS_PROMPT) + 16)
|
||||
|
||||
/* USDHC */
|
||||
#define CONFIG_FSL_USDHC
|
||||
|
||||
#define CONFIG_SYS_FSL_USDHC_NUM 2
|
||||
#define CONFIG_SYS_FSL_ESDHC_ADDR 0
|
||||
|
||||
#define CONFIG_SYS_MMC_IMG_LOAD_PART 1
|
||||
|
||||
#define CONFIG_SYS_I2C_SPEED 100000
|
||||
|
||||
#define CONFIG_ETHPRIME "FEC"
|
||||
|
||||
#define CONFIG_FEC_XCV_TYPE RGMII
|
||||
#define CONFIG_FEC_MXC_PHYADDR 0
|
||||
#define FEC_QUIRK_ENET_MAC
|
||||
|
||||
#define IMX_FEC_BASE 0x30BE0000
|
||||
|
||||
/* USB Configs */
|
||||
#define CONFIG_EHCI_HCD_INIT_AFTER_RESET
|
||||
#define CONFIG_MXC_USB_PORTSC (PORT_PTS_UTMI | PORT_PTS_PTW)
|
||||
#define CONFIG_USB_MAX_CONTROLLER_COUNT 2
|
||||
|
||||
#endif /*__IMX8MM_CL_IOT_GATE_H*/
|
100
include/configs/imx8mm_icore_mx8mm.h
Normal file
100
include/configs/imx8mm_icore_mx8mm.h
Normal file
|
@ -0,0 +1,100 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0+ */
|
||||
/*
|
||||
* Copyright (c) 2020 Engicam srl
|
||||
* Copyright (c) 2020 Amarula Solutions(India)
|
||||
*/
|
||||
|
||||
#ifndef __IMX8MM_ICORE_MX8MM_H
|
||||
#define __IMX8MM_ICORE_MX8MM_H
|
||||
|
||||
#include <linux/sizes.h>
|
||||
#include <asm/arch/imx-regs.h>
|
||||
|
||||
#define CONFIG_SPL_MAX_SIZE (148 * 1024)
|
||||
#define CONFIG_SYS_MONITOR_LEN SZ_512K
|
||||
#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR
|
||||
#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300
|
||||
#define CONFIG_SYS_UBOOT_BASE \
|
||||
(QSPI0_AMBA_BASE + CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR * 512)
|
||||
|
||||
#ifdef CONFIG_SPL_BUILD
|
||||
# define CONFIG_SPL_STACK 0x920000
|
||||
# define CONFIG_SPL_BSS_START_ADDR 0x910000
|
||||
# define CONFIG_SPL_BSS_MAX_SIZE SZ_8K
|
||||
# define CONFIG_SYS_SPL_MALLOC_START 0x42200000
|
||||
# define CONFIG_SYS_SPL_MALLOC_SIZE SZ_512K
|
||||
|
||||
/* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
|
||||
# define CONFIG_MALLOC_F_ADDR 0x930000
|
||||
/* For RAW image gives a error info not panic */
|
||||
# define CONFIG_SPL_ABORT_ON_RAW_IMAGE
|
||||
#endif /* CONFIG_SPL_BUILD */
|
||||
|
||||
#define CONFIG_SYS_MEMTEST_START PHYS_SDRAM
|
||||
#define CONFIG_SYS_MEMTEST_END (CONFIG_SYS_MEMTEST_START + (PHYS_SDRAM_SIZE >> 1))
|
||||
|
||||
#ifndef CONFIG_SPL_BUILD
|
||||
#define BOOT_TARGET_DEVICES(func) \
|
||||
func(MMC, mmc, 2) \
|
||||
func(MMC, mmc, 0)
|
||||
#include <config_distro_bootcmd.h>
|
||||
#undef CONFIG_ISO_PARTITION
|
||||
#else
|
||||
#define BOOTENV
|
||||
#endif
|
||||
|
||||
#define ENV_MEM_LAYOUT_SETTINGS \
|
||||
"fdt_addr_r=0x44000000\0" \
|
||||
"kernel_addr_r=0x42000000\0" \
|
||||
"ramdisk_addr_r=0x46400000\0" \
|
||||
"scriptaddr=0x46000000\0"
|
||||
|
||||
#define CONFIG_EXTRA_ENV_SETTINGS \
|
||||
ENV_MEM_LAYOUT_SETTINGS \
|
||||
"fdtfile=" CONFIG_DEFAULT_FDT_FILE "\0" \
|
||||
"console=ttymxc1,115200\0" \
|
||||
BOOTENV
|
||||
|
||||
/* Link Definitions */
|
||||
#define CONFIG_LOADADDR 0x40480000
|
||||
#define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
|
||||
|
||||
#define CONFIG_SYS_INIT_RAM_ADDR 0x40000000
|
||||
#define CONFIG_SYS_INIT_RAM_SIZE SZ_2M
|
||||
#define CONFIG_SYS_INIT_SP_OFFSET \
|
||||
(CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
|
||||
#define CONFIG_SYS_INIT_SP_ADDR \
|
||||
(CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
|
||||
|
||||
/* Size of malloc() pool */
|
||||
#define CONFIG_SYS_MALLOC_LEN SZ_32M
|
||||
#define CONFIG_SYS_SDRAM_BASE 0x40000000
|
||||
|
||||
/* SDRAM configuration */
|
||||
#define PHYS_SDRAM 0x40000000
|
||||
#define PHYS_SDRAM_SIZE SZ_2G /* 2GB DDR */
|
||||
#define CONFIG_SYS_BOOTM_LEN SZ_256M
|
||||
|
||||
#define CONFIG_SYS_MEMTEST_START PHYS_SDRAM
|
||||
#define CONFIG_SYS_MEMTEST_END \
|
||||
(CONFIG_SYS_MEMTEST_START + (PHYS_SDRAM_SIZE >> 1))
|
||||
|
||||
/* UART */
|
||||
#define CONFIG_MXC_UART_BASE UART2_BASE_ADDR
|
||||
|
||||
/* Monitor Command Prompt */
|
||||
#define CONFIG_SYS_CBSIZE 2048
|
||||
#define CONFIG_SYS_MAXARGS 64
|
||||
#define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE
|
||||
#define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + \
|
||||
sizeof(CONFIG_SYS_PROMPT) + 16)
|
||||
|
||||
/* USDHC */
|
||||
#define CONFIG_SYS_FSL_USDHC_NUM 2
|
||||
#define CONFIG_SYS_FSL_ESDHC_ADDR 0
|
||||
#define CONFIG_SYS_MMC_IMG_LOAD_PART 1
|
||||
|
||||
/* I2C */
|
||||
#define CONFIG_SYS_I2C_SPEED 100000
|
||||
|
||||
#endif /* __IMX8MM_ICORE_MX8MM_H */
|
104
include/configs/imx8mq_cm.h
Normal file
104
include/configs/imx8mq_cm.h
Normal file
|
@ -0,0 +1,104 @@
|
|||
/* SPDX-License-Identifier: GPL-2.0+ */
|
||||
/*
|
||||
* Copyright 2018 NXP
|
||||
*/
|
||||
|
||||
#ifndef __IMX8M_CM_H
|
||||
#define __IMX8M_CM_H
|
||||
|
||||
#include <linux/sizes.h>
|
||||
#include <linux/stringify.h>
|
||||
#include <asm/arch/imx-regs.h>
|
||||
|
||||
#define CONFIG_SYS_BOOTM_LEN (32 * SZ_1M)
|
||||
|
||||
#define CONFIG_SPL_MAX_SIZE (124 * 1024)
|
||||
#define CONFIG_SYS_MONITOR_LEN (512 * 1024)
|
||||
#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_USE_SECTOR
|
||||
#define CONFIG_SYS_MMCSD_RAW_MODE_U_BOOT_SECTOR 0x300
|
||||
|
||||
#ifdef CONFIG_SPL_BUILD
|
||||
#define CONFIG_SPL_STACK 0x187FF0
|
||||
#define CONFIG_SPL_BSS_START_ADDR 0x00180000
|
||||
#define CONFIG_SPL_BSS_MAX_SIZE 0x2000 /* 8 KB */
|
||||
#define CONFIG_SYS_SPL_MALLOC_START 0x42200000
|
||||
#define CONFIG_SYS_SPL_MALLOC_SIZE 0x80000 /* 512 KB */
|
||||
#define CONFIG_SYS_SPL_PTE_RAM_BASE 0x41580000
|
||||
|
||||
/* malloc f used before GD_FLG_FULL_MALLOC_INIT set */
|
||||
#define CONFIG_MALLOC_F_ADDR 0x182000
|
||||
/* For RAW image gives a error info not panic */
|
||||
#define CONFIG_SPL_ABORT_ON_RAW_IMAGE
|
||||
|
||||
#endif
|
||||
|
||||
#define CONFIG_REMAKE_ELF
|
||||
|
||||
/* ENET Config */
|
||||
/* ENET1 */
|
||||
#if defined(CONFIG_CMD_NET)
|
||||
#define CONFIG_ETHPRIME "FEC"
|
||||
#endif
|
||||
|
||||
#ifndef CONFIG_SPL_BUILD
|
||||
#define BOOT_TARGET_DEVICES(func) \
|
||||
func(MMC, mmc, 0) \
|
||||
func(MMC, mmc, 1) \
|
||||
func(DHCP, dhcp, na)
|
||||
|
||||
#include <config_distro_bootcmd.h>
|
||||
#endif
|
||||
|
||||
/* Initial environment variables */
|
||||
#define CONFIG_EXTRA_ENV_SETTINGS \
|
||||
BOOTENV \
|
||||
"scriptaddr=0x43500000\0" \
|
||||
"kernel_addr_r=0x40880000\0" \
|
||||
"image=Image\0" \
|
||||
"console=ttymxc0,115200\0" \
|
||||
"fdt_addr=0x43000000\0" \
|
||||
"boot_fdt=try\0" \
|
||||
"fdt_file=imx8mq-cm.dtb\0" \
|
||||
"initrd_addr=0x43800000\0" \
|
||||
"bootm_size=0x10000000\0" \
|
||||
"mmcpart=" __stringify(CONFIG_SYS_MMC_IMG_LOAD_PART) "\0" \
|
||||
"mmcroot=" CONFIG_MMCROOT " rootwait rw\0" \
|
||||
|
||||
/* Link Definitions */
|
||||
#define CONFIG_LOADADDR 0x40480000
|
||||
|
||||
#define CONFIG_SYS_LOAD_ADDR CONFIG_LOADADDR
|
||||
|
||||
#define CONFIG_SYS_INIT_RAM_ADDR 0x40000000
|
||||
#define CONFIG_SYS_INIT_RAM_SIZE 0x80000
|
||||
#define CONFIG_SYS_INIT_SP_OFFSET \
|
||||
(CONFIG_SYS_INIT_RAM_SIZE - GENERATED_GBL_DATA_SIZE)
|
||||
#define CONFIG_SYS_INIT_SP_ADDR \
|
||||
(CONFIG_SYS_INIT_RAM_ADDR + CONFIG_SYS_INIT_SP_OFFSET)
|
||||
|
||||
#define CONFIG_MMCROOT "/dev/mmcblk1p2" /* USDHC2 */
|
||||
|
||||
/* Size of malloc() pool */
|
||||
#define CONFIG_SYS_MALLOC_LEN ((CONFIG_ENV_SIZE + (2 * 1024)) * 1024)
|
||||
|
||||
#define CONFIG_SYS_SDRAM_BASE 0x40000000
|
||||
#define PHYS_SDRAM 0x40000000
|
||||
#define PHYS_SDRAM_SIZE 0x40000000 /* 1 GB DDR */
|
||||
|
||||
#define CONFIG_MXC_UART_BASE UART1_BASE_ADDR
|
||||
|
||||
/* Monitor Command Prompt */
|
||||
#define CONFIG_SYS_CBSIZE 1024
|
||||
#define CONFIG_SYS_MAXARGS 64
|
||||
#define CONFIG_SYS_BARGSIZE CONFIG_SYS_CBSIZE
|
||||
#define CONFIG_SYS_PBSIZE (CONFIG_SYS_CBSIZE + \
|
||||
sizeof(CONFIG_SYS_PROMPT) + 16)
|
||||
|
||||
#define CONFIG_IMX_BOOTAUX
|
||||
|
||||
#define CONFIG_SYS_FSL_USDHC_NUM 2
|
||||
#define CONFIG_SYS_FSL_ESDHC_ADDR 0
|
||||
|
||||
#define CONFIG_SYS_MMC_IMG_LOAD_PART 1
|
||||
|
||||
#endif
|
|
@ -64,23 +64,25 @@
|
|||
"vt.global_cursor_default=0 bootcause=${bootcause} ${quiet}\0" \
|
||||
"bootargs_emmc=setenv bootargs root=/dev/${rootdev}${partnum} ro " \
|
||||
"rootwait ${bootargs}\0" \
|
||||
"doquiet=if ext2load ${dev} ${devnum}:5 0x7000A000 /boot/console; " \
|
||||
"then setenv quiet; fi\0" \
|
||||
"doquiet=" \
|
||||
"if ext2load ${dev} ${devnum}:5 0x7000A000 /boot/console; " \
|
||||
"then setenv quiet; fi\0" \
|
||||
"hasfirstboot=" \
|
||||
"test -e ${dev} ${devnum}:${partnum} /boot/bootcause/firstboot\0" \
|
||||
"swappartitions=setexpr partnum 3 - ${partnum}\0" \
|
||||
"swappartitions=" \
|
||||
"setexpr partnum 3 - ${partnum}\0" \
|
||||
"failbootcmd=" \
|
||||
"cls; " \
|
||||
"setcurs 5 4; " \
|
||||
"lcdputs \"Monitor failed to start. " \
|
||||
"Try again, or contact GE Service for support.\"; " \
|
||||
"bootcount reset; \0" \
|
||||
"bootcount reset; " \
|
||||
"while true; do sleep 1; done; \0" \
|
||||
"altbootcmd=" \
|
||||
"run doquiet; " \
|
||||
"setenv partnum 1; run hasfirstboot || setenv partnum 2; " \
|
||||
"run hasfirstboot || setenv partnum 0; " \
|
||||
"if test ${partnum} != 0; then " \
|
||||
"setenv bootcause REVERT; " \
|
||||
"run swappartitions loadimage doboot; " \
|
||||
"fi; " \
|
||||
"run failbootcmd\0" \
|
||||
|
@ -101,10 +103,8 @@
|
|||
"lcd:800x480-24@60,monitor=lcd\0" \
|
||||
|
||||
#define CONFIG_MMCBOOTCOMMAND \
|
||||
"if mmc dev ${devnum}; then " \
|
||||
"run doquiet; " \
|
||||
"run tryboot; " \
|
||||
"fi; " \
|
||||
"run doquiet; " \
|
||||
"run tryboot; " \
|
||||
|
||||
#define CONFIG_BOOTCOMMAND CONFIG_MMCBOOTCOMMAND
|
||||
|
||||
|
|
|
@ -1690,6 +1690,14 @@ int sandbox_pci_get_emul(const struct udevice *bus, pci_dev_t find_devfn,
|
|||
*/
|
||||
int sandbox_pci_get_client(struct udevice *emul, struct udevice **devp);
|
||||
|
||||
/**
|
||||
* board_pci_fixup_dev() - Board callback for PCI device fixups
|
||||
*
|
||||
* @bus: PCI bus
|
||||
* @dev: PCI device
|
||||
*/
|
||||
extern void board_pci_fixup_dev(struct udevice *bus, struct udevice *dev);
|
||||
|
||||
#endif /* CONFIG_DM_PCI */
|
||||
|
||||
/**
|
||||
|
|
Loading…
Reference in a new issue