aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ath79/dts/qca955x_senao_loader.dtsi
Commit message (Collapse)AuthorAgeFilesLines
* ath79: move pcie node to DTSI for qca955x Senao APsMichael Pratt2021-04-081-0/+9
| | | | | | | | | | pcie0 is the same for this generation of Senao APs while eth0, eth1, and wmac can differ the qca,no-eeprom property has no effect for the ath10k drivers Signed-off-by: Michael Pratt <mcpratt@pm.me>
* ath79: add Senao 'failsafe' sysupgrade procedureMichael Pratt2021-04-081-1/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Use a similar upgrade method for sysupgrade.bin, like factory.bin, for Senao boards with the tar.gz OEM upgrade platform, and 'failsafe' image which is loaded on checksum failure. This is inspired by the OEM upgrade script /etc/fwupgrade.sh and the existing platforms for dual-boot Senao boards. Previously, if the real kernel was damaged or missing the only way to recover was with UART serial console, because the OKLI lzma-loader is programmed to halt. uboot did not detect cases where kernel or rootfs is damaged and boots OKLI instead of the failsafe image, because the checksums stored in uboot environment did not include the real kernel and rootfs space. Now, the stored checksums include the space for both the lzma-loader, kernel, and rootfs. Therefore, these boards are now practically unbrickable. Also, the factory.bin and sysupgrade.bin are now the same, except for image metadata. This allows for flashing OEM image directly from openwrt as well as flashing openwrt image directly from OEM. Make 'loader' partition writable so that it can be updated during a sysupgrade. tested with ENS202EXT v1 EAP1200H EAP350 v1 EAP600 ECB350 v1 ECB600 ENH202 v1 Signed-off-by: Michael Pratt <mcpratt@pm.me>
* ath79: remove 'fakeroot' for Senao devicesMichael Pratt2021-04-081-9/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | By using the same custom kernel header magic in both OKLI lzma-loader, DTS, and makefile this hack is not necessary anymore However, "rootfs" size and checksum must now be supplied by the factory.bin image through a script that is accepted by the OEM upgrade script. This is because Senao OEM scripts assume a squashfs header exists at the offset for the original "rootfs" partition which is actually the kernel + rootfs in this implementation, and takes size value from the header that would be there with hexdump, but this offset is now the uImage header instead. This frees up 1 eraseblock previously used by the "fakeroot" partition for bypassing the OEM image verification. Also, these Senao devices with a 'failsafe' partition and the tar-gz factory.bin platform would otherwise require flashing the new tar-gz sysupgrade.bin afterward. So this also prevents having to flash both images when starting from OEM or 'failsafe' the OEM upgrade script verifies the header magic numbers, but only the first two bytes. Example: [ "${magic_word_kernel}" = "2705" ] && [ "${magic_word_rootfs}" = "7371" -o "${magic_word_rootfs}" = "6873" ] && errcode="0" therefore picked the magic number 0x73714f4b which is 'sqOK' Signed-off-by: Michael Pratt <mcpratt@pm.me>
* ath79: create common DTSI for Senao qca955x APsAdrian Schmutzler2021-02-241-0/+89
This creates a shared DTSI for qca955x Senao/Engenius APs with concatenated firmware partition/okli loader: - EAP1200H - EnstationAC v1 To make this usable for future boards with 32 MB flash as well, split the partitions node already. Suggested-by: Michael Pratt <mcpratt@pm.me> Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>