layerscape: update README for SD card boot and new devices

This patch is to update the README since SD card boot support
and LS1012AFRWY/LS1021ATWR were introduced.

Signed-off-by: Yangbo Lu <yangbo.lu@nxp.com>
master
Yangbo Lu 6 years ago committed by Hauke Mehrtens
parent 7016dd48f1
commit 0f44c7c8d1
  1. 176
      target/linux/layerscape/README

@ -4,10 +4,15 @@ Layerscape Quick Start
1. Layerscape target support 1. Layerscape target support
---------------------------- ----------------------------
* ARMv8 64-bit * ARMv8 64-bit
LS1012ARDB LS1012AFRDM LS1043ARDB LS1046ARDB LS1088ARDB LS2088ARDB LS1012ARDB LS1012AFRWY LS1043ARDB LS1046ARDB LS1088ARDB LS2088ARDB
(SD card boot support on LS1043ARDB/LS1046ARDB/LS1088ARDB)
* ARMv8 32-bit * ARMv8 32-bit
LS1012ARDB LS1012AFRDM LS1043ARDB LS1046ARDB LS1012ARDB LS1012AFRWY LS1043ARDB LS1046ARDB
* ARMv7
LS1021ATWR
(SD card boot support on LS1021ATWR)
2. Build 2. Build
@ -17,49 +22,12 @@ Before configuration and build, update and install package feeds.
$ ./scripts/feeds update -a $ ./scripts/feeds update -a
$ ./scripts/feeds install -a $ ./scripts/feeds install -a
2.1 make menuconfig * make menuconfig
------------------- Target System: "NXP Layerscape"
* For single device Subtarget: (Select subtarget)
Target Profile: (Select device, or "Multiple devices")
Target System: "NXP Layerscape". Target Devices: (Select devices. Available when Target Profile is "Multiple devices")
Subtarget: "ARMv8 64-bit based boards" or "ARMv8 32-bit based boards" Target Images: (Disable "GZip images" if don't want to unzip manually to use the images.)
Target Profile: (select device you want to build)
For example, build firmware for 64-bit ls1043ardb.
+---------------------------------------------+
| Target System (NXP Layerscape) ---> |
|---------------------------------------------|
| Subtarget (ARMv8 64-bit based boards) ---> |
|---------------------------------------------|
| Target Profile (ls1043ardb-armv8_64b) ---> |
+---------------------------------------------+
* For multiple devices
Target System: "NXP Layerscape".
Subtarget: "ARMv8 64-bit based boards" or "ARMv8 32-bit based boards"
Target Profile: "Multiple devices"
Target Devices: (select devices you want to build)
For example, build firmware for all 64-bit devices.
Target Devices --->
+-----------------------------------------------------------------+
| [*] Enable all profiles by default |
|-----------------------------------------------------------------|
| [*] Use a per-device root filesystem that adds profile packages |
|-----------------------------------------------------------------|
| [*] ls1012afrdm-armv8_64b ---> |
|-----------------------------------------------------------------|
| [*] ls1012ardb-armv8_64b ---> |
|-----------------------------------------------------------------|
| [*] ls1043ardb-armv8_64b ---> |
|-----------------------------------------------------------------|
| [*] ls1046ardb-armv8_64b ---> |
|-----------------------------------------------------------------|
| [*] ls1088ardb-armv8_64b ---> |
|-----------------------------------------------------------------|
| [*] ls2088ardb-armv8_64b ---> |
+-----------------------------------------------------------------+
Note: The first time make menuconfig would create a .config file which Note: The first time make menuconfig would create a .config file which
would include all dependencies for selected target. After that, make would include all dependencies for selected target. After that, make
@ -67,79 +35,81 @@ menuconfig still could be used to modify packages. If want to change
other target, please remove .config and make menuconfig to select again. other target, please remove .config and make menuconfig to select again.
Otherwise the packages selected in .config would be a mess. Otherwise the packages selected in .config would be a mess.
2.2 make (or make -j<n>) * make download (or make download -j<n>)
------------------------
2.3 Final firmware * make (or make -j<n>)
------------------
Final firmware would be in bin/targets/layerscape/<subtarget>/, and
named as openwrt-layerscape-<subtarget>-<device>-<rootfs>-firmware.bin.
* Final firmware/image
Path: bin/targets/layerscape/<subtarget>/
Firmware for flash: openwrt-layerscape-<subtarget>-<device>-<rootfs>-firmware.bin
Image for SD card: openwrt-layerscape-<subtarget>-<device>-<rootfs>-sdcard.img
3. Program firmware to NOR/QSPI flash
-------------------------------------
* LS1043ARDB (NOR flash)
Start up from bank0, and program firmware to bank4 with below commands. 3. Program NOR/QSPI flash or SD card
Switch to bank4 to start up OpenWrt. ------------------------------------
The firmware.bin or sdcard.img is an all-in-one image including all things for
OpenWrt staring up. (except LS1012AFRWY. Refer to 3.3.)
If you want to install all things into flash, please use firmware.bin.
If you want to install all things into SD card, please use sdcard.img.
=> tftp a0000000 <firmware_name>.bin 3.1 Program sdcard.img to SD card
=> protect off all ---------------------------------
=> erase 64000000 +$filesize sdcard.img could be programmed to SD card in either u-boot environment
=> cp.b a0000000 64000000 $filesize or linux environment. After programming, configure the board to boot
=> cpld reset altbank from SD card.
* LS2088ARDB (NOR flash) * u-boot environment
Start up from bank0, and program firmware to bank4 with below commands. => tftp a0000000 <image_name>-sdcard.img
Switch to bank4 to start up OpenWrt. => mmc write a0000000 0 a0000
=> tftp a0000000 <firmware_name>.bin Note: The default sdcard.img size is 320MB. a0000 is the block number for 320MB.
=> protect off all blk_num = filesize / 512.
=> erase 584000000 +$filesize
=> cp.b a0000000 584000000 $filesize
=> qix altbank
* LS1012ARDB (QSPI flash) * linux environment
$ dd if=./<image_name>-sdcard.img of=/dev/mmcblkx
Note: Need to check the SD card device name to replace "mmcblkx".
3.2 Program firmware.bin to flash
---------------------------------
* LS1012ARDB (QSPI flash)
Start up from bank1, and program firmware to bank2 with below commands. Start up from bank1, and program firmware to bank2 with below commands.
Switch to bank2 to start up OpenWrt. Switch to bank2 to start up OpenWrt.
=> tftp a0000000 <firmware_name>.bin => tftp a0000000 <firmware_name>-firmware.bin
=> i2c mw 0x24 0x7 0xfc;i2c mw 0x24 0x3 0xf5 => i2c mw 0x24 0x7 0xfc;i2c mw 0x24 0x3 0xf5
=> sf probe 0:0 => sf probe 0:0
=> sf erase 0 +$filesize => sf erase 0 +$filesize
=> sf write a0000000 0 $filesize => sf write a0000000 0 $filesize
=> reset => reset
* LS1012AFRDM (QSPI flash) * LS1043ARDB (NOR flash)
Start up from bank0, and program firmware to bank4 with below commands.
LS1012AFRDM board only has one bank. Start up board, and program firmware Switch to bank4 to start up OpenWrt.
with below commands. Reset to start up OpenWrt.
=> tftp 96000000 <firmware_name>.bin => tftp a0000000 <firmware_name>-firmware.bin
=> sf probe 0:0 => protect off all
=> sf erase 0 +$filesize => erase 64000000 +$filesize
=> sf write 96000000 0 $filesize => cp.b a0000000 64000000 $filesize
=> reset => cpld reset altbank
* LS1046ARDB (QSPI flash) * LS1046ARDB (QSPI flash)
Start up from bank1, and program firmware to bank2 with below commands. Start up from bank1, and program firmware to bank2 with below commands.
Switch to bank2 to start up OpenWrt. Switch to bank2 to start up OpenWrt.
=> tftp a0000000 <firmware_name>.bin => tftp a0000000 <firmware_name>-firmware.bin
=> sf probe 0:1 => sf probe 0:1
=> sf erase 0 +$filesize => sf erase 0 +$filesize
=> sf write a0000000 0 $filesize => sf write a0000000 0 $filesize
=> cpld reset altbank => cpld reset altbank
* LS1088ARDB (QSPI flash) * LS1088ARDB (QSPI flash)
Start up from bank0, and program firmware to bank1 with below commands. Start up from bank0, and program firmware to bank1 with below commands.
Switch to bank1 to start up OpenWrt. Switch to bank1 to start up OpenWrt.
=> tftp a0000000 <firmware_name>.bin => tftp a0000000 <firmware_name>-firmware.bin
=> sf probe 0:1 => sf probe 0:1
=> sf erase 0 +$filesize => sf erase 0 +$filesize
=> sf write a0000000 0 $filesize => sf write a0000000 0 $filesize
@ -149,6 +119,35 @@ named as openwrt-layerscape-<subtarget>-<device>-<rootfs>-firmware.bin.
bank1 instead of 'qix altbank'. bank1 instead of 'qix altbank'.
=> i2c mw 66 50 20;i2c mw 66 10 20;i2c mw 66 10 21 => i2c mw 66 50 20;i2c mw 66 10 20;i2c mw 66 10 21
* LS2088ARDB (NOR flash)
Start up from bank0, and program firmware to bank4 with below commands.
Switch to bank4 to start up OpenWrt.
=> tftp a0000000 <firmware_name>-firmware.bin
=> protect off all
=> erase 584000000 +$filesize
=> cp.b a0000000 584000000 $filesize
=> qix altbank
3.3 Program LS1012AFRWY
-----------------------
* LS1012AFRWY (QSPI flash + SD card)
LS1012AFRWY only supports 2MB QSPI flash. We have to put u-boot, and
some firmwares on QSPI flash, and kernel/dtb/rootfs on SD card.
So both firmware.bin and sdcard.img are needed for OpenWrt starting up.
To program sdcard.img, please use linux command described in 3.1 on a
linux machine.
To program firmware.bin, start up board from QSPI flash, and program
firmware with below commands. Reset to start up OpenWrt. (LS1012AFRWY
supports only one bank.)
=> tftp 96000000 <firmware_name>-firmware.bin
=> sf probe 0:0
=> sf erase 0 +$filesize
=> sf write 96000000 0 $filesize
=> reset
4. Known issues and limitation 4. Known issues and limitation
------------------------------ ------------------------------
@ -161,10 +160,7 @@ named as openwrt-layerscape-<subtarget>-<device>-<rootfs>-firmware.bin.
=> setenv eth1addr 00:04:9F:04:65:4c => setenv eth1addr 00:04:9F:04:65:4c
5. Other references and sources 5. Other references
------------------------------- -------------------
- NXP LSDK site: https://lsdk.github.io/ - NXP LSDK site: https://lsdk.github.io/
- OpenWrt documentation: https://openwrt.org/docs/start
- NXP LSDK github: https://github.com/qoriq-open-source
- LEDE documentation: https://lede-project.org/docs/start

Loading…
Cancel
Save