From a5689ca365a538f914078478c620dd18165fdc15 Mon Sep 17 00:00:00 2001 From: Baruch Siach Date: Tue, 20 Nov 2018 15:30:09 +0200 Subject: configs/solidrun_macchiatobin_mainline: bump kernel and U-Boot Bump U-Boot to version 2018.11. This version supports autodetection of SD/eMMC boot source, so we can now enable environment load from SD card. Add a U-Boot kconfig fragment that sets SD/eMMC as environment load/save device. This avoids stale environment values from the SPI flash. That in turn, allows to use the more convenient distro boot which is enabled in the default environment. Bump kernel to version 4.19.2. This version enables CONFIG_PHY_MVEBU_CP110_COMPHY in the arm64 defconfig, so remove it from the kernel kconfig fragment. Enable support for SFP modules detection and configuration. Leave the PHY drivers for now to keep them built into the kernel. The kernel defconfig builds these drivers as modules. But that does not work as expected in the default configuration. Cc: Sergey Matyukevich Signed-off-by: Baruch Siach Tested-by: Sergey Matyukevich Signed-off-by: Peter Korsgaard --- board/solidrun/macchiatobin/extlinux.conf | 4 ++++ board/solidrun/macchiatobin/linux-extras.config | 2 +- board/solidrun/macchiatobin/post-build-mainline.sh | 5 +++++ board/solidrun/macchiatobin/uboot-fragment.config | 2 ++ 4 files changed, 12 insertions(+), 1 deletion(-) create mode 100644 board/solidrun/macchiatobin/extlinux.conf create mode 100755 board/solidrun/macchiatobin/post-build-mainline.sh create mode 100644 board/solidrun/macchiatobin/uboot-fragment.config (limited to 'board') diff --git a/board/solidrun/macchiatobin/extlinux.conf b/board/solidrun/macchiatobin/extlinux.conf new file mode 100644 index 0000000000..1008af1af0 --- /dev/null +++ b/board/solidrun/macchiatobin/extlinux.conf @@ -0,0 +1,4 @@ +label Macchiatobin Linux + kernel /boot/Image + devicetree /boot/armada-8040-mcbin.dtb + append console=ttyS0,115200n8 root=/dev/mmcblk1p1 rootwait diff --git a/board/solidrun/macchiatobin/linux-extras.config b/board/solidrun/macchiatobin/linux-extras.config index 11267d2f80..29fd630626 100644 --- a/board/solidrun/macchiatobin/linux-extras.config +++ b/board/solidrun/macchiatobin/linux-extras.config @@ -1,3 +1,3 @@ CONFIG_MARVELL_PHY=y CONFIG_MARVELL_10G_PHY=y -CONFIG_PHY_MVEBU_CP110_COMPHY=y +CONFIG_SFP=y diff --git a/board/solidrun/macchiatobin/post-build-mainline.sh b/board/solidrun/macchiatobin/post-build-mainline.sh new file mode 100755 index 0000000000..1f5ff6a611 --- /dev/null +++ b/board/solidrun/macchiatobin/post-build-mainline.sh @@ -0,0 +1,5 @@ +#!/bin/sh + +BOARD_DIR="$(dirname $0)" + +install -m 0644 -D $BOARD_DIR/extlinux.conf $TARGET_DIR/boot/extlinux/extlinux.conf diff --git a/board/solidrun/macchiatobin/uboot-fragment.config b/board/solidrun/macchiatobin/uboot-fragment.config new file mode 100644 index 0000000000..717a094247 --- /dev/null +++ b/board/solidrun/macchiatobin/uboot-fragment.config @@ -0,0 +1,2 @@ +CONFIG_ENV_IS_IN_MMC=y +# CONFIG_ENV_IS_IN_SPI_FLASH is not set -- cgit v1.2.1 From 2ffdcbe0a5304a865e4486e7de0a7e6d983e2ce2 Mon Sep 17 00:00:00 2001 From: Baruch Siach Date: Tue, 20 Nov 2018 15:30:10 +0200 Subject: board: macchiatobin: update readme.txt Update the kernel and U-Boot versions to the actual versions in use. Update the description of supported hardware features. Add a note that the stale SPI flash environment issue only affects the vendor BSP. Cc: Sergey Matyukevich Signed-off-by: Baruch Siach Signed-off-by: Peter Korsgaard --- board/solidrun/macchiatobin/readme.txt | 30 +++++++++++++++++------------- 1 file changed, 17 insertions(+), 13 deletions(-) (limited to 'board') diff --git a/board/solidrun/macchiatobin/readme.txt b/board/solidrun/macchiatobin/readme.txt index dfbd6e793b..dc5d6c794d 100644 --- a/board/solidrun/macchiatobin/readme.txt +++ b/board/solidrun/macchiatobin/readme.txt @@ -15,19 +15,20 @@ How to build There are two build options: mainline support and vendor support. For the mainline BSP, we use: - - Linux v4.15 - - U-Boot v2018.01 + - Linux v4.19.2 + - U-Boot v2018.11 For the vendor BSP, we use the sources available from Marvell Github page at https://github.com/MarvellEmbeddedProcessors, which uses: - - Linux v4.4.52 - - U-Boot v2017.03 + - Linux v4.4.120 + - U-Boot v2018.03 -At the moment mainline support for the board is a work in progress. -Mainline kernel 4.15 enables eth2 in 1Gb (RJ45 connector J5) and -eth0 in 10Gb (SFP connector CON15 and RJ45 connector CON16). -The vendor BSP enables more hardware features out of the box, -e.g. all the network interfaces. +At the moment mainline support for the board is a work in +progress. Mainline kernel 4.19 enables eth2 in 1Gb (RJ45 connector J5), +copper 10Gb interfaces, and automatic configuration of select SFP +modules on the SFP cages. The vendor BSP enables more hardware features +out of the box, but lacks support for SFP detection and automatic +configuration. To use the mainline BSP run the following commands: @@ -73,10 +74,13 @@ Insert the micro SDcard in the MacchiatoBin board and power it up. The serial console is accessible at the micro-USB Type-B connector marked CON9. The serial line settings are 115200 8N1. -By default U-Boot will load its environment from the SPI flash. On the -first boot SPI flash may be empty or it may contain a legacy -environment incompatible with up-to-date mainline U-Boot and -kernel. Then the following commands can be used to boot the board: +Note: the following text only applies to the vendor BSP from +solidrun_macchiatobin_marvell_defconfig. + +By default Marvell provided U-Boot will load its environment from the +SPI flash. On the first boot SPI flash may be empty or it may contain a +legacy environment that prevents proper boot. Then the following +commands can be used to boot the board: => ext4load mmc 1:1 0x01700000 /boot/uEnv-example.txt => env import -t 0x01700000 $filesize -- cgit v1.2.1 From 91887cf778081d31b408d8f527eb4bc24fdcb1d8 Mon Sep 17 00:00:00 2001 From: Peter Korsgaard Date: Fri, 23 Nov 2018 08:51:13 +0100 Subject: orangepi_pc_defconfig: bump linux to 4.19.3, u-boot to 2018.11 4.18 brought cpufreq support for H3, but sunxi_defconfig does not enable the driver for the sy8106a regulator used on the board or enable the ondemand cpufreq govenor so the frequency is dynamically adjusted - So enable these in linux.fragment. Signed-off-by: Peter Korsgaard Signed-off-by: Thomas Petazzoni --- board/orangepi/orangepi-pc/linux.fragment | 2 ++ 1 file changed, 2 insertions(+) (limited to 'board') diff --git a/board/orangepi/orangepi-pc/linux.fragment b/board/orangepi/orangepi-pc/linux.fragment index cdd522452a..581b715bd5 100644 --- a/board/orangepi/orangepi-pc/linux.fragment +++ b/board/orangepi/orangepi-pc/linux.fragment @@ -1,3 +1,5 @@ +CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND=y +CONFIG_REGULATOR_SY8106A=y CONFIG_DRM_SUN8I_DW_HDMI=y CONFIG_SUN8I_DE2_CCU=y CONFIG_SND_SUN8I_CODEC_ANALOG=y -- cgit v1.2.1 From aabd7f6ad02a3c533fc7dbb549102b2c47887360 Mon Sep 17 00:00:00 2001 From: Peter Korsgaard Date: Fri, 23 Nov 2018 08:51:14 +0100 Subject: orangepi_zero_defconfig: bump linux to 4.19.3, u-boot to 2018.11 4.18 brought cpufreq support for H3, but sunxi_defconfig does not enable the ondemand cpufreq govenor so the frequency is dynamically adjusted - So enable it in linux-extra.config. Signed-off-by: Peter Korsgaard Signed-off-by: Thomas Petazzoni --- board/orangepi/orangepi-zero/linux-extras.config | 3 +++ 1 file changed, 3 insertions(+) (limited to 'board') diff --git a/board/orangepi/orangepi-zero/linux-extras.config b/board/orangepi/orangepi-zero/linux-extras.config index fe00af5ef7..2db241de28 100644 --- a/board/orangepi/orangepi-zero/linux-extras.config +++ b/board/orangepi/orangepi-zero/linux-extras.config @@ -15,3 +15,6 @@ CONFIG_CFG80211_WEXT=y # wireless drivers CONFIG_WLAN=y + +# ondemand cpufreq governor +CONFIG_CPU_FREQ_DEFAULT_GOV_ONDEMAND=y -- cgit v1.2.1 From 9fb2a489598e82497f79f144b2374241e4912575 Mon Sep 17 00:00:00 2001 From: Erico Nunes Date: Thu, 27 Sep 2018 00:37:18 +0200 Subject: configs/aarch64_efi_defconfig: new defconfig New generic defconfig for aarch64, to run on aarch64 servers compliant with EFI firmware and ACPI. This can also be tested with qemu, and is useful so that we have an arm defconfig with grub enabled. Tested with qemu 2.11.2 and AAVMF, the aarch64 virtual machine UEFI firmware. Signed-off-by: Erico Nunes [Thomas: extend readme.txt with more details] Signed-off-by: Thomas Petazzoni --- board/aarch64-efi/genimage-efi.cfg | 30 ++++++++++++++++++++++++++++++ board/aarch64-efi/grub.cfg | 6 ++++++ board/aarch64-efi/post-image.sh | 5 +++++ board/aarch64-efi/readme.txt | 34 ++++++++++++++++++++++++++++++++++ 4 files changed, 75 insertions(+) create mode 100644 board/aarch64-efi/genimage-efi.cfg create mode 100644 board/aarch64-efi/grub.cfg create mode 100755 board/aarch64-efi/post-image.sh create mode 100644 board/aarch64-efi/readme.txt (limited to 'board') diff --git a/board/aarch64-efi/genimage-efi.cfg b/board/aarch64-efi/genimage-efi.cfg new file mode 100644 index 0000000000..f93ab9d64f --- /dev/null +++ b/board/aarch64-efi/genimage-efi.cfg @@ -0,0 +1,30 @@ +image efi-part.vfat { + vfat { + file startup.nsh { + image = "efi-part/startup.nsh" + } + file EFI { + image = "efi-part/EFI" + } + file Image { + image = "Image" + } + } + size = 32M +} + +image disk.img { + + hdimage { + } + + partition boot { + partition-type = 0xEF + image = "efi-part.vfat" + } + + partition root { + partition-type = 0x83 + image = "rootfs.ext2" + } +} diff --git a/board/aarch64-efi/grub.cfg b/board/aarch64-efi/grub.cfg new file mode 100644 index 0000000000..ab88da91b9 --- /dev/null +++ b/board/aarch64-efi/grub.cfg @@ -0,0 +1,6 @@ +set default="0" +set timeout="5" + +menuentry "Buildroot" { + linux /Image root=/dev/vda2 rootwait console=ttyAMA0 +} diff --git a/board/aarch64-efi/post-image.sh b/board/aarch64-efi/post-image.sh new file mode 100755 index 0000000000..f0214dc866 --- /dev/null +++ b/board/aarch64-efi/post-image.sh @@ -0,0 +1,5 @@ +#!/bin/sh + +BOARD_DIR="$(dirname $0)" + +cp -f ${BOARD_DIR}/grub.cfg ${BINARIES_DIR}/efi-part/EFI/BOOT/grub.cfg diff --git a/board/aarch64-efi/readme.txt b/board/aarch64-efi/readme.txt new file mode 100644 index 0000000000..65a6345b6c --- /dev/null +++ b/board/aarch64-efi/readme.txt @@ -0,0 +1,34 @@ + +The aarch64_efi_defconfig allows to build a minimal Linux system that +can boot on all AArch64 servers providing an EFI firmware and ACPI. + +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 \ + -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 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 . -- cgit v1.2.1