This is the version 2 of the LS1021A patches. It merges the machine support into the Layerscape machine and add minimal support for UART, DDR3 and SPI boot. Unlike version 1, the network support is not present and will be provided in another patch. The code is ported from NXP U-boot 2021-04. Renaud Barbier (2): ARM: add LS1021A to Layerscape machine support ARM: Layerscape: Add LS1021A IOT board support arch/arm/boards/Makefile | 1 + arch/arm/boards/ls1021aiot/Makefile | 3 + arch/arm/boards/ls1021aiot/board.c | 47 +++ arch/arm/boards/ls1021aiot/lowlevel.c | 120 ++++++ arch/arm/boards/ls1021aiot/ls102xa_pbi.cfg | 11 + .../boards/ls1021aiot/ls102xa_rcw_sd_qspi.cfg | 8 + arch/arm/boards/ls1021aiot/start.S | 11 + arch/arm/boards/ls1046ardb/lowlevel.c | 4 +- arch/arm/boards/tqmls1046a/board.c | 2 +- arch/arm/boards/tqmls1046a/lowlevel.c | 6 +- arch/arm/configs/layerscape_v7_defconfig | 94 +++++ arch/arm/dts/Makefile | 1 + arch/arm/dts/fsl-ls1021a-iot.dts | 77 ++++ arch/arm/lib32/Makefile | 1 + arch/arm/lib32/pbl.c | 21 + arch/arm/mach-layerscape/Kconfig | 14 + arch/arm/mach-layerscape/Makefile | 9 +- arch/arm/mach-layerscape/boot.c | 11 +- arch/arm/mach-layerscape/errata.c | 64 +-- .../mach-layerscape/include/mach/debug_ll.h | 5 +- .../arm/mach-layerscape/include/mach/errata.h | 4 +- .../mach-layerscape/include/mach/fsl_epu.h | 67 ++++ .../mach-layerscape/include/mach/layerscape.h | 13 +- .../mach-layerscape/include/mach/lowlevel.h | 1 + arch/arm/mach-layerscape/include/mach/xload.h | 4 +- arch/arm/mach-layerscape/lowlevel-ls102xa.c | 379 ++++++++++++++++++ arch/arm/mach-layerscape/lowlevel-ls1046a.c | 2 +- arch/arm/mach-layerscape/ls102xa_stream_id.c | 47 +++ arch/arm/mach-layerscape/ls102xa_stream_id.h | 15 + arch/arm/mach-layerscape/restart.c | 27 ++ arch/arm/mach-layerscape/xload-qspi.c | 4 +- arch/arm/mach-layerscape/xload.c | 8 +- images/Makefile.layerscape | 9 + include/soc/fsl/immap_lsch2.h | 171 +++++++- 34 files changed, 1208 insertions(+), 53 deletions(-) create mode 100644 arch/arm/boards/ls1021aiot/Makefile create mode 100644 arch/arm/boards/ls1021aiot/board.c create mode 100644 arch/arm/boards/ls1021aiot/lowlevel.c create mode 100644 arch/arm/boards/ls1021aiot/ls102xa_pbi.cfg create mode 100644 arch/arm/boards/ls1021aiot/ls102xa_rcw_sd_qspi.cfg create mode 100644 arch/arm/boards/ls1021aiot/start.S create mode 100644 arch/arm/configs/layerscape_v7_defconfig create mode 100644 arch/arm/dts/fsl-ls1021a-iot.dts create mode 100644 arch/arm/lib32/pbl.c create mode 100644 arch/arm/mach-layerscape/include/mach/fsl_epu.h create mode 100644 arch/arm/mach-layerscape/lowlevel-ls102xa.c create mode 100644 arch/arm/mach-layerscape/ls102xa_stream_id.c create mode 100644 arch/arm/mach-layerscape/ls102xa_stream_id.h create mode 100644 arch/arm/mach-layerscape/restart.c -- 2.27.0