* [Buildroot] [PATCH 0/5] A20-OLinuXino-Lime: new board
@ 2015-06-15 18:45 Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 1/5] sunxi-board: bump to version a6a4e94066f4ec6b26fc7060dc453a6bcf26a504 Francois Perrad
` (4 more replies)
0 siblings, 5 replies; 8+ messages in thread
From: Francois Perrad @ 2015-06-15 18:45 UTC (permalink / raw)
To: buildroot
This set adds the board A20-OLinuXino-Lime, with 2 flavors:
- kernel mainline + uboot mainline
- linux-sunxi (3.4.x) + uboot-sunxi
And also updates two sunxi related packages (sunxi-board & a10disp).
Francois Perrad (5):
sunxi-board: bump to version a6a4e94066f4ec6b26fc7060dc453a6bcf26a504
a10disp: bump to version v0.6.1
A20-OLinuXino-Lime: new board (mainline)
cubieboard: rename script to mksunxicard.sh
A20-OLinuXino-Lime: new board (legacy)
board/cubietech/cubieboard/mkcubiecard.sh | 124 ----------------------
board/cubietech/cubieboard/mksunxicard.sh | 124 ++++++++++++++++++++++
board/cubietech/cubieboard/readme.txt | 4 +-
board/olimex/a20_olinuxino_lime/boot-legacy.cmd | 4 +
board/olimex/a20_olinuxino_lime/boot.cmd | 5 +
board/olimex/a20_olinuxino_lime/mksunxicard.sh | 1 +
board/olimex/a20_olinuxino_lime/post-build.sh | 16 +++
board/olimex/a20_olinuxino_lime/readme-legacy.txt | 60 +++++++++++
board/olimex/a20_olinuxino_lime/readme.txt | 89 ++++++++++++++++
configs/olimex_a20_olinuxino_defconfig | 35 ++++++
configs/olimex_a20_olinuxino_legacy_defconfig | 43 ++++++++
package/a10disp/a10disp.mk | 2 +-
package/sunxi-boards/sunxi-boards.mk | 2 +-
13 files changed, 381 insertions(+), 128 deletions(-)
delete mode 100755 board/cubietech/cubieboard/mkcubiecard.sh
create mode 100755 board/cubietech/cubieboard/mksunxicard.sh
create mode 100644 board/olimex/a20_olinuxino_lime/boot-legacy.cmd
create mode 100644 board/olimex/a20_olinuxino_lime/boot.cmd
create mode 120000 board/olimex/a20_olinuxino_lime/mksunxicard.sh
create mode 100755 board/olimex/a20_olinuxino_lime/post-build.sh
create mode 100644 board/olimex/a20_olinuxino_lime/readme-legacy.txt
create mode 100644 board/olimex/a20_olinuxino_lime/readme.txt
create mode 100644 configs/olimex_a20_olinuxino_defconfig
create mode 100644 configs/olimex_a20_olinuxino_legacy_defconfig
--
2.1.4
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 1/5] sunxi-board: bump to version a6a4e94066f4ec6b26fc7060dc453a6bcf26a504
2015-06-15 18:45 [Buildroot] [PATCH 0/5] A20-OLinuXino-Lime: new board Francois Perrad
@ 2015-06-15 18:46 ` Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 2/5] a10disp: bump to version v0.6.1 Francois Perrad
` (3 subsequent siblings)
4 siblings, 0 replies; 8+ messages in thread
From: Francois Perrad @ 2015-06-15 18:46 UTC (permalink / raw)
To: buildroot
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
package/sunxi-boards/sunxi-boards.mk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/package/sunxi-boards/sunxi-boards.mk b/package/sunxi-boards/sunxi-boards.mk
index cacf824..83b3842 100644
--- a/package/sunxi-boards/sunxi-boards.mk
+++ b/package/sunxi-boards/sunxi-boards.mk
@@ -4,7 +4,7 @@
#
################################################################################
-SUNXI_BOARDS_VERSION = 68acb3b1610a44b9402560623f7e35b7882585e9
+SUNXI_BOARDS_VERSION = a6a4e94066f4ec6b26fc7060dc453a6bcf26a504
SUNXI_BOARDS_SITE = $(call github,linux-sunxi,sunxi-boards,$(SUNXI_BOARDS_VERSION))
SUNXI_BOARDS_DEPENDENCIES = host-sunxi-tools
SUNXI_BOARDS_INSTALL_IMAGES = YES
--
2.1.4
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 2/5] a10disp: bump to version v0.6.1
2015-06-15 18:45 [Buildroot] [PATCH 0/5] A20-OLinuXino-Lime: new board Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 1/5] sunxi-board: bump to version a6a4e94066f4ec6b26fc7060dc453a6bcf26a504 Francois Perrad
@ 2015-06-15 18:46 ` Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 3/5] A20-OLinuXino-Lime: new board (mainline) Francois Perrad
` (2 subsequent siblings)
4 siblings, 0 replies; 8+ messages in thread
From: Francois Perrad @ 2015-06-15 18:46 UTC (permalink / raw)
To: buildroot
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
package/a10disp/a10disp.mk | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/package/a10disp/a10disp.mk b/package/a10disp/a10disp.mk
index 066e988..7353ede 100644
--- a/package/a10disp/a10disp.mk
+++ b/package/a10disp/a10disp.mk
@@ -4,7 +4,7 @@
#
################################################################################
-A10DISP_VERSION = a899cc6dcf909360aac00482ede5369f3656f226
+A10DISP_VERSION = v0.6.1
A10DISP_SITE = $(call github,hglm,a10disp,$(A10DISP_VERSION))
A10DISP_LICENSE = MIT
--
2.1.4
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 3/5] A20-OLinuXino-Lime: new board (mainline)
2015-06-15 18:45 [Buildroot] [PATCH 0/5] A20-OLinuXino-Lime: new board Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 1/5] sunxi-board: bump to version a6a4e94066f4ec6b26fc7060dc453a6bcf26a504 Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 2/5] a10disp: bump to version v0.6.1 Francois Perrad
@ 2015-06-15 18:46 ` Francois Perrad
2015-06-17 22:30 ` Arnout Vandecappelle
2015-06-15 18:46 ` [Buildroot] [PATCH 4/5] cubieboard: rename script to mksunxicard.sh Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 5/5] A20-OLinuXino-Lime: new board (legacy) Francois Perrad
4 siblings, 1 reply; 8+ messages in thread
From: Francois Perrad @ 2015-06-15 18:46 UTC (permalink / raw)
To: buildroot
config device tree / mainline (4.0.5)
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
board/olimex/a20_olinuxino_lime/boot.cmd | 5 ++
board/olimex/a20_olinuxino_lime/post-build.sh | 12 ++++
board/olimex/a20_olinuxino_lime/readme.txt | 89 +++++++++++++++++++++++++++
configs/olimex_a20_olinuxino_defconfig | 35 +++++++++++
4 files changed, 141 insertions(+)
create mode 100644 board/olimex/a20_olinuxino_lime/boot.cmd
create mode 100755 board/olimex/a20_olinuxino_lime/post-build.sh
create mode 100644 board/olimex/a20_olinuxino_lime/readme.txt
create mode 100644 configs/olimex_a20_olinuxino_defconfig
diff --git a/board/olimex/a20_olinuxino_lime/boot.cmd b/board/olimex/a20_olinuxino_lime/boot.cmd
new file mode 100644
index 0000000..f3554ed
--- /dev/null
+++ b/board/olimex/a20_olinuxino_lime/boot.cmd
@@ -0,0 +1,5 @@
+setenv bootargs console=ttyS0,115200 root=/dev/mmcblk0p1 rootwait panic=10 ${extra}
+ext2load mmc 0 0x49000000 boot/dtb/sun7i-a20-olinuxino-lime.dtb
+ext2load mmc 0 0x46000000 boot/zImage
+env set fdt_high ffffffff
+bootz 0x46000000 - 0x49000000
diff --git a/board/olimex/a20_olinuxino_lime/post-build.sh b/board/olimex/a20_olinuxino_lime/post-build.sh
new file mode 100755
index 0000000..d8d8fa4
--- /dev/null
+++ b/board/olimex/a20_olinuxino_lime/post-build.sh
@@ -0,0 +1,12 @@
+#!/bin/sh
+
+BOARD_DIR="$(dirname $0)"
+BOOT_DIR=$TARGET_DIR/boot
+MKIMAGE=$HOST_DIR/usr/bin/mkimage
+
+rm -rf $BOOT_DIR
+mkdir $BOOT_DIR
+mkdir $BOOT_DIR/dtb
+cp $BINARIES_DIR/sun7i-a20-olinuxino-lime.dtb $BOOT_DIR/dtb/sun7i-a20-olinuxino-lime.dtb
+$MKIMAGE -A arm -O linux -T script -C none -d $BOARD_DIR/boot.cmd $BOOT_DIR/boot.scr
+cp $BINARIES_DIR/zImage $BOOT_DIR/zImage
diff --git a/board/olimex/a20_olinuxino_lime/readme.txt b/board/olimex/a20_olinuxino_lime/readme.txt
new file mode 100644
index 0000000..32148b7
--- /dev/null
+++ b/board/olimex/a20_olinuxino_lime/readme.txt
@@ -0,0 +1,89 @@
+A20-OLinuXino-LIME
+
+Intro
+=====
+
+This is a open hardware board,
+see https://www.olimex.com/Products/OLinuXino/open-source-hardware
+
+See https://linux-sunxi.org/Linux_Kernel, for choosing between
+the legacy linux-sunxi kernel and the device tree / mainline kernel.
+
+
+How to build it
+===============
+
+ $ make olimex_a20_olinuxino_defconfig
+
+Compile all and build rootfs image:
+
+ $ make
+
+Result of the build
+-------------------
+
+After building, you should get a tree like this:
+
+ output/images/
+ +-- rootfs.ext2
+ +-- sun7i-a20-olinuxino-lime.dtb
+ +-- u-boot.bin
+ +-- u-boot-sunxi-with-spl.bin
+ `-- zImage
+
+
+How setting up the SD card
+==========================
+
+
+Prepare the SD card
+-------------------
+
+Erase existing stuff, and create an unique Linux partition with `fdisk`.
+
+ # fdisk /dev/sdX
+ Command (m for help): o
+ Building a new DOS disklabel with disk identifier 0xf9e1616a.
+ Changes will remain in memory only, until you decide to write them.
+ After that, of course, the previous content won't be recoverable.
+
+ Command (m for help): n
+ Partition type:
+ p primary (0 primary, 0 extended, 4 free)
+ e extended
+ Select (default p): p
+ Partition number (1-4, default 1): 1
+ First sector (2048-7626751, default 2048): 2048
+ Last sector, +sectors or +size{K,M,G} (2048-7626751, default 7626751):
+ Using default value 7626751
+
+ Command (m for help): p
+
+ Disk /dev/sdX: 3904 MB, 3904897024 bytes
+ 4 heads, 16 sectors/track, 119168 cylinders, total 7626752 sectors
+ Units = sectors of 1 * 512 = 512 bytes
+ Sector size (logical/physical): 512 bytes / 512 bytes
+ I/O size (minimum/optimal): 512 bytes / 512 bytes
+ Disk identifier: 0xf9e1616a
+
+ Device Boot Start End Blocks Id System
+ /dev/sdX1 2048 7626751 3812352 83 Linux
+
+ Command (m for help): w
+ The partition table has been altered!
+
+ Calling ioctl() to re-read partition table.
+ Syncing disks.
+
+Copy images on the SD card
+--------------------------
+
+ # dd if=output/images/rootfs.ext2 of=/dev/sdX1 bs=512
+ # dd if=output/images/u-boot-sunxi-with-spl.bin of=/dev/sdX bs=1024 seek=8
+
+
+Finish
+======
+
+Eject the SD card, insert it in the A20-OLinuXino-LIME board, and power it up.
+
diff --git a/configs/olimex_a20_olinuxino_defconfig b/configs/olimex_a20_olinuxino_defconfig
new file mode 100644
index 0000000..ce9435c
--- /dev/null
+++ b/configs/olimex_a20_olinuxino_defconfig
@@ -0,0 +1,35 @@
+# Architecture
+BR2_arm=y
+BR2_cortex_a7=y
+
+# System configuration
+BR2_TARGET_GENERIC_HOSTNAME="a20-olinuxino"
+BR2_TARGET_GENERIC_ISSUE="Welcome to use OLinuXino!"
+BR2_TARGET_GENERIC_GETTY=y
+BR2_TARGET_GENERIC_GETTY_PORT="ttyS0"
+BR2_ROOTFS_POST_BUILD_SCRIPT="board/olimex/a20_olinuxino_lime/post-build.sh"
+
+# Kernel
+BR2_LINUX_KERNEL=y
+BR2_LINUX_KERNEL_CUSTOM_VERSION=y
+BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="4.0.5"
+BR2_LINUX_KERNEL_USE_DEFCONFIG=y
+BR2_LINUX_KERNEL_DEFCONFIG="sunxi"
+BR2_LINUX_KERNEL_ZIMAGE=y
+BR2_LINUX_KERNEL_DTS_SUPPORT=y
+BR2_LINUX_KERNEL_INTREE_DTS_NAME="sun7i-a20-olinuxino-lime"
+
+# Filesystem
+BR2_TARGET_ROOTFS_EXT2=y
+# BR2_TARGET_ROOTFS_TAR is not set
+
+# Bootloaders
+BR2_TARGET_UBOOT=y
+BR2_TARGET_UBOOT_VERSION="2015.04"
+BR2_TARGET_UBOOT_BOARDNAME="A20-OLinuXino-Lime"
+BR2_TARGET_UBOOT_FORMAT_BIN=y
+BR2_TARGET_UBOOT_SPL=y
+BR2_TARGET_UBOOT_SPL_NAME="u-boot-sunxi-with-spl.bin"
+
+# Additional tools
+BR2_PACKAGE_HOST_UBOOT_TOOLS=y
--
2.1.4
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 4/5] cubieboard: rename script to mksunxicard.sh
2015-06-15 18:45 [Buildroot] [PATCH 0/5] A20-OLinuXino-Lime: new board Francois Perrad
` (2 preceding siblings ...)
2015-06-15 18:46 ` [Buildroot] [PATCH 3/5] A20-OLinuXino-Lime: new board (mainline) Francois Perrad
@ 2015-06-15 18:46 ` Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 5/5] A20-OLinuXino-Lime: new board (legacy) Francois Perrad
4 siblings, 0 replies; 8+ messages in thread
From: Francois Perrad @ 2015-06-15 18:46 UTC (permalink / raw)
To: buildroot
in order to reuse it for A20-OLinuXino
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
board/cubietech/cubieboard/{mkcubiecard.sh => mksunxicard.sh} | 4 ++--
board/cubietech/cubieboard/readme.txt | 4 ++--
2 files changed, 4 insertions(+), 4 deletions(-)
rename board/cubietech/cubieboard/{mkcubiecard.sh => mksunxicard.sh} (97%)
diff --git a/board/cubietech/cubieboard/mkcubiecard.sh b/board/cubietech/cubieboard/mksunxicard.sh
similarity index 97%
rename from board/cubietech/cubieboard/mkcubiecard.sh
rename to board/cubietech/cubieboard/mksunxicard.sh
index f1d5a9f..97e04b5 100755
--- a/board/cubietech/cubieboard/mkcubiecard.sh
+++ b/board/cubietech/cubieboard/mksunxicard.sh
@@ -82,12 +82,12 @@ fi
if [ -b ${DRIVE}2 ]; then
D2=${DRIVE}2
umount ${DRIVE}2
- mkfs.ext4 -L "Cubie" ${DRIVE}2
+ mkfs.ext4 -L "SUNXI" ${DRIVE}2
else
if [ -b ${DRIVE}p2 ]; then
D2=${DRIVE}p2
umount ${DRIVE}p2
- mkfs.ext4 -L "Cubie" ${DRIVE}p2
+ mkfs.ext4 -L "SUNXI" ${DRIVE}p2
else
echo "Cant find rootfs partition in /dev"
exit 1
diff --git a/board/cubietech/cubieboard/readme.txt b/board/cubietech/cubieboard/readme.txt
index 81cc5e4..3b542c7 100644
--- a/board/cubietech/cubieboard/readme.txt
+++ b/board/cubietech/cubieboard/readme.txt
@@ -41,7 +41,7 @@ How setting up the SD card
--------------------------
Depending on the rootfs size, you might want to use a 2GB or larger SD-card.
-The script mkcubiecard.sh will take care of partitioning and formatting
+The script mksunxicard.sh will take care of partitioning and formatting
the SD-card.
BEWARE! This process will erase your SD card.
@@ -49,7 +49,7 @@ BEWARE! This process will erase your SD card.
Use dmesg to find out where the SD card is attached in the /dev tree
(<device>) and then:
-# sudo ./mkcubiecard.sh <images_dir> <device>
+# sudo ./mksunxicard.sh <images_dir> <device>
where:
- <images_dir> is the directory containing the generated files (usually
--
2.1.4
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 5/5] A20-OLinuXino-Lime: new board (legacy)
2015-06-15 18:45 [Buildroot] [PATCH 0/5] A20-OLinuXino-Lime: new board Francois Perrad
` (3 preceding siblings ...)
2015-06-15 18:46 ` [Buildroot] [PATCH 4/5] cubieboard: rename script to mksunxicard.sh Francois Perrad
@ 2015-06-15 18:46 ` Francois Perrad
2015-06-17 22:52 ` Arnout Vandecappelle
4 siblings, 1 reply; 8+ messages in thread
From: Francois Perrad @ 2015-06-15 18:46 UTC (permalink / raw)
To: buildroot
config legacy / sunxi like Cubieboard2
Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
---
board/olimex/a20_olinuxino_lime/boot-legacy.cmd | 4 ++
board/olimex/a20_olinuxino_lime/mksunxicard.sh | 1 +
board/olimex/a20_olinuxino_lime/post-build.sh | 16 +++---
board/olimex/a20_olinuxino_lime/readme-legacy.txt | 60 +++++++++++++++++++++++
configs/olimex_a20_olinuxino_legacy_defconfig | 43 ++++++++++++++++
5 files changed, 118 insertions(+), 6 deletions(-)
create mode 100644 board/olimex/a20_olinuxino_lime/boot-legacy.cmd
create mode 120000 board/olimex/a20_olinuxino_lime/mksunxicard.sh
create mode 100644 board/olimex/a20_olinuxino_lime/readme-legacy.txt
create mode 100644 configs/olimex_a20_olinuxino_legacy_defconfig
diff --git a/board/olimex/a20_olinuxino_lime/boot-legacy.cmd b/board/olimex/a20_olinuxino_lime/boot-legacy.cmd
new file mode 100644
index 0000000..849ed00
--- /dev/null
+++ b/board/olimex/a20_olinuxino_lime/boot-legacy.cmd
@@ -0,0 +1,4 @@
+setenv bootargs console=ttyS0,115200 root=/dev/mmcblk0p2 rootwait panic=10 ${extra}
+fatload mmc 0 0x43000000 script.bin
+fatload mmc 0 0x48000000 uImage
+bootm 0x48000000
diff --git a/board/olimex/a20_olinuxino_lime/mksunxicard.sh b/board/olimex/a20_olinuxino_lime/mksunxicard.sh
new file mode 120000
index 0000000..8879400
--- /dev/null
+++ b/board/olimex/a20_olinuxino_lime/mksunxicard.sh
@@ -0,0 +1 @@
+../../cubietech/cubieboard/mksunxicard.sh
\ No newline at end of file
diff --git a/board/olimex/a20_olinuxino_lime/post-build.sh b/board/olimex/a20_olinuxino_lime/post-build.sh
index d8d8fa4..8343611 100755
--- a/board/olimex/a20_olinuxino_lime/post-build.sh
+++ b/board/olimex/a20_olinuxino_lime/post-build.sh
@@ -4,9 +4,13 @@ BOARD_DIR="$(dirname $0)"
BOOT_DIR=$TARGET_DIR/boot
MKIMAGE=$HOST_DIR/usr/bin/mkimage
-rm -rf $BOOT_DIR
-mkdir $BOOT_DIR
-mkdir $BOOT_DIR/dtb
-cp $BINARIES_DIR/sun7i-a20-olinuxino-lime.dtb $BOOT_DIR/dtb/sun7i-a20-olinuxino-lime.dtb
-$MKIMAGE -A arm -O linux -T script -C none -d $BOARD_DIR/boot.cmd $BOOT_DIR/boot.scr
-cp $BINARIES_DIR/zImage $BOOT_DIR/zImage
+if [ -e $BINARIES_DIR/sun7i-a20-olinuxino-lime.dtb ]; then
+ rm -rf $BOOT_DIR
+ mkdir $BOOT_DIR
+ mkdir $BOOT_DIR/dtb
+ cp $BINARIES_DIR/sun7i-a20-olinuxino-lime.dtb $BOOT_DIR/dtb/sun7i-a20-olinuxino-lime.dtb
+ $MKIMAGE -A arm -O linux -T script -C none -d $BOARD_DIR/boot.cmd $BOOT_DIR/boot.scr
+ cp $BINARIES_DIR/zImage $BOOT_DIR/zImage
+else
+ $MKIMAGE -A arm -O linux -T script -C none -d $BOARD_DIR/boot-legacy.cmd $BINARIES_DIR/boot.scr
+fi
diff --git a/board/olimex/a20_olinuxino_lime/readme-legacy.txt b/board/olimex/a20_olinuxino_lime/readme-legacy.txt
new file mode 100644
index 0000000..7a0b452
--- /dev/null
+++ b/board/olimex/a20_olinuxino_lime/readme-legacy.txt
@@ -0,0 +1,60 @@
+A20-OLinuXino-LIME
+
+Intro
+=====
+
+This is a open hardware board,
+see https://www.olimex.com/Products/OLinuXino/open-source-hardware
+
+See https://linux-sunxi.org/Linux_Kernel, for choosing between
+the legacy linux-sunxi kernel and the device tree / mainline kernel.
+
+
+How to build it
+===============
+
+ $ make olimex_a20_olinuxino_legacy_defconfig
+
+Compile all and build rootfs image:
+
+ $ make
+
+Result of the build
+-------------------
+
+After building, you should get a tree like this:
+
+ output/images/
+ +-- boot.scr
+ +-- rootfs.tar
+ +-- script.bin
+ +-- u-boot-sunxi-with-spl.bin
+ +-- u-boot.bin
+ `-- uImage
+
+
+How setting up the SD card
+==========================
+
+Depending on the rootfs size, you might want to use a 2GB or larger SD-card.
+The script `mksunxicard.sh` will take care of partitioning and formatting
+the SD-card.
+
+BEWARE! This process will erase your SD card.
+
+Use `dmesg` to find out where the SD card is attached in the /dev tree
+(<device>) and then:
+
+ # ./mksunxicard.sh <images_dir> <device>
+
+where:
+ - <images_dir> is the directory containing the generated files (usually
+ output/images)
+ - <device> is the device file of the SD card (usually /dev/sdX)
+
+
+Finish
+======
+
+Eject the SD card, insert it in the A20-OLinuXino-LIME board, and pwer it up.
+
diff --git a/configs/olimex_a20_olinuxino_legacy_defconfig b/configs/olimex_a20_olinuxino_legacy_defconfig
new file mode 100644
index 0000000..d5987d4
--- /dev/null
+++ b/configs/olimex_a20_olinuxino_legacy_defconfig
@@ -0,0 +1,43 @@
+# Architecture
+BR2_arm=y
+BR2_cortex_a7=y
+
+# Kernel headers
+BR2_KERNEL_HEADERS_3_4=y
+
+# System configuration
+BR2_TARGET_GENERIC_HOSTNAME="a20-olinuxino"
+BR2_TARGET_GENERIC_ISSUE="Welcome to use OLinuXino!"
+BR2_TARGET_GENERIC_GETTY=y
+BR2_TARGET_GENERIC_GETTY_PORT="ttyS0"
+BR2_ROOTFS_POST_BUILD_SCRIPT="board/olimex/a20_olinuxino_lime/post-build.sh"
+
+# Kernel
+BR2_LINUX_KERNEL=y
+BR2_LINUX_KERNEL_CUSTOM_GIT=y
+BR2_LINUX_KERNEL_VERSION="sunxi-3.4"
+BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://github.com/linux-sunxi/linux-sunxi.git"
+# based on Linux version 3.4.103
+BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="9a1cd034181af628d4145202289e1993c1687db6"
+BR2_LINUX_KERNEL_USE_DEFCONFIG=y
+BR2_LINUX_KERNEL_DEFCONFIG="sun7i"
+
+# sunxi packages
+BR2_PACKAGE_SUNXI_TOOLS=y
+BR2_PACKAGE_SUNXI_BOARDS=y
+BR2_PACKAGE_SUNXI_BOARDS_FEX_FILE="a20/a20-olinuxino_lime.fex"
+
+# Bootloaders
+BR2_TARGET_UBOOT=y
+BR2_TARGET_UBOOT_BOARDNAME="A20-OLinuXino-Lime"
+BR2_TARGET_UBOOT_CUSTOM_GIT=y
+BR2_TARGET_UBOOT_VERSION="sunxi"
+BR2_TARGET_UBOOT_CUSTOM_REPO_URL="https://github.com/linux-sunxi/u-boot-sunxi.git"
+# based on U-Boot 2014.04
+BR2_TARGET_UBOOT_CUSTOM_REPO_VERSION="ea1ac32bf76eb60baef474c2516fc431b381d952"
+BR2_TARGET_UBOOT_FORMAT_BIN=y
+BR2_TARGET_UBOOT_SPL=y
+BR2_TARGET_UBOOT_SPL_NAME="u-boot-sunxi-with-spl.bin"
+
+# Additional tools
+BR2_PACKAGE_HOST_UBOOT_TOOLS=y
--
2.1.4
^ permalink raw reply related [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 3/5] A20-OLinuXino-Lime: new board (mainline)
2015-06-15 18:46 ` [Buildroot] [PATCH 3/5] A20-OLinuXino-Lime: new board (mainline) Francois Perrad
@ 2015-06-17 22:30 ` Arnout Vandecappelle
0 siblings, 0 replies; 8+ messages in thread
From: Arnout Vandecappelle @ 2015-06-17 22:30 UTC (permalink / raw)
To: buildroot
On 06/15/15 20:46, Francois Perrad wrote:
> config device tree / mainline (4.0.5)
>
> Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
[snip]
> diff --git a/board/olimex/a20_olinuxino_lime/post-build.sh b/board/olimex/a20_olinuxino_lime/post-build.sh
> new file mode 100755
> index 0000000..d8d8fa4
> --- /dev/null
> +++ b/board/olimex/a20_olinuxino_lime/post-build.sh
> @@ -0,0 +1,12 @@
> +#!/bin/sh
> +
> +BOARD_DIR="$(dirname $0)"
> +BOOT_DIR=$TARGET_DIR/boot
> +MKIMAGE=$HOST_DIR/usr/bin/mkimage
> +
> +rm -rf $BOOT_DIR
> +mkdir $BOOT_DIR
> +mkdir $BOOT_DIR/dtb
> +cp $BINARIES_DIR/sun7i-a20-olinuxino-lime.dtb $BOOT_DIR/dtb/sun7i-a20-olinuxino-lime.dtb
If you set BR2_LINUX_KERNEL_INSTALL_TARGET=y, buildroot will install the dtb(s)
and the kernel in /boot. It will not use a dtb directory but that's not really
needed, right?
> +$MKIMAGE -A arm -O linux -T script -C none -d $BOARD_DIR/boot.cmd $BOOT_DIR/boot.scr
So actually, this is the only part of the script that is really needed.
Perhaps we could add an option in boot/uboot to do this from buildroot as well.
> +cp $BINARIES_DIR/zImage $BOOT_DIR/zImage
> diff --git a/board/olimex/a20_olinuxino_lime/readme.txt b/board/olimex/a20_olinuxino_lime/readme.txt
> new file mode 100644
> index 0000000..32148b7
> --- /dev/null
> +++ b/board/olimex/a20_olinuxino_lime/readme.txt
> @@ -0,0 +1,89 @@
[snip]
> +Copy images on the SD card
> +--------------------------
> +
> + # dd if=output/images/rootfs.ext2 of=/dev/sdX1 bs=512
bs is not needed here (it just slows thing down).
> + # dd if=output/images/u-boot-sunxi-with-spl.bin of=/dev/sdX bs=1024 seek=8
> +
> +
> +Finish
> +======
> +
> +Eject the SD card, insert it in the A20-OLinuXino-LIME board, and power it up.
> +
> diff --git a/configs/olimex_a20_olinuxino_defconfig b/configs/olimex_a20_olinuxino_defconfig
> new file mode 100644
> index 0000000..ce9435c
> --- /dev/null
> +++ b/configs/olimex_a20_olinuxino_defconfig
> @@ -0,0 +1,35 @@
> +# Architecture
> +BR2_arm=y
> +BR2_cortex_a7=y
> +
Please also use a custom kernel headers version (4.1 will be the default soon...).
> +# System configuration
> +BR2_TARGET_GENERIC_HOSTNAME="a20-olinuxino"
> +BR2_TARGET_GENERIC_ISSUE="Welcome to use OLinuXino!"
> +BR2_TARGET_GENERIC_GETTY=y
> +BR2_TARGET_GENERIC_GETTY_PORT="ttyS0"
> +BR2_ROOTFS_POST_BUILD_SCRIPT="board/olimex/a20_olinuxino_lime/post-build.sh"
> +
> +# Kernel
> +BR2_LINUX_KERNEL=y
> +BR2_LINUX_KERNEL_CUSTOM_VERSION=y
> +BR2_LINUX_KERNEL_CUSTOM_VERSION_VALUE="4.0.5"
and use SAME_AS_HEADERS here.
> +BR2_LINUX_KERNEL_USE_DEFCONFIG=y
> +BR2_LINUX_KERNEL_DEFCONFIG="sunxi"
> +BR2_LINUX_KERNEL_ZIMAGE=y
> +BR2_LINUX_KERNEL_DTS_SUPPORT=y
> +BR2_LINUX_KERNEL_INTREE_DTS_NAME="sun7i-a20-olinuxino-lime"
As mentioned above, use BR2_LINUX_KERNEL_INSTALL_TARGET
> +
> +# Filesystem
> +BR2_TARGET_ROOTFS_EXT2=y
I think we should start using BR2_TARGET_ROOTFS_EXT2_4 where possible. A few of
our defconfigs have it already but it should be generalized IMHO.
> +# BR2_TARGET_ROOTFS_TAR is not set
> +
> +# Bootloaders
> +BR2_TARGET_UBOOT=y
> +BR2_TARGET_UBOOT_VERSION="2015.04"
> +BR2_TARGET_UBOOT_BOARDNAME="A20-OLinuXino-Lime"
> +BR2_TARGET_UBOOT_FORMAT_BIN=y
> +BR2_TARGET_UBOOT_SPL=y
> +BR2_TARGET_UBOOT_SPL_NAME="u-boot-sunxi-with-spl.bin"
> +
> +# Additional tools
> +BR2_PACKAGE_HOST_UBOOT_TOOLS=y
>
Regards,
Arnout
--
Arnout Vandecappelle arnout at mind be
Senior Embedded Software Architect +32-16-286500
Essensium/Mind http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint: 7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
^ permalink raw reply [flat|nested] 8+ messages in thread
* [Buildroot] [PATCH 5/5] A20-OLinuXino-Lime: new board (legacy)
2015-06-15 18:46 ` [Buildroot] [PATCH 5/5] A20-OLinuXino-Lime: new board (legacy) Francois Perrad
@ 2015-06-17 22:52 ` Arnout Vandecappelle
0 siblings, 0 replies; 8+ messages in thread
From: Arnout Vandecappelle @ 2015-06-17 22:52 UTC (permalink / raw)
To: buildroot
On 06/15/15 20:46, Francois Perrad wrote:
> config legacy / sunxi like Cubieboard2
Instead of legacy, I'd call it 3d or accelerated or something, that makes the
difference a little clearer.
>
> Signed-off-by: Francois Perrad <francois.perrad@gadz.org>
> ---
> board/olimex/a20_olinuxino_lime/boot-legacy.cmd | 4 ++
> board/olimex/a20_olinuxino_lime/mksunxicard.sh | 1 +
> board/olimex/a20_olinuxino_lime/post-build.sh | 16 +++---
> board/olimex/a20_olinuxino_lime/readme-legacy.txt | 60 +++++++++++++++++++++++
> configs/olimex_a20_olinuxino_legacy_defconfig | 43 ++++++++++++++++
> 5 files changed, 118 insertions(+), 6 deletions(-)
> create mode 100644 board/olimex/a20_olinuxino_lime/boot-legacy.cmd
> create mode 120000 board/olimex/a20_olinuxino_lime/mksunxicard.sh
> create mode 100644 board/olimex/a20_olinuxino_lime/readme-legacy.txt
> create mode 100644 configs/olimex_a20_olinuxino_legacy_defconfig
>
> diff --git a/board/olimex/a20_olinuxino_lime/boot-legacy.cmd b/board/olimex/a20_olinuxino_lime/boot-legacy.cmd
> new file mode 100644
> index 0000000..849ed00
> --- /dev/null
> +++ b/board/olimex/a20_olinuxino_lime/boot-legacy.cmd
> @@ -0,0 +1,4 @@
> +setenv bootargs console=ttyS0,115200 root=/dev/mmcblk0p2 rootwait panic=10 ${extra}
> +fatload mmc 0 0x43000000 script.bin
> +fatload mmc 0 0x48000000 uImage
> +bootm 0x48000000
> diff --git a/board/olimex/a20_olinuxino_lime/mksunxicard.sh b/board/olimex/a20_olinuxino_lime/mksunxicard.sh
> new file mode 120000
> index 0000000..8879400
> --- /dev/null
> +++ b/board/olimex/a20_olinuxino_lime/mksunxicard.sh
> @@ -0,0 +1 @@
> +../../cubietech/cubieboard/mksunxicard.sh
Since this is anyway a symlink, there's no need to rename the script in patch
4/5, you can just link to mkcubiecard.sh.
> \ No newline at end of file
> diff --git a/board/olimex/a20_olinuxino_lime/post-build.sh b/board/olimex/a20_olinuxino_lime/post-build.sh
> index d8d8fa4..8343611 100755
> --- a/board/olimex/a20_olinuxino_lime/post-build.sh
> +++ b/board/olimex/a20_olinuxino_lime/post-build.sh
> @@ -4,9 +4,13 @@ BOARD_DIR="$(dirname $0)"
> BOOT_DIR=$TARGET_DIR/boot
> MKIMAGE=$HOST_DIR/usr/bin/mkimage
>
> -rm -rf $BOOT_DIR
> -mkdir $BOOT_DIR
> -mkdir $BOOT_DIR/dtb
> -cp $BINARIES_DIR/sun7i-a20-olinuxino-lime.dtb $BOOT_DIR/dtb/sun7i-a20-olinuxino-lime.dtb
> -$MKIMAGE -A arm -O linux -T script -C none -d $BOARD_DIR/boot.cmd $BOOT_DIR/boot.scr
> -cp $BINARIES_DIR/zImage $BOOT_DIR/zImage
> +if [ -e $BINARIES_DIR/sun7i-a20-olinuxino-lime.dtb ]; then
> + rm -rf $BOOT_DIR
> + mkdir $BOOT_DIR
> + mkdir $BOOT_DIR/dtb
> + cp $BINARIES_DIR/sun7i-a20-olinuxino-lime.dtb $BOOT_DIR/dtb/sun7i-a20-olinuxino-lime.dtb
> + $MKIMAGE -A arm -O linux -T script -C none -d $BOARD_DIR/boot.cmd $BOOT_DIR/boot.scr
> + cp $BINARIES_DIR/zImage $BOOT_DIR/zImage
> +else
> + $MKIMAGE -A arm -O linux -T script -C none -d $BOARD_DIR/boot-legacy.cmd $BINARIES_DIR/boot.scr
If you follow the comments I made in patch 3/5, you can rewrite this to pass
the input .cmd and output directory as a parameter to the script. So
$MKIMAGE -A arm -O linux -T script -C none -d $2 $3/boot.scr
BR2_ROOTFS_POST_SCRIPT_ARGS="board/.../boot-legacy.cmd $(BINARIES_DIR)"
and for the mainline one:
BR2_ROOTFS_POST_SCRIPT_ARGS="board/.../boot.cmd $(TARGET_DIR)/boot"
> +fi
> diff --git a/board/olimex/a20_olinuxino_lime/readme-legacy.txt b/board/olimex/a20_olinuxino_lime/readme-legacy.txt
> new file mode 100644
> index 0000000..7a0b452
> --- /dev/null
> +++ b/board/olimex/a20_olinuxino_lime/readme-legacy.txt
I would combine both versions in a single readme.txt.
> @@ -0,0 +1,60 @@
> +A20-OLinuXino-LIME
> +
> +Intro
> +=====
> +
> +This is a open hardware board,
> +see https://www.olimex.com/Products/OLinuXino/open-source-hardware
> +
> +See https://linux-sunxi.org/Linux_Kernel, for choosing between
> +the legacy linux-sunxi kernel and the device tree / mainline kernel.
I think you should copy the TL;DR in this file:
The legacy linux-sunxi kernels are based on the vendor code drops. It is only
useful when accelerated 3D graphics and multimedia support is strictly necessary.
The Mainline Kernel is already a much better choice for a headless server. And
also the mainline kernel works fine even for a basic Linux desktop system
running on top of a simple framebuffer, which may be good enough for the users
who do not need fancy 3D graphics or video playback acceleration.
> +
> +
> +How to build it
> +===============
> +
> + $ make olimex_a20_olinuxino_legacy_defconfig
> +
> +Compile all and build rootfs image:
> +
> + $ make
> +
> +Result of the build
> +-------------------
> +
> +After building, you should get a tree like this:
> +
> + output/images/
> + +-- boot.scr
> + +-- rootfs.tar
> + +-- script.bin
> + +-- u-boot-sunxi-with-spl.bin
> + +-- u-boot.bin
> + `-- uImage
> +
> +
> +How setting up the SD card
> +==========================
> +
> +Depending on the rootfs size, you might want to use a 2GB or larger SD-card.
> +The script `mksunxicard.sh` will take care of partitioning and formatting
> +the SD-card.
> +
> +BEWARE! This process will erase your SD card.
> +
> +Use `dmesg` to find out where the SD card is attached in the /dev tree
> +(<device>) and then:
> +
> + # ./mksunxicard.sh <images_dir> <device>
> +
> +where:
> + - <images_dir> is the directory containing the generated files (usually
> + output/images)
> + - <device> is the device file of the SD card (usually /dev/sdX)
Of course, you could just as well use the same approach for the mainline
version, i.e. put the boot stuff in a fatfs and only the real rootfs in the ext2.
> +
> +
> +Finish
> +======
> +
> +Eject the SD card, insert it in the A20-OLinuXino-LIME board, and pwer it up.
pwer -> power
> +
> diff --git a/configs/olimex_a20_olinuxino_legacy_defconfig b/configs/olimex_a20_olinuxino_legacy_defconfig
> new file mode 100644
> index 0000000..d5987d4
> --- /dev/null
> +++ b/configs/olimex_a20_olinuxino_legacy_defconfig
> @@ -0,0 +1,43 @@
> +# Architecture
> +BR2_arm=y
> +BR2_cortex_a7=y
> +
> +# Kernel headers
> +BR2_KERNEL_HEADERS_3_4=y
> +
> +# System configuration
> +BR2_TARGET_GENERIC_HOSTNAME="a20-olinuxino"
> +BR2_TARGET_GENERIC_ISSUE="Welcome to use OLinuXino!"
> +BR2_TARGET_GENERIC_GETTY=y
> +BR2_TARGET_GENERIC_GETTY_PORT="ttyS0"
> +BR2_ROOTFS_POST_BUILD_SCRIPT="board/olimex/a20_olinuxino_lime/post-build.sh"
> +
> +# Kernel
> +BR2_LINUX_KERNEL=y
> +BR2_LINUX_KERNEL_CUSTOM_GIT=y
> +BR2_LINUX_KERNEL_VERSION="sunxi-3.4"
> +BR2_LINUX_KERNEL_CUSTOM_REPO_URL="https://github.com/linux-sunxi/linux-sunxi.git"
You can use a wget URL instead:
$(call github,linux-sunxi,linux-sunxi,9a1cd034181af628d4145202289e1993c1687db6)
> +# based on Linux version 3.4.103
> +BR2_LINUX_KERNEL_CUSTOM_REPO_VERSION="9a1cd034181af628d4145202289e1993c1687db6"
> +BR2_LINUX_KERNEL_USE_DEFCONFIG=y
> +BR2_LINUX_KERNEL_DEFCONFIG="sun7i"
> +
> +# sunxi packages
> +BR2_PACKAGE_SUNXI_TOOLS=y
> +BR2_PACKAGE_SUNXI_BOARDS=y
> +BR2_PACKAGE_SUNXI_BOARDS_FEX_FILE="a20/a20-olinuxino_lime.fex"
> +
> +# Bootloaders
> +BR2_TARGET_UBOOT=y
> +BR2_TARGET_UBOOT_BOARDNAME="A20-OLinuXino-Lime"
> +BR2_TARGET_UBOOT_CUSTOM_GIT=y
> +BR2_TARGET_UBOOT_VERSION="sunxi"
> +BR2_TARGET_UBOOT_CUSTOM_REPO_URL="https://github.com/linux-sunxi/u-boot-sunxi.git"
Same here.
Regards,
Arnout
> +# based on U-Boot 2014.04
> +BR2_TARGET_UBOOT_CUSTOM_REPO_VERSION="ea1ac32bf76eb60baef474c2516fc431b381d952"
> +BR2_TARGET_UBOOT_FORMAT_BIN=y
> +BR2_TARGET_UBOOT_SPL=y
> +BR2_TARGET_UBOOT_SPL_NAME="u-boot-sunxi-with-spl.bin"
> +
> +# Additional tools
> +BR2_PACKAGE_HOST_UBOOT_TOOLS=y
>
--
Arnout Vandecappelle arnout at mind be
Senior Embedded Software Architect +32-16-286500
Essensium/Mind http://www.mind.be
G.Geenslaan 9, 3001 Leuven, Belgium BE 872 984 063 RPR Leuven
LinkedIn profile: http://www.linkedin.com/in/arnoutvandecappelle
GPG fingerprint: 7CB5 E4CC 6C2E EFD4 6E3D A754 F963 ECAB 2450 2F1F
^ permalink raw reply [flat|nested] 8+ messages in thread
end of thread, other threads:[~2015-06-17 22:52 UTC | newest]
Thread overview: 8+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2015-06-15 18:45 [Buildroot] [PATCH 0/5] A20-OLinuXino-Lime: new board Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 1/5] sunxi-board: bump to version a6a4e94066f4ec6b26fc7060dc453a6bcf26a504 Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 2/5] a10disp: bump to version v0.6.1 Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 3/5] A20-OLinuXino-Lime: new board (mainline) Francois Perrad
2015-06-17 22:30 ` Arnout Vandecappelle
2015-06-15 18:46 ` [Buildroot] [PATCH 4/5] cubieboard: rename script to mksunxicard.sh Francois Perrad
2015-06-15 18:46 ` [Buildroot] [PATCH 5/5] A20-OLinuXino-Lime: new board (legacy) Francois Perrad
2015-06-17 22:52 ` Arnout Vandecappelle
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox