buildroot long term support release 2024.02.3

buildroot-2024.02.3.tar.gz

Signed-off-by: carbon <carbon@milkv.io>
This commit is contained in:
carbon
2024-06-14 22:30:26 +08:00
parent aac91c08cd
commit e42fe97d74
19479 changed files with 284259 additions and 232833 deletions

View File

@ -0,0 +1,30 @@
image efi-part.vfat {
vfat {
file EFI {
image = "efi-part/EFI"
}
file Image {
image = "Image"
}
}
size = 64M
}
image disk.img {
hdimage {
partition-table-type = "gpt"
}
partition boot {
image = "efi-part.vfat"
partition-type-uuid = U
offset = 32K
bootable = true
}
partition root {
partition-type-uuid = b921b045-1df0-41c3-af44-4c6f280d3fae
image = "rootfs.ext2"
}
}

View File

@ -0,0 +1,6 @@
set default="0"
set timeout="5"
menuentry "Buildroot" {
linux /Image root=PARTLABEL=root rootwait
}

View File

@ -0,0 +1,5 @@
#!/bin/sh
BOARD_DIR="$(dirname $0)"
cp -f ${BOARD_DIR}/grub.cfg ${BINARIES_DIR}/efi-part/EFI/BOOT/grub.cfg

View File

@ -0,0 +1,53 @@
The aarch64_efi_defconfig allows to build a minimal Linux system that
can boot on all AArch64 servers providing an EFI firmware.
This includes all Arm EBBR[1] compliant systems, and all Arm SystemReady[2]
compliant systems for example.
Building and booting
====================
$ make aarch64_efi_defconfig
$ make
The file output/images/disk.img is a complete disk image that can be
booted, it includes the grub2 bootloader, Linux kernel and root
filesystem.
Testing under Qemu
==================
This image can also be tested using Qemu:
qemu-system-aarch64 \
-M virt \
-cpu cortex-a57 \
-m 512 \
-nographic \
-bios </path/to/QEMU_EFI.fd> \
-drive file=output/images/disk.img,if=none,format=raw,id=hd0 \
-device virtio-blk-device,drive=hd0 \
-netdev user,id=eth0 \
-device virtio-net-device,netdev=eth0
Note that </path/to/QEMU_EFI.fd> needs to point to a valid aarch64 UEFI
firmware image for qemu.
It may be provided by your distribution as a edk2-aarch64 or AAVMF
package, in path such as /usr/share/edk2/aarch64/QEMU_EFI.fd .
U-Boot based qemu firmware
==========================
A qemu firmware with support for UEFI based on U-Boot can be built following
the instructions in [3], with qemu_arm64_defconfig.
This should give you a nor_flash.bin, which you can use with qemu as an
alternative to QEMU_EFI.fd. You will also need to change the machine
specification to "-M virt,secure=on" on qemu command line, to enable TrustZone
support, and you will need to increase the memory with "-m 1024".
[1]: https://github.com/ARM-software/ebbr
[2]: https://developer.arm.com/architectures/system-architectures/arm-systemready
[3]: https://github.com/glikely/u-boot-tfa-build

View File

@ -0,0 +1,334 @@
/*
* acme-acqua.dts - Device Tree file for Acqua A5 Board
*
* Copyright (C) 2014 Atmel,
* 2014 Nicolas Ferre <nicolas.ferre@atmel.com>
*
* 2022 Sergio Tanzilli <tanzilli@acmesystems.it>
*
* Licensed under GPLv2 or later.
*/
/dts-v1/;
#include "microchip/sama5d31.dtsi"
/ {
model = "Acme Systems Acqua SOM";
compatible = "acme,acqua", "atmel,sama5d3", "atmel,sama5";
chosen {
stdout-path = "serial0:115200n8";
bootargs = "mem=256M console=ttyS0,115200 root=/dev/mmcblk0p2 rootfstype=ext4 rw rootwait net.ifnames=0";
};
memory {
reg = <0x20000000 0x10000000>;
};
clocks {
slow_xtal {
clock-frequency = <32768>;
};
main_xtal {
clock-frequency = <12000000>;
};
};
ahb {
apb {
hlcdc: hlcdc@f0030000 {
status = "disabled";
hlcdc-display-controller {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_lcd_base &pinctrl_lcd_rgb888_alt>;
port@0 {
hlcdc_panel_output: endpoint@0 {
remote-endpoint = <&panel_input>;
};
};
};
};
/* MicroSD mounted on the SOM */
mmc0: mmc@f0000000 {
pinctrl-0 = <&pinctrl_mmc0_clk_cmd_dat0 &pinctrl_mmc0_dat1_3 &pinctrl_mmc0_cd>;
status = "okay";
slot@0 {
reg = <0>;
bus-width = <4>;
};
};
/* Optional MicroSD to mount on the carrier board */
mmc1: mmc@f8000000 {
pinctrl-0 = <&pinctrl_mmc1_clk_cmd_dat0 &pinctrl_mmc1_dat1_3 &pinctrl_mmc1_cd>;
status = "disabled";
slot@0 {
reg = <0>;
bus-width = <4>;
cd-gpios = <&pioE 1 GPIO_ACTIVE_LOW>;
};
};
spi0: spi@f0004000 {
cs-gpios = <&pioD 13 0>, <0>, <0>, <&pioD 16 0>;
status = "disabled";
};
can0: can@f000c000 {
status = "disabled";
};
tcb0: timer@f0010000 {
timer0: timer@0 {
compatible = "atmel,tcb-timer";
reg = <0>;
};
timer1: timer@1 {
compatible = "atmel,tcb-timer";
reg = <1>;
};
};
i2c0: i2c@f0014000 {
pinctrl-0 = <&pinctrl_i2c0_pu>;
status = "disabled";
};
i2c1: i2c@f0018000 {
status = "disabled";
};
macb1: ethernet@f802c000 {
compatible = "atmel,sama5d3-macb", "cdns,at91sam9260-macb", "cdns,macb";
status = "okay";
phy-mode = "rmii";
#address-cells = <1>;
#size-cells = <0>;
nvmem-cells = <&eth0_addr>;
nvmem-cell-names = "mac-address";
phy0: ethernet-phy@1 {
interrupt-parent = <&pioE>;
interrupts = <30 IRQ_TYPE_EDGE_FALLING>;
reg = <1>;
};
/*ethernet-phy@1 {
reg = <0x1>;
};*/
};
/* Bit banging internal I2C to manage the AT24MAC402 chip */
i2c3@ {
compatible = "i2c-gpio";
sda-gpios = <&pioE 1 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
scl-gpios = <&pioE 2 (GPIO_ACTIVE_HIGH|GPIO_OPEN_DRAIN)>;
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_i2c3_gpio>;
i2c-gpio,delay-us = <4>; /* ~178 kHz */
#address-cells = <1>;
#size-cells = <0>;
/* EEPROM contains the eth0 MAC address */
eeprom@58 {
compatible = "atmel,24mac402";
pagesize = <256>;
read-only;
reg = <0x58>;
#address-cells = <1>;
#size-cells = <1>;
eth0_addr: eth-mac-addr@9A {
reg = <0x0 0x06>;
};
};
};
pwm0: pwm@f002c000 {
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_pwm0_pwmh0_0 &pinctrl_pwm0_pwmh1_0>;
status = "disabled";
};
usart0: serial@f001c000 {
status = "okay";
};
usart1: serial@f0020000 {
pinctrl-0 = <&pinctrl_usart1 &pinctrl_usart1_rts_cts>;
status = "disabled";
};
uart0: serial@f0024000 {
status = "disabled";
};
spi1: spi@f8008000 {
cs-gpios = <&pioC 25 0>;
status = "disabled";
};
adc0: adc@f8018000 {
atmel,adc-vref = <3300>;
atmel,adc-channels-used = <0xfe>;
pinctrl-0 = <
&pinctrl_adc0_adtrg
&pinctrl_adc0_ad1
&pinctrl_adc0_ad2
&pinctrl_adc0_ad3
&pinctrl_adc0_ad4
&pinctrl_adc0_ad5
&pinctrl_adc0_ad6
&pinctrl_adc0_ad7
>;
status = "disabled";
};
i2c2: i2c@f801c000 {
dmas = <0>, <0>; /* Do not use DMA for i2c2 */
pinctrl-0 = <&pinctrl_i2c2_pu>;
status = "disabled";
};
dbgu: serial@ffffee00 {
status = "okay";
};
pinctrl@fffff200 {
atmel,mux-mask = <
/* A B C */
0xffffffff 0xc0fc0000 0xc0ff0000 /* pioA */
0xffffffff 0x0ff8ffff 0x00000000 /* pioB */
0xffffffff 0xbc00f1ff 0x7c00fc00 /* pioC */
0xffffffff 0xc001c0e0 0x0001c1e0 /* pioD */
0xfffffff9 0xbf9f8000 0x18000000 /* pioE */
/* 0xffffffff 0xb8000000 0x18000000 */ /* pioE */
>;
board {
pinctrl_i2c0_pu: i2c0_pu {
atmel,pins =
<AT91_PIOA 30 AT91_PERIPH_A AT91_PINCTRL_PULL_UP>,
<AT91_PIOA 31 AT91_PERIPH_A AT91_PINCTRL_PULL_UP>;
};
pinctrl_i2c2_pu: i2c2_pu {
atmel,pins =
<AT91_PIOA 18 AT91_PERIPH_B AT91_PINCTRL_PULL_UP>,
<AT91_PIOA 19 AT91_PERIPH_B AT91_PINCTRL_PULL_UP>;
};
pinctrl_i2c3_gpio: i2c3-gpio {
atmel,pins =
<AT91_PIOE 1 AT91_PERIPH_GPIO AT91_PINCTRL_NONE
AT91_PIOE 2 AT91_PERIPH_GPIO AT91_PINCTRL_NONE>;
};
pinctrl_key_gpio: key_gpio_0 {
atmel,pins =
<AT91_PIOE 29 AT91_PERIPH_GPIO AT91_PINCTRL_PULL_UP_DEGLITCH>;
};
pinctrl_mmc0_cd: mmc0_cd {
atmel,pins =
<AT91_PIOE 0 AT91_PERIPH_GPIO AT91_PINCTRL_PULL_UP_DEGLITCH>;
};
pinctrl_mmc1_cd: mmc1_cd {
atmel,pins =
<AT91_PIOE 1 AT91_PERIPH_GPIO AT91_PINCTRL_PULL_UP_DEGLITCH>;
};
pinctrl_usba_vbus: usba_vbus {
atmel,pins =
<AT91_PIOE 9 AT91_PERIPH_GPIO AT91_PINCTRL_DEGLITCH>; /* PE9, conflicts with A9 */
};
pinctrl_gpio_leds: gpio_leds_default {
atmel,pins =
<AT91_PIOE 3 AT91_PERIPH_GPIO AT91_PINCTRL_NONE
AT91_PIOE 4 AT91_PERIPH_GPIO AT91_PINCTRL_NONE
AT91_PIOE 5 AT91_PERIPH_GPIO AT91_PINCTRL_NONE
AT91_PIOE 6 AT91_PERIPH_GPIO AT91_PINCTRL_NONE>;
};
};
};
};
usb0: gadget@500000 {
status = "disabled";
};
usb1: ohci@600000 {
status = "okay";
};
usb2: ehci@700000 {
status = "okay";
};
};
panel: panel {
/* compatible = "acme,43inch", "simple-panel"; */
compatible = "acme,50inch", "simple-panel";
/* compatible = "acme,70inch", "simple-panel"; */
status = "disable";
port@0 {
panel_input: endpoint@0 {
remote-endpoint = <&hlcdc_panel_output>;
};
};
};
leds {
compatible = "gpio-leds";
pinctrl-names = "default";
pinctrl-0 = <&pinctrl_gpio_leds>;
led0 {
label = "led0";
gpios = <&pioE 3 GPIO_ACTIVE_LOW>;
default-state = "off";
};
led1 {
label = "led1";
gpios = <&pioE 4 GPIO_ACTIVE_LOW>;
default-state = "off";
};
led2 {
label = "led2";
gpios = <&pioE 5 GPIO_ACTIVE_LOW>;
linux,default-trigger = "heartbeat";
};
led3 {
label = "led3";
gpios = <&pioE 6 GPIO_ACTIVE_LOW>;
linux,default-trigger = "mmc0";
default-state = "off";
};
};
};

View File

@ -0,0 +1,29 @@
# Minimal SD card image for the Acme Systems Acqua A5
image boot.vfat {
vfat {
files = {
"boot.bin",
"zImage",
"at91-sama5d3_acqua.dtb"
}
}
size = 16M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
}
}

View File

@ -0,0 +1,2 @@
# Locally calculated
sha256 cdc04cca9e811043efdea43ad203d70d897e23a8bd46f01896ba45c8df50f6ec at91bootstrap3-v3.10.3-br1.tar.gz

View File

@ -0,0 +1 @@
../linux/linux.hash

View File

@ -0,0 +1,2 @@
# Locally calculated
sha256 b66a5b863b0f8669448b74ca83bd641a856f164b29956e539bbcb5fdeeab9cc6 linux-6.6.30.tar.xz

View File

@ -0,0 +1,44 @@
Acme Systems Acqua A5
Intro
=====
The Acqua A5 is a system on module based on the Microchip SAMA5D31 SoC:
https://www.acmesystems.it/acqua
The files here support configurations that build a microSD image for a
minimal system that can be accessed through the serial console. You will
need an USB-to-serial interface in order to access that console from
your computer:
https://www.acmesystems.it/DPI
How to build the image
======================
If you have an Acqua module with 256 MiB of RAM, type:
$ make acmesystems_acqua_a5_256mb_defconfig
If you have the 512 MiB version, type instead:
$ make acmesystems_acqua_a5_512mb_defconfig
You can optionally tweak the configuration and add packages by typing:
$ make menuconfig
Then, proceed with the build:
$ make
How to write the microSD card
=============================
The system image is the file "sdcard.img" in the "output/images"
directory. Write it to the card by invoking:
$ sudo dd if=output/images/sdcard.img of=/dev/sdX bs=1M
where `sdX' is the block device representing the microSD card.

View File

@ -0,0 +1,36 @@
# Minimal SD card image for the Acmesystems Aria G25
image boot.vfat {
vfat {
file zImage {
image = "zImage"
}
file at91-ariag25.dtb {
image = "at91-ariag25.dtb"
}
file boot.bin {
image = "at91sam9x5_aria-sdcardboot-linux-zimage-dt-3.10.3.bin"
}
}
size = 16M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
size = 512M
}
}

View File

@ -0,0 +1,44 @@
Acme Systems Aria G25
Build instructions
==================
To build an image for the Aria G25 choose the configuration
corresponding to the Aria variant.
For 128MB RAM variant type:
$ make acmesystems_aria_g25_128mb_defconfig
else for 256MB RAM variant type:
$ make acmesystems_aria_g25_256mb_defconfig
To customize the configuration choosed type:
$ make menuconfig
When you are ready to start building Buildroot type:
$ make
How to write the microSD card
=============================
Once the build process is finished you will have an image called
"sdcard.img" in the output/images/ directory.
Write the bootable SD card image "sdcard.img" onto an SD card with
"dd" command:
$ sudo dd if=output/images/sdcard.img of=/dev/sdX
Assuming your Aria G25 baseboard has a MicroSD socket, for example
with the Terra baseboard, insert the microSD card into the baseboard
slot and power it.
To get the kernel log messages you can use a DPI cable
(http://www.acmesystems.it/DPI)
You can find additional informations, tutorials and a very
comprehensive documentation on http://www.acmesystems.it/aria.

View File

@ -0,0 +1,36 @@
# Minimal SD card image for the Acmesystems Arietta G25
image boot.vfat {
vfat {
file zImage {
image = "zImage"
}
file acme-arietta.dtb {
image = "at91-ariettag25.dtb"
}
file boot.bin {
image = "at91sam9x5_arietta-sdcardboot-linux-zimage-dt-3.10.3.bin"
}
}
size = 16M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
size = 512M
}
}

View File

@ -0,0 +1,49 @@
Acme Systems Arietta G25
Intro
=====
This default configuration will allow you to start experimenting with the
buildroot environment for the Arietta G25. With the current configuration
it will bring-up the board, and allow access through the serial console.
You can find additional informations, tutorials and a very comprehensive
documentation on http://www.acmesystems.it/arietta.
Build instructions
==================
To build an image for the Arietta G25 choose the configuration
corresponding to the Arietta variant.
For 128MB RAM variant type:
$ make acmesystems_arietta_g25_128mb_defconfig
else for 256MB RAM variant type:
$ make acmesystems_arietta_g25_256mb_defconfig
To customize the configuration chosen type:
$ make menuconfig
When you are ready to start building Buildroot type:
$ make
How to write the microSD card
=============================
Once the build process is finished you will have an image called "sdcard.img"
in the output/images/ directory.
Copy the bootable "sdcard.img" onto an SD card with "dd":
$ sudo dd if=output/images/sdcard.img of=/dev/sdX
Insert the microSD card into the Arietta slot and power it.
The image just built is fairly basic and the only output
you will get is on serial console, please consider to use a DPI
cable (http://www.acmesystems.it/DPI)

View File

@ -0,0 +1,8 @@
linux_load_address=0x100000
linux_dtb_load_address=0x100
linux_dtb=socfpga_cyclone5_socrates.dtb
linux_load=mmc rescan; fatload mmc 0:1 ${linux_load_address} zImage; fatload mmc 0:1 ${linux_dtb_load_address} ${linux_dtb}
bootargs=console=ttyS0,115200 root=/dev/mmcblk0p3 ro rootwait
source_env=fatload mmc 0:1 0x2000000 boot.scr; source 0x2000000
bootcmd=run linux_load; bootz ${linux_load_address} - ${linux_dtb_load_address}
bootdelay=1

View File

@ -0,0 +1,59 @@
image boot.vfat {
vfat {
files = {
"zImage",
"socfpga_cyclone5_socrates.dtb"
}
}
size = 8M
}
image uboot.img {
hdimage {
partition-table = "no"
}
partition spl {
in-partition-table = "no"
image = "u-boot-spl.bin.crc"
offset = 0
size = 64K
}
partition uboot-full {
in-partition-table = "no"
image = "u-boot.img"
offset = 256K
}
size = 1M
}
image sdcard.img {
hdimage {
}
partition uboot-env {
in-partition-table = "no"
image = "uboot-env.bin"
offset = 17K # 512 * 34 -> just after gpt
}
partition boot {
partition-type = 0xc
bootable = "true"
image = "boot.vfat"
}
partition uboot {
partition-type = 0xa2
image = "uboot.img"
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext2"
size = 500M
}
}

View File

@ -0,0 +1,52 @@
EBV SoCrates Evaluation Board
Intro
=====
More information about this board can be found here:
https://rocketboards.org/foswiki/Documentation/EBVSoCratesEvaluationBoard
Build
=====
First, load socrates config for buildroot
make socrates_cyclone5_defconfig
Build everything
make
Following files will be generated in output/images
.
├── boot.vfat
├── rootfs.ext2
├── rootfs.ext4 -> rootfs.ext2
├── rootfs.tar
├── sdcard.img
├── socfpga_cyclone5_socrates.dtb
├── u-boot-spl.bin
├── u-boot-spl.bin.crc
├── u-boot.bin
├── u-boot.img
├── uboot-env.bin
├── uboot.img
└── zImage
Creating bootable SD card
=========================
Simply invoke
dd if=output/images/sdcard.img of=/dev/sdX
Where X is your SD card device (not partition)
Booting
=======
Pins 6:8 on P18 selector is used to determine boot device. To boot socrates from
sdcard set these pins to value 0x5 (101b). Remaining pins are used to determine
how to configure FPGA and are not associated with booting into Linux kernel.

View File

@ -0,0 +1,4 @@
label Vyasa linux-next
kernel /boot/uImage
devicetree /boot/rk3288-vyasa.dtb
append console=ttyS2,115200n8 root=/dev/mmcblk0p1 rootwait

View File

@ -0,0 +1,22 @@
image sdcard.img {
hdimage {
}
partition u-boot-tpl-spl-dtb {
in-partition-table = "no"
image = "u-boot-tpl-spl-dtb.img"
offset = 32K
}
partition u-boot-dtb {
in-partition-table = "no"
image = "u-boot-dtb.img"
offset = 8M
size = 30M # falcon mode: args @ 16M args, uImage @ 17M
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
}
}

View File

@ -0,0 +1,3 @@
# Currently mainline kernel exhibits issues when running rockchip gmac
# on the board, so enable it as loadable module and insert it later
CONFIG_DWMAC_ROCKCHIP=m

View File

@ -0,0 +1,9 @@
#!/bin/sh
MKIMAGE=$HOST_DIR/bin/mkimage
BOARD_DIR="$(dirname $0)"
$MKIMAGE -n rk3288 -T rksd -d $BINARIES_DIR/u-boot-tpl.bin $BINARIES_DIR/u-boot-tpl.img
cat $BINARIES_DIR/u-boot-tpl.img $BINARIES_DIR/u-boot-spl-dtb.bin > $BINARIES_DIR/u-boot-tpl-spl-dtb.img
install -m 0644 -D $BOARD_DIR/extlinux.conf $TARGET_DIR/boot/extlinux/extlinux.conf

View File

@ -0,0 +1,31 @@
Vyasa RK3288
============
Vyasa is RK3288 based Single board computer with fully supported opensource software.
https://openedev.amarulasolutions.com/display/ODWIKI/Vyasa+RK3288
How to build it
===============
$ make amarula_vyasa_rk3288_defconfig
Then you can edit the build options using
$ make menuconfig
Compile all and build rootfs image:
$ make
Prepare your SDCard
===================
Buildroot generates a ready-to-use SD card image that you can flash directly to
the card. The image will be in output/images/sdcard.img.
You can write this image directly to an SD card device (i.e. /dev/xxx):
$ sudo dd if=output/images/sdcard.img of=/dev/xxx
$ sudo sync
Finally, you can insert the SD card to the Vyasa RK3288 board, close J4 and boot it.

View File

@ -0,0 +1,26 @@
image boot.vfat {
vfat {
files = {
"u-boot-spl.bin",
"u-boot.itb",
"ae350_ax45mp.dtb",
}
}
size = 2M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
image = "boot.vfat"
}
partition rootfs {
partition-type = 0x83
bootable = true
image = "rootfs.ext4"
}
}

View File

@ -0,0 +1,38 @@
From 16aad5594e08550295ea3c12c1c9ed6f64774748 Mon Sep 17 00:00:00 2001
From: Rick Chen <rick@andestech.com>
Date: Tue, 29 Mar 2022 13:41:10 +0800
Subject: [PATCH] mmc: ftsdc010_mci: Support DTS of ftsdc010 driver for
generic dma
The ftsdc010 driver has been implemented for generic dma in Linux
kernel. And its compatible is andestech,atfsdc010g to distinguish
the legacy andestech,atfsdc010 which is not for generic dma.
Althought the ftsdc010_mci driver in U-Boot does not use dma, but
it still can work well with the mmc node for generic dma. So add
the compatible string to support it.
Signed-off-by: Rick Chen <rick@andestech.com>
Upstream-Status: Pending
Signed-off-by: Yu Chien Peter Lin <peterlin@andestech.com>
---
drivers/mmc/ftsdc010_mci.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/drivers/mmc/ftsdc010_mci.c b/drivers/mmc/ftsdc010_mci.c
index 570d54cf9d..65b1d447a8 100644
--- a/drivers/mmc/ftsdc010_mci.c
+++ b/drivers/mmc/ftsdc010_mci.c
@@ -460,6 +460,7 @@ int ftsdc010_mmc_bind(struct udevice *dev)
static const struct udevice_id ftsdc010_mmc_ids[] = {
{ .compatible = "andestech,atfsdc010" },
+ { .compatible = "andestech,atfsdc010g" },
{ }
};
--
2.34.1

View File

@ -0,0 +1,42 @@
From 933ad8a59f7fd9b2088badc3e97167d750a40b5a Mon Sep 17 00:00:00 2001
From: Bin Meng <bmeng.cn@gmail.com>
Date: Mon, 12 Jul 2021 11:52:31 +0800
Subject: [PATCH] spl: Align device tree blob address at 8-byte boundary
Since libfdt v1.6.1, a new requirement on the device tree address via:
commit 5e735860c478 ("libfdt: Check for 8-byte address alignment in fdt_ro_probe_()")
must be met that the device tree must be loaded in to memory at an
8-byte aligned address.
Signed-off-by: Bin Meng <bmeng.cn@gmail.com>
This patch was imported from U-boot patchwork:
https://patchwork.ozlabs.org/project/uboot/patch/20210712035231.26475-1-bmeng.cn@gmail.com/
Signed-off-by: Yu Chien Peter Lin <peterlin@andestech.com>
---
common/spl/spl_fit.c | 6 ++++++
1 file changed, 6 insertions(+)
diff --git a/common/spl/spl_fit.c b/common/spl/spl_fit.c
index a35be529..a76ad14a 100644
--- a/common/spl/spl_fit.c
+++ b/common/spl/spl_fit.c
@@ -382,6 +382,12 @@ static int spl_fit_append_fdt(struct spl_image_info *spl_image,
*/
image_info.load_addr = spl_image->load_addr + spl_image->size;
+ /*
+ * Since libfdt v1.6.1, the device tree must be loaded in to memory
+ * at an 8-byte aligned address.
+ */
+ image_info.load_addr = roundup(image_info.load_addr, 8);
+
/* Figure out which device tree the board wants to use */
node = spl_fit_get_image_node(ctx, FIT_FDT_PROP, index++);
if (node < 0) {
--
2.34.1

View File

@ -0,0 +1,3 @@
#!/bin/sh
cp $BINARIES_DIR/Image $TARGET_DIR/boot
cp $BINARIES_DIR/ae350_ax45mp.dtb $TARGET_DIR/boot

View File

@ -0,0 +1,63 @@
Intro
=====
Andestech AE350 Platform
The AE350 prototype demonstrates the AE350 platform on the FPGA.
How to build it
===============
Configure Buildroot
-------------------
$ make andes_ae350_45_defconfig
If you want to customize your configuration:
$ make menuconfig
Build everything
----------------
Note: you will need to access to the network, since Buildroot will
download the packages' sources.
$ make
Result of the build
-------------------
After building, you should obtain the following files:
output/images/
|-- ae350_ax45mp.dtb
|-- boot.vfat
|-- fw_dynamic.bin
|-- fw_dynamic.elf
|-- Image
|-- rootfs.ext2
|-- rootfs.ext4 -> rootfs.ext2
|-- sdcard.img
|-- u-boot-spl.bin
`-- u-boot.itb
Copy the sdcard.img to a SD card with "dd":
$ sudo dd if=sdcard.img of=/dev/sdX bs=4096
$ sudo sync
Your SD card partition should be:
Disk /dev/sdb: 14.48 GiB, 15552479232 bytes, 30375936 sectors
Disk model: Multi-Card
Units: sectors of 1 * 512 = 512 bytes
Sector size (logical/physical): 512 bytes / 512 bytes
I/O size (minimum/optimal): 512 bytes / 512 bytes
Disklabel type: dos
Disk identifier: 0x00000000
Device Boot Start End Sectors Size Id Type
/dev/sdb1 1 4096 4096 2M c W95 FAT32 (LBA)
/dev/sdb2 * 4097 126976 122880 60M 83 Linux
Insert SD card and reset the board, it should boot Linux from mmc.

View File

@ -0,0 +1,4 @@
label linux
kernel /boot/Image
fdt /boot/ae350_ax45mp.dtb
append earlycon=sbi root=/dev/mmcblk0p2 rootwait

View File

@ -0,0 +1,7 @@
CONFIG_SPL_FS_FAT=y
CONFIG_SPL_MMC=y
# CONFIG_SPL_RAM_SUPPORT is not set
CONFIG_SPL_OPENSBI_LOAD_ADDR=0x0
CONFIG_SPL_OPENSBI_SCRATCH_OPTIONS=0x0
CONFIG_DISPLAY_CPUINFO=y
CONFIG_DISPLAY_BOARDINFO=y

View File

@ -0,0 +1,4 @@
#!/bin/sh
mkdir -p ${TARGET_DIR}/lib/firmware
cp -f ${BUILD_DIR}/linux-custom/br2-ucls1012a.its ${BINARIES_DIR}/

View File

@ -0,0 +1,6 @@
#!/bin/sh
MKIMAGE=${HOST_DIR}/usr/bin/mkimage
MKIMAGE_IN=${BINARIES_DIR}/br2-ucls1012a.its
MKIMAGE_OUT=${BINARIES_DIR}/part0-000000.itb
${MKIMAGE} -f ${MKIMAGE_IN} ${MKIMAGE_OUT}

View File

@ -0,0 +1,74 @@
Arcturus uCLS1012A SoM
======================
This tutorial describes how to use the predefined Buildroot
configuration for the Arcturus uCLS101A SoM platform.
Additional information about the uCLS1012A System on Module can be found at
https://www.arcturusnetworks.com/products/ucls1012a
and product support for registered users at
https://www.arcturusnetworks.com/support
Building
--------
Return to the top directory <buildrootdir> and execute the following commands.
make arcturus_ucls1012a_defconfig
make
Result of the build
-------------------
After building, you should obtain this tree:
output/images/
+-- arc-ucls1012a.dtb
+-- Image.gz
+-- part0-000000.itb
+-- rootfs.cpio
+-- rootfs.cpio.gz
+-- rootfs.tar
+-- u-boot.bin
+-- br2-ucls1012a.its
Flashing
--------
You'll need to program the image created by buildroot into the SPI NOR flash.
1. Reboot your module and via the serial console press <escape> to enter the B$
u-boot shell.
From the shell you will need to update four environment variables replacing the
IPv4 IP Address with ones that will work with your network and tftp server.
B$ setenv ipaddr 192.168.1.81
B$ setenv serverip 192.168.1.80
B$ setenv gatewayip 192.168.1.1
B$ setenv netmask 255.255.255.0
B$ saveenv
2. Enable tftp server to serve the <buildrootdir>/output/images/ folder.
3. Program the new U-Boot binary (optional)
If you don't feel confident upgrading your bootloader then don't do it,
it's unnecessary most of the time.
B$ tftp u-boot.bin
B$ run program_uboot
4. Program the ITB image (includes Kernel, DTB and Ramdisk)
B$ tftp part0-000000.itb
B$ run iprogram
5. Booting your new system
Reboot your system by reset command
B$ reset
or
B$ run bootcmd
Good Luck !

View File

@ -0,0 +1,74 @@
Arcturus uCP1020 SoM
====================
This tutorial describes how to use the predefined Buildroot
configuration for the Arcturus uCP1020 SoM platform.
Additional information about this module can be found at
<www.arcturusnetworks.com/products/ucp1020>
Building
--------
make arcturus_ucp1020_defconfig
make
Result of the build
-------------------
After building, you should obtain this tree:
output/images/
+-- rootfs.jffs2
+-- rootfs.tar
+-- u-boot.bin
+-- ucp1020.dtb
+-- uImage
Flashing
--------
You'll need to program the files created by buildroot into the NOR flash.
1. Program the new U-Boot binary (optional)
If you don't feel confident upgrading your bootloader then don't do it,
it's unnecessary most of the time.
B$ tftp u-boot.bin
B$ protect off 0xeff80000 +$filesize
B$ erase 0xeff80000 +$filesize
B$ cp.b $loadaddr 0xeff80000 $filesize
B$ protect on 0xeff80000 +$filesize
2. Program the kernel
B$ tftp uImage
B$ erase 0xec140000 +$filesize
B$ cp.b $loadaddr 0xec140000 $filesize
3. Program the DTB
B$ tftp ucp1020.dtb
B$ erase 0xec100000 +$filesize
B$ cp.b $loadaddr 0xec100000 $filesize
4. Program the jffs2 root filesystem
B$ tftp rootfs.jffs2
B$ erase 0xec800000 0xee8fffff
B$ cp.b $loadaddr 0xec800000 $filesize
5. Booting your new system
B$ setenv norboot 'setenv bootargs root=/dev/mtdblock1 rootfstype=jffs2 console=$consoledev,$baudrate;bootm 0xec140000 - 0xec100000'
If you want to set this boot option as default:
B$ setenv bootcmd 'run norboot'
B$ saveenv
...or for a single boot:
B$ run norboot
Good Luck !

View File

@ -0,0 +1,20 @@
This is the support for the ARM Foundation v8 machine emulated by the
ARM software simulator of the AArch64 architecture.
First, one has to download the AArch64 software simulator from:
https://armkeil.blob.core.windows.net/developer/Files/downloads/ecosystem-models/Foundation_Platform_11.20_15_Linux64.tgz
Then, use the arm_foundationv8_defconfig configuration to build your
Buildroot system.
Finally, boot your system with:
${LOCATION_OF_FOUNDATIONV8_SIMULATOR}/models/Linux64_GCC-9.3/Foundation_Platform \
--image output/images/linux-system.axf \
--block-device output/images/rootfs.ext2 \
--network=nat \
--cores 4
You can get network access from within the simulated environment
by requesting an IP address using DHCP (run the command 'udhcpc').

View File

@ -0,0 +1,216 @@
# CONFIG_SWAP is not set
CONFIG_SYSVIPC=y
CONFIG_POSIX_MQUEUE=y
CONFIG_NO_HZ=y
CONFIG_HIGH_RES_TIMERS=y
CONFIG_LOG_BUF_SHIFT=14
CONFIG_CGROUPS=y
CONFIG_EMBEDDED=y
# CONFIG_COMPAT_BRK is not set
CONFIG_SLAB=y
CONFIG_PROFILING=y
CONFIG_OPROFILE=m
CONFIG_MODULES=y
CONFIG_MODULE_UNLOAD=y
# CONFIG_BLK_DEV_BSG is not set
# CONFIG_IOSCHED_DEADLINE is not set
# CONFIG_IOSCHED_CFQ is not set
# CONFIG_ARCH_MULTI_V7 is not set
CONFIG_ARCH_MXC=y
CONFIG_MACH_IMX27_DT=y
CONFIG_PREEMPT=y
CONFIG_AEABI=y
CONFIG_ZBOOT_ROM_TEXT=0x0
CONFIG_ZBOOT_ROM_BSS=0x0
CONFIG_PM_DEBUG=y
CONFIG_NET=y
CONFIG_PACKET=y
CONFIG_UNIX=y
CONFIG_INET=y
CONFIG_IP_MULTICAST=y
CONFIG_IP_PNP=y
CONFIG_IP_PNP_DHCP=y
# CONFIG_INET_XFRM_MODE_TRANSPORT is not set
# CONFIG_INET_XFRM_MODE_TUNNEL is not set
# CONFIG_INET_XFRM_MODE_BEET is not set
# CONFIG_INET_DIAG is not set
CONFIG_CAN=m
CONFIG_CAN_VCAN=m
CONFIG_CAN_MCP251X=m
CONFIG_BT=m
CONFIG_BT_RFCOMM=m
CONFIG_BT_RFCOMM_TTY=y
CONFIG_BT_BNEP=m
CONFIG_BT_HIDP=m
CONFIG_BT_HCIBTUSB=m
CONFIG_BT_HCIUART=m
CONFIG_BT_HCIUART_H4=y
CONFIG_BT_HCIUART_BCSP=y
CONFIG_CFG80211=m
CONFIG_MAC80211=m
CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
CONFIG_DEVTMPFS=y
CONFIG_DEVTMPFS_MOUNT=y
CONFIG_MTD=y
CONFIG_MTD_CMDLINE_PARTS=y
CONFIG_MTD_BLOCK=y
CONFIG_MTD_CFI=y
CONFIG_MTD_CFI_ADV_OPTIONS=y
CONFIG_MTD_CFI_GEOMETRY=y
# CONFIG_MTD_MAP_BANK_WIDTH_1 is not set
# CONFIG_MTD_CFI_I2 is not set
CONFIG_MTD_CFI_INTELEXT=y
CONFIG_MTD_PHYSMAP=y
CONFIG_MTD_NAND=y
CONFIG_MTD_NAND_MXC=y
CONFIG_MTD_UBI=y
CONFIG_EEPROM_AT24=y
CONFIG_EEPROM_AT25=y
CONFIG_SCSI=y
CONFIG_BLK_DEV_SD=y
CONFIG_NETDEVICES=y
# CONFIG_NET_VENDOR_BROADCOM is not set
# CONFIG_NET_VENDOR_CIRRUS is not set
# CONFIG_NET_VENDOR_FARADAY is not set
# CONFIG_NET_VENDOR_INTEL is not set
# CONFIG_NET_VENDOR_MARVELL is not set
# CONFIG_NET_VENDOR_MICREL is not set
# CONFIG_NET_VENDOR_MICROCHIP is not set
# CONFIG_NET_VENDOR_NATSEMI is not set
# CONFIG_NET_VENDOR_SEEQ is not set
# CONFIG_NET_VENDOR_SMSC is not set
# CONFIG_NET_VENDOR_STMICRO is not set
# CONFIG_NET_VENDOR_WIZNET is not set
CONFIG_SMSC_PHY=y
CONFIG_LIBERTAS=m
CONFIG_LIBERTAS_SDIO=m
CONFIG_RT2X00=m
CONFIG_RT2500USB=m
CONFIG_RT73USB=m
CONFIG_RT2800USB=m
CONFIG_RTL8187=m
CONFIG_RTL8192CU=m
CONFIG_ZD1211RW=m
CONFIG_INPUT_JOYDEV=y
CONFIG_INPUT_EVDEV=y
CONFIG_KEYBOARD_GPIO=y
CONFIG_KEYBOARD_IMX=m
# CONFIG_INPUT_MOUSE is not set
CONFIG_INPUT_JOYSTICK=y
CONFIG_INPUT_TOUCHSCREEN=y
# CONFIG_LEGACY_PTYS is not set
CONFIG_SERIAL_IMX=y
CONFIG_SERIAL_IMX_CONSOLE=y
# CONFIG_HW_RANDOM is not set
CONFIG_I2C=y
CONFIG_I2C_CHARDEV=y
CONFIG_I2C_IMX=y
CONFIG_SPI=y
CONFIG_SPI_IMX=y
CONFIG_SPI_SPIDEV=m
CONFIG_GPIO_SYSFS=y
CONFIG_W1=y
CONFIG_W1_MASTER_MXC=y
CONFIG_W1_SLAVE_THERM=y
CONFIG_WATCHDOG=y
CONFIG_IMX2_WDT=y
CONFIG_REGULATOR=y
CONFIG_REGULATOR_FIXED_VOLTAGE=y
CONFIG_MEDIA_SUPPORT=m
CONFIG_MEDIA_CAMERA_SUPPORT=y
CONFIG_MEDIA_USB_SUPPORT=y
CONFIG_USB_VIDEO_CLASS=m
CONFIG_USB_PWC=m
CONFIG_V4L_PLATFORM_DRIVERS=y
CONFIG_SOC_CAMERA=m
# CONFIG_MEDIA_SUBDRV_AUTOSELECT is not set
CONFIG_FB=y
# CONFIG_FB_MX3 is not set
CONFIG_BACKLIGHT_LCD_SUPPORT=y
# CONFIG_LCD_CLASS_DEVICE is not set
CONFIG_BACKLIGHT_CLASS_DEVICE=y
CONFIG_FRAMEBUFFER_CONSOLE=y
CONFIG_LOGO=y
# CONFIG_LOGO_LINUX_MONO is not set
# CONFIG_LOGO_LINUX_VGA16 is not set
CONFIG_SOUND=m
CONFIG_SND=m
CONFIG_SND_MIXER_OSS=m
CONFIG_SND_PCM_OSS=m
# CONFIG_SND_DRIVERS is not set
# CONFIG_SND_ARM is not set
# CONFIG_SND_SPI is not set
# CONFIG_SND_USB is not set
CONFIG_SND_SOC=m
CONFIG_SND_IMX_SOC=m
CONFIG_USB=y
CONFIG_USB_EHCI_HCD=y
CONFIG_USB_EHCI_MXC=y
CONFIG_USB_ACM=y
CONFIG_USB_PRINTER=y
CONFIG_USB_STORAGE=y
CONFIG_USB_CHIPIDEA=y
CONFIG_USB_CHIPIDEA_HOST=y
CONFIG_USB_SERIAL=y
CONFIG_USB_SERIAL_FTDI_SIO=y
CONFIG_USB_SERIAL_PL2303=y
CONFIG_USB_ULPI=y
CONFIG_USB_GADGET=y
CONFIG_USB_ETH=m
CONFIG_USB_GADGETFS=m
CONFIG_USB_MASS_STORAGE=m
CONFIG_USB_G_HID=m
CONFIG_MMC=y
CONFIG_MMC_MXC=y
CONFIG_NEW_LEDS=y
CONFIG_LEDS_CLASS=y
CONFIG_LEDS_GPIO=y
CONFIG_LEDS_TRIGGERS=y
CONFIG_LEDS_TRIGGER_TIMER=y
CONFIG_LEDS_TRIGGER_ONESHOT=y
CONFIG_LEDS_TRIGGER_HEARTBEAT=y
CONFIG_LEDS_TRIGGER_BACKLIGHT=y
CONFIG_LEDS_TRIGGER_CPU=y
CONFIG_LEDS_TRIGGER_GPIO=y
CONFIG_LEDS_TRIGGER_DEFAULT_ON=y
CONFIG_LEDS_TRIGGER_TRANSIENT=y
CONFIG_RTC_CLASS=y
CONFIG_RTC_DRV_DS1374=y
CONFIG_RTC_DRV_MXC=m
CONFIG_DMADEVICES=y
CONFIG_IMX_DMA=y
CONFIG_IMX_SDMA=y
# CONFIG_IOMMU_SUPPORT is not set
CONFIG_IIO=y
CONFIG_MAX1027=y
CONFIG_MAX5821=y
CONFIG_PWM=y
CONFIG_PWM_IMX=y
CONFIG_EXT2_FS=y
CONFIG_EXT3_FS=y
CONFIG_EXT3_FS_POSIX_ACL=y
CONFIG_EXT3_FS_SECURITY=y
# CONFIG_DNOTIFY is not set
CONFIG_MSDOS_FS=y
CONFIG_VFAT_FS=y
# CONFIG_PROC_PAGE_MONITOR is not set
CONFIG_TMPFS=y
CONFIG_JFFS2_FS=y
CONFIG_UBIFS_FS=y
CONFIG_NFS_FS=y
CONFIG_NFS_V4=y
CONFIG_ROOT_NFS=y
CONFIG_NLS_CODEPAGE_437=y
CONFIG_NLS_CODEPAGE_850=y
CONFIG_NLS_ISO8859_1=y
CONFIG_NLS_ISO8859_15=m
CONFIG_PRINTK_TIME=y
CONFIG_DEBUG_INFO=y
CONFIG_DEBUG_FS=y
# CONFIG_SCHED_DEBUG is not set
# CONFIG_DEBUG_PREEMPT is not set
# CONFIG_FTRACE is not set
CONFIG_DEBUG_LL=y
CONFIG_EARLY_PRINTK=y
CONFIG_FONTS=y
CONFIG_FONT_8x8=y

View File

@ -0,0 +1,278 @@
CONFIG_EXPERIMENTAL=y
# CONFIG_LOCALVERSION_AUTO is not set
# CONFIG_SWAP is not set
CONFIG_SYSVIPC=y
CONFIG_NO_HZ=y
CONFIG_HIGH_RES_TIMERS=y
CONFIG_IKCONFIG=y
CONFIG_IKCONFIG_PROC=y
CONFIG_LOG_BUF_SHIFT=14
CONFIG_EMBEDDED=y
# CONFIG_COMPAT_BRK is not set
CONFIG_SLAB=y
CONFIG_PROFILING=y
CONFIG_OPROFILE=y
CONFIG_MODULES=y
CONFIG_MODULE_UNLOAD=y
# CONFIG_BLK_DEV_BSG is not set
CONFIG_PARTITION_ADVANCED=y
CONFIG_BSD_DISKLABEL=y
# CONFIG_IOSCHED_CFQ is not set
CONFIG_ARCH_MXC=y
CONFIG_MXC_IRQ_PRIOR=y
CONFIG_SOC_IMX51=y
CONFIG_ARM_THUMBEE=y
CONFIG_PREEMPT=y
CONFIG_AEABI=y
CONFIG_ZBOOT_ROM_TEXT=0x0
CONFIG_ZBOOT_ROM_BSS=0x0
CONFIG_CPU_FREQ=y
CONFIG_CPU_FREQ_STAT_DETAILS=y
CONFIG_CPU_FREQ_DEFAULT_GOV_USERSPACE=y
CONFIG_CPU_FREQ_GOV_PERFORMANCE=y
CONFIG_CPU_FREQ_GOV_POWERSAVE=y
CONFIG_CPU_FREQ_GOV_ONDEMAND=y
CONFIG_CPU_FREQ_GOV_CONSERVATIVE=y
CONFIG_CPU_FREQ_IMX=y
CONFIG_CPU_IDLE=y
CONFIG_VFP=y
CONFIG_NEON=y
# CONFIG_CORE_DUMP_DEFAULT_ELF_HEADERS is not set
# CONFIG_SUSPEND is not set
CONFIG_NET=y
CONFIG_PACKET=y
CONFIG_UNIX=y
CONFIG_INET=y
CONFIG_IP_MULTICAST=y
CONFIG_IP_PNP=y
# CONFIG_INET_XFRM_MODE_TRANSPORT is not set
# CONFIG_INET_XFRM_MODE_TUNNEL is not set
# CONFIG_INET_XFRM_MODE_BEET is not set
# CONFIG_INET_LRO is not set
# CONFIG_INET_DIAG is not set
CONFIG_IPV6=y
CONFIG_CAN=m
CONFIG_CAN_RAW=m
CONFIG_CAN_BCM=m
CONFIG_CAN_VCAN=m
CONFIG_CAN_MCP251X=m
CONFIG_BT=m
CONFIG_BT_L2CAP=y
CONFIG_BT_SCO=y
CONFIG_BT_RFCOMM=m
CONFIG_BT_RFCOMM_TTY=y
CONFIG_BT_BNEP=m
CONFIG_BT_HIDP=m
CONFIG_BT_HCIBTUSB=m
CONFIG_BT_HCIUART=m
CONFIG_BT_HCIUART_H4=y
CONFIG_BT_HCIUART_BCSP=y
CONFIG_CFG80211=m
CONFIG_MAC80211=m
CONFIG_MAC80211_RC_PID=y
CONFIG_UEVENT_HELPER_PATH="/sbin/hotplug"
CONFIG_DEVTMPFS=y
CONFIG_DEVTMPFS_MOUNT=y
CONFIG_FW_LOADER=m
CONFIG_MTD=y
CONFIG_MTD_CMDLINE_PARTS=y
CONFIG_MTD_CHAR=y
CONFIG_MTD_BLOCK=y
CONFIG_MTD_NAND=y
CONFIG_MTD_NAND_MXC=y
CONFIG_MTD_UBI=y
CONFIG_MISC_DEVICES=y
CONFIG_EEPROM_AT24=y
CONFIG_EEPROM_AT25=y
CONFIG_SCSI=y
CONFIG_BLK_DEV_SD=y
CONFIG_CHR_DEV_ST=y
CONFIG_BLK_DEV_SR=y
CONFIG_CHR_DEV_SG=y
CONFIG_CHR_DEV_SCH=y
CONFIG_SCSI_MULTI_LUN=y
CONFIG_SCSI_LOGGING=y
CONFIG_SCSI_SCAN_ASYNC=y
CONFIG_NETDEVICES=y
CONFIG_MII=y
CONFIG_SMSC_PHY=y
CONFIG_NET_ETHERNET=y
# CONFIG_NETDEV_1000 is not set
# CONFIG_NETDEV_10000 is not set
CONFIG_RTL8187=m
CONFIG_LIBERTAS=m
CONFIG_LIBERTAS_SDIO=m
CONFIG_RT2X00=m
CONFIG_RT73USB=m
CONFIG_ZD1211RW=m
CONFIG_INPUT_JOYDEV=y
CONFIG_INPUT_EVDEV=y
CONFIG_KEYBOARD_GPIO=m
CONFIG_KEYBOARD_IMX=m
CONFIG_INPUT_TOUCHSCREEN=y
CONFIG_TOUCHSCREEN_WM831X=y
CONFIG_TOUCHSCREEN_MC13XXX=m
CONFIG_INPUT_MISC=y
CONFIG_INPUT_MC13783_PWRBUTTON=m
CONFIG_INPUT_UINPUT=m
CONFIG_INPUT_WM831X_ON=y
# CONFIG_LEGACY_PTYS is not set
CONFIG_SERIAL_8250=m
CONFIG_SERIAL_IMX=y
CONFIG_SERIAL_IMX_CONSOLE=y
# CONFIG_HW_RANDOM is not set
CONFIG_I2C=y
CONFIG_I2C_CHARDEV=y
CONFIG_I2C_IMX=y
CONFIG_SPI=y
CONFIG_SPI_IMX=y
CONFIG_SPI_SPIDEV=m
CONFIG_GPIO_SYSFS=y
CONFIG_GPIO_WM831X=m
CONFIG_POWER_SUPPLY=y
CONFIG_WM831X_BACKUP=m
CONFIG_WM831X_POWER=m
CONFIG_HWMON=m
CONFIG_SENSORS_AS1531=m
CONFIG_SENSORS_MC13783_ADC=m
CONFIG_SENSORS_WM831X=m
CONFIG_WATCHDOG=y
CONFIG_WATCHDOG_NOWAYOUT=y
CONFIG_WM831X_WATCHDOG=m
CONFIG_IMX2_WDT=y
CONFIG_MFD_MC13XXX_I2C=y
CONFIG_MFD_WM831X_I2C=y
CONFIG_REGULATOR=y
CONFIG_REGULATOR_FIXED_VOLTAGE=y
CONFIG_REGULATOR_MC13892=m
CONFIG_IMX_IPUV3_CORE=y
CONFIG_DRM=y
CONFIG_MFD_IMX_IPU_V3=y
CONFIG_MEDIA_SUPPORT=m
CONFIG_VIDEO_DEV=m
# CONFIG_RC_CORE is not set
# CONFIG_MEDIA_TUNER_SIMPLE is not set
# CONFIG_MEDIA_TUNER_TDA8290 is not set
# CONFIG_MEDIA_TUNER_TDA827X is not set
# CONFIG_MEDIA_TUNER_TDA18271 is not set
# CONFIG_MEDIA_TUNER_TDA9887 is not set
# CONFIG_MEDIA_TUNER_TEA5761 is not set
# CONFIG_MEDIA_TUNER_TEA5767 is not set
# CONFIG_MEDIA_TUNER_MT20XX is not set
# CONFIG_MEDIA_TUNER_MT2060 is not set
# CONFIG_MEDIA_TUNER_MT2266 is not set
# CONFIG_MEDIA_TUNER_MT2131 is not set
# CONFIG_MEDIA_TUNER_QT1010 is not set
# CONFIG_MEDIA_TUNER_XC2028 is not set
# CONFIG_MEDIA_TUNER_XC5000 is not set
# CONFIG_MEDIA_TUNER_MXL5005S is not set
# CONFIG_MEDIA_TUNER_MXL5007T is not set
# CONFIG_MEDIA_TUNER_MC44S803 is not set
# CONFIG_MEDIA_TUNER_MAX2165 is not set
# CONFIG_MEDIA_TUNER_TDA18218 is not set
CONFIG_VIDEO_VIVI=m
CONFIG_USB_VIDEO_CLASS=m
# CONFIG_RADIO_ADAPTERS is not set
CONFIG_FB=y
CONFIG_FB_MX5=y
CONFIG_BACKLIGHT_LCD_SUPPORT=y
CONFIG_FRAMEBUFFER_CONSOLE=y
CONFIG_FONTS=y
CONFIG_FONT_8x8=y
CONFIG_LOGO=y
# CONFIG_LOGO_LINUX_MONO is not set
# CONFIG_LOGO_LINUX_VGA16 is not set
CONFIG_SOUND=m
# CONFIG_SOUND_OSS_CORE_PRECLAIM is not set
CONFIG_SND=m
CONFIG_SND_MIXER_OSS=m
CONFIG_SND_PCM_OSS=m
# CONFIG_SND_DRIVERS is not set
# CONFIG_SND_ARM is not set
# CONFIG_SND_SPI is not set
# CONFIG_SND_USB is not set
CONFIG_SND_SOC=m
CONFIG_SND_IMX_SOC=m
CONFIG_SND_SOC_APF51_DEV_WM8960=m
CONFIG_USB=y
CONFIG_USB_DEBUG=y
CONFIG_USB_ANNOUNCE_NEW_DEVICES=y
CONFIG_USB_DEVICEFS=y
# CONFIG_USB_DEVICE_CLASS is not set
CONFIG_USB_SUSPEND=y
CONFIG_USB_OTG=y
# CONFIG_USB_OTG_WHITELIST is not set
CONFIG_USB_MON=y
CONFIG_USB_EHCI_HCD=y
CONFIG_USB_EHCI_MXC=y
CONFIG_USB_ACM=y
CONFIG_USB_PRINTER=y
CONFIG_USB_WDM=y
CONFIG_USB_STORAGE=y
CONFIG_USB_CHIPIDEA=y
CONFIG_USB_CHIPIDEA_UDC=y
CONFIG_USB_CHIPIDEA_HOST=y
CONFIG_USB_PHY=y
CONFIG_NOP_USB_XCEIV=y
CONFIG_USB_GPIO_VBUS=y
CONFIG_USB_ULPI=y
CONFIG_USB_GADGET=y
CONFIG_USB_GADGET_DEBUG_FILES=y
CONFIG_USB_GADGET_DEBUG_FS=y
CONFIG_USB_ETH=m
CONFIG_USB_MASS_STORAGE=m
CONFIG_USB_G_SERIAL=m
CONFIG_USB_CDC_COMPOSITE=m
CONFIG_USB_G_MULTI=m
CONFIG_USB_G_MULTI_CDC=y
CONFIG_USB_G_HID=m
CONFIG_MMC=y
CONFIG_MMC_SDHCI=y
CONFIG_MMC_SDHCI_PLTFM=y
CONFIG_MMC_SDHCI_ESDHC_IMX=y
CONFIG_MMC_SPI=m
CONFIG_NEW_LEDS=y
CONFIG_LEDS_CLASS=y
CONFIG_LEDS_GPIO=y
CONFIG_LEDS_WM831X_STATUS=m
CONFIG_LEDS_MC13783=m
CONFIG_LEDS_TRIGGERS=y
CONFIG_LEDS_TRIGGER_HEARTBEAT=y
CONFIG_RTC_CLASS=y
CONFIG_RTC_MXC=y
CONFIG_RTC_DRV_WM831X=y
CONFIG_RTC_DRV_MC13XXX=m
CONFIG_STAGING=y
CONFIG_DRM_IMX=y
CONFIG_DRM_IMX_FB_HELPER=y
CONFIG_DRM_IMX_PARALLEL_DISPLAY=y
CONFIG_DRM_IMX_TVE=y
CONFIG_DRM_IMX_IPUV3=y
CONFIG_IIO=m
CONFIG_EXT2_FS=y
CONFIG_EXT2_FS_XATTR=y
CONFIG_EXT2_FS_POSIX_ACL=y
CONFIG_EXT2_FS_SECURITY=y
CONFIG_EXT2_FS_XIP=y
CONFIG_EXT3_FS=y
CONFIG_EXT3_FS_POSIX_ACL=y
CONFIG_EXT3_FS_SECURITY=y
CONFIG_EXT4_FS=y
CONFIG_AUTOFS4_FS=y
CONFIG_ISO9660_FS=y
CONFIG_JOLIET=y
CONFIG_ZISOFS=y
CONFIG_MSDOS_FS=y
CONFIG_VFAT_FS=y
CONFIG_TMPFS=y
CONFIG_UBIFS_FS=y
CONFIG_NFS_FS=y
CONFIG_NFS_V3=y
CONFIG_NFS_V4=y
CONFIG_ROOT_NFS=y
CONFIG_NLS_CODEPAGE_437=y
CONFIG_NLS_CODEPAGE_850=y
CONFIG_NLS_ISO8859_1=y
CONFIG_DEBUG_FS=y
# CONFIG_CRYPTO_ANSI_CPRNG is not set
# CONFIG_CRYPTO_HW is not set

View File

@ -0,0 +1,84 @@
Introduction
============
Armadeus APFxx are Systems On Module (SOM) based on Freescale/NXP i.MX
processors associated with an FPGA (except on APF28). Non volatile
data are stored in on-module NOR or NAND Flash, depending on the
model. These SOM can be used on Armadeus development boards or with
custom docking boards.
Supported platforms
===================
Buildroot currently supports the following Armadeus platforms with the
associated defconfigs:
* APF27 SOM + devt board -> armadeus_apf27_defconfig
* APF51 SOM + devt board -> armadeus_apf51_defconfig
* APF28 SOM + devt board -> armadeus_apf28_defconfig
Vanilla Linux versions are preferred to Freescale's one in these
configurations.
How to build it
===============
Configure Buildroot
-------------------
Let's say you own an APFxx SOM with it's corresponding development
board, all you have to do is:
$ make armadeus_apfxx_defconfig
where "apfxx" is the version of your SOM.
Launch build
------------
$ make
Result of the build
-------------------
When the build is finished, you will end up with:
output/images/
+-- imx**-apfxxdev.dtb [1]
+-- rootfs.tar
+-- rootfs.ubi
+-- rootfs.ubifs
+-- uImage
[1] Only if the kernel version used uses a Device Tree.
Building U-Boot is currently not supported in these configurations.
Installation
============
You will require a serial connection to the board and a TFTP server on
your Host PC. Assuming your server is configured for exporting
/tftpboot/ directory, you will have to copy the generated images to
it:
$ cp output/images/uImage /tftpboot/apfxx-linux.bin
$ cp output/images/*.dtb /tftpboot/
$ cp output/images/rootfs.ubi /tftpboot/apfxx-rootfs.ubi
where "apfxx" is the version of your SOM, as used with _defconfigs.
Then on your serial terminal, all you have to do is:
* interrupt the boot process and access U-Boot console by pressing any
key when booting,
* configure board and server IP addresses with "ipaddr" and "serverip"
environment variables,
* if you want to update kernel:
BIOS > run update_kernel
* if you want to update device tree:
BIOS > run update_dtb
* if you want to update rootfs:
BIOS > run update_rootfs
That's it !

View File

@ -0,0 +1,4 @@
label stm32mp157c-dk2-buildroot
kernel /boot/zImage
devicetree /boot/stm32mp157a-dhcor-avenger96.dtb
append root=/dev/mmcblk1p4 rootwait

View File

@ -0,0 +1,51 @@
From 336dc301e02d64507447f82020ce7a349797bef3 Mon Sep 17 00:00:00 2001
From: Peter Korsgaard <peter@korsgaard.com>
Date: Sun, 5 Nov 2023 14:59:16 +0100
Subject: [PATCH] stm32mp157a-avenger96.dts: enable hash device to unbreak boot
issue
The avenger96 board was forgotten when authentication support was added with
commit 4bdb1a7a6a1325343 (stm32mp1: add authentication support for
stm32image), causing a panic when stm32mp_init_auth() is called, so fix it
similar to how it was done for the STM32MP157C-ED1 board with:
commit b37b52ef8bc05bfd8dcca992d4ba84cd7c5d23bb
Author: Yann Gautier <yann.gautier@st.com>
Date: Tue Oct 13 18:05:06 2020 +0200
fdts: add missing hash node in STM32MP157C-ED1 board DT
Without this node, the board fails to boot and panics in the function
stm32mp_init_auth().
Change-Id: Ia54924410dac2a8c94dd6e45d7e93977fe7d87e2
Signed-off-by: Yann Gautier <yann.gautier@st.com>
Upstream: N/A - Upstream reworked authentication to skip it for MP157A
variant since v2.7, see "feat(st): disable authentication based on
part_number"
(https://github.com/ARM-software/arm-trusted-firmware/commit/49abdfd8cececb91a4bc7e7b29a30c09dce461c7)
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
---
fdts/stm32mp157a-avenger96.dts | 4 ++++
1 file changed, 4 insertions(+)
diff --git a/fdts/stm32mp157a-avenger96.dts b/fdts/stm32mp157a-avenger96.dts
index b967736e4..76edecb83 100644
--- a/fdts/stm32mp157a-avenger96.dts
+++ b/fdts/stm32mp157a-avenger96.dts
@@ -271,6 +271,10 @@
};
};
+&hash1 {
+ status = "okay";
+};
+
&rng1 {
status = "okay";
};
--
2.39.2

View File

@ -0,0 +1,41 @@
Arrow Avenger96
Intro
=====
This configuration supports the Arrow Avenger96 board:
https://wiki.dh-electronics.com/index.php/Avenger96
How to build
============
$ make avenger96_defconfig
$ make
How to write the microSD card
=============================
WARNING! This will destroy all the card content. Use with care!
Once the build process is finished you will have an image called
"sdcard.img" in the output/images/ directory.
Copy the bootable "sdcard.img" onto an microSD card with "dd":
$ sudo dd if=output/images/sdcard.img of=/dev/sdX
Boot the board
==============
(1) Configure the boot switches for boot from microsd: 1-0-1
(2) Insert the microSD card in the slot
(3) Plug a serial adapter (beware: 1v8 levels!) to the low speed
expansion connector
(4) Plug in power cable
(5) The system will start, with the console on UART, but also visible
on the screen.

View File

@ -0,0 +1,40 @@
#
# This config reproduces the OpenBMC flash layout defined in Linux :
#
# arch/arm/boot/dts/openbmc-flash-layout.dtsi
#
# and included by aspeed-ast2500-evb.dts
#
flash nor-32M-256 {
pebsize = 4K
numpebs = 8K
minimum-io-unit-size = 256
}
image flash.img {
flash {
}
flashtype = "nor-32M-256"
partition uboot {
image = "u-boot.bin"
size = 384K
}
partition ubootenv {
/* TODO */
offset = 384K
size = 128K
}
partition fitimage {
image = "image.itb"
offset = 512K
size = 4352K
}
partition spare {
offset = 4864K
size = 27904K
}
}

View File

@ -0,0 +1,7 @@
CONFIG_KERNEL_XZ=y
CONFIG_ARCH_MULTI_V7=n
CONFIG_MACH_ASPEED_G6=n
CONFIG_SMP=n
CONFIG_EXT4_FS=n
CONFIG_DEBUG_FS=n
CONFIG_SUSPEND=n

View File

@ -0,0 +1,80 @@
Aspeed AST2500 EVB
Introduction
============
The AST2500 EVB is an evaluation board for the AST2500 SoC, most
commonly used as a Server Management Processor. It includes an 800MHz
ARM11 processor with DDR3 or DDR4 SDRAM (up to 1GB), SPI flash memory
devices for BMC and host firmwares and numerous controllers to drive
the server board.
https://www.aspeedtech.com/server_ast2500/
How to build it
===============
Configure buildroot:
$ make aspeed_ast2500evb_defconfig
Compile everything and build the rootfs image:
$ make
Result of the build
===================
After building, the output/images directory contains:
output/images/
├── aspeed-ast2500-evb.dtb
├── flash.img
├── image.itb
├── rootfs.cpio
├── rootfs.cpio.xz
├── rootfs.tar
├── u-boot.bin
└── zImage
Flashing the image
==================
To update the contents of the first flash device, copy flash.img :
$ flashcp flash.img /dev/mtd0
or simply the boot loader:
$ flashcp u-boot.bin /dev/mtd1
Preparing the board
===================
* Connect a serial line to the board
* Power-up the board
Booting the board
=================
The AST2500 EVB boots from the SPI flash device directly and loads a
first bootloader (usually U-Boot). U-Boot will attempt to load a Linux
kernel from the same flash device by default but other storage could
be used.
* from U-Boot
The FIT image image.itb can be used to boot the board from U-Boot
using tftp
* with QEMU
$ qemu-system-arm -M ast2500-evb \
-drive file=output/images/flash.img,format=raw,if=mtd \
-nographic
$ qemu-system-arm -M ast2500-evb \
-kernel output/images/zImage \
-initrd output/images/rootfs.cpio \
-dtb output/images/aspeed-ast2500-evb.dtb \
-nographic

View File

@ -0,0 +1,3 @@
CONFIG_BOOTCOMMAND="bootm 20080000"
CONFIG_FIT=y
CONFIG_SHA256=y

View File

@ -0,0 +1,40 @@
#
# This config reproduces the OpenBMC flash layout defined in Linux :
#
# arch/arm/boot/dts/openbmc-flash-layout-64.dtsi
#
# and included by aspeed-ast2600-evb.dts
#
flash nor-64M-256 {
pebsize = 4K
numpebs = 16K
minimum-io-unit-size = 256
}
image flash.img {
flash {
}
flashtype = "nor-64M-256"
partition uboot {
image = "u-boot.bin"
size = 896K
}
partition ubootenv {
/* TODO */
offset = 896K
size = 128K
}
partition fitimage {
image = "image.itb"
offset = 1M
size = 9M
}
partition spare {
offset = 10M
size = 54M
}
}

View File

@ -0,0 +1,80 @@
Aspeed AST2600 EVB
Introduction
============
The AST2600 EVB is an evaluation board for the AST2600 SoC, most
commonly used as a Server Management Processor. It includes a
Dual-core ARM Cortex A7 processor with DDR4 SDRAM (up to 2GB), SPI
flash memory devices for BMC and host firmwares and numerous
controllers to drive the server board.
https://www.aspeedtech.com/server_ast2600/
How to build it
===============
Configure buildroot:
$ make aspeed_ast2600evb_defconfig
Compile everything and build the rootfs image:
$ make
Result of the build
===================
After building, the output/images directory contains:
output/images/
├── aspeed-ast2600-evb.dtb
├── flash.img
├── image.itb
├── rootfs.cpio
├── rootfs.cpio.xz
├── rootfs.tar
├── u-boot.bin
└── zImage
Flashing the image
==================
To update the contents of the first flash device, copy flash.img :
$ flashcp flash.img /dev/mtd0
or simply the boot loader:
$ flashcp u-boot.bin /dev/mtd1
Preparing the board
===================
* Connect a serial line to the board
* Power-up the board
Booting the board
=================
The AST2600 EVB boots from the SPI flash device directly and loads a
first bootloader (usually U-Boot). U-Boot will attempt to load a Linux
kernel from the same flash device by default but other storage could
be used.
* from U-Boot
The FIT image image.itb can be used to boot the board from U-Boot
using tftp
* with QEMU
$ qemu-system-arm -M ast2600-evb \
-drive file=output/images/flash.img,format=raw,if=mtd \
-nographic
$ qemu-system-arm -M ast2600-evb \
-kernel output/images/zImage \
-initrd output/images/rootfs.cpio \
-dtb output/images/aspeed-ast2600-evb.dtb \
-nographic

View File

@ -0,0 +1,56 @@
/dts-v1/;
/ {
description = "Kernel and buildroot image";
#address-cells = <1>;
images {
kernel-1 {
description = "Linux kernel";
data = /incbin/("zImage");
type = "kernel";
arch = "arm";
os = "linux";
compression = "none";
load = <0x80001000>;
entry = <0x80001000>;
hash-1 {
algo = "sha256";
};
};
fdt-1 {
description = "Flattened Device Tree blob";
data = /incbin/("%BOARD_DTB%");
type = "flat_dt";
arch = "arm";
compression = "none";
hash-1 {
algo = "sha256";
};
};
ramdisk-1 {
description = "ramdisk";
data = /incbin/("rootfs.cpio.xz");
type = "ramdisk";
arch = "arm";
os = "linux";
compression = "none";
hash-1 {
algo = "sha256";
};
};
};
configurations {
default = "conf-1";
conf-1 {
description = "Boot Linux kernel with FDT blob, ramdisk";
kernel = "kernel-1";
fdt = "fdt-1";
ramdisk = "ramdisk-1";
hash-1 {
algo = "sha256";
};
};
};
};

View File

@ -0,0 +1,27 @@
#!/bin/bash
BOARD_DIR="$(dirname $0)"
mkimage=$HOST_DIR/bin/mkimage
BOARD_DT=$(sed -n \
's/^BR2_LINUX_KERNEL_INTREE_DTS_NAME="\([a-z0-9\-]*\).*"$/\1/p' \
${BR2_CONFIG})
sed -e "s/%BOARD_DTB%/${BOARD_DT}.dtb/" \
$BOARD_DIR/image.its.template > $BINARIES_DIR/image.its
(cd $BINARIES_DIR && $mkimage -f image.its image.itb)
GENIMAGE_CFG="board/aspeed/${BOARD_DT#aspeed-*}/genimage.cfg"
GENIMAGE_TMP="${BUILD_DIR}/genimage.tmp"
rm -rf "${GENIMAGE_TMP}"
genimage \
--rootpath "${TARGET_DIR}" \
--tmppath "${GENIMAGE_TMP}" \
--inputpath "${BINARIES_DIR}" \
--outputpath "${BINARIES_DIR}" \
--config "${GENIMAGE_CFG}"
rm -f $BINARIES_DIR/image.its

View File

@ -0,0 +1,4 @@
label Tinker linux
kernel /boot/zImage
devicetree /boot/rk3288-tinker-s.dtb
append console=ttyS2,115200n8 root=179:1 rootwait

View File

@ -0,0 +1,9 @@
#!/bin/sh
MKIMAGE=$HOST_DIR/bin/mkimage
BOARD_DIR="$(dirname "$0")"
$MKIMAGE -n rk3288 -T rksd -d "$BINARIES_DIR"/u-boot-tpl.bin "$BINARIES_DIR"/u-boot-tpl.img
cat "$BINARIES_DIR"/u-boot-tpl.img "$BINARIES_DIR"/u-boot-spl-dtb.bin > "$BINARIES_DIR"/u-boot-tpl-spl-dtb.img
install -m 0644 -D "$BOARD_DIR"/extlinux.conf "$TARGET_DIR"/boot/extlinux/extlinux.conf

View File

@ -0,0 +1,43 @@
Tinker S RK3288
=============
Tinker Board is a Single Board Computer (SBC) in an ultra-small form
factor that offers class-leading performance while leveraging outstanding
mechanical compatibility. The "S" variant of the Tinker Board has eMMC
Tinker link:
https://www.asus.com/br/motherboards-components/single-board-computer/all-series/tinker-board-s/
Wiki link:
https://openedev.amarulasolutions.com/display/ODWIKI/Tinker+RK3288
How to build it
===============
$ make asus_tinker-s_rk3288_defconfig
Then you can edit the build options using
$ make menuconfig
Compile all and build rootfs image:
$ make
Prepare your SDCard
===================
Buildroot generates a ready-to-use SD card image that you can flash directly to
the card. The image will be in output/images/sdcard.img.
You can write this image directly to an SD card device (i.e. /dev/xxx):
$ sudo dd if=output/images/sdcard.img of=/dev/xxx
$ sudo sync
Finally, you can insert the SD card to the Tinker RK3288 board and boot it.
NOTE:
USB power supply requires more than the standard 500mA USB current, so
this board must be supplied from a capable port or from an external
AC/DC adapter. Otherwise it will hang forever while loading the kernel
image.

View File

@ -0,0 +1,4 @@
label Tinker linux
kernel /boot/zImage
devicetree /boot/rk3288-tinker.dtb
append console=ttyS2,115200n8 root=/dev/mmcblk0p1 rootwait

View File

@ -0,0 +1,22 @@
image sdcard.img {
hdimage {
}
partition u-boot-tpl-spl-dtb {
in-partition-table = "no"
image = "u-boot-tpl-spl-dtb.img"
offset = 32K
}
partition u-boot-dtb {
in-partition-table = "no"
image = "u-boot-dtb.img"
offset = 8M
size = 30M
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
}
}

View File

@ -0,0 +1,9 @@
#!/bin/sh
MKIMAGE=$HOST_DIR/bin/mkimage
BOARD_DIR="$(dirname $0)"
$MKIMAGE -n rk3288 -T rksd -d $BINARIES_DIR/u-boot-tpl.bin $BINARIES_DIR/u-boot-tpl.img
cat $BINARIES_DIR/u-boot-tpl.img $BINARIES_DIR/u-boot-spl-dtb.bin > $BINARIES_DIR/u-boot-tpl-spl-dtb.img
install -m 0644 -D $BOARD_DIR/extlinux.conf $TARGET_DIR/boot/extlinux/extlinux.conf

View File

@ -0,0 +1,43 @@
Tinker RK3288
=============
Tinker Board is a Single Board Computer (SBC) in an ultra-small form
factor that offers class-leading performance while leveraging outstanding
mechanical compatibility.
Tinker link:
https://www.asus.com/in/Single-Board-Computer/Tinker-Board/
Wiki link:
https://openedev.amarulasolutions.com/display/ODWIKI/Tinker+RK3288
How to build it
===============
$ make asus_tinker_rk3288_defconfig
Then you can edit the build options using
$ make menuconfig
Compile all and build rootfs image:
$ make
Prepare your SDCard
===================
Buildroot generates a ready-to-use SD card image that you can flash directly to
the card. The image will be in output/images/sdcard.img.
You can write this image directly to an SD card device (i.e. /dev/xxx):
$ sudo dd if=output/images/sdcard.img of=/dev/xxx
$ sudo sync
Finally, you can insert the SD card to the Tinker RK3288 board and boot it.
NOTE:
USB power supply requires more than the standard 500mA USB current, so
this board must be supplied from a capable port or from an external
AC/DC adapter. Otherwise it will hang forever while loading the kernel
image.

View File

@ -0,0 +1,40 @@
# Image for SD card boot on Atmel at91sam9x5ek boards
#
image boot.vfat {
vfat {
files = {
"zImage",
"at91sam9g15ek.dtb",
"at91sam9g25ek.dtb",
"at91sam9g35ek.dtb",
"at91sam9x25ek.dtb",
"at91sam9x35ek.dtb",
"boot.bin",
"u-boot.bin"
}
file uboot.env {
image = "uboot-env.bin"
}
}
size = 16M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
offset = 1M
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
size = 512M
}
}

View File

@ -0,0 +1,7 @@
bootargs=console=ttyS0,115200 root=/dev/mmcblk0p2 rw rootfstype=ext4 rootwait video=Unknown-1:800x480-16
bootcmd=fatload mmc 0:1 0x21000000 at91sam9g35ek.dtb; fatload mmc 0:1 0x22000000 zImage; bootz 0x22000000 - 0x21000000
bootdelay=1
ethact=gmac0
stderr=serial
stdin=serial
stdout=serial

View File

@ -0,0 +1,145 @@
#!/usr/bin/env bash
BUILDIR=$1
TTY=$2
BOARD=$3
family_at91sam9260ek="at91sam9260ek"
mach_at91sam9260ek="at91sam9260-ek"
dtb_at91sam9260ek="at91sam9260ek.dtb"
family_at91sam9g45m10ek="at91sam9m10g45ek"
mach_at91sam9g45m10ek="at91sam9m10-g45-ek"
dtb_at91sam9g45m10ek="at91sam9m10g45ek.dtb"
family_at91sam9rlek="at91sam9rlek"
mach_at91sam9rlek="at91sam9rl64-ek"
dtb_at91sam9rlek="at91sam9rlek.dtb"
family_at91sam9g15ek="at91sam9x5ek"
mach_at91sam9g15ek="at91sam9g15-ek"
dtb_at91sam9g15ek="at91sam9g15ek.dtb"
family_at91sam9g20ek="at91sam9g20ek"
mach_at91sam9g20ek="at91sam9g20-ek"
dtb_at91sam9g20ek="at91sam9g20ek.dtb"
family_at91sam9g25ek="at91sam9x5ek"
mach_at91sam9g25ek="at91sam9g25-ek"
dtb_at91sam9g25ek="at91sam9g25ek.dtb"
family_at91sam9g35ek="at91sam9x5ek"
mach_at91sam9g35ek="at91sam9g35-ek"
dtb_at91sam9g35ek="at91sam9g35ek.dtb"
family_at91sam9x25ek="at91sam9x5ek"
mach_at91sam9x25ek="at91sam9x25-ek"
dtb_at91sam9x25ek="at91sam9x25ek.dtb"
family_at91sam9x35ek="at91sam9x5ek"
mach_at91sam9x35ek="at91sam9x35-ek"
dtb_at91sam9x35ek="at91sam9x35ek.dtb"
family_sama5d31ek="sama5d3xek"
mach_sama5d31ek="at91sama5d3x-ek"
dtb_sama5d31ek="sama5d31ek.dtb"
family_sama5d31ek_revc="sama5d3xek"
mach_sama5d31ek_revc="at91sama5d3x-ek"
dtb_sama5d31ek_revc="sama5d31ek_revc.dtb"
family_sama5d33ek="sama5d3xek"
mach_sama5d33ek="at91sama5d3x-ek"
dtb_sama5d33ek="sama5d33ek.dtb"
family_sama5d33ek_revc="sama5d3xek"
mach_sama5d33ek_revc="at91sama5d3x-ek"
dtb_sama5d33ek_revc="sama5d33ek_revc.dtb"
family_sama5d34ek="sama5d3xek"
mach_sama5d34ek="at91sama5d3x-ek"
dtb_sama5d34ek="sama5d34ek.dtb"
family_sama5d34ek_revc="sama5d3xek"
mach_sama5d34ek_revc="at91sama5d3x-ek"
dtb_sama5d34ek_revc="sama5d34ek_revc.dtb"
family_sama5d35ek="sama5d3xek"
mach_sama5d35ek="at91sama5d3x-ek"
dtb_sama5d35ek="sama5d35ek.dtb"
family_sama5d35ek_revc="sama5d3xek"
mach_sama5d35ek_revc="at91sama5d3x-ek"
dtb_sama5d35ek_revc="sama5d35ek_revc.dtb"
family_sama5d36ek="sama5d3xek"
mach_sama5d36ek="at91sama5d3x-ek"
dtb_sama5d36ek="sama5d36ek.dtb"
family_sama5d36ek_revc="sama5d3xek"
mach_sama5d36ek_revc="at91sama5d3x-ek"
dtb_sama5d36ek_revc="sama5d36ek_revc.dtb"
family_sama5d3_xplained="sama5d3_xplained"
mach_sama5d3_xplained="at91sama5d3x-xplained"
dtb_sama5d3_xplained="at91-sama5d3_xplained.dtb"
family_sama5d4ek="sama5d4ek"
mach_sama5d4ek="at91sama5d4x-ek"
dtb_sama5d4ek="at91-sama5d4ek.dtb"
family_sama5d4_xplained="sama5d4_xplained"
mach_sama5d4_xplained="at91sama5d4x-ek"
dtb_sama5d4_xplained="at91-sama5d4_xplained.dtb"
usage() {
cat << EOF
Usage:
$0 <builddir_path> <interface> <board>
Available boards:
at91sam9260ek
at91sam9g45m10ek
at91sam9rlek
at91sam9g15ek
at91sam9g20ek
at91sam9g25ek
at91sam9x25ek
at91sam9g35ek
at91sam9x35ek
sama5d31ek
sama5d33ek
sama5d34ek
sama5d35ek
sama5d36ek
sama5d31ek_revc (Until rev. C)
sama5d33ek_revc (Until rev. C)
sama5d34ek_revc (Until rev. C)
sama5d35ek_revc (Until rev. C)
sama5d36ek_revc (Until rev. C)
sama5d3_xplained
sama5d4ek
sama5d4_xplained
Example:
$0 ./output /dev/ttyACM0 at91sam9g45m10ek
EOF
}
F="family_$BOARD"
M="mach_$BOARD"
D="dtb_$BOARD"
if [[ $# != 3 || -z ${!F} ]]; then
usage
exit 1
fi
video_mode="video=LVDS-1:800x480-16"
if [[ $BOARD == "*pda4" ]]; then
video_mode="video=LVDS-1:480x272-16"
fi
echo "Executing: ${!F} O=$1/images $1/host/bin/sam-ba $TTY ${!M} $(dirname $0)/nandflash.tcl -- ${!F} ${!D} $video_mode"
export O=$1/images
$1/host/bin/sam-ba $TTY ${!M} $(dirname $0)/nandflash.tcl -- ${!F} ${!D} $video_mode

View File

@ -0,0 +1,358 @@
# ----------------------------------------------------------------------------
# ATMEL Microcontroller
# ----------------------------------------------------------------------------
# Copyright (c) 2015, Atmel Corporation
#
# All rights reserved.
#
# Redistribution and use in source and binary forms, with or without
# modification, are permitted provided that the following conditions are met:
#
# - Redistributions of source code must retain the above copyright notice,
# this list of conditions and the disclaimer below.
#
# Atmel's name may not be used to endorse or promote products derived from
# this software without specific prior written permission.
#
# DISCLAIMER: THIS SOFTWARE IS PROVIDED BY ATMEL "AS IS" AND ANY EXPRESS OR
# IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE IMPLIED WARRANTIES OF
# MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NON-INFRINGEMENT ARE
# DISCLAIMED. IN NO EVENT SHALL ATMEL BE LIABLE FOR ANY DIRECT, INDIRECT,
# INCIDENTAL, SPECIAL, EXEMPLARY, OR CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT
# LIMITED TO, PROCUREMENT OF SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA,
# OR PROFITS; OR BUSINESS INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF
# LIABILITY, WHETHER IN CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING
# NEGLIGENCE OR OTHERWISE) ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE,
# EVEN IF ADVISED OF THE POSSIBILITY OF SUCH DAMAGE.
# ----------------------------------------------------------------------------
################################################################################
# Script data
################################################################################
# DBGU address for rm9200, 9260/9g20, 9261/9g10, 9rl, 9x5
set at91_base_dbgu0 0xfffff200
# DBGU address for 9263, 9g45, sama5d3
set at91_base_dbgu1 0xffffee00
# DBGU address for sama5d4
set at91_base_dbgu2 0xfc069000
set arch_exid_offset 0x44
# arch id
set arch_id_at91sam9g20 0x019905a0
set arch_id_at91sam9g45 0x819b05a0
set arch_id_at91sam9x5 0x819a05a0
set arch_id_at91sam9n12 0x819a07a0
set arch_id_sama5d3 0x8a5c07c0
## Find out at91sam9x5 variant to load the corresponding dtb file
array set at91sam9x5_variant {
0x00000000 at91sam9g15
0x00000001 at91sam9g35
0x00000002 at91sam9x35
0x00000003 at91sam9g25
0x00000004 at91sam9x25
}
## Find out sama5d3 variant to load the corresponding dtb file
array set sama5d3_variant {
0x00444300 sama5d31
0x00414300 sama5d33
0x00414301 sama5d34
0x00584300 sama5d35
0x00004301 sama5d36
}
## Find out sama5d4 variant
array set sama5d4_variant {
0x00000001 sama5d41
0x00000002 sama5d42
0x00000003 sama5d43
0x00000004 sama5d44
}
################################################################################
# proc uboot_env: Convert u-boot variables in a string ready to be flashed
# in the region reserved for environment variables
################################################################################
proc set_uboot_env {nameOfLstOfVar} {
upvar $nameOfLstOfVar lstOfVar
# sector size is the size defined in u-boot CFG_ENV_SIZE
set sectorSize [expr 0x20000 - 5]
set strEnv [join $lstOfVar "\0"]
while {[string length $strEnv] < $sectorSize} {
append strEnv "\0"
}
# \0 between crc and strEnv is the flag value for redundant environment
set strCrc [binary format i [::vfs::crc $strEnv]]
return "$strCrc\0$strEnv"
}
################################################################################
proc find_variant_name {boardType} {
global at91_base_dbgu0
global at91_base_dbgu1
global at91_base_dbgu2
global arch_exid_offset
global at91sam9x5_variant
global sama5d3_variant
global sama5d4_variant
set socName "none"
switch $boardType {
at91sam9x5ek {
set exidAddr [expr {$at91_base_dbgu0 + $arch_exid_offset}]
set chip_variant [format "0x%08x" [read_int $exidAddr]]
foreach {key value} [array get at91sam9x5_variant] {
if {$key == $chip_variant} {
set socName "$value"
break;
}
}
}
sama5d3xek {
set exidAddr [expr {$at91_base_dbgu1 + $arch_exid_offset}]
set chip_variant [format "0x%08x" [read_int $exidAddr]]
foreach {key value} [array get sama5d3_variant] {
#puts "-I- === $chip_variant ? $key ($value) ==="
if {$key == $chip_variant} {
set socName "$value"
break;
}
}
}
sama5d3_xplained {
set exidAddr [expr {$at91_base_dbgu1 + $arch_exid_offset}]
set chip_variant [format "0x%08x" [read_int $exidAddr]]
foreach {key value} [array get sama5d3_variant] {
#puts "-I- === $chip_variant ? $key ($value) ==="
if {$key == $chip_variant} {
set socName "$value"
break;
}
}
}
sama5d4ek {
set exidAddr [expr {$at91_base_dbgu2 + $arch_exid_offset}]
set chip_variant [format "0x%08x" [read_int $exidAddr]]
foreach {key value} [array get sama5d4_variant] {
#puts "-I- === $chip_variant ? $key ($value) ==="
if {$key == $chip_variant} {
set socName "$value"
break;
}
}
}
sama5d4_xplained {
set exidAddr [expr {$at91_base_dbgu2 + $arch_exid_offset}]
set chip_variant [format "0x%08x" [read_int $exidAddr]]
foreach {key value} [array get sama5d4_variant] {
#puts "-I- === $chip_variant ? $key ($value) ==="
if {$key == $chip_variant} {
set socName "$value"
break;
}
}
}
}
return "$socName"
}
proc find_variant_ecc {boardType} {
set eccType "none"
switch $boardType {
at91sam9x5ek {
set eccType 0xc0c00405
}
at91sam9n12ek {
set eccType 0xc0c00405
}
sama5d3xek {
set eccType 0xc0902405
}
sama5d3_xplained {
set eccType 0xc0902405
}
sama5d4ek {
set eccType 0xc1e04e07
}
sama5d4_xplained {
set eccType 0xc1e04e07
}
}
puts "-I- === eccType is $eccType ==="
return $eccType
}
proc get_kernel_load_addr {boardType} {
set kernel_load_addr 0x22000000
switch $boardType {
at91sam9m10g45ek {
set kernel_load_addr 0x72000000
}
}
return $kernel_load_addr
}
proc get_dtb_load_addr {boardType} {
set dtb_load_addr 0x21000000
switch $boardType {
at91sam9m10g45ek {
set dtb_load_addr 0x71000000
}
}
return $dtb_load_addr
}
################################################################################
# Main script: Load the linux demo in NandFlash,
# Update the environment variables
################################################################################
################################################################################
# check for proper variable initialization
if {! [info exists boardFamily]} {
puts "-I- === Parsing script arguments ==="
if {! [info exists env(O)]} {
puts "-E- === Binaries path not defined ==="
exit
}
set bootstrapFile "$env(O)/at91bootstrap.bin"
set ubootFile "$env(O)/u-boot.bin"
set kernelFile "$env(O)/zImage"
set rootfsFile "$env(O)/rootfs.ubi"
set build_uboot_env "yes"
set i 1
foreach arg $::argv {
puts "argument $i is $arg"
switch $i {
4 { set boardFamily $arg }
5 { set dtbFile "$env(O)/$arg" }
6 { set videoMode $arg }
}
incr i
}
}
puts "-I- === Board Family is $boardFamily ==="
set pmeccConfig [find_variant_ecc $boardFamily]
## Now check for the needed files
if {! [file exists $bootstrapFile]} {
puts "-E- === AT91Bootstrap file not found ==="
exit
}
if {! [file exists $ubootFile]} {
puts "-E- === U-Boot file not found ==="
exit
}
if {! [file exists $kernelFile]} {
puts "-E- === Linux kernel file not found ==="
exit
}
if {! [file exists $dtbFile]} {
puts "-E- === Device Tree binary: $dtbFile file not found ==="
exit
}
if {! [file exists $rootfsFile]} {
puts "-E- === Rootfs file not found ==="
exit
}
## NandFlash Mapping
set bootStrapAddr 0x00000000
set ubootAddr 0x00040000
set ubootEnvAddr 0x000c0000
set dtbAddr 0x00180000
set kernelAddr 0x00200000
set rootfsAddr 0x00800000
## u-boot variable
set kernelLoadAddr [get_kernel_load_addr $boardFamily]
set dtbLoadAddr [get_dtb_load_addr $boardFamily]
## NandFlash Mapping
set kernelSize [format "0x%08X" [file size $kernelFile]]
set dtbSize [format "0x%08X" [file size $dtbFile]]
set bootCmd "bootcmd=nand read $dtbLoadAddr $dtbAddr $dtbSize; nand read $kernelLoadAddr $kernelAddr $kernelSize; bootz $kernelLoadAddr - $dtbLoadAddr"
set rootfsSize [format "0x%08X" [file size $rootfsFile]]
lappend u_boot_variables \
"bootdelay=1" \
"baudrate=115200" \
"stdin=serial" \
"stdout=serial" \
"stderr=serial" \
"bootargs=console=ttyS0,115200 mtdparts=atmel_nand:256k(bootstrap)ro,512k(uboot)ro,256k(env),256k(env_redundant),256k(spare),512k(dtb),6M(kernel)ro,-(rootfs) rootfstype=ubifs ubi.mtd=7 root=ubi0:rootfs rw $videoMode" \
"$bootCmd"
## Additional files to load
set ubootEnvFile "ubootEnvtFileNandFlash.bin"
## Start flashing procedure ##################################################
puts "-I- === Initialize the NAND access ==="
NANDFLASH::Init
if {$pmeccConfig != "none"} {
puts "-I- === Enable PMECC OS Parameters ==="
NANDFLASH::NandHeaderValue HEADER $pmeccConfig
}
puts "-I- === Erase all the NAND flash blocs and test the erasing ==="
NANDFLASH::EraseAllNandFlash
puts "-I- === Load AT91Bootstrap in the first sector ==="
if {$pmeccConfig != "none"} {
NANDFLASH::SendBootFilePmeccCmd $bootstrapFile
} else {
NANDFLASH::sendBootFile $bootstrapFile
}
puts "-I- === Load u-boot in the next sectors ==="
send_file {NandFlash} "$ubootFile" $ubootAddr 0
if {$build_uboot_env == "yes"} {
puts "-I- === Load the u-boot environment variables ==="
set fh [open "$ubootEnvFile" w]
fconfigure $fh -translation binary
puts -nonewline $fh [set_uboot_env u_boot_variables]
close $fh
send_file {NandFlash} "$ubootEnvFile" $ubootEnvAddr 0
}
puts "-I- === Load the Kernel image and device tree database ==="
send_file {NandFlash} "$dtbFile" $dtbAddr 0
send_file {NandFlash} "$kernelFile" $kernelAddr 0
if {$pmeccConfig != "none"} {
puts "-I- === Enable trimffs ==="
NANDFLASH::NandSetTrimffs 1
}
puts "-I- === Load the linux file system ==="
send_file {NandFlash} "$rootfsFile" $rootfsAddr 0
puts "-I- === DONE. ==="

View File

@ -0,0 +1,181 @@
This document explains how to set up a basic Buildroot system on
various Atmel/Microchip boards. Additional details can also be found
on the Linux4SAM website: http://www.linux4sam.org
This guide covers the following configurations:
- at91sam9g45m10ek_defconfig
- at91sam9rlek_defconfig
- at91sam9x5ek_defconfig (at91sam9g15, at91sam9g25, at91sam9x25,
at91sam9g35 and at91sam9x35)
- atmel_sama5d3xek_defconfig (sama5d31, sama5d33, sama5d34, sama5d35,
sama5d36)
- atmel_sama5d3_xplained_defconfig
- atmel_sama5d3_xplained_dev_defconfig
- atmel_sama5d3_xplained_mmc_defconfig
- atmel_sama5d3_xplained_mmc_dev_defconfig
- atmel_sama5d4_xplained_defconfig
- atmel_sama5d4_xplained_dev_defconfig
- atmel_sama5d4_xplained_mmc_defconfig
- atmel_sama5d4_xplained_mmc_dev_defconfig
- atmel_sama5d2_xplained_mmc_defconfig
- atmel_sama5d2_xplained_mmc_dev_defconfig
- microchip_sama5d27_wlsom1_ek_mmc_defconfig
- microchip_sama5d27_wlsom1_ek_mmc_dev_defconfig
- microchip_sam9x60ek_mmc_defconfig
- microchip_sam9x60ek_mmc_dev_defconfig
- microchip_sama5d2_icp_mmc_defconfig
- microchip_sama5d2_icp_mmc_dev_defconfig
- microchip_sama7g5ek_mmc_defconfig
- microchip_sama7g5ek_mmc_dev_defconfig
These configurations will use AT91Bootstrap, u-boot and a linux kernel from
the git trees maintained by Atmel.
The configurations labeled as 'dev' provide a development rootfs with tools to
tests the features of the SoC:
- ALSA tools to test audio
- FFMPEG to record video from the ISI/ISC
- I2C, SPI, CAN, etc. tools
- modetest for LCD screens, HDMI
- Wilc1000/Wilc3000 firmware for the Atmel Wireless sdio module
- SSH for convenience
- GDB/GDB server for debug
Configuring and building Buildroot
==================================
For the Xplained/Evaluation Kit boards, the Buildroot configuration is
provided to boot from an SD card. Those configurations are labeled as
'mmc'. In this case, after building Buildroot, follow the instructions
in the "Preparing the SD card" section.
For the other configurations listed above, the Buildroot configuration
assumes the system will be flashed on NAND. In this case, after
building Buildroot, follow the instructions in the "Flashing the NAND
using SAM-BA" section below.
To configure and build Buildroot, run:
make <board>_defconfig
make
Flashing the NAND using SAM-BA
==============================
Flashing the board
------------------
Connect the board:
o at91sam9g45m10ek: DBGU: J10, USB sam-ba: J14
o at91sam9rlek: DBGU: J19, USB sam-ba: J21
o at91sam9x5ek: DBGU: J11, USB sam-ba: J20
o sama5d3xek: DBGU: J14, USB sam-ba: J20
o sama5d3 Xplained: DBGU: J23, USB sam-ba: J6
o sama5d4ek: DBGU: J22 or J24, USB sam-ba: J1
o sama5d4 Xplained: DBGU: J1, USB sam-ba: J11
Start the board in RomBOOT:
o at91sam9g45m10ek:
1. open JP8, JP10 and JP12
2. start the board
3. close JP8, JP10 and JP12
o at91sam9rlek:
1. J11 on 1-2 (BMS=1), open J12 and J13
2. start the board
3. close J12 and J13
o at91sam9x5ek:
1. open JP9 and:
- Cogent: open *NCS jumper
- Embest: open SW1
- Ronetix: open J1 and J2
2. start the board
3. close JP9 and:
- Cogent: close *NCS jumper
- Embest: close SW1 (ON position)
- Ronetix: close J1 and J2
o sama5d3xek:
1. start the board
2. push BP4 and BP1
3. release BP1
4. release BP4
o sama5d3 Xplained:
1. open JP5 (NANDCS) and JP6 (SPICS)
2. start the board
3. close JP5 ans JP6
o sama5d4ek:
1. start the board
2. push BP3 and BP4
3. release BP4
4. release BP3
o sama5d4 Xplained:
1. close JP7 (BOOT_DIS)
2. start the board
3. open JP7
"RomBOOT" should appear on your console (this should be ttyUSBx or ttyACMx)
Now locate the USB sam-ba interface it should be ttyACMx, usually ttyACM0
dmesg on your machine should give:
usb 1-2.1.4: New USB device found, idVendor=03eb, idProduct=6124
usb 1-2.1.4: New USB device strings: Mfr=0, Product=0, SerialNumber=0
cdc_acm 1-2.1.4:1.0: ttyACM0: USB ACM device
Look for idVendor=03eb, idProduct=6124, this is the interface you want to use.
You can then flash the board using the provided flasher.sh script in board/atmel:
board/atmel/flasher.sh <builddir_path> <interface> <board>
For example, for an out of tree build made in
/tmp/atmel_sama5d3_xplained/ for the sama5d3 Xplained, you would use:
board/atmel/flasher.sh /tmp/atmel_sama5d3_xplained/ /dev/ttyACM0 sama5d3_xplained
Reboot, the system should boot up to the buildroot login invite.
Preparing the SD card
=====================
An image named sdcard.img is automatically generated. With this image,
you no longer have to care about the creation of the partition and
copying files to the SD card.
You need at least a 1GB SD card. All the data on the SD card will be
lost. To copy the image on the SD card:
/!\ Caution be sure to do it on the right mmcblk device /!\
dd if=output/images/sdcard.img of=/dev/mmcblk0
Insert your SD card in your Xplained/Evaluation Kit board, and
enjoy. The default U-Boot environment will load properly the kernel
and Device Tree blob from the first partition of the SD card, so
everything works automatically.
By default a 16MB FAT partition is created. It contains at91bootstrap,
u-boot, the kernel image and all dtb variants for your board. The dtb
used is the basic one:
U-Boot> print
[...]
bootcmd=fatload mmc 1:1 0x21000000 at91-sama5d2_xplained.dtb; fatload mmc 1:1 0x22000000 zImage; bootz 0x22000000 - 0x21000000
[...]
If you want to use a variant such as the _pda7 one, you will have to
update your u-boot environment:
U-Boot> setenv bootcmd 'fatload mmc 1:1 0x21000000 at91-sama5d2_xplained_pda7.dtb; fatload mmc 1:1 0x22000000 zImage; bootz 0x22000000 - 0x21000000'
U-Boot> save
Saving Environment to FAT...
writing uboot.env
done
A 512MB ext4 partition is also created to store the rootfs generated.
If you want to customize the size of the partitions and their content,
take a look at the the genimage.cfg file in the board directory.

View File

@ -0,0 +1,32 @@
# Image for SD card boot on Atmel SAMA5D2 Xplained boards
#
image boot.vfat {
vfat {
files = {
"zImage",
"at91-sama5d27_som1_ek.dtb",
"boot.bin",
"u-boot.bin"
}
}
size = 16M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
offset = 1M
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
size = 512M
}
}

View File

@ -0,0 +1,32 @@
# Image for SD card boot on Microchip SAMA5D27 WLSOM1 EK
#
image boot.vfat {
vfat {
files = {
"zImage",
"at91-sama5d27_wlsom1_ek.dtb",
"boot.bin",
"u-boot.bin"
}
}
size = 16M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
offset = 1M
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
size = 512M
}
}

View File

@ -0,0 +1,32 @@
# Image for SD card boot on Atmel SAMA5D2 Xplained boards
#
image boot.vfat {
vfat {
files = {
"zImage",
"at91-sama5d2_xplained.dtb",
"boot.bin",
"u-boot.bin"
}
}
size = 16M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
offset = 1M
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
size = 512M
}
}

View File

@ -0,0 +1,32 @@
# Image for SD card boot on Atmel SAMA5D3 Xplained boards
#
image boot.vfat {
vfat {
files = {
"zImage",
"at91-sama5d3_xplained.dtb",
"boot.bin",
"u-boot.bin"
}
}
size = 16M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
offset = 1M
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
size = 512M
}
}

View File

@ -0,0 +1,32 @@
# Image for SD card boot on Atmel SAMA5D4 Xplained boards
#
image boot.vfat {
vfat {
files = {
"zImage",
"at91-sama5d4_xplained.dtb",
"boot.bin",
"u-boot.bin"
}
}
size = 16M
}
image sdcard.img {
hdimage {
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
offset = 1M
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
size = 512M
}
}

View File

@ -0,0 +1,29 @@
# SD card image for RZBoard V2L
image boot.vfat {
vfat {
files = {
"Image",
"rzboard.dtb",
"uEnv.txt"
}
}
size = 24M
}
image sdcard.img {
hdimage {
partition-table-type = "hybrid"
}
partition boot {
partition-type = "0xC"
bootable = "true"
image = "boot.vfat"
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext2"
}
}

View File

@ -0,0 +1,5 @@
#!/usr/bin/env bash
set -e
cp board/avnet/rzboard_v2l/uEnv.txt "${BINARIES_DIR}"
support/scripts/genimage.sh -c board/avnet/rzboard_v2l/genimage.cfg

View File

@ -0,0 +1,71 @@
RZBoard V2L
===========
https://www.avnet.com/wps/portal/us/products/avnet-boards/avnet-board-families/rzboard-v2l/
This board support creates a bootable sd card image for the AVNET RZBoard V2L.
This board is shipped with a u-boot inside its eMMC. This board support uses
that u-boot and only puts uEnv.txt, kernel image and rootfs onto the sd card.
Build:
======
$ make rzboard_v2l_defconfig
$ make
Files created in output directory
=================================
output/images
.
├── Image
├── boot.vfat
├── rootfs.ext2
├── rootfs.ext4
├── rootfs.tar
├── rzboard.dtb
├── sdcard.img
└── uEnv.txt
Creating bootable SD card:
==========================
Simply invoke (as root)
sudo dd if=output/images/sdcard.img of=/dev/sdX && sync
Where X is your SD card device.
Booting:
========
Configure board for sd card boot:
---------------------------------
Set the 'BOOT1' switch (next to the audio jack) to '1' (away from 'ON') in
order to let the board boot kernel and rootfs from SD card.
Serial console:
---------------
The RZBoard V2L has a 4-pin header "J19" right next to the micro USB. Its
layout can be seen in the Quick-Start Guide, or the Hardware User Guide,
obtainable from:
https://www.avnet.com/wps/portal/us/products/avnet-boards/avnet-board-families/rzboard-v2l/
The uart pins are as follows (from left to right - orientation according to the
board's labeling):
pin 1: n/a (most away from the board's corner)
pin 2: tx
pin 3: rx
pin 4: gnd (nearest to the board's corner)
Baudrate for this board is 115200.
Power-Up:
---------
Plug in a suitable USB-C power supply and press the button 'S1' (next to the
USB-C port) for 2 seconds until the LED goes on.
Login:
------
Enter 'root' as login user, and the prompt is ready.

View File

@ -0,0 +1,3 @@
bootcmd=booti ${kernel_addr_r} - ${fdt_addr_r}
uenvcmd=fatload mmc 0:1 ${kernel_addr_r} Image; fatload mmc 0:1 ${fdt_addr_r} rzboard.dtb
bootargs=root=/dev/mmcblk0p2 rw rootfstype=ext4 earlyprintk console=ttyS0,115200 rootwait earlycon clk_ignore_unused debug

View File

@ -0,0 +1,247 @@
/*
* Device Tree Generator version: 1.3
*
* (C) Copyright 2007-2008 Xilinx, Inc.
* (C) Copyright 2007-2009 Michal Simek
*
* Michal SIMEK <monstr@monstr.eu>
*
* This program is free software; you can redistribute it and/or
* modify it under the terms of the GNU General Public License as
* published by the Free Software Foundation; either version 2 of
* the License, or (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program; if not, write to the Free Software
* Foundation, Inc., 59 Temple Place, Suite 330, Boston,
* MA 02111-1307 USA
*
* CAUTION: This file is automatically generated by libgen.
* Version: Xilinx EDK 13.2 EDK_O.61xd
*
* XPS project directory: device-tree_bsp_230-orig
*/
/dts-v1/;
/ {
#address-cells = <1>;
#size-cells = <1>;
compatible = "xlnx,microblaze";
model = "testing";
MCB3_LPDDR: memory@80000000 {
device_type = "memory";
reg = < 0x80000000 0x4000000 >;
} ;
aliases {
ethernet0 = &Ethernet_MAC;
serial0 = &USB_Uart;
} ;
chosen {
bootargs = "console=ttyUL0";
linux,stdout-path = "/axi@0/serial@40600000";
} ;
cpus {
#address-cells = <1>;
#cpus = <0x1>;
#size-cells = <0>;
microblaze_0: cpu@0 {
clock-frequency = <66666667>;
compatible = "xlnx,microblaze-8.20.a";
d-cache-baseaddr = <0x80000000>;
d-cache-highaddr = <0x83ffffff>;
d-cache-line-size = <0x10>;
d-cache-size = <0x2000>;
device_type = "cpu";
i-cache-baseaddr = <0x80000000>;
i-cache-highaddr = <0x83ffffff>;
i-cache-line-size = <0x10>;
i-cache-size = <0x2000>;
model = "microblaze,8.20.a";
reg = <0>;
timebase-frequency = <66666667>;
xlnx,addr-tag-bits = <0xd>;
xlnx,allow-dcache-wr = <0x1>;
xlnx,allow-icache-wr = <0x1>;
xlnx,area-optimized = <0x0>;
xlnx,avoid-primitives = <0x0>;
xlnx,branch-target-cache-size = <0x0>;
xlnx,cache-byte-size = <0x2000>;
xlnx,d-axi = <0x1>;
xlnx,d-lmb = <0x1>;
xlnx,d-plb = <0x0>;
xlnx,data-size = <0x20>;
xlnx,dcache-addr-tag = <0xd>;
xlnx,dcache-always-used = <0x1>;
xlnx,dcache-byte-size = <0x2000>;
xlnx,dcache-data-width = <0x0>;
xlnx,dcache-force-tag-lutram = <0x0>;
xlnx,dcache-interface = <0x0>;
xlnx,dcache-line-len = <0x4>;
xlnx,dcache-use-fsl = <0x0>;
xlnx,dcache-use-writeback = <0x0>;
xlnx,dcache-victims = <0x0>;
xlnx,debug-enabled = <0x1>;
xlnx,div-zero-exception = <0x0>;
xlnx,dynamic-bus-sizing = <0x1>;
xlnx,ecc-use-ce-exception = <0x0>;
xlnx,edge-is-positive = <0x1>;
xlnx,endianness = <0x1>;
xlnx,family = "spartan6";
xlnx,fault-tolerant = <0x0>;
xlnx,fpu-exception = <0x0>;
xlnx,freq = <0x3f940ab>;
xlnx,fsl-data-size = <0x20>;
xlnx,fsl-exception = <0x0>;
xlnx,fsl-links = <0x0>;
xlnx,i-axi = <0x0>;
xlnx,i-lmb = <0x1>;
xlnx,i-plb = <0x0>;
xlnx,icache-always-used = <0x1>;
xlnx,icache-data-width = <0x0>;
xlnx,icache-force-tag-lutram = <0x0>;
xlnx,icache-interface = <0x0>;
xlnx,icache-line-len = <0x4>;
xlnx,icache-streams = <0x0>;
xlnx,icache-use-fsl = <0x0>;
xlnx,icache-victims = <0x0>;
xlnx,ill-opcode-exception = <0x0>;
xlnx,instance = "microblaze_0";
xlnx,interconnect = <0x2>;
xlnx,interconnect-m-axi-dc-aw-register = <0x0>;
xlnx,interconnect-m-axi-dc-read-issuing = <0x2>;
xlnx,interconnect-m-axi-dc-w-register = <0x0>;
xlnx,interconnect-m-axi-dc-write-issuing = <0x20>;
xlnx,interconnect-m-axi-dp-read-issuing = <0x1>;
xlnx,interconnect-m-axi-dp-write-issuing = <0x1>;
xlnx,interconnect-m-axi-ic-read-issuing = <0x2>;
xlnx,interconnect-m-axi-ip-read-issuing = <0x1>;
xlnx,interrupt-is-edge = <0x0>;
xlnx,lockstep-slave = <0x0>;
xlnx,mmu-dtlb-size = <0x1>;
xlnx,mmu-itlb-size = <0x1>;
xlnx,mmu-privileged-instr = <0x0>;
xlnx,mmu-tlb-access = <0x3>;
xlnx,mmu-zones = <0x2>;
xlnx,number-of-pc-brk = <0x1>;
xlnx,number-of-rd-addr-brk = <0x0>;
xlnx,number-of-wr-addr-brk = <0x0>;
xlnx,opcode-0x0-illegal = <0x0>;
xlnx,optimization = <0x0>;
xlnx,pvr = <0x0>;
xlnx,pvr-user1 = <0x0>;
xlnx,pvr-user2 = <0x0>;
xlnx,reset-msr = <0x0>;
xlnx,sco = <0x0>;
xlnx,stream-interconnect = <0x0>;
xlnx,unaligned-exceptions = <0x0>;
xlnx,use-barrel = <0x1>;
xlnx,use-branch-target-cache = <0x0>;
xlnx,use-dcache = <0x1>;
xlnx,use-div = <0x0>;
xlnx,use-ext-brk = <0x1>;
xlnx,use-ext-nm-brk = <0x1>;
xlnx,use-extended-fsl-instr = <0x0>;
xlnx,use-fpu = <0x0>;
xlnx,use-hw-mul = <0x1>;
xlnx,use-icache = <0x1>;
xlnx,use-interrupt = <0x1>;
xlnx,use-mmu = <0x3>;
xlnx,use-msr-instr = <0x1>;
xlnx,use-pcmp-instr = <0x0>;
xlnx,use-stack-protection = <0x0>;
} ;
} ;
axi4lite_0: axi@0 {
#address-cells = <1>;
#size-cells = <1>;
compatible = "xlnx,axi-interconnect-1.03.a", "simple-bus";
ranges ;
Ethernet_MAC: ethernet@40e00000 {
compatible = "xlnx,axi-ethernetlite-1.00.a", "xlnx,xps-ethernetlite-1.00.a";
device_type = "network";
interrupt-parent = <&microblaze_0_intc>;
interrupts = < 2 0 >;
local-mac-address = [ 00 0a 35 aa de 00 ];
// phy-handle = <&phy0>;
reg = < 0x40e00000 0x10000 >;
xlnx,duplex = <0x1>;
xlnx,family = "spartan6";
xlnx,include-global-buffers = <0x0>;
xlnx,include-internal-loopback = <0x0>;
xlnx,include-mdio = <0x1>;
xlnx,include-phy-constraints = <0x1>;
xlnx,interconnect-s-axi-read-acceptance = <0x1>;
xlnx,interconnect-s-axi-write-acceptance = <0x1>;
xlnx,rx-ping-pong = <0x0>;
xlnx,s-axi-aclk-period-ps = <0x3a98>;
xlnx,s-axi-id-width = <0x1>;
xlnx,s-axi-supports-narrow-burst = <0x0>;
xlnx,tx-ping-pong = <0x0>;
/*
mdio {
#address-cells = <1>;
#size-cells = <0>;
phy0: phy@7 {
compatible = "marvell,88e1111";
device_type = "ethernet-phy";
reg = <7>;
} ;
} ;
*/
} ;
SPI_FLASH: spi@40a00000 {
compatible = "xlnx,axi-spi-1.01.a", "xlnx,xps-spi-2.00.a";
interrupt-parent = <&microblaze_0_intc>;
interrupts = < 1 2 >;
reg = < 0x40a00000 0x10000 >;
xlnx,family = "spartan6";
xlnx,fifo-exist = <0x1>;
xlnx,num-ss-bits = <0x1>;
xlnx,num-transfer-bits = <0x8>;
xlnx,sck-ratio = <0x4>;
} ;
USB_Uart: serial@40600000 {
clock-frequency = <66666667>;
compatible = "xlnx,axi-uartlite-1.02.a", "xlnx,xps-uartlite-1.00.a";
current-speed = <115200>;
device_type = "serial";
interrupt-parent = <&microblaze_0_intc>;
interrupts = < 3 0 >;
port-number = <0>;
reg = < 0x40600000 0x10000 >;
xlnx,baudrate = <0x1c200>;
xlnx,data-bits = <0x8>;
xlnx,family = "spartan6";
xlnx,odd-parity = <0x1>;
xlnx,s-axi-aclk-freq-hz = <0x3f940ab>;
xlnx,use-parity = <0x0>;
} ;
microblaze_0_intc: interrupt-controller@41200000 {
#interrupt-cells = <0x2>;
compatible = "xlnx,axi-intc-1.01.a", "xlnx,xps-intc-1.00.a";
interrupt-controller ;
reg = < 0x41200000 0x10000 >;
xlnx,kind-of-intr = <0xc>;
xlnx,num-intr-inputs = <0x4>;
} ;
system_timer: timer@41c00000 {
clock-frequency = <66666667>;
compatible = "xlnx,axi-timer-1.02.a", "xlnx,xps-timer-1.00.a";
interrupt-parent = <&microblaze_0_intc>;
interrupts = < 0 2 >;
reg = < 0x41c00000 0x10000 >;
xlnx,count-width = <0x20>;
xlnx,family = "spartan6";
xlnx,gen0-assert = <0x1>;
xlnx,gen1-assert = <0x1>;
xlnx,one-timer-only = <0x0>;
xlnx,trig0-assert = <0x1>;
xlnx,trig1-assert = <0x1>;
} ;
} ;
} ;

View File

@ -0,0 +1,68 @@
CONFIG_EXPERIMENTAL=y
CONFIG_SYSVIPC=y
CONFIG_IKCONFIG=y
CONFIG_IKCONFIG_PROC=y
CONFIG_BLK_DEV_INITRD=y
CONFIG_INITRAMFS_SOURCE="rootfs.cpio"
CONFIG_INITRAMFS_COMPRESSION_GZIP=y
# CONFIG_CC_OPTIMIZE_FOR_SIZE is not set
CONFIG_EXPERT=y
CONFIG_KALLSYMS_ALL=y
CONFIG_KALLSYMS_EXTRA_PASS=y
# CONFIG_HOTPLUG is not set
# CONFIG_BASE_FULL is not set
# CONFIG_FUTEX is not set
# CONFIG_EPOLL is not set
# CONFIG_SIGNALFD is not set
# CONFIG_SHMEM is not set
CONFIG_SLAB=y
CONFIG_MODULES=y
CONFIG_MODULE_UNLOAD=y
# CONFIG_BLK_DEV_BSG is not set
# CONFIG_OPT_LIB_ASM is not set
CONFIG_KERNEL_BASE_ADDR=0x80000000
CONFIG_XILINX_MICROBLAZE0_FAMILY="spartan6"
CONFIG_XILINX_MICROBLAZE0_USE_MSR_INSTR=1
# CONFIG_XILINX_MICROBLAZE0_USE_PCMP_INSTR is not set
CONFIG_XILINX_MICROBLAZE0_USE_BARREL=1
CONFIG_XILINX_MICROBLAZE0_USE_HW_MUL=1
CONFIG_XILINX_MICROBLAZE0_HW_VER="8.20.a"
CONFIG_HZ_100=y
CONFIG_MMU=y
CONFIG_CMDLINE_BOOL=y
CONFIG_CMDLINE_FORCE=y
CONFIG_NET=y
CONFIG_PACKET=y
CONFIG_UNIX=y
CONFIG_INET=y
# CONFIG_INET_LRO is not set
# CONFIG_IPV6 is not set
CONFIG_PROC_DEVICETREE=y
CONFIG_BLK_DEV_RAM=y
CONFIG_BLK_DEV_RAM_SIZE=8192
CONFIG_NETDEVICES=y
CONFIG_NET_ETHERNET=y
CONFIG_XILINX_EMACLITE=y
# CONFIG_INPUT is not set
# CONFIG_SERIO is not set
# CONFIG_VT is not set
CONFIG_SERIAL_UARTLITE=y
CONFIG_SERIAL_UARTLITE_CONSOLE=y
# CONFIG_HW_RANDOM is not set
# CONFIG_HWMON is not set
# CONFIG_USB_SUPPORT is not set
CONFIG_EXT2_FS=y
# CONFIG_DNOTIFY is not set
CONFIG_NFS_FS=y
CONFIG_NFS_V3=y
CONFIG_CIFS=y
CONFIG_CIFS_STATS=y
CONFIG_CIFS_STATS2=y
CONFIG_PARTITION_ADVANCED=y
CONFIG_DEBUG_KERNEL=y
CONFIG_DETECT_HUNG_TASK=y
CONFIG_DEBUG_SLAB=y
CONFIG_DEBUG_SPINLOCK=y
CONFIG_DEBUG_INFO=y
CONFIG_EARLY_PRINTK=y
# CONFIG_CRYPTO_ANSI_CPRNG is not set

View File

@ -0,0 +1,70 @@
This is the buildroot board support for the Avnet Spartan6 LX9 MicroBoard.
The Avnet S6LX9 Microboard is a small USB-Stick sized module containing
a Spartan6 FPGA capable of running the Microblaze softcore processor
together with RAM and FLASH memory.
The board can be bought from Avnet (avnet.com) or from Trenz Electronic
(www.trenz-electronic.de) for a low price.
To run the Linux built with buildroot you have to install the FPGA bitfile
and u-boot as described in the tutorial AvtS6LX9MicroBoard_SW302_PetaLinux
available on http://www.em.avnet.com/s6microboard
On this site also is a forum containing information on how to build your own
Microblaze processor for the Microboard.
The image file (default name is simpleImage.lx9_mmu.ub) has to be copied
to your tftp folder (often /tftpboot/) or can be programmed into the
board's SPI flash.
Sample session:
$ make s6lx9_microboard_defconfig
$ make
$ cp build/linux-<version>/arch/microblaze/boot/simpleImage.lx9_mmu.ub /tftpboot/br12.2a.ub
$ minicom
<hit the reset button on the S6LX9 Microboard>
Icache:ON
Dcache:ON
U-Boot Start:0x83f00000
SF: Got idcode 20 ba 18 10 01
*** Warning - bad CRC, using default environment
Net: Xilinx_Emaclite
MAC: 00:0a:35:00:63:37
U-BOOT for Avnet-LX9-Microboard-AXI-tiny-13.1
BOOTP broadcast 1
DHCP client bound to address 192.168.11.122
Hit any key to stop autoboot: 0
U-Boot-PetaLinux> tftp br12.2a.ub
Using Xilinx_Emaclite device
TFTP from server 192.168.11.10; our IP address is 192.168.11.122
Filename 'br12.2a.ub'.
Load address: 0x80002000
Loading: #################################################################
#################################################################
#################################################################
#################################################################
#################################################################
##############################
done
Bytes transferred = 5207724 (4f76ac hex)
U-Boot-PetaLinux> bootm
## Booting kernel from Legacy Image at 80002000 ...
Image Name: Linux-3.1.0
Image Type: MicroBlaze Linux Kernel Image (uncompressed)
Data Size: 5207660 Bytes = 5 MB
Load Address: 80000000
Entry Point: 80000000
Verifying Checksum ... OK
Loading Kernel Image ... OK
OK
## Transferring control to Linux (at address 80000000), 0x80000000 ramdisk 0x00000000, FDT 0x00000000...
Early console on uartlite at 0x40600000
..... boot log skipped
Welcome to Microblaze Buildroot
Microblaze login:

View File

@ -0,0 +1,4 @@
label Bananapi M2 Berry linux
kernel /boot/zImage
devicetree /boot/sun8i-v40-bananapi-m2-berry.dtb
append console=ttyS0,115200n8 root=/dev/mmcblk0p1 rootwait

View File

@ -0,0 +1,16 @@
image sdcard.img {
hdimage {
}
partition u-boot {
in-partition-table = "no"
image = "u-boot-sunxi-with-spl.bin"
offset = 8K
size = 1016K # 1MB - 8KB
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
}
}

View File

@ -0,0 +1,6 @@
#!/bin/sh
BOARD_DIR="$(dirname "$0")"
install -m 644 -D "${BOARD_DIR}"/extlinux.conf \
"${TARGET_DIR}"/boot/extlinux/extlinux.conf

View File

@ -0,0 +1,35 @@
Intro
=====
This default configuration will allow you to start experimenting with the
buildroot environment for the Bananapi M2 Berry. With the current
configuration it will bring-up the board, and allow access through the
serial console.
Bananapi M2 Berry link:
https://wiki.banana-pi.org/Banana_Pi_BPI-M2_Berry
This configuration uses U-Boot mainline and kernel mainline.
How to build
============
$ make bananapi_m2_berry_defconfig
$ make
Note: you will need access to the internet to download the required
sources.
How to write the SD card
========================
Once the build process is finished you will have an image called "sdcard.img"
in the output/images/ directory.
Copy the bootable "sdcard.img" onto an SD card with "dd":
$ sudo dd if=output/images/sdcard.img of=/dev/sdX
$ sudo sync
Insert the micro SDcard in your Bananapi M2 Berry and power it up. The console
is on the serial line, 115200 8N1.

View File

@ -0,0 +1,4 @@
label Bananapi M2 Ultra linux
kernel /boot/zImage
devicetree /boot/sun8i-r40-bananapi-m2-ultra.dtb
append console=ttyS0,115200n8 root=/dev/mmcblk0p1 rootwait

View File

@ -0,0 +1,16 @@
image sdcard.img {
hdimage {
}
partition u-boot {
in-partition-table = "no"
image = "u-boot-sunxi-with-spl.bin"
offset = 8K
size = 1016K # 1MB - 8KB
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
}
}

View File

@ -0,0 +1,6 @@
#!/bin/sh
BOARD_DIR="$(dirname "$0")"
install -m 644 -D "${BOARD_DIR}"/extlinux.conf \
"${TARGET_DIR}"/boot/extlinux/extlinux.conf

View File

@ -0,0 +1,35 @@
Intro
=====
This default configuration will allow you to start experimenting with the
buildroot environment for the Bananapi M2 ULtra. With the current
configuration it will bring-up the board, and allow access through the
serial console.
Bananapi M2 Ultra link:
http://www.banana-pi.org/m2u.html
This configuration uses U-Boot mainline and kernel mainline.
How to build
============
$ make bananapi_m2_ultra_defconfig
$ make
Note: you will need access to the internet to download the required
sources.
How to write the SD card
========================
Once the build process is finished you will have an image called "sdcard.img"
in the output/images/ directory.
Copy the bootable "sdcard.img" onto an SD card with "dd":
$ sudo dd if=output/images/sdcard.img of=/dev/sdX
$ sudo sync
Insert the micro SDcard in your Bananapi M2 Ultra and power it up. The console
is on the serial line, 115200 8N1.

View File

@ -0,0 +1,7 @@
setenv bootargs console=ttyS0,115200 earlyprintk root=/dev/mmcblk0p2 rootwait
mmc dev 0
fatload mmc 0 $kernel_addr_r zImage
fatload mmc 0 $fdt_addr_r sun8i-h2-plus-bananapi-m2-zero.dtb
bootz $kernel_addr_r - $fdt_addr_r

View File

@ -0,0 +1,34 @@
image boot.vfat {
vfat {
files = {
"zImage",
"sun8i-h2-plus-bananapi-m2-zero.dtb",
"boot.scr"
}
}
size = 64M
}
image sdcard.img {
hdimage {
}
partition u-boot {
in-partition-table = "no"
image = "u-boot-sunxi-with-spl.bin"
offset = 8K
size = 1016K # 1MB - 8KB
}
partition boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
}
}

View File

@ -0,0 +1,34 @@
Intro
=====
This default configuration will allow you to start experimenting with the
Buildroot environment for the Bananapi M2 Zero. With the current configuration
it will bring-up the board, and allow access through the serial console.
Bananapi M2 Zero link:
http://www.banana-pi.org/m2z.html
This configuration uses U-Boot mainline and kernel mainline.
How to build
============
$ make bananapi_m2_zero_defconfig
$ make
Note: you will need access to the internet to download the required
sources.
How to write the SD card
========================
Once the build process is finished you will have an image called "sdcard.img"
in the output/images/ directory.
Copy the bootable "sdcard.img" onto an SD card with "dd":
$ sudo dd if=output/images/sdcard.img of=/dev/sdX
$ sync
Insert the micro SDcard in your Bananapi M2 Zero and power it up. The console
is on the Debug UART on the CON3 header, with serial settings 115200 8N1.

View File

@ -0,0 +1,27 @@
image boot.vfat {
vfat {
files = {
"MLO",
"u-boot.img"
}
}
size = 4M
}
image sdcard.img {
hdimage {
}
partition u-boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
size = 512M
}
}

View File

@ -0,0 +1,49 @@
BeagleBoard X15
Intro
=====
This config currently supports the beagleboard x15,
and generates a barebone image.
The image must be flashed to a SD card to be used.
How to build it
===============
$ make beagleboardx15_defconfig
Then you can edit the build options using
$ make menuconfig
Compile all and build a sdcard image:
$ make
Result of the build
-------------------
After building, you should get a tree like this:
output/images/
+-- am57xx-beagle-x15.dtb
+-- am57xx-beagle-x15-revb1.dtb
+-- boot.vfat
+-- MLO
+--rootfs.ext2
+-- rootfs.ext4
+-- rootfs.tar
+-- sdcard.img
+-- u-boot.img
+-- u-boot-spl.bin
+-- zImage
How to write the microSD card
=============================
Once the build process is finished you will have an image called "sdcard.img"
in the output/images/ directory.
Copy the bootable "sdcard.img" onto an SD card with "dd":
$ sudo dd if=output/images/sdcard.img of=/dev/sdX

View File

@ -0,0 +1,4 @@
label beaglebone-buildroot
kernel /zImage
fdtdir /
append console=ttyS0,115200n8 root=/dev/mmcblk0p2 rw rootfstype=ext4 rootwait

View File

@ -0,0 +1,37 @@
image boot.vfat {
vfat {
files = {
"MLO",
"u-boot.img",
"zImage",
"uEnv.txt",
"am335x-evm.dtb",
"am335x-evmsk.dtb",
"am335x-bone.dtb",
"am335x-boneblack.dtb",
"am335x-bonegreen.dtb",
"am335x-boneblack-wireless.dtb",
"am335x-bonegreen-wireless.dtb",
"extlinux"
}
}
size = 16M
}
image sdcard.img {
hdimage {
}
partition u-boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
size = 512M
}
}

View File

@ -0,0 +1,13 @@
CONFIG_PREEMPT=y
CONFIG_PREEMPT_COUNT=y
CONFIG_OMAP2_DSS_INIT=y
CONFIG_OMAP_DSS_BASE=y
CONFIG_OMAP2_DSS=y
CONFIG_OMAP2_DSS_DPI=y
CONFIG_DRM_OMAP=y
CONFIG_DRM_OMAP_NUM_CRTCS=2
CONFIG_DRM_OMAP_WB_M2M=y
CONFIG_DRM_TILCDC=y
CONFIG_DRM_I2C_NXP_TDA998X=y
CONFIG_DRM=y
CONFIG_DRM_LEGACY=y

View File

@ -0,0 +1,16 @@
This patch keeps the debugSS clock alive, it clocks the JTAG macro and enables
access to the SoC via JTAG after the kernel booted.
Signed-off-by: Lothar Felten <lothar.felten@gmail.com>
---
diff -Naur linux-orig/arch/arm/mach-omap2/omap_hwmod_33xx_data.c linux-52c4aa7cdb93d61f8008f380135beaf7b8fa6593/arch/arm/mach-omap2/omap_hwmod_33xx_data.c
--- linux-orig/arch/arm/mach-omap2/omap_hwmod_33xx_data.c 2015-10-02 17:30:56.000000000 +0200
+++ linux-52c4aa7cdb93d61f8008f380135beaf7b8fa6593/arch/arm/mach-omap2/omap_hwmod_33xx_data.c 2016-08-15 11:28:55.017617612 +0200
@@ -208,6 +208,7 @@
.name = "debugss",
.class = &am33xx_debugss_hwmod_class,
.clkdm_name = "l3_aon_clkdm",
+ .flags = (HWMOD_INIT_NO_IDLE|HWMOD_INIT_NO_RESET), /* keep debugSS clock alive for JTAG */
.main_clk = "trace_clk_div_ck",
.prcm = {
.omap4 = {

View File

@ -0,0 +1,6 @@
#!/bin/sh
BOARD_DIR="$(dirname $0)"
cp $BOARD_DIR/uEnv.txt $BINARIES_DIR/uEnv.txt
install -m 0644 -D $BOARD_DIR/extlinux.conf $BINARIES_DIR/extlinux/extlinux.conf

View File

@ -0,0 +1,66 @@
CircuitCo BeagleBone
Texas Instuments AM335x Evaluation Module (TMDXEVM3358)
Description
===========
This configuration will build a complete image for the beaglebone and
the TI AM335x-EVM, the board type is identified by the on-board
EEPROM. The configuration is based on the
ti-processor-sdk-06.01.00.08. Device tree blobs for beaglebone
variants and the evm-sk are built too.
For Qt5 support support use the beaglebone_qt5_defconfig.
How to build it
===============
Select the default configuration for the target:
$ make beaglebone_defconfig
Optional: modify the configuration:
$ make menuconfig
Build:
$ make
Result of the build
===================
output/images/
+-- am335x-boneblack.dtb
+-- am335x-boneblack-wireless.dtb
+-- am335x-boneblue.dtb
+-- am335x-bonegreen.dtb
+-- am335x-bonegreen-wireless.dtb
+-- am335x-bone.dtb
+-- am335x-evm.dtb
+-- am335x-evmsk.dtb
+-- boot.vfat
+-- MLO
+-- rootfs.ext2
+-- rootfs.tar
+-- sdcard.img
+-- u-boot.img
+-- uEnv.txt
+-- zImage
To copy the image file to the sdcard use dd:
$ dd if=output/images/sdcard.img of=/dev/XXX
Running Qt5 hellowindow opengl demo:
===================
# export QT_QPA_EGLFS_KMS_CONFIG=/etc/qt5/eglfs_kms_cfg.json
# export QT_QPA_PLATFORM=eglfs
# export QT_QPA_EGLFS_INTEGRATION=none
# /usr/lib/qt/examples/opengl/hellowindow/hellowindow
Tested hardware
===============
am335x-evm (rev. 1.1A)
beagleboneblack (rev. A5A)
beaglebone (rev. A6)
2020, Adam Duskett <aduskett@gmail.com>
2016, Lothar Felten <lothar.felten@gmail.com>

View File

@ -0,0 +1,15 @@
{
"device": "/dev/dri/card0",
"hwcursor": false,
"pbuffers": true,
"outputs": [
{
"name": "VGA1",
"mode": "off"
},
{
"name": "HDMI1",
"mode": "1024x768"
}
]
}

View File

@ -0,0 +1,11 @@
bootpart=0:1
devtype=mmc
bootdir=
bootfile=zImage
bootpartition=mmcblk0p2
console=ttyS0,115200n8
loadaddr=0x82000000
fdtaddr=0x88000000
set_mmc1=if test $board_name = A33515BB; then setenv bootpartition mmcblk1p2; fi
set_bootargs=setenv bootargs console=${console} root=/dev/${bootpartition} rw rootfstype=ext4 rootwait
uenvcmd=run set_mmc1; run set_bootargs;run loadimage;run loadfdt;printenv bootargs;bootz ${loadaddr} - ${fdtaddr}

View File

@ -0,0 +1,30 @@
image boot.vfat {
vfat {
files = {
"MLO",
"u-boot.img",
"zImage",
"am5729-beagleboneai.dtb",
"uEnv.txt"
}
}
size = 16M
}
image sdcard.img {
hdimage {
}
partition u-boot {
partition-type = 0xC
bootable = "true"
image = "boot.vfat"
}
partition rootfs {
partition-type = 0x83
image = "rootfs.ext4"
size = 512M
}
}

View File

@ -0,0 +1,839 @@
From 702ea30b462ba06f4fbee3393f0e6c19531f1e5f Mon Sep 17 00:00:00 2001
From: Robert Nelson <robertcnelson@gmail.com>
Date: Fri, 25 Jun 2021 11:33:25 -0500
Subject: [PATCH] am57xx_evm-fixes
Signed-off-by: Robert Nelson <robertcnelson@gmail.com>
[Patch from https://github.com/beagleboard/u-boot/commit/702ea30b462ba06f4fbee3393f0e6c19531f1e5f]
Signed-off-by: Peter Korsgaard <peter@korsgaard.com>
---
arch/arm/mach-omap2/omap5/hw_data.c | 1 +
board/ti/am57xx/board.c | 167 +++++++++++-
configs/am57xx_evm_defconfig | 15 +-
include/configs/ti_armv7_common.h | 407 ++++++++++++++++++++++++++++
include/configs/ti_omap5_common.h | 5 +
include/environment/ti/boot.h | 32 ++-
include/environment/ti/mmc.h | 49 +++-
7 files changed, 651 insertions(+), 25 deletions(-)
diff --git a/arch/arm/mach-omap2/omap5/hw_data.c b/arch/arm/mach-omap2/omap5/hw_data.c
index fa4e27063c..d5192b1671 100644
--- a/arch/arm/mach-omap2/omap5/hw_data.c
+++ b/arch/arm/mach-omap2/omap5/hw_data.c
@@ -421,6 +421,7 @@ void enable_basic_clocks(void)
(*prcm)->cm_l4per_uart1_clkctrl,
(*prcm)->cm_l4per_uart3_clkctrl,
(*prcm)->cm_l4per_i2c1_clkctrl,
+ (*prcm)->cm_l4per_i2c4_clkctrl,
#ifdef CONFIG_DRIVER_TI_CPSW
(*prcm)->cm_gmac_gmac_clkctrl,
#endif
diff --git a/board/ti/am57xx/board.c b/board/ti/am57xx/board.c
index 73063faee6..ad05c41f22 100644
--- a/board/ti/am57xx/board.c
+++ b/board/ti/am57xx/board.c
@@ -41,6 +41,7 @@
#include <mmc.h>
#include <dm/uclass.h>
#include <hang.h>
+#include <i2c.h>
#include "../common/board_detect.h"
#include "mux_data.h"
@@ -528,8 +529,10 @@ void do_board_detect(void)
rc = ti_i2c_eeprom_am_get(CONFIG_EEPROM_BUS_ADDRESS,
CONFIG_EEPROM_CHIP_ADDRESS);
- if (rc)
+ if (rc) {
printf("ti_i2c_eeprom_init failed %d\n", rc);
+ ti_i2c_eeprom_am_set("BBONE-AI", "A");
+ };
#ifdef CONFIG_SUPPORT_EMMC_BOOT
rc = board_bootmode_has_emmc();
@@ -579,6 +582,164 @@ void do_board_detect(void)
"Board: %s REV %s\n", bname, board_ti_get_rev());
}
+struct am335x_cape_eeprom_id {
+ unsigned int header;
+ char eeprom_rev[2];
+ char board_name[32];
+ char version[4];
+ char manufacture[16];
+ char part_number[16];
+ char number_of_pins[2];
+ char serial_number[12];
+ char pin_usage[140];
+ char vdd_3v3exp[ 2];
+ char vdd_5v[ 2];
+ char sys_5v[2];
+ char dc_supplied[2];
+};
+
+#define CAPE_EEPROM_BUS_NUM 3
+#define CAPE_EEPROM_ADDR0 0x54
+#define CAPE_EEPROM_ADDR1 0x55
+#define CAPE_EEPROM_ADDR2 0x56
+#define CAPE_EEPROM_ADDR3 0x57
+
+#define CAPE_EEPROM_ADDR_LEN 0x10
+
+static int probe_cape_eeprom(struct am335x_cape_eeprom_id *cape_header)
+{
+ int ret;
+ struct udevice *dev;
+ unsigned char addr;
+ /* /lib/firmware/BB-CAPE-DISP-CT4-00A0.dtbo */
+ /* 14 + 16 + 1 + 4 + 5 = 40 */
+ char hash_cape_overlay[40];
+ char cape_overlay[26];
+ char process_cape_part_number[16];
+ char process_cape_version[4];
+ char end_part_number;
+ char cape_overlay_pass_to_kernel[18];
+
+ strlcpy(cape_overlay_pass_to_kernel, "", 1);
+
+ for ( addr = CAPE_EEPROM_ADDR0; addr <= CAPE_EEPROM_ADDR3; addr++ ) {
+ ret = i2c_get_chip_for_busnum(CAPE_EEPROM_BUS_NUM, addr, 1, &dev);
+ if (ret) {
+ printf("BeagleBone Cape EEPROM: no EEPROM at address: 0x%x\n", addr);
+ } else {
+ printf("BeagleBone Cape EEPROM: found EEPROM at address: 0x%x\n", addr);
+
+ ret = i2c_set_chip_offset_len(dev, 2);
+ if (ret) {
+ printf("BeagleBone Cape EEPROM: i2c_set_chip_offset_len failure\n");
+ }
+
+ ret = dm_i2c_read(dev, 0, (uchar *)cape_header, sizeof(struct am335x_cape_eeprom_id));
+ if (ret) {
+ printf("BeagleBone Cape EEPROM: Cannot read eeprom params\n");
+ }
+
+ if (cape_header->header == 0xEE3355AA) {
+ strlcpy(hash_cape_overlay, "/lib/firmware/", 14 + 1);
+ strlcpy(cape_overlay, "", 2);
+ strlcpy(cape_overlay_pass_to_kernel, "", 2);
+ strlcpy(process_cape_part_number, "...............", 16 + 1);
+ strlcpy(process_cape_version, "...", 4 + 1);
+
+ strlcpy(process_cape_part_number, cape_header->part_number, 16 + 1);
+ printf("BeagleBone Cape EEPROM: debug part_number field:[%s]\n", process_cape_part_number);
+
+ //FIXME: some capes end with '.'
+ if ( process_cape_part_number[15] == 0x2E ) {
+ puts("debug: fixup, extra . in eeprom field\n");
+ process_cape_part_number[15] = 0x00;
+ if ( process_cape_part_number[14] == 0x2E ) {
+ process_cape_part_number[14] = 0x00;
+ }
+ }
+
+ //Find ending 0x00 or 0xFF
+ puts("BeagleBone Cape EEPROM: debug part_number field HEX:[");
+ end_part_number=16;
+ for ( int i=0; i <= 16; i++ ) {
+ if (( process_cape_part_number[i] == 0x00 ) || ( process_cape_part_number[i] == 0xFF )) {
+ end_part_number=i;
+ i=17;
+ } else {
+ printf("%x", process_cape_part_number[i]);
+ }
+ }
+ puts("]\n");
+
+ strncat(cape_overlay_pass_to_kernel, process_cape_part_number, end_part_number);
+ strncat(cape_overlay_pass_to_kernel, ",", 1);
+ //printf("debug: %s\n", cape_overlay_pass_to_kernel);
+
+ strncat(hash_cape_overlay, process_cape_part_number, end_part_number);
+ strncat(cape_overlay, process_cape_part_number, end_part_number);
+ //printf("debug: %s %s\n", hash_cape_overlay, cape_overlay);
+
+ strncat(hash_cape_overlay, "-", 1);
+ strncat(cape_overlay, "-", 1);
+ //printf("debug: %s %s\n", hash_cape_overlay, cape_overlay);
+
+ strlcpy(process_cape_version, cape_header->version, 4 + 1);
+ //printf("debug: version field:[%s]\n", process_cape_version);
+
+ //Find invalid 0xFF -> 0x30 BBAI FAN Cape...
+ puts("BeagleBone Cape EEPROM: debug version field HEX:[");
+ for ( int i=0; i <= 3; i++ ) {
+ printf("%x", process_cape_version[i]);
+ if ( process_cape_version[i] == 0xFF ) {
+ process_cape_version[i] = 0x30;
+ }
+ }
+ puts("]\n");
+
+ strncat(hash_cape_overlay, process_cape_version, 4);
+ strncat(cape_overlay, process_cape_version, 4);
+ //printf("debug: %s %s\n", hash_cape_overlay, cape_overlay);
+
+ strncat(hash_cape_overlay, ".dtbo", 5);
+ strncat(cape_overlay, ".dtbo", 5);
+ //printf("debug: %s %s\n", hash_cape_overlay, cape_overlay);
+
+ printf("BeagleBone Cape EEPROM: 0x%x %s\n", addr, cape_overlay);
+
+ switch(addr) {
+ case CAPE_EEPROM_ADDR0:
+ env_set("uboot_overlay_addr0", cape_overlay);
+ env_set("uboot_detected_capes_addr0", cape_overlay_pass_to_kernel);
+ break;
+ case CAPE_EEPROM_ADDR1:
+ env_set("uboot_overlay_addr1", cape_overlay);
+ env_set("uboot_detected_capes_addr1", cape_overlay_pass_to_kernel);
+ break;
+ case CAPE_EEPROM_ADDR2:
+ env_set("uboot_overlay_addr2", cape_overlay);
+ env_set("uboot_detected_capes_addr2", cape_overlay_pass_to_kernel);
+ break;
+ case CAPE_EEPROM_ADDR3:
+ env_set("uboot_overlay_addr3", cape_overlay);
+ env_set("uboot_detected_capes_addr3", cape_overlay_pass_to_kernel);
+ break;
+ }
+ env_set("uboot_detected_capes", "1");
+ } else {
+ printf("BeagleBone Cape EEPROM: EEPROM contents not valid (or blank) on address: 0x%x\n", addr);
+ }
+ }
+ }
+ return 0;
+}
+
+void do_cape_detect(void)
+{
+ struct am335x_cape_eeprom_id cape_header;
+
+ probe_cape_eeprom(&cape_header);
+}
+
static void setup_board_eeprom_env(void)
{
char *name = "beagle_x15";
@@ -782,8 +943,10 @@ int board_late_init(void)
/* Just probe the potentially supported cdce913 device */
uclass_get_device(UCLASS_CLK, 0, &dev);
- if (board_is_bbai())
+ if (board_is_bbai()) {
env_set("console", "ttyS0,115200n8");
+ do_cape_detect();
+ }
#if !defined(CONFIG_SPL_BUILD)
board_ti_set_ethaddr(2);
diff --git a/configs/am57xx_evm_defconfig b/configs/am57xx_evm_defconfig
index 4da4aaa1c7..ed5b8aec16 100644
--- a/configs/am57xx_evm_defconfig
+++ b/configs/am57xx_evm_defconfig
@@ -10,16 +10,20 @@ CONFIG_SPL_TEXT_BASE=0x40300000
CONFIG_OMAP54XX=y
CONFIG_TARGET_AM57XX_EVM=y
CONFIG_SPL=y
-CONFIG_ENV_OFFSET_REDUND=0x280000
CONFIG_SPL_SPI_FLASH_SUPPORT=y
CONFIG_SPL_SPI_SUPPORT=y
CONFIG_ARMV7_LPAE=y
-CONFIG_DEFAULT_DEVICE_TREE="am572x-idk"
+CONFIG_DEFAULT_DEVICE_TREE="am57xx-beagle-x15-revc"
CONFIG_AHCI=y
CONFIG_DISTRO_DEFAULTS=y
CONFIG_SPL_LOAD_FIT=y
# CONFIG_USE_SPL_FIT_GENERATOR is not set
CONFIG_OF_BOARD_SETUP=y
+CONFIG_BOOTDELAY=1
+CONFIG_AUTOBOOT_KEYED=y
+CONFIG_AUTOBOOT_PROMPT="Press SPACE to abort autoboot in %d seconds\n"
+CONFIG_AUTOBOOT_DELAY_STR="d"
+CONFIG_AUTOBOOT_STOP_STR=" "
CONFIG_USE_BOOTARGS=y
CONFIG_BOOTARGS="androidboot.serialno=${serial#} console=ttyS2,115200 androidboot.console=ttyS2 androidboot.hardware=beagle_x15board"
# CONFIG_USE_BOOTCOMMAND is not set
@@ -48,13 +52,12 @@ CONFIG_BOOTP_DNS2=y
CONFIG_CMD_AVB=y
CONFIG_OF_CONTROL=y
CONFIG_SPL_OF_CONTROL=y
-CONFIG_OF_LIST="am57xx-beagle-x15 am57xx-beagle-x15-revb1 am57xx-beagle-x15-revc am5729-beagleboneai am572x-idk am571x-idk am574x-idk"
+CONFIG_OF_LIST="am57xx-beagle-x15 am57xx-beagle-x15-revb1 am57xx-beagle-x15-revc am5729-beagleboneai"
CONFIG_ENV_OVERWRITE=y
-CONFIG_ENV_IS_IN_MMC=y
-CONFIG_SYS_REDUNDAND_ENVIRONMENT=y
+# CONFIG_ENV_IS_IN_FAT is not set
CONFIG_SYS_RELOC_GD_ENV_ADDR=y
-CONFIG_SYS_MMC_ENV_DEV=1
CONFIG_ENV_VARS_UBOOT_RUNTIME_CONFIG=y
+# CONFIG_SPL_ENV_IS_NOWHERE is not set
CONFIG_VERSION_VARIABLE=y
CONFIG_BOOTP_SEND_HOSTNAME=y
CONFIG_DM=y
diff --git a/include/configs/ti_armv7_common.h b/include/configs/ti_armv7_common.h
index f13e9e5264..eabd03e27d 100644
--- a/include/configs/ti_armv7_common.h
+++ b/include/configs/ti_armv7_common.h
@@ -92,6 +92,413 @@
#define CONFIG_SYS_I2C
#endif
+#define EEPROM_PROGRAMMING \
+ "eeprom_dump=i2c dev 0; " \
+ "i2c md 0x50 0x00.2 20; " \
+ "\0" \
+ "eeprom_blank=i2c dev 0; " \
+ "i2c mw 0x50 0x00.2 ff; " \
+ "i2c mw 0x50 0x01.2 ff; " \
+ "i2c mw 0x50 0x02.2 ff; " \
+ "i2c mw 0x50 0x03.2 ff; " \
+ "i2c mw 0x50 0x04.2 ff; " \
+ "i2c mw 0x50 0x05.2 ff; " \
+ "i2c mw 0x50 0x06.2 ff; " \
+ "i2c mw 0x50 0x07.2 ff; " \
+ "i2c mw 0x50 0x08.2 ff; " \
+ "i2c mw 0x50 0x09.2 ff; " \
+ "i2c mw 0x50 0x0a.2 ff; " \
+ "i2c mw 0x50 0x0b.2 ff; " \
+ "i2c mw 0x50 0x0c.2 ff; " \
+ "i2c mw 0x50 0x0d.2 ff; " \
+ "i2c mw 0x50 0x0e.2 ff; " \
+ "i2c mw 0x50 0x0f.2 ff; " \
+ "i2c mw 0x50 0x10.2 ff; " \
+ "i2c mw 0x50 0x11.2 ff; " \
+ "i2c mw 0x50 0x12.2 ff; " \
+ "i2c mw 0x50 0x13.2 ff; " \
+ "i2c mw 0x50 0x14.2 ff; " \
+ "i2c mw 0x50 0x15.2 ff; " \
+ "i2c mw 0x50 0x16.2 ff; " \
+ "i2c mw 0x50 0x17.2 ff; " \
+ "i2c mw 0x50 0x18.2 ff; " \
+ "i2c mw 0x50 0x19.2 ff; " \
+ "i2c mw 0x50 0x1a.2 ff; " \
+ "i2c mw 0x50 0x1b.2 ff; " \
+ "i2c mw 0x50 0x1c.2 ff; " \
+ "i2c mw 0x50 0x1d.2 ff; " \
+ "i2c mw 0x50 0x1e.2 ff; " \
+ "i2c mw 0x50 0x1f.2 ff; " \
+ "i2c md 0x50 0x00.2 20; " \
+ "\0" \
+ "eeprom_x15_b1=i2c dev 0; " \
+ "i2c mw 0x50 0x00.2 aa; " \
+ "i2c mw 0x50 0x01.2 55; " \
+ "i2c mw 0x50 0x02.2 33; " \
+ "i2c mw 0x50 0x03.2 ee; " \
+ "i2c mw 0x50 0x04.2 42; " \
+ "i2c mw 0x50 0x05.2 42; " \
+ "i2c mw 0x50 0x06.2 52; " \
+ "i2c mw 0x50 0x07.2 44; " \
+ "i2c mw 0x50 0x08.2 58; " \
+ "i2c mw 0x50 0x09.2 31; " \
+ "i2c mw 0x50 0x0a.2 35; " \
+ "i2c mw 0x50 0x0b.2 5f; " \
+ "i2c mw 0x50 0x0c.2 42; " \
+ "i2c mw 0x50 0x0d.2 2e; " \
+ "i2c mw 0x50 0x0e.2 31; " \
+ "i2c mw 0x50 0x0f.2 30; " \
+ "i2c mw 0x50 0x10.2 57; " \
+ "i2c mw 0x50 0x11.2 57; " \
+ "i2c mw 0x50 0x12.2 59; " \
+ "i2c mw 0x50 0x13.2 59; " \
+ "i2c mw 0x50 0x14.2 34; " \
+ "i2c mw 0x50 0x15.2 50; " \
+ "i2c mw 0x50 0x16.2 35; " \
+ "i2c mw 0x50 0x17.2 35; " \
+ "i2c mw 0x50 0x18.2 30; " \
+ "i2c mw 0x50 0x19.2 30; " \
+ "i2c mw 0x50 0x1a.2 30; " \
+ "i2c mw 0x50 0x1b.2 30; " \
+ "i2c mw 0x50 0x1c.2 ff; " \
+ "i2c mw 0x50 0x1d.2 ff; " \
+ "i2c mw 0x50 0x1e.2 ff; " \
+ "i2c mw 0x50 0x1f.2 ff; " \
+ "i2c md 0x50 0x00.2 20; " \
+ "\0" \
+ "eeprom_x15_c=i2c dev 0; " \
+ "i2c mw 0x50 0x00.2 aa; " \
+ "i2c mw 0x50 0x01.2 55; " \
+ "i2c mw 0x50 0x02.2 33; " \
+ "i2c mw 0x50 0x03.2 ee; " \
+ "i2c mw 0x50 0x04.2 42; " \
+ "i2c mw 0x50 0x05.2 42; " \
+ "i2c mw 0x50 0x06.2 52; " \
+ "i2c mw 0x50 0x07.2 44; " \
+ "i2c mw 0x50 0x08.2 58; " \
+ "i2c mw 0x50 0x09.2 31; " \
+ "i2c mw 0x50 0x0a.2 35; " \
+ "i2c mw 0x50 0x0b.2 5f; " \
+ "i2c mw 0x50 0x0c.2 43; " \
+ "i2c mw 0x50 0x0d.2 2e; " \
+ "i2c mw 0x50 0x0e.2 30; " \
+ "i2c mw 0x50 0x0f.2 30; " \
+ "i2c mw 0x50 0x10.2 79; " \
+ "i2c mw 0x50 0x11.2 79; " \
+ "i2c mw 0x50 0x12.2 77; " \
+ "i2c mw 0x50 0x13.2 77; " \
+ "i2c mw 0x50 0x14.2 50; " \
+ "i2c mw 0x50 0x15.2 58; " \
+ "i2c mw 0x50 0x16.2 31; " \
+ "i2c mw 0x50 0x17.2 35; " \
+ "i2c mw 0x50 0x18.2 6e; " \
+ "i2c mw 0x50 0x19.2 6e; " \
+ "i2c mw 0x50 0x1a.2 6e; " \
+ "i2c mw 0x50 0x1b.2 6e; " \
+ "i2c mw 0x50 0x1c.2 ff; " \
+ "i2c mw 0x50 0x1d.2 ff; " \
+ "i2c mw 0x50 0x1e.2 ff; " \
+ "i2c mw 0x50 0x1f.2 ff; " \
+ "i2c md 0x50 0x00.2 20; " \
+ "eeprom_bbai_a2=i2c dev 0; " \
+ "i2c mw 0x50 0x00.2 aa; " \
+ "i2c mw 0x50 0x01.2 55; " \
+ "i2c mw 0x50 0x02.2 33; " \
+ "i2c mw 0x50 0x03.2 ee; " \
+ "i2c mw 0x50 0x04.2 42; " \
+ "i2c mw 0x50 0x05.2 42; " \
+ "i2c mw 0x50 0x06.2 4F; " \
+ "i2c mw 0x50 0x07.2 4E; " \
+ "i2c mw 0x50 0x08.2 45; " \
+ "i2c mw 0x50 0x09.2 2D; " \
+ "i2c mw 0x50 0x0a.2 41; " \
+ "i2c mw 0x50 0x0b.2 49; " \
+ "i2c mw 0x50 0x0c.2 30; " \
+ "i2c mw 0x50 0x0d.2 30; " \
+ "i2c mw 0x50 0x0e.2 41; " \
+ "i2c mw 0x50 0x0f.2 32; " \
+ "i2c mw 0x50 0x10.2 57; " \
+ "i2c mw 0x50 0x11.2 57; " \
+ "i2c mw 0x50 0x12.2 59; " \
+ "i2c mw 0x50 0x13.2 59; " \
+ "i2c mw 0x50 0x14.2 53; " \
+ "i2c mw 0x50 0x15.2 42; " \
+ "i2c mw 0x50 0x16.2 41; " \
+ "i2c mw 0x50 0x17.2 49; " \
+ "i2c mw 0x50 0x18.2 30; " \
+ "i2c mw 0x50 0x19.2 30; " \
+ "i2c mw 0x50 0x1a.2 30; " \
+ "i2c mw 0x50 0x1b.2 30; " \
+ "i2c mw 0x50 0x1c.2 30; " \
+ "i2c mw 0x50 0x1d.2 30; " \
+ "i2c mw 0x50 0x1e.2 ff; " \
+ "i2c mw 0x50 0x1f.2 ff; " \
+ "i2c md 0x50 0x00.2 20; " \
+ "\0" \
+
+#define EEWIKI_MMC_BOOT \
+ "mmc_boot=${devtype} dev ${mmcdev}; ${devtype} part; " \
+ "if ${devtype} rescan; then " \
+ "echo Scanning ${devtype} device ${mmcdev};" \
+ "setenv bootpart ${mmcdev}:1; " \
+ "echo Checking for: /uEnv.txt ...;" \
+ "if test -e ${devtype} ${bootpart} /uEnv.txt; then " \
+ "load ${devtype} ${bootpart} ${loadaddr} /uEnv.txt;" \
+ "env import -t ${loadaddr} ${filesize};" \
+ "echo Loaded environment from /uEnv.txt;" \
+ "echo Checking if uenvcmd is set ...;" \
+ "if test -n ${uenvcmd}; then " \
+ "echo Running uenvcmd ...;" \
+ "run uenvcmd;" \
+ "fi;" \
+ "fi; " \
+ "echo Checking for: /boot/uEnv.txt ...;" \
+ "for i in 1 2 3 4 5 6 7 ; do " \
+ "setenv mmcpart ${i};" \
+ "setenv bootpart ${mmcdev}:${mmcpart};" \
+ "if test -e ${devtype} ${bootpart} /boot/uEnv.txt; then " \
+ "load ${devtype} ${bootpart} ${loadaddr} /boot/uEnv.txt;" \
+ "env import -t ${loadaddr} ${filesize};" \
+ "echo Loaded environment from /boot/uEnv.txt;" \
+ "if test -n ${dtb}; then " \
+ "setenv fdtfile ${dtb};" \
+ "echo debug: [dtb=${fdtfile}] ...;" \
+ "fi;" \
+ "echo Checking if uname_r is set in /boot/uEnv.txt ...;" \
+ "if test -n ${uname_r}; then " \
+ "echo debug: [uname_r=${uname_r}] ...;" \
+ "setenv oldroot /dev/mmcblk${mmcdev}p${mmcpart};" \
+ "run uname_boot;" \
+ "fi;" \
+ "fi;" \
+ "done;" \
+ "fi;\0" \
+
+#define EEWIKI_SCSI_BOOT \
+ "scsi_boot=${devtype} reset ; " \
+ "if ${devtype} dev ${mmcdev}; then " \
+ "echo Scanning ${devtype} device ${mmcdev};" \
+ "setenv bootpart ${mmcdev}:1; " \
+ "echo Checking for: /uEnv.txt ...;" \
+ "if test -e ${devtype} ${bootpart} /uEnv.txt; then " \
+ "load ${devtype} ${bootpart} ${loadaddr} /uEnv.txt;" \
+ "env import -t ${loadaddr} ${filesize};" \
+ "echo Loaded environment from /uEnv.txt;" \
+ "echo Checking if uenvcmd is set ...;" \
+ "if test -n ${uenvcmd}; then " \
+ "echo Running uenvcmd ...;" \
+ "run uenvcmd;" \
+ "fi;" \
+ "fi; " \
+ "echo Checking for: /boot/uEnv.txt ...;" \
+ "for i in 1 2 3 4 ; do " \
+ "setenv mmcpart ${i};" \
+ "setenv bootpart ${mmcdev}:${mmcpart};" \
+ "if test -e ${devtype} ${bootpart} /boot/uEnv.txt; then " \
+ "load ${devtype} ${bootpart} ${loadaddr} /boot/uEnv.txt;" \
+ "env import -t ${loadaddr} ${filesize};" \
+ "echo Loaded environment from /boot/uEnv.txt;" \
+ "if test -n ${dtb}; then " \
+ "setenv fdtfile ${dtb};" \
+ "echo debug: [dtb=${fdtfile}] ...;" \
+ "fi;" \
+ "echo Checking if uname_r is set in /boot/uEnv.txt ...;" \
+ "if test -n ${uname_r}; then " \
+ "echo debug: [uname_r=${uname_r}] ...;" \
+ "setenv oldroot /dev/sda${mmcpart};" \
+ "run uname_boot;" \
+ "fi;" \
+ "fi;" \
+ "done;" \
+ "fi;\0" \
+
+#define EEWIKI_USB_BOOT \
+ "usb_boot=${devtype} reset ; " \
+ "if ${devtype} dev ${mmcdev}; then " \
+ "echo Scanning ${devtype} device ${mmcdev};" \
+ "setenv bootpart ${mmcdev}:1; " \
+ "echo Checking for: /uEnv.txt ...;" \
+ "if test -e ${devtype} ${bootpart} /uEnv.txt; then " \
+ "load ${devtype} ${bootpart} ${loadaddr} /uEnv.txt;" \
+ "env import -t ${loadaddr} ${filesize};" \
+ "echo Loaded environment from /uEnv.txt;" \
+ "echo Checking if uenvcmd is set in /uEnv.txt ...;" \
+ "if test -n ${uenvcmd}; then " \
+ "echo Running uenvcmd ...;" \
+ "run uenvcmd;" \
+ "fi;" \
+ "fi; " \
+ "echo Checking for: /boot/uEnv.txt ...;" \
+ "for i in 1 2 3 4 ; do " \
+ "setenv mmcpart ${i};" \
+ "setenv bootpart ${mmcdev}:${mmcpart};" \
+ "if test -e ${devtype} ${bootpart} /boot/uEnv.txt; then " \
+ "load ${devtype} ${bootpart} ${loadaddr} /boot/uEnv.txt;" \
+ "env import -t ${loadaddr} ${filesize};" \
+ "echo Loaded environment from /boot/uEnv.txt;" \
+ "if test -n ${dtb}; then " \
+ "setenv fdtfile ${dtb};" \
+ "echo debug: [dtb=${fdtfile}] ...;" \
+ "fi;" \
+ "echo Checking if uname_r is set in /boot/uEnv.txt ...;" \
+ "if test -n ${uname_r}; then " \
+ "echo debug: [uname_r=${uname_r}] ...;" \
+ "setenv oldroot /dev/sda${mmcpart};" \
+ "run uname_boot;" \
+ "fi;" \
+ "fi;" \
+ "done;" \
+ "fi;\0" \
+
+#define EEWIKI_UNAME_BOOT \
+ "uname_boot="\
+ "setenv bootdir /boot; " \
+ "setenv bootfile vmlinuz-${uname_r}; " \
+ "if test -e ${devtype} ${bootpart} ${bootdir}/${bootfile}; then " \
+ "echo loading ${bootdir}/${bootfile} ...; "\
+ "run loadimage;" \
+ "setenv fdtdir /boot/dtbs/${uname_r}; " \
+ "if test -e ${devtype} ${bootpart} ${fdtdir}/${fdtfile}; then " \
+ "run loadfdt;" \
+ "else " \
+ "setenv fdtdir /usr/lib/linux-image-${uname_r}; " \
+ "if test -e ${devtype} ${bootpart} ${fdtdir}/${fdtfile}; then " \
+ "run loadfdt;" \
+ "else " \
+ "setenv fdtdir /lib/firmware/${uname_r}/device-tree; " \
+ "if test -e ${devtype} ${bootpart} ${fdtdir}/${fdtfile}; then " \
+ "run loadfdt;" \
+ "else " \
+ "setenv fdtdir /boot/dtb-${uname_r}; " \
+ "if test -e ${devtype} ${bootpart} ${fdtdir}/${fdtfile}; then " \
+ "run loadfdt;" \
+ "else " \
+ "setenv fdtdir /boot/dtbs; " \
+ "if test -e ${devtype} ${bootpart} ${fdtdir}/${fdtfile}; then " \
+ "run loadfdt;" \
+ "else " \
+ "setenv fdtdir /boot/dtb; " \
+ "if test -e ${devtype} ${bootpart} ${fdtdir}/${fdtfile}; then " \
+ "run loadfdt;" \
+ "else " \
+ "setenv fdtdir /boot; " \
+ "if test -e ${devtype} ${bootpart} ${fdtdir}/${fdtfile}; then " \
+ "run loadfdt;" \
+ "else " \
+ "echo; echo unable to find ${fdtfile} ...; echo booting legacy ...;"\
+ "run args_mmc;" \
+ "echo debug: [${bootargs}] ... ;" \
+ "echo debug: [bootz ${loadaddr}] ... ;" \
+ "bootz ${loadaddr}; " \
+ "fi;" \
+ "fi;" \
+ "fi;" \
+ "fi;" \
+ "fi;" \
+ "fi;" \
+ "fi; " \
+ "if test -n ${enable_uboot_overlays}; then " \
+ "setenv fdt_buffer 0x60000;" \
+ "if test -n ${uboot_fdt_buffer}; then " \
+ "setenv fdt_buffer ${uboot_fdt_buffer};" \
+ "fi;" \
+ "echo uboot_overlays: [fdt_buffer=${fdt_buffer}] ... ;" \
+ "if test -n ${uboot_overlay_addr0}; then " \
+ "if test -n ${disable_uboot_overlay_addr0}; then " \
+ "echo uboot_overlays: uboot loading of [${uboot_overlay_addr0}] disabled by /boot/uEnv.txt [disable_uboot_overlay_addr0=1]...;" \
+ "else " \
+ "setenv uboot_overlay ${uboot_overlay_addr0}; " \
+ "run virtualloadoverlay;" \
+ "fi;" \
+ "fi;" \
+ "if test -n ${uboot_overlay_addr1}; then " \
+ "if test -n ${disable_uboot_overlay_addr1}; then " \
+ "echo uboot_overlays: uboot loading of [${uboot_overlay_addr1}] disabled by /boot/uEnv.txt [disable_uboot_overlay_addr1=1]...;" \
+ "else " \
+ "setenv uboot_overlay ${uboot_overlay_addr1}; " \
+ "run virtualloadoverlay;" \
+ "fi;" \
+ "fi;" \
+ "if test -n ${uboot_overlay_addr2}; then " \
+ "if test -n ${disable_uboot_overlay_addr2}; then " \
+ "echo uboot_overlays: uboot loading of [${uboot_overlay_addr2}] disabled by /boot/uEnv.txt [disable_uboot_overlay_addr2=1]...;" \
+ "else " \
+ "setenv uboot_overlay ${uboot_overlay_addr2}; " \
+ "run virtualloadoverlay;" \
+ "fi;" \
+ "fi;" \
+ "if test -n ${uboot_overlay_addr3}; then " \
+ "if test -n ${disable_uboot_overlay_addr3}; then " \
+ "echo uboot_overlays: uboot loading of [${uboot_overlay_addr3}] disabled by /boot/uEnv.txt [disable_uboot_overlay_addr3=1]...;" \
+ "else " \
+ "setenv uboot_overlay ${uboot_overlay_addr3}; " \
+ "run virtualloadoverlay;" \
+ "fi;" \
+ "fi;" \
+ "if test -n ${uboot_overlay_addr4}; then " \
+ "setenv uboot_overlay ${uboot_overlay_addr4}; " \
+ "run virtualloadoverlay;" \
+ "fi;" \
+ "if test -n ${uboot_overlay_addr5}; then " \
+ "setenv uboot_overlay ${uboot_overlay_addr5}; " \
+ "run virtualloadoverlay;" \
+ "fi;" \
+ "if test -n ${uboot_overlay_addr6}; then " \
+ "setenv uboot_overlay ${uboot_overlay_addr6}; " \
+ "run virtualloadoverlay;" \
+ "fi;" \
+ "if test -n ${uboot_overlay_addr7}; then " \
+ "setenv uboot_overlay ${uboot_overlay_addr7}; " \
+ "run virtualloadoverlay;" \
+ "fi;" \
+ "if test -n ${uboot_overlay_pru}; then " \
+ "setenv uboot_overlay ${uboot_overlay_pru}; " \
+ "run virtualloadoverlay;" \
+ "fi;" \
+ "else " \
+ "echo uboot_overlays: add [enable_uboot_overlays=1] to /boot/uEnv.txt to enable...;" \
+ "fi;" \
+ "setenv rdfile initrd.img-${uname_r}; " \
+ "if test -e ${devtype} ${bootpart} ${bootdir}/${rdfile}; then " \
+ "echo loading ${bootdir}/${rdfile} ...; "\
+ "run loadrd;" \
+ "if test -n ${netinstall_enable}; then " \
+ "run args_netinstall; run message;" \
+ "echo debug: [${bootargs}] ... ;" \
+ "echo debug: [bootz ${loadaddr} ${rdaddr}:${rdsize} ${fdtaddr}] ... ;" \
+ "bootz ${loadaddr} ${rdaddr}:${rdsize} ${fdtaddr}; " \
+ "fi;" \
+ "if test -n ${uenv_root}; then " \
+ "run args_uenv_root;" \
+ "echo debug: [${bootargs}] ... ;" \
+ "echo debug: [bootz ${loadaddr} ${rdaddr}:${rdsize} ${fdtaddr}] ... ;" \
+ "bootz ${loadaddr} ${rdaddr}:${rdsize} ${fdtaddr}; " \
+ "fi;" \
+ "if test -n ${uuid}; then " \
+ "run args_mmc_uuid;" \
+ "echo debug: [${bootargs}] ... ;" \
+ "echo debug: [bootz ${loadaddr} ${rdaddr}:${rdsize} ${fdtaddr}] ... ;" \
+ "bootz ${loadaddr} ${rdaddr}:${rdsize} ${fdtaddr}; " \
+ "else " \
+ "run args_mmc_old;" \
+ "echo debug: [${bootargs}] ... ;" \
+ "echo debug: [bootz ${loadaddr} ${rdaddr}:${rdsize} ${fdtaddr}] ... ;" \
+ "bootz ${loadaddr} ${rdaddr}:${rdsize} ${fdtaddr}; " \
+ "fi;" \
+ "else " \
+ "if test -n ${uenv_root}; then " \
+ "run args_uenv_root;" \
+ "echo debug: [${bootargs}] ... ;" \
+ "echo debug: [bootz ${loadaddr} - ${fdtaddr}] ... ;" \
+ "bootz ${loadaddr} - ${fdtaddr}; " \
+ "fi;" \
+ "run args_mmc_old;" \
+ "echo debug: [${bootargs}] ... ;" \
+ "echo debug: [bootz ${loadaddr} - ${fdtaddr}] ... ;" \
+ "bootz ${loadaddr} - ${fdtaddr}; " \
+ "fi;" \
+ "fi;\0" \
+
/*
* The following are general good-enough settings for U-Boot. We set a
* large malloc pool as we generally have a lot of DDR, and we opt for
diff --git a/include/configs/ti_omap5_common.h b/include/configs/ti_omap5_common.h
index de0a6af2fd..0cd2ccea03 100644
--- a/include/configs/ti_omap5_common.h
+++ b/include/configs/ti_omap5_common.h
@@ -64,6 +64,11 @@
DEFAULT_FIT_TI_ARGS \
DEFAULT_COMMON_BOOT_TI_ARGS \
DEFAULT_FDT_TI_ARGS \
+ EEWIKI_USB_BOOT \
+ EEWIKI_SCSI_BOOT \
+ EEWIKI_MMC_BOOT \
+ EEWIKI_UNAME_BOOT \
+ EEPROM_PROGRAMMING \
DFUARGS \
NETARGS \
NANDARGS \
diff --git a/include/environment/ti/boot.h b/include/environment/ti/boot.h
index a9d8f28d46..1480b6e3df 100644
--- a/include/environment/ti/boot.h
+++ b/include/environment/ti/boot.h
@@ -132,6 +132,7 @@
"bootpart=0:2\0" \
"bootdir=/boot\0" \
"bootfile=zImage\0" \
+ "board_eeprom_header=undefined\0" \
"usbtty=cdc_acm\0" \
"vram=16M\0" \
AVB_VERIFY_CMD \
@@ -183,7 +184,14 @@
"else " \
"echo $apart partition not found; " \
"exit; " \
- "fi;\0"
+ "fi;\0 " \
+ "read_board_eeprom=" \
+ "if test $board_eeprom_header = beagle_x15_revb1_blank; then " \
+ "run eeprom_dump; run eeprom_x15_b1; reset; fi; " \
+ "if test $board_eeprom_header = beagle_x15_revc_blank; then " \
+ "run eeprom_dump; run eeprom_x15_c; reset; fi; " \
+ "if test $board_eeprom_header = bbai_a2_blank; then " \
+ "run eeprom_dump; run eeprom_bbai_a2; reset; fi; \0 "
#ifdef CONFIG_OMAP54XX
@@ -223,19 +231,17 @@
"echo WARNING: Could not determine device tree to use; fi; \0"
#define CONFIG_BOOTCOMMAND \
- "if test ${dofastboot} -eq 1; then " \
- "echo Boot fastboot requested, resetting dofastboot ...;" \
- "setenv dofastboot 0; saveenv;" \
- FASTBOOT_CMD \
- "fi;" \
- "if test ${boot_fit} -eq 1; then " \
- "run update_to_fit;" \
- "fi;" \
+ "run read_board_eeprom; " \
"run findfdt; " \
- "run envboot; " \
- "run mmcboot;" \
- "run emmc_linux_boot; " \
- "run emmc_android_boot; " \
+ "setenv mmcdev 0; " \
+ "setenv devtype usb; " \
+ "echo usb_boot is currently disabled;" \
+ "setenv devtype scsi; " \
+ "echo scsi_boot is currently disabled;" \
+ "setenv devtype mmc; " \
+ "run mmc_boot;" \
+ "setenv mmcdev 1; " \
+ "run mmc_boot;" \
""
#endif /* CONFIG_OMAP54XX */
diff --git a/include/environment/ti/mmc.h b/include/environment/ti/mmc.h
index b86c8dc7a4..0ec09f279a 100644
--- a/include/environment/ti/mmc.h
+++ b/include/environment/ti/mmc.h
@@ -11,11 +11,31 @@
#define DEFAULT_MMC_TI_ARGS \
"mmcdev=0\0" \
"mmcrootfstype=ext4 rootwait\0" \
- "finduuid=part uuid mmc ${bootpart} uuid\0" \
+ "finduuid=part uuid ${devtype} ${bootpart} uuid\0" \
"args_mmc=run finduuid;setenv bootargs console=${console} " \
"${optargs} " \
- "root=PARTUUID=${uuid} rw " \
- "rootfstype=${mmcrootfstype}\0" \
+ "root=PARTUUID=${uuid} ro " \
+ "rootfstype=${mmcrootfstype} " \
+ "${cmdline}\0" \
+ "args_mmc_old=setenv bootargs console=${console} " \
+ "${optargs} " \
+ "root=${oldroot} ro " \
+ "rootfstype=${mmcrootfstype} " \
+ "${cmdline}\0" \
+ "args_mmc_uuid=setenv bootargs console=${console} " \
+ "${optargs} " \
+ "root=UUID=${uuid} ro " \
+ "rootfstype=${mmcrootfstype} " \
+ "${cmdline}\0" \
+ "args_uenv_root=setenv bootargs console=${console} " \
+ "${optargs} " \
+ "root=${uenv_root} ro " \
+ "rootfstype=${mmcrootfstype} " \
+ "${musb} ${cmdline}\0" \
+ "args_netinstall=setenv bootargs ${netinstall_bootargs} " \
+ "${optargs} " \
+ "root=/dev/ram rw " \
+ "${cmdline}\0" \
"loadbootscript=load mmc ${mmcdev} ${loadaddr} boot.scr\0" \
"bootscript=echo Running bootscript from mmc${mmcdev} ...; " \
"source ${loadaddr}\0" \
@@ -24,7 +44,28 @@
"env import -t ${loadaddr} ${filesize}\0" \
"loadbootenv=fatload mmc ${mmcdev} ${loadaddr} ${bootenvfile}\0" \
"loadimage=load ${devtype} ${bootpart} ${loadaddr} ${bootdir}/${bootfile}\0" \
- "loadfdt=load ${devtype} ${bootpart} ${fdtaddr} ${bootdir}/${fdtfile}\0" \
+ "loadrd=load ${devtype} ${bootpart} ${rdaddr} ${bootdir}/${rdfile}; setenv rdsize ${filesize}\0" \
+ "loadfdt=echo loading ${fdtdir}/${fdtfile} ...; load ${devtype} ${bootpart} ${fdtaddr} ${fdtdir}/${fdtfile}\0" \
+ "loadoverlay=echo uboot_overlays: loading ${actual_uboot_overlay} ...; " \
+ "load ${devtype} ${bootpart} ${rdaddr} ${actual_uboot_overlay}; " \
+ "fdt addr ${fdtaddr}; fdt resize ${fdt_buffer}; " \
+ "fdt apply ${rdaddr}; fdt resize ${fdt_buffer};\0" \
+ "virtualloadoverlay=if test -e ${devtype} ${bootpart} ${fdtdir}/overlays/${uboot_overlay}; then " \
+ "setenv actual_uboot_overlay ${fdtdir}/overlays/${uboot_overlay}; " \
+ "run loadoverlay;" \
+ "else " \
+ "if test -e ${devtype} ${bootpart} /lib/firmware/${uboot_overlay}; then " \
+ "setenv actual_uboot_overlay /lib/firmware/${uboot_overlay}; " \
+ "run loadoverlay;" \
+ "else " \
+ "if test -e ${devtype} ${bootpart} ${uboot_overlay}; then " \
+ "setenv actual_uboot_overlay ${uboot_overlay}; " \
+ "run loadoverlay;" \
+ "else " \
+ "echo uboot_overlays: unable to find [${devtype} ${bootpart} ${uboot_overlay}]...;" \
+ "fi;" \
+ "fi;" \
+ "fi;\0" \
"envboot=mmc dev ${mmcdev}; " \
"if mmc rescan; then " \
"echo SD/MMC found on device ${mmcdev};" \
--
2.20.1

View File

@ -0,0 +1,4 @@
#!/bin/sh
BOARD_DIR="$(dirname $0)"
cp board/beagleboneai/uEnv.txt $BINARIES_DIR/uEnv.txt

View File

@ -0,0 +1,28 @@
Intro
=====
This configuration will build a basic image for the BeagleBoard.org
BeagleBone AI. For more details about the board, visit:
https://beagleboard.org/ai
How to build it
===============
Configure Buildroot:
$ make beagleboneai_defconfig
Compile everything and build the USB flash drive image:
$ make
How to write the SD card
========================
Once the build process is finished you will have an image called "sdcard.img"
in the output/images/ directory.
Copy the bootable "sdcard.img" onto an SD card with "dd":
$ sudo dd if=output/images/sdcard.img of=/dev/sdX

View File

@ -0,0 +1,6 @@
bootpart=0:1
bootdir=/
bootargs=console=ttyS0,115200n8 root=/dev/mmcblk0p2 ro rootwait
devtype=mmc
fdtfile=am5729-beagleboneai.dtb
uenvcmd=run loadimage; run loadfdt; printenv bootargs; bootz ${loadaddr} - ${fdtaddr}

View File

@ -0,0 +1,4 @@
label linux
kernel /boot/Image
devicetree /boot/jh7100-beaglev-starlight.dtb
append console=ttyS0,115200 earlyprintk root=PARTUUID=0fef845a-c6e1-45bc-82f7-002fa720f958 rootwait

View File

@ -0,0 +1,12 @@
image sdcard.img {
hdimage {
partition-table-type = "gpt"
}
partition rootfs {
partition-type-uuid = 72ec70a6-cf74-40e6-bd49-4bda08e8f224
partition-uuid = 0fef845a-c6e1-45bc-82f7-002fa720f958
bootable = "true"
image = "rootfs.ext4"
}
}

Some files were not shown because too many files have changed in this diff Show More