| 1 | Boundary Devices SABRE Lite (``sabrelite``) |
| 2 | =========================================== |
| 3 | |
| 4 | Boundary Devices SABRE Lite i.MX6 Development Board is a low-cost development |
| 5 | platform featuring the powerful Freescale / NXP Semiconductor's i.MX 6 Quad |
| 6 | Applications Processor. |
| 7 | |
| 8 | Supported devices |
| 9 | ----------------- |
| 10 | |
| 11 | The SABRE Lite machine supports the following devices: |
| 12 | |
| 13 | * Up to 4 Cortex-A9 cores |
| 14 | * Generic Interrupt Controller |
| 15 | * 1 Clock Controller Module |
| 16 | * 1 System Reset Controller |
| 17 | * 5 UARTs |
| 18 | * 2 EPIC timers |
| 19 | * 1 GPT timer |
| 20 | * 2 Watchdog timers |
| 21 | * 1 FEC Ethernet controller |
| 22 | * 3 I2C controllers |
| 23 | * 7 GPIO controllers |
| 24 | * 4 SDHC storage controllers |
| 25 | * 4 USB 2.0 host controllers |
| 26 | * 5 ECSPI controllers |
| 27 | * 2 FlexCAN CAN controllers |
| 28 | * 1 SST 25VF016B flash |
| 29 | |
| 30 | Please note above list is a complete superset the QEMU SABRE Lite machine can |
| 31 | support. For a normal use case, a device tree blob that represents a real world |
| 32 | SABRE Lite board, only exposes a subset of devices to the guest software. |
| 33 | |
| 34 | Boot options |
| 35 | ------------ |
| 36 | |
| 37 | The SABRE Lite machine can start using the standard -kernel functionality |
| 38 | for loading a Linux kernel, U-Boot bootloader or ELF executable. |
| 39 | |
| 40 | Running Linux kernel |
| 41 | -------------------- |
| 42 | |
| 43 | Linux mainline v5.10 release is tested at the time of writing. To build a Linux |
| 44 | mainline kernel that can be booted by the SABRE Lite machine, simply configure |
| 45 | the kernel using the imx_v6_v7_defconfig configuration: |
| 46 | |
| 47 | .. code-block:: bash |
| 48 | |
| 49 | $ export ARCH=arm |
| 50 | $ export CROSS_COMPILE=arm-linux-gnueabihf- |
| 51 | $ make imx_v6_v7_defconfig |
| 52 | $ make |
| 53 | |
| 54 | To boot the newly built Linux kernel in QEMU with the SABRE Lite machine, use: |
| 55 | |
| 56 | .. code-block:: bash |
| 57 | |
| 58 | $ qemu-system-arm -M sabrelite -smp 4 -m 1G \ |
| 59 | -display none -serial null -serial stdio \ |
| 60 | -kernel arch/arm/boot/zImage \ |
| 61 | -dtb arch/arm/boot/dts/imx6q-sabrelite.dtb \ |
| 62 | -initrd /path/to/rootfs.ext4 \ |
| 63 | -append "root=/dev/ram" |
| 64 | |
| 65 | Running U-Boot |
| 66 | -------------- |
| 67 | |
| 68 | U-Boot mainline v2020.10 release is tested at the time of writing. To build a |
| 69 | U-Boot mainline bootloader that can be booted by the SABRE Lite machine, use |
| 70 | the mx6qsabrelite_defconfig with similar commands as described above for Linux: |
| 71 | |
| 72 | .. code-block:: bash |
| 73 | |
| 74 | $ export CROSS_COMPILE=arm-linux-gnueabihf- |
| 75 | $ make mx6qsabrelite_defconfig |
| 76 | |
| 77 | Note we need to adjust settings by: |
| 78 | |
| 79 | .. code-block:: bash |
| 80 | |
| 81 | $ make menuconfig |
| 82 | |
| 83 | then manually select the following configuration in U-Boot: |
| 84 | |
| 85 | Device Tree Control > Provider of DTB for DT Control > Embedded DTB |
| 86 | |
| 87 | To start U-Boot using the SABRE Lite machine, provide the u-boot binary to |
| 88 | the -kernel argument, along with an SD card image with rootfs: |
| 89 | |
| 90 | .. code-block:: bash |
| 91 | |
| 92 | $ qemu-system-arm -M sabrelite -smp 4 -m 1G \ |
| 93 | -display none -serial null -serial stdio \ |
| 94 | -kernel u-boot |
| 95 | |
| 96 | The following example shows booting Linux kernel from dhcp, and uses the |
| 97 | rootfs on an SD card. This requires some additional command line parameters |
| 98 | for QEMU: |
| 99 | |
| 100 | .. code-block:: none |
| 101 | |
| 102 | -nic user,tftp=/path/to/kernel/zImage \ |
| 103 | -drive file=sdcard.img,id=rootfs -device sd-card,drive=rootfs |
| 104 | |
| 105 | The directory for the built-in TFTP server should also contain the device tree |
| 106 | blob of the SABRE Lite board. The sample SD card image was populated with the |
| 107 | root file system with one single partition. You may adjust the kernel "root=" |
| 108 | boot parameter accordingly. |
| 109 | |
| 110 | After U-Boot boots, type the following commands in the U-Boot command shell to |
| 111 | boot the Linux kernel: |
| 112 | |
| 113 | .. code-block:: none |
| 114 | |
| 115 | => setenv ethaddr 00:11:22:33:44:55 |
| 116 | => setenv bootfile zImage |
| 117 | => dhcp |
| 118 | => tftpboot 14000000 imx6q-sabrelite.dtb |
| 119 | => setenv bootargs root=/dev/mmcblk3p1 |
| 120 | => bootz 12000000 - 14000000 |