mediatek: rework support for BananaPi BPi-R64
**What's new**
* Bring support for the Bananapi BPi-R64 to the level desirable for
a nice hackable routerboard.
* Use ARM Trusted Firmware A from source. (goodbye binary preloader)
* Use Das U-Boot from source. (see previous commit)
* Assemble SD-card image using OpenWrt image-commands.
(no gen_sd_cruz_foo.sh added, this is not Raspbian)
* Updated kernel options to support root filesystem.
* Updated DTS to match OpenWrt LAN ports, known LEDs, buttons, ...
* Detect root device, handle sysupgrade, config restore, ...
* Wire up (known) LEDs and buttons in OpenWrt-fashion.
* Build one set of images from SD-card and eMMC.
* Hopefully provide a good example of how things can be done right
from scratch.
**Installation and images**
* Have an empty SD-card at hand
* Write stuff to the card, as root (card device is /dev/mmcblkX)
- write header, gpt, bl2, atf, u-boot and recovery kernel:
`cat *bpi-r64-boot-sdcard.img *bpi-r64-initramfs-recovery.fit > /dev/mmcblkX`
- rescan partitions:
`blockdev --rereadpt /dev/mmcblkX`
- write main system to production partition:
`cat *bpi-r64-squashfs-sysupgrade.fit > /dev/mmcblkXp5`
* Installation to eMMC works using SD-card bootloader via TFTP
When running OpenWrt of SD-card, issue this to trigger installation
to eMMC:
`fw_setenv bootcmd run emmc_init`
Be prepared to serve the content of bin/targets/mediatek/mt7622 on
TFTP server address 192.168.1.254.
**What's missing**
* The red LED is always on, probably a hardware bug.
* AHCI (probably needs DTS changes)
* Ship SD-card image ready with every needed for eMMC install.
* The eMMC has a second, currently unused boot partition. This would
be ideal to store the WiFi EEPROM and Ethernet MAC address(es).
@sinovoip ideas?
Thanks to Thomas Hühn @thuehn for providing the hardware!
Signed-off-by:
Daniel Golle <daniel@makrotopia.org>
Showing
- target/linux/mediatek/dts/mt7622-bananapi-bpi-r64-rootdisk.dts 0 additions, 18 deletions...t/linux/mediatek/dts/mt7622-bananapi-bpi-r64-rootdisk.dts
- target/linux/mediatek/image/gen_mt7622_emmc_img.sh 0 additions, 19 deletionstarget/linux/mediatek/image/gen_mt7622_emmc_img.sh
- target/linux/mediatek/image/mt7622.mk 43 additions, 20 deletionstarget/linux/mediatek/image/mt7622.mk
- target/linux/mediatek/mt7622/base-files/etc/board.d/02_network 0 additions, 1 deletion...t/linux/mediatek/mt7622/base-files/etc/board.d/02_network
- target/linux/mediatek/mt7622/base-files/lib/upgrade/platform.sh 51 additions, 12 deletions.../linux/mediatek/mt7622/base-files/lib/upgrade/platform.sh
- target/linux/mediatek/mt7622/config-5.10 1 addition, 0 deletionstarget/linux/mediatek/mt7622/config-5.10
- target/linux/mediatek/mt7622/target.mk 1 addition, 1 deletiontarget/linux/mediatek/mt7622/target.mk
- target/linux/mediatek/patches-5.10/112-dts-fix-bpi64-lan-names.patch 29 additions, 0 deletions...x/mediatek/patches-5.10/112-dts-fix-bpi64-lan-names.patch
- target/linux/mediatek/patches-5.10/112-dts-fix-bpi64-leds-and-buttons.patch 56 additions, 0 deletions...tek/patches-5.10/112-dts-fix-bpi64-leds-and-buttons.patch
- target/linux/mediatek/patches-5.10/602-arm64-dts-mediatek-Split-PCIe-node-for-MT2712-MT7622.patch 1 addition, 1 deletion...rm64-dts-mediatek-Split-PCIe-node-for-MT2712-MT7622.patch
Loading
Please register or sign in to comment