summaryrefslogtreecommitdiff
path: root/arch
AgeCommit message (Collapse)Author
2020-12-28apalis-imx8x: fix flags properties for usbotg1toradex_imx_v2020.04_5.4.24_2.1.0Oleksandr Suvorov
The driver supports combined flag to disable srp/hnp and doesn't support disabling adp. Fix flag properties. Related-to: ELB-3424 Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
2020-12-28apalis-imx8x: enable on-board USB hub and USBH3/4 portsOleksandr Suvorov
Currently the Cadence,usb3 driver doesn't support a phy vbus regulator. Emulate it keeping the USBH_EN signal high with gpio-hog entry. This enables the on-board USB-Hub with ports USB2[ABCD] and on-board USB ports USBH3/4. Related-to: ELB-3424 Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
2020-12-28apalis-imx8x: request usbh_en signal pinOleksandr Suvorov
Request using the pin of USBH_EN signal that enables on-board USB hub (USBH2[ABCD] ports) and USBH3/4 ports. Related-to: ELB-3424 Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
2020-12-28apalis-imx8x: fix host mode for usbotg1 portOleksandr Suvorov
Trying to use the usbotg1 port in host mode led to the following error: ================= starting USB... Bus usb@5b0d0000: usb dr_mode not found Port not available. ================= Adding the correct dual-role mode fixes this issue and let the usbotg1 port working in both peripheral and host mode. Related-to: ELB-3424 Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
2020-12-13verdin imx8mp: change on-carrier phy addressMarcel Ziswiler
Both Verdin Developer Board V1.0A and V1.1A have their PHYs at address 7. Only V1.0B had it at the address 3! Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2020-12-13verdin imx8mp: remove defunct regulator-on-bootMarcel Ziswiler
Turns out U-Boot won't do anything with those even if paired with regulator-always-on. I guess this is due to U-Boot's lazy loading. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2020-12-03imx8m/soc.c: deleting phandles pointing to deleted cpusMax Krummenacher
For i.MX8M Mini with less than 4 CPU cores the code patches the device tree to reflect that and deletes the nodes representing the not existing cores. The deleted nodes are referenced by phandles in the following two properties: /thermal-zones/cpu-thermal/cooling-maps/map0/cooling-device /pmu/interrupt-affinity Modify these properties to no longer contain the phandles to no longer existing nodes. Fixes the thermal subsystem which otherwise bails out with: [ 0.102895] OF: /thermal-zones/cpu-thermal/cooling-maps/map0: could not find phandle [ 0.102922] thermal_sys: failed to build thermal zone cpu-thermal: -22 [ 1.377046] i.mx8mm_thermal 30260000.tmu: failed to register thermal zone sensor[0]: 0 [ 3.013718] i.mx8mm_thermal 30260000.tmu: failed to register thermal zone sensor[0]: 0 ... Related-to: ELB-3292 Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2020-12-03imx8m/soc.c: drop some printfMax Krummenacher
Each node which gets touched prints two lines. Drop the one that the node is found. I.e. all "Found..." lines in U-Boot output are now suppressed: | Found /vpu_g1@38300000 node | Modify /vpu_g1@38300000:status disabled | Found /vpu_g2@38310000 node | Modify /vpu_g2@38310000:status disabled | Found /vpu_h1@38320000 node | Modify /vpu_h1@38320000:status disabled | Found /cpus/cpu@2 node | Delete node /cpus/cpu@2 | Found /cpus/cpu@3 node | Delete node /cpus/cpu@3 Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2020-11-19board: toradex: add verdin imx8m plus supportMarcel Ziswiler
This adds initial minimal support for the Toradex Verdin iMX8M Plus Quad 4GB WB IT V1.0A and Toradex Verdin iMX8M Plus Quad 2GB V1.0A modules. They are strapped to boot from eFuses which are factory fused to properly boot from their on-module eMMC. U-Boot supports booting from the on-module eMMC or, if the recovery button/pin is asserted, via USB serial download aka SDP support. Functionality wise the following is known to be working: - eMMC, 8-bit and 4-bit MMC/SD card slots - Ethernet (but only 2nd one available on the Verdin Development board) - GPIOs - I2C Boot sequence is: SPL ---> ATF (TF-A) ---> U-boot proper ATF, U-boot proper and u-boot.dtb images are packed into a FIT image, loaded by SPL. Boot: U-Boot SPL 2020.04-00217-gfad48768ba (Nov 18 2020 - 14:22:31 +0100) DDRINFO: start DRAM init DDRINFO: DRAM rate 4000MTS DDRINFO:ddrphy calibration done DDRINFO: ddrmix config done Normal Boot Trying to boot from BOOTROM Find FIT header 0x4803afa0, size 855 Need continue download 1024 Download 833424, total fit 834544 NOTICE: BL31: v2.2(release):imx_5.4.24_er3-6-g0a236bda5 NOTICE: BL31: Built : 13:40:19, Nov 12 2020 U-Boot 2020.04-00217-gfad48768ba (Nov 18 2020 - 14:22:31 +0100) alloc_simple() alloc space exhausted CPU: i.MX8MP[8] rev1.0 1800 MHz (running at 1200 MHz) CPU: Commercial temperature grade (0C to 95C) at 46C Reset cause: POR DRAM: 4 GiB MMC: FSL_SDHC: 1, FSL_SDHC: 2 In: serial Out: serial Err: serial Model: Toradex Verdin iMX8M Plus Quad 4GB Wi-Fi / BT IT V1.0A, Serial# 06775455 MISSING TORADEX CARRIER CONFIG BLOCKS BuildInfo: - ATF 0a236bd - U-Boot 2020.04-00217-gfad48768ba Detect USB boot. Will enter fastboot mode! Net: Warning: ethernet@30bf0000 (eth1) using random MAC address - 56:c0:c6:84:63:a0 eth0: ethernet@30be0000, eth1: ethernet@30bf0000 [PRIME] Fastboot: Normal Boot from USB for mfgtools *** Warning - Use default environment for mfgtools , using default environment Run bootcmd_mfg: fastboot 0 Hit any key to stop autoboot: 0 Verdin iMX8MP # Related-to: ELB-3208 Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2020-11-19imx8m: make board_phys_sdram_size() two bank awareMarcel Ziswiler
Make weak board_phys_sdram_size() function two bank aware. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2020-11-18imx: romapi: fix spurious ampersand in address printMarcel Ziswiler
Fix spurious ampersand in address print e.g. Find FIT header 0x&480331a0, size 855 Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com>
2020-10-19ARM: dts: fsl-imx8qxp-colibri: sync u-boot dtsi with MEKIgor Opaniuk
Sync U-Boot specific device tree include with NXP MEK platform. Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-10-19ARM: dts: fsl-imx8qxp-colibri: change hierarchy of device treeIgor Opaniuk
As U-Boot specific dtsi (fsl-imx8qxp-colibri-u-boot.dtsi) requires the nodes to be defined already before adding properties to them, move all module nodes that nodes to dtsi, and include both hw and u-boot specific dtsi's in proper order. Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-10-19ARM: dts: fsl-imx8qxp-colibri: drop u-boot properties from generic dtsIgor Opaniuk
Drop u-boot specific from generic device tree. Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-10-14ARM: dts: imx8mm-verdin: v1.1: follow changed pmicMax Krummenacher
The used PMIC has been changed from RHOM BD71837 to NXP PCA9450A. Adjust the device tree accordingly. Remove the old ADC node as the ADC has been changed and has no longer a separate power rail. Related-to: ELB-3130 Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2020-10-14ARM: dts: imx8mm-verdin: v1.1: introduced changed pin usageMax Krummenacher
The eMMC reset is now connected to SD1_RESET_B ball. Add that ball to eMMC pinctrl groups. The following signals are not used in U-Boot code, however they are changed from V1.0 to V1.1 HW. CTRL_FORCE_OFF_MOCI# used to be controlled by SAI5_RXC in V1.0 HW. In V1.1 HW it is no longer under SW control. -> The unused pinmuxing is deleted. Wi-Fi_WKUP_WLAN used to be controlled by SD1_RESET_B in V1.0 HW. In V1.1 HW it is controlled by SAI5_RXC. -> The pincontrol is updated to reflect V1.1 HW. Related-to: ELB-3150 Signed-off-by: Max Krummenacher <max.krummenacher@toradex.com>
2020-10-08ARM: dts: apalis-imx8qxp: remove unnecessary delay flagsPhilippe Schenker
Those flags are not implemented in U-Boot so delete them that they don't continue to confuse people. Related-to: ELB-3056 Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com>
2020-10-05colibri-imx8x: reserve usb cdet gpio pinOleksandr Suvorov
After running a command "ums" u-boot shows the warning: "gpio@5d0d0000: get_value: error: gpio GPIO5_9 not reserved". Reserve the usb_cdet pin (GPIO5_9) for usbotg1 to fix this warning. Related-to: ELB-3077 Signed-off-by: Oleksandr Suvorov <oleksandr.suvorov@toradex.com>
2020-09-18imx8: allow overriding memory layoutMarcel Ziswiler
Introduce weak function board_mem_get_layout() which allows overriding the memory layout from board code e.g. handy to do our SKU handling. Signed-off-by: Marcel Ziswiler <marcel.ziswiler@toradex.com> (cherry picked from commit e3baa4dcecb2ab6a70d8ec5617f544e2f4954027)
2020-09-07apalis-imx8x: fix usb enumeration issuesIgor Opaniuk
Now usb is enumerated (and USB OTG can work in both peripheral and host modes): Apalis iMX8X # usb reset resetting USB... Bus usb@5b0d0000: usb dr_mode not found USB EHCI 1.00 Bus usbh3: XHCI-imx8 init hccr 0x000000005b130000 and hcor 0x000000005b130080 hc_length 128 Register 2000820 NbrPorts 2 Starting the controller USB XHCI 1.00 scanning bus usb@5b0d0000 for devices... EHCI timed out on TD - token=0x80008c80 2 USB Device(s) found scanning bus usbh3 for devices... 1 USB Device(s) found scanning usb for storage devices... 1 Storage Device(s) found Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-08-20rename all occurences of apalis-imx8qm to apalis-imx8Philippe Schenker
The Toradex product is called apalis-imx8 consisting of SoM with i.MX8QM and i.MX8QP SoCs. Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com>
2020-08-20rename all occurences of colibri-imx8qxp to colibri-imx8xPhilippe Schenker
The Toradex product is called colibri-imx8x consisting of SoM with i.MX8QXP and i.MX8DX SoCs. Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com>
2020-08-20arm: dts: colibri-imx8qxp: remove old earlycon descriptionPhilippe Schenker
works also without so remove this old description. Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com>
2020-08-20board: add apalis-imx8xPhilippe Schenker
Signed-off-by: Philippe Schenker <philippe.schenker@toradex.com>
2020-08-06verdin-imx8mm: fix usb otg issueIgor Opaniuk
Add usbg1/usbg2 and appropriate aliases, so correct usbotg is used for UMS. Relates-to: ELB-2919 Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-08-05apalix-imx8: up-port initial implementationIgor Opaniuk
Boot test: U-Boot 2020.04-00118-gea539ce4dc-dirty (Jul 31 2020 - 22:57:53 +0300) CPU: NXP i.MX8QM RevB A53 at 1200 MHz DRAM: 4 GiB MMC: FSL_SDHC: 0, FSL_SDHC: 1, FSL_SDHC: 2 Loading Environment from MMC... OK In: serial@5a070000 Out: serial@5a070000 Err: serial@5a070000 Model: Toradex Apalis iMX8 QuadMax 4GB Wi-Fi / BT IT V1.0B, Serial# 06438736 switch to partitions #0, OK ----------------------------------------- Was tested with: imx-mkimage: imx_5.4.24_2.1.0 imx-scfw: ab182211e("Update .gitignore to ignore our built files...") imx-atf: imx_5.4.24_2.1.0 imx-seco: 3.6.3 [1] ----------------------------------------- USB test: - USB flash drive connected with OTG cable (USBO1) - works => usb tree USB device tree: 1 Hub (480 Mb/s, 0mA) | u-boot EHCI Host Controller | +-2 Mass Storage (480 Mb/s, 200mA) USB DISK 2.0 077507A9002D 1 Hub (5 Gb/s, 0mA) U-Boot XHCI Host Controller - USB flash drive connected to USB 3.0 port (USBH4) - works => usb tree USB device tree: 1 Hub (5 Gb/s, 0mA) | U-Boot XHCI Host Controller | +-2 Mass Storage (480 Mb/s, 200mA) USB DISK 2.0 077507A9002D - USB flash drive connected to one of 4 USB 2.0 (USBH2 and USBH3) - doesn't (isn't enumerated at all) - UMS works (USBO1) ----------------------------------------- Network test: => dhcp BOOTP broadcast 1 DHCP client bound to address 192.168.88.251 (4 ms) Using ethernet@5b040000 device TFTP from server 192.168.88.2; our IP address is 192.168.88.251 Filename 'zImage'. Load address: 0x80280000 Loading: ################################################## 5.3 MiB 20.7 MiB/s done Bytes transferred = 5598256 (556c30 hex) ----------------------------------------- MMC test: => mmc rescan => mmc list FSL_SDHC: 0 (eMMC) FSL_SDHC: 1 FSL_SDHC: 2 ----------------------------------------- Dropped patches from toradex_imx_v2018.03_4.14.98_2.3.0_bringup as they have come in from mainline v2020.04 or just not relevant anymore: 2773302a("apalis-imx8: initial add") 09ab034c("apalis-imx8: add Apalis iMX8 specific device tree") 3e9d6dad("apalis-imx8: fix eMMC/MMC/SD interface muxing") 55cedfc1("apalis-imx8: remove unavailable peripherals") 1125cb6b("apalis-imx8: remove PCA9557 GPIO controllers") 47b1eeb2("apalis-imx8: fix Ethernet") 8e37e076("imx8: support UART1 as console UART for Apalis iMX8") d42b68ec("apalis-imx8: use UART1 as console UART") 2e356ef5("apalis-imx8: remove unused GPIOs") 954bef99("apalis-imx8: set device tree to Apalis DT by default") ce9ae949("apalis-imx8: load HDMI firmware") e90b8d36("apalis-imx8: use eMMC as environment location/default boot device") d872cd6e("apalis-imx8: add default memory layout and network options") ee3bf34e("tdx-cfg-block: add Apalis iMX8 QuadMax support") cdac0b13("apalis-imx8: config: remove pcie and sata") 1e77935d("apalis-imx8.c: fix typo") 3e6440d1("apalis-imx8: forward port to 2018.03") 365994c5("apalis-imx8: adjust copyright/licensing headers") 365994c5("apalis-imx8: adjust copyright/licensing headers ") 5bd6bdb9("apalis-imx8: change top-level compatible") 3d7dde4f("apalis-imx8: clean-up device tree") 5d2d7ec2("apalis-imx8: clean-up configuration") 58354713("apalis-imx8: clean-up board file") 7af4c9cb("apalis-imx8: fused modules boot from emmc") 478ad2f0("apalis-imx8: clean-up ethernet functionality") dfc9a6db("apalis-imx8: remove board code for usdhc") f574377c("apalis-imx8: modify default ramdisk loading address") 186747eb("apalis-imx8: do not undef configs configured using Kconfig") adb20873("apalis-imx8: make sure config block fdt fix-ups are called") ff45d3d5("apalis-imx8: increase bootm loading size") 912a867e("apalis-imx8: enable distro boot in tezi") b7beb5e5("apalis-imx8.h: move environment into first boot area") 70a89d49("apalis-imx8: add scriptaddr for distroboot") ca562b4d("apalis-imx8: enable FDT relocation") 32948b33("apalis-imx8: fix ramdisk relocation address") 62493440("apalis-imx8/colibri-imx8x: use proper distroboot script") f1993901("apalis-imx8/colibri-imx8x: set fdtfile since it is used by distro bootcmd") 83ec3f91("include: apalis-imx8.h: add default tdxargs pci=nomsi") bb64b46f("include: apalis-imx8.h: change tdxargs to defargs for pci_nomsi") a638c2aa("include: apalis-imx8.h: change default devicetree file") 7a829fc7("configs: apalis/colibri-imx8: change bootdelay to one second") c707a04a("ARM: dts: imx8qxp-apalis: Remove phy-reset-post-delay") 6415bc94("config: apalis/colibri-imx8*: Add fdt_high variable without value") 96c61bda("ARM: dts: apalis-imx8qm: update node fec1") cb3eb29b("config: apalis-imx8: fix auto-negotiation timeout error") 34ecf495("apalis-imx8: Remove fdt_file env variable") ff527ebc("apalis-imx8: Implement hardware version detection") 4653dcf8("apalis-imx8x: sync with MEK platform") 5b32f0b4("apalis-imx8: Fix hardware version detection in recovery mode") d626574b("apalis-imx8x: usb3 bringup") [1] https://www.nxp.com/lgfiles/NMG/MAD/YOCTO/imx-seco-3.6.3.bin Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-08-05colibri-imx8x: up-port initial implementationIgor Opaniuk
USB (both host and device), Networking, MMC/SD work. Testing: ----------------------------------------------- U-Boot 2020.04-00119-g9dc5e94cb0-dirty (Jul 30 2020 - 22:36:54 +0300) CPU: NXP i.MX8QXP RevB A35 at 1200 MHz at 47C DRAM: 2 GiB MMC: FSL_SDHC: 0, FSL_SDHC: 1 Loading Environment from MMC... OK In: serial@5a090000 Out: serial@5a090000 Err: serial@5a090000 Model: Toradex Colibri iMX8 QuadXPlus 2GB Wi-Fi / BT IT V1.0B, Serial# 06494331 Net: eth0: ethernet@5b040000 [PRIME] Boot from USB for mfgtools Hit any key to stop autoboot: 0 ----------------------------------------------- Was tested with: imx-mkimage: imx_5.4.24_2.1.0 imx-scfw: ab182211e("Update .gitignore to ignore our built files and files from vscode") imx-atf: imx_5.4.24_2.1.0 imx-seco: 3.6.3 [1] ----------------------------------------------- Dropped patches from toradex_imx_v2018.03_4.14.98_2.3.0_bringup as they have come in from mainline v2020.04 or just not relevant anymore: 9bfdda4f ("tdx-cfg-block.c: correct colibri imx8 string") ae52342b ("colibri-imx8qxp: initial add") 9b950998 ("colibri-imx8qxp: move debug uart to lpuart3") f9b0065b ("colibri-imx8qxp: synchronize with imx8qxp-mek from beta2") 982b4667 ("colibri-imx8qxp: forward port to 2018.03") 5c80880d ("colibri-imx8qxp: add unused pins as gpio") 30b37a6a ("colibri-imx8qxp: adjust copyright/licensing headers) 873a9561 ("colibri-imx8qxp: fix top-level compatible") 0e0f095d ("colibri-imx8qxp: clean-up device tree") f61187df ("colibri-imx8qxp: clean-up configuration") 85a5d16b ("colibri-imx8qxp: clean-up board file") a5a9bb4b ("colibri-imx8qxp: fused modules boot from emmc") 39c20ddd ("colibri-imx8qxp: default to dsihdmi device tree") 7443a6e5 ("colibri-imx8qxp: fix usb device/host functionality") c721083a ("colibri-imx8qxp: fix ethernet functionality") 9f40db9d ("colibri-imx8qxp: adjust copyright/licensing headers some more") 9070b6f0 ("colibri-imx8qxp: dts: clean-up whitespace") 257470ac ("colibri-imx8x: enable FDT relocation") a9272336 ("colibri-imx8qxp: change default device tree") 8470fb25 ("colibri-imx8x/apalis-imx8: converge scriptaddr for distroboot") 62493440 ("apalis-imx8/colibri-imx8x: use proper distroboot script") f1993901 ("apalis-imx8/colibri-imx8x: set fdtfile since it is used by distro bootcmd") 890d03ae ("colibri-imx8qxp: sync with MEK platform") eeb1d9b8 ("colibri-imx8qxp: move environment into first boot area") c8c562ea ("colibri-imx8qxp: do not undef configs configured using Kconfig") 12489199 ("colibri-imx8qxp: make sure config block fdt fix-ups are called") 6a84ffaa ("colibri-imx8qxp: modify default ramdisk loading address") [1] https://www.nxp.com/lgfiles/NMG/MAD/YOCTO/imx-seco-3.6.3.bin Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-07-21board: toradex: up-port verdin imx8mm module supportIgor Opaniuk
This patch introduces changes on top of existing Verdin iMX8MM support in the mainline U-Boot v2020.04. Some patches were already upstreamed, some were squashed and included into this commit: 78e80d3f ("board: toradex: add verdin imx8mm 2gb wb it v1.0a module support") a6c18891 ("verdin-imx8mm: lpddr4_timing.c: intial lpddr4 calibration data") b16da3d6 ("verdin-imx8mm: fix usb_1 device aka peripheral operation") 6451e680 ("verdin-imx8: do not undef configs configured using Kconfig") d5382436 ("fsl-imx8mm-verdin.dts: remove fsl,rgmii_rxc_dly et. al.") c24fe844 ("fsl-imx8mm-verdin.dts: fix eth phy power up") b07ae5f3 ("verdin-imx8mm.c: set eth phy skew") 4eb91e6e ("tdx-cfg-block: adjust verdin naming") 569703d4 ("verdin-imx8mm: sync with EVK board") 8c8b56a5 ("tdx-cfg-block: add proper defines for other Verdin SKUs") Relates-to: ELB-2771 Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-07-21ARM: dts: imx8mm-pinfunc: add additional muxingsIgor Opaniuk
Add alternative UART muxings. Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-07-21mach-imx: spl_sd: drop config includeIgor Opaniuk
Drop config.h include as it leads to compilation issues. Signed-off-by: Igor Opaniuk <igor.opaniuk@toradex.com>
2020-05-30MLK-24149 arm: imx8mp: update i.MX8MP pin headerPeng Fan
Update i.mx8mp pinfunc.h according to RM REV C. Reviewed-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit ba3bbb67f512400d9b67304d04cbfb7327fc4f35)
2020-05-28MLK-24192-2 DTS: imx8qm/qxp/dxl: Update PCIE clocksYe Li
Update PCIE clocks to align with latest v5.4 kernel, otherwise we may miss some LPCG clocks in u-boot and have potential problem if they have been disabled in kernel during partition reboot. Signed-off-by: Ye Li <ye.li@nxp.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit 76ebe2016c2ab7199cb6a6b83f8bc97fe0140549)
2020-05-28MLK-23820 imx8mq/mm: Add config to support secondary image bootYe Li
When primary image boot is failed, ROM will select secondary image to boot if SIT (secondary image table) exists. However, SPL does not know the secondary boot, still loads the FIT from the position of primary image. Introduce a config to add secondary image sector offset to FIT sector offset. This config is default set to 0. Secondary image should configure it to the same value of firstSectorNumber field in SIT. Signed-off-by: Ye Li <ye.li@nxp.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit 665972355dfe8156b3aa7bce52845722b15d9922)
2020-05-28MLK-24189-2 arm: imx: optee: ignore node create for xenPeng Fan
Ignore node create for xen, currently we not have valid registers when booting in xen, it might have garbage value and cause kernel hang. Reviewed-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit 0c6cc66b1181c72b8f9165875b9db075a1de89de)
2020-05-28MLK-24189-1 arm: dts: xen: drop power domain for gpio4/1Peng Fan
gpio4/1 is handled by dom0, but shared with domu. without dropping the power domain, probe will fail. Reviewed-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit aad3cccd54acdbb1f96df12189be9e8bc03a3a93)
2020-05-28MLK-24188-1 imx8: add AHB clk for SDHCPeng Fan
Add AHB clk for SDHC, without AHB clock, sdhc cmd will not finish. Reviewed-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit 3ea6b86eecbfd5a1e082b86c99e411af1310afa1)
2020-05-27MLK-24185: dts: imx8qxp: include the u-boot dtsi in gpmi dtsHan Xu
include the fsl-imx8qxp-lpddr4-val-u-boot.dtsi explicitly in imx8qxp-lpddr4-val-gpmi-nand.dts, otherwise boot image failed to boot due to some power domains were not enabled. Signed-off-by: Han Xu <han.xu@nxp.com> (cherry picked from commit 06ddd9e78bcad974fc4f0f05c6dcfacf8551d2d5)
2020-05-27MLK-24178 imx8: Fix build warning in sciYe Li
Find below warning on some boards, because sci.h does not include log.h. Fix the issue by replacing linux/errno.h to common.h ./arch/arm/include/asm/arch/sci/sci.h: In function ‘sc_err_to_linux’: ./arch/arm/include/asm/arch/sci/sci.h:56:2: warning: implicit declaration of function ‘debug’ [-Wimplicit-function-declaration] 56 | debug("%s %d %d\n", _func_, err, ret); Signed-off-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit 29509c2104e6820f6618074fd1f109c7ff70bdd2)
2020-05-27MLK-24172-1 imx8qm: update xen defconfig/dts for 2020.04Peng Fan
Update xen defconfig Update dts to let xen serial could be used in early stage, but seems without mmu enabled, it output nothing. It only output data after mmu enabled. Reviewed-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit c1ac080ab69b27e4a66aaf10a9b801d2a3c7b8d0)
2020-05-27MLK-20955 imx8qm: delete power-domains for lpuart0 on xenPeng Fan
To U-Boot on DomU, the lpuart0 is replaced with a xen paravirtual consol driver, but reused the previous lpuart node. However there is an power-domains entry in lpuart0 which will call power_domain_on and failed to probe xen paravirtual driver, because of recent change: commit 8524ca764d8f("MLK-20945-2 dm: device: Check the power up result in probe ") So remove the power-domains entry in lpuart0 to let DomU U-Boot could output again. Signed-off-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Flynn xu <flynn.xu@nxp.com> (cherry picked from commit 38155100481a07e961f375052241d9d03e20a899) (cherry picked from commit 92104edf74363ab1a322e186887bf4515d47aa9c) (cherry picked from commit 75074ecb28d47cb1064d10e3d0b85defd7fb3c87) (cherry picked from commit 87b6d6158dcd4132328a4891f6446a4b565e5ab6)
2020-05-27MLK-20383 imx8qm: xen: enable dm usbPeng Fan
Enable dm usb using the base board otg usb port for fastboot usage Signed-off-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Ye Li <ye.li@nxp.com> (cherry picked from commit 88a1718aa7096782e9cf538e391762aaef631bb2) (cherry picked from commit 279e82b731e7671536b729934e1dc88b760ea05a) (cherry picked from commit b874dc0882e329af07de4f6bb0d01573d4e02da2)
2020-05-27MLK-20373-6 imx8qm: xen: enable dm serialPeng Fan
Enable dm serial for xen uboot. Log as below: #xl console 1 MMC: FSL_SDHC: 0 Loading Environment from <NULL>... *** Warning - bad CRC, using default environment Failed (-5) In: serial@5a060000 Out: serial@5a060000 Err: serial@5a060000 flash target is MMC:0 Fastboot: Normal Normal Boot => Signed-off-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Flynn xu <flynn.xu@nxp.com> (cherry picked from commit 132cb6f74bcd963b180de83279f00aef31bbbdca) (cherry picked from commit 38313a6f8e437568dbc15075251d344fa67fd14b) (cherry picked from commit 653f877b1beb4779ef0c24b81ba428503ce8ae3d)
2020-05-27MLK-20373-4 imx8: update mem map tablePeng Fan
Update mem map table for xen uboot. xen console and some magic pages needs to be mappe as normal memory. Signed-off-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Flynn xu <flynn.xu@nxp.com> (cherry picked from commit c96a9844cd3342f6e31627ccc4f3e63544ffd78e) (cherry picked from commit 30b2d9f4a7c0cfc9b3f999f1c3a1a8c466d66a68) (cherry picked from commit 152de9a5752881e43dd7afc9b47afa56b3b230e8)
2020-05-27MLK-20373-3 armv8: xen: introduce new hypercallsPeng Fan
Introduce new hypercalls Signed-off-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Flynn xu <flynn.xu@nxp.com> (cherry picked from commit e1610fa574b20794c184e00d86c9d0f7505672f1) (cherry picked from commit 6e9e957e8d0891e4ec3bfb4b6c2bbef747eb8812) (cherry picked from commit 46a34b4456fb895786d25721b54a10e0182cb312)
2020-05-27MLK-20373-1 Intrdouce xen header filesPeng Fan
Introduce xen header files from Linux Kernel commit e2b623fbe6a3("Merge tag 's390-4.20-1' of git://git.kernel.org/pub/scm/linux/kernel/git/s390/linux") Signed-off-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Peng Fan <peng.fan@nxp.com> Reviewed-by: Flynn xu <flynn.xu@nxp.com> (cherry picked from commit ddb393c45158f6114bd53c83dcd8397a6c2acbdc) (cherry picked from commit 8591f37af6345695a98216c136e9209a880901f1) (cherry picked from commit b93308506902dd30b84640f59fa75ada21d8775a)
2020-05-27MLK-19552 imx8qm: xen: fix memory mapPeng Fan
Fixes 9486251ced24("MLK-19494 configs: imx8qm mek android audo: correct xen physical memory") correct text base, IPC address, memmap. Signed-off-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit 884cada50b9a9fcda09d259cf145d87a29122cac) (cherry picked from commit 55822e16786817f843d32c1347d705c2a2a435dd) (cherry picked from commit f13108a1842a2819489975f0d0040c9c65c3856c)
2020-05-27MLK-18614-3 Xen: imx8qm_mek: Fix the CONFIG_FASTBOOT_USB_DEV and DTB issueYe Li
Because the Xen u-boot is using OTG port not typec port, the CONFIG_FASTBOOT_USB_DEV should set to 0 not 1. Otherwise the fastboot will fail. Remove duplicated "/dts-v1/;" from Xen DTB. Signed-off-by: Ye Li <ye.li@nxp.com> (cherry picked from commit ceaa529b34752045dcd294572c30c7c56a48abe7) (cherry picked from commit 2942cb192c0fff45307042bf60da08a30ccddaf2) (cherry picked from commit 9e8b963dc74f54a781cdb495f24b9b6a669cd17e) (cherry picked from commit 17fd71abdfa9895275be17ed9391fb8b68cd85ef)
2020-05-27MLK-18577-7 imx8qm: mek: support uboot in vmPeng Fan
We are targeting let uboot loading images from emmc to boot android. Currently only emmc1 is enabled, so other devices are disabled. Also change memory layout according to VM layout. The memory layout needs to be samesize as what you configured in as "memory = "3584"". Add a new dts dedicated for this kind uboot, add a new defconfig to select CONFIG_XEN/CONFIG_XEN_DEBUG_SERIAL, deselect CONFIG_DM_SERIAL, select CONFIG_ENABLE_ARM_SOC_BOOT0_HOOK, and disable some devices compared with imx8qm_mek_androidauto_defconfig. Reviewed-by: Ye Li <ye.li@nxp.com> Signed-off-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit a4e932cae433b9d2e1cff6a94b12e4abcac45543) (cherry picked from commit a26de6e05563d3e3e6734e0d99e464437aa89db5) (cherry picked from commit 74ac579ee195c4a2f6651ccc0f86efb0eebd889e) (cherry picked from commit 7efc2eca10c9d48da6e01ba6a5df63b6f619d7ab)
2020-05-27MLK-18577-6 imx8: boot0: add boot headerPeng Fan
Starting U-Boot in a XEN VM, needs a header, just like Linux Kernel. Without it, xen tool will take is as a file not supported. Signed-off-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit 344ddf76c6de808699ab742d3c11728ca62f36ee) (cherry picked from commit d260e97be35718bea46019b7ca8666e83d0b9f01) (cherry picked from commit fa6d1e299da0f6913564dcb11c171cee69a43f8e) (cherry picked from commit 2f1f8069405bdb74d811bb594cbbea3d552fa31a)
2020-05-27MLK-18577-5 imx8: update soc code to support uboot in XEN VMPeng Fan
Update SOC code to support U-Boot in a XEN VM. Currently we only support to boot android using uboot in a VM, so there is hardcode that using MMC1_BOOT boot. There are a few small fixes included. For the mmu configuration, the mem map is used from xen guest VM and our iomem space in vm cfg file. Signed-off-by: Peng Fan <peng.fan@nxp.com> (cherry picked from commit 533087bc1bce0c35fead0956b0613971862c280f) (cherry picked from commit c2ba2460d8985aa0b084f7beef2d0bc8773d90e3) (cherry picked from commit 2b0a537f59646f3f222d60ebe46611160ba6bdc9) (cherry picked from commit 179a0a6ff3eba16fcf8d5966904b810531fe8665)