armbian-build/config/boards/odroidhc4.conf
Ricardo Pardini 2079811064
meson64: bump u-boot to 2021.07 // HC4/N2(+) cleanups (#3155)
* meson64: bump u-boot to 2021.07, rework patches

- as always based on chewitt's tree, with differences:
  - squashed versions of HC4+SATA, Radxa Zero, DT tree sync patches
    - so that DTB/config/code changes related to the same feature/board are grouped
  - removed documentation changes and Makefile reordering patches

Signed-off-by: Ricardo Pardini <ricardo@pardini.net>

* meson64: ODROID HC4/N2: simplify/remove board vs family hacks; better SPI support

- thanks to mainline 2021.07 u-boot and it's HC4 config we can remove the conditionals
- boards now define the u-boot vars instead of conditionals in family
- on the HC4, build u-boot twice: one for SD (old C4 config) and one for HC4 (new SATA/SPI config)
  - reason is that the HC4 version does not work very well unless it is actually booted from SPI
- meson64_common: don't override UBOOT_TARGET_MAP if board-defined
  - but the default UBOOT_TARGET_MAP is still defined if the board didn't
- (sneakily) add lm-sensors fancontrol to the HC4's board packages

Signed-off-by: Ricardo Pardini <ricardo@pardini.net>
2021-09-26 20:47:33 +02:00

20 lines
965 B
Plaintext

# Amlogic S905X3 quad core 4GB RAM SoC GBE USB3 SPI 2 x SATA
BOARD_NAME="Odroid HC4"
BOARDFAMILY="meson-sm1"
BOOTCONFIG="odroid-c4_defconfig" # But also 'odroid-hc4_defconfig', see below at UBOOT_TARGET_MAP
KERNEL_TARGET="legacy,current,edge"
FULL_DESKTOP="no"
SERIALCON="ttyAML0"
BOOT_FDT_FILE="amlogic/meson-sm1-odroid-hc4.dtb"
PACKAGE_LIST_BOARD="mtd-utils lm-sensors fancontrol" # SPI, sensors, manual fan control via 'pwmconfig'
# We build u-boot twice: C4 config for SD cards, and HC4 (with SATA) config for SPI.
# To be able to flash to SPI (via nand-sata-install), you need to use the C4 (SD) version.
UBOOT_TARGET_MAP="odroid-c4_defconfig u-boot-dtb.img;;u-boot.bin.sd.bin:u-boot.bin u-boot-dtb.img
odroid-hc4_defconfig u-boot-dtb.img;;u-boot.bin:u-boot-spi.bin"
# The SPI version (u-boot-spi.bin, built from odroid-hc4_defconfig above) is then used by nand-sata-install
function write_uboot_platform_mtd() {
dd if=$1/u-boot-spi.bin of=/dev/mtdblock0
}