aboutsummaryrefslogtreecommitdiff
path: root/package/boot
Commit message (Collapse)AuthorAge
* uboot-envtools: add env settings for ubnt,unifi-6-lr-v2Joel Low2024-05-06
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This has been tested on two of my Unifi 6 LR v2s: ```bash $ fw_printenv # before Cannot parse config file '/etc/fw_env.config': No such file or directory $ cat /etc/fw_env.config /dev/mtd3 0x0000 0x1000 0x1000 1 $ fw_printenv arch=arm baudrate=115200 board=mt7622_evb board_name=mt7622_evb bootcmd=bootubnt bootdelay=3 bootfile=uImage cpu=armv7 device_model=U6-LR ethact=mtk_eth ethaddr=<redacted> ethcard=AQR112C ipaddr=<redacted> is_default=true loadaddr=0x5007FF28 macaddr=<redacted> serverip=<redacted> soc=mt7622 stderr=serial stdin=serial stdout=serial vendor=mediatek is_ble_stp=true ``` I had to reverse-engineer the working settings above to the UCI script. Signed-off-by: Joel Low <joel@joelsplace.sg> Link: https://github.com/openwrt/openwrt/pull/13897 Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* uboot-envtools: filogic: add support for BananaPi R4 PoEMartin Schiller2024-05-06
| | | | | | | This adds support for the bpi-r4 variant with internal 2.5G PHY and additional ethernet port instead of second sfp. Signed-off-by: Martin Schiller <ms@dev.tdt.de>
* uboot-mediatek: bpi-r4: add support for 2.5GE PoE variantMartin Schiller2024-05-06
| | | | | | | This adds support for the bpi-r4 variant with internal 2.5G PHY and additional ethernet port instead of second sfp. Signed-off-by: Martin Schiller <ms@dev.tdt.de>
* ipq40xx: add support for Linksys WHW03 V1Rodrigo Balerdi2024-05-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Hardware: ========= SOC: Qualcomm IPQ4019 WiFi 1: QCA4019 IEEE 802.11b/g/n WiFi 2: QCA4019 IEEE 802.11a/n/ac WiFi 3: QCA9886 IEEE 802.11a/n/ac Bluetooth: Qualcomm CSR8510 (A10) Zigbee: Silicon Labs EM3581 NCP + Skyworks SE2432L Ethernet: Qualcomm Atheros QCA8072 (2-port) Flash: Samsung KLM4G1FEPD (4GB eMMC) RAM (NAND): 512MB LED Controller: NXP PCA9633 (I2C) Buttons: Single reset button (GPIO). Ethernet: ========= The device has 2 ethernet ports, configured as follows by default: - left port: WAN - right port: LAN Wifi: ===== The Wifi radios are turned off by default. To configure the router, you will need to connect your computer to the LAN port of the device. Bluetooth and Zigbee: ===================== Configuration included but not tested. Storage: ======== For compatibility with stock firmware, all of OpenWrt runs in a 136 MiB eMMC partition (of which there are two copies, see below). You can also use partition /dev/mmcblk0p19 "syscfg" (3.4 GiB) any way you see fit. During very limited tests, stock firmware did not mount this partition. However, backing up its stock content before use is recommended anyway. Firmware: ========= The device uses a dual firmware mechanism: it automatically reverts to the previous firmware after 3 failed boot attempts. You can switch to the inactive firmware copy by changing the "boot_part" U-Boot environment variable. You can also do it by turning on the device for a couple of seconds and then back off, 3 times in a row. Installation: ============= OpenWrt's "factory" image can be installed via the stock web UI: 1. Login to the UI. (The default password is printed on the label.) 2. Enter support mode by clicking on the "CA" link at the bottom. 3. Click "Connectivity", "Choose file", "Start", and ignore warnings. This port is based on work done by flipy (https://github.com/flipy). Signed-off-by: Rodrigo Balerdi <lanchon@gmail.com> Link: https://github.com/openwrt/openwrt/pull/15345 Signed-off-by: Robert Marko <robimarko@gmail.com>
* uboot-rockchip: add Bananapi-R2 Pro supportAntonio Flores2024-05-05
| | | | | | add uboot support for Bananapi-R2 Pro Signed-off-by: Antonio Flores <antflores627@gmail.com>
* grub2: add EFI support for loongarch64Weijie Gao2024-05-04
| | | | | | Add a new package for loongarch64 which only supports EFI. Signed-off-by: Weijie Gao <hackpascal@gmail.com>
* sunxi: add support for Lichee Pi Zero Dock (V3s) boardZoltan HERPAI2024-05-04
| | | | | | | | | | | | | | CPU: Allwinner V3s single-core Cortex-A7 @ 1.2GHz Memory: 64Mb DDR2 integrated into SoC package Storage: 1x SDcard on board, 1x SDcard on dock Network: 10/100M ethernet Other: 4x buttons via LRADC, CSI Flashing instructions: Standard sunxi SD card installation procedure - copy image to SD card, insert into SD card slot on the device and boot. Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
* opensbi: bump to 1.4Zoltan HERPAI2024-05-03
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Upgrade the OpenSBI firmware used by RISC-V CPUs to 1.4. Runtime-tested: - d1 (Lichee RV) - sifiveu (SiFive Unleashed) Updates since last release: 1.4: Synopsys DesignWare APB GPIO driver Zicntr and Zihpm support Console print improvements Smepmp support Simple FDT based syscon regmap driver Syscon based reboot and poweroff driver Non-contiguous hpm counters Smcntrpmf support Full sparse hartid support IPI improvements RFENCE improvements Zkr support Andes custom PMU support 1.3.1: ACLINT driver fix for disabled CPUs SBI PMU fix for out-of-bound access Designware GPIO driver 1.3: Allow platform to influence cold boot HART selection Starfive JH7110 platform support Split RX and RW firmware regions Advertise non-retentive suspend for allwinner D1 platform Byteorder/endianness conversion macros SBI debug console extension (Experimental) Configure the PMA regions for RZ/Five platform SBI system suspend extension (Experimental) SBI PMU platform firmware events (Experimental) SBI CPPC extension (Experimental) Optimized remote TLB flushes Simple heap for boot time memory allocations Bring back no-map DT property for reserved memory nodes Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
* uboot-bmips: Add U-Boot for the BMIPS targetLinus Walleij2024-05-01
| | | | | | | | This is needed to boot the BCM6238-based Inteno XG6846. Currently this is restricted to the XG6846 board. Reviewed-by: Paul Donald <newtwen+github@gmail.com> Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
* mediatek: switch to fitblk for JDCloud RE-CP-03Tianling Shen2024-04-30
| | | | | | | Use the new fitblk driver. Tested-By: Yangyu Chen <cyy@cyyself.name> Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
* arm-trusted-firmware-mvebu: refresh cryptopp hashRobert Marko2024-04-29
| | | | | | | | Well, it seems that cryptopp hash was never refreshed since calling make package/boot/arm-trusted-firmware-mvebu/check FIXUP=1 V=s does not actually refresh the download calls hashes so refresh it manually. Signed-off-by: Robert Marko <robert.marko@sartura.hr>
* arm-trusted-firmware-mvebu: use SOURCE_VERSION instead of VERSIONRobert Marko2024-04-29
| | | | | | | | | | | | Since ("download: don't overwrite VERSION variable") trying to download the required sources for mvebu ATF will fail with: Makefile:247: *** Download/mox-boot-builder is missing the SOURCE_VERSION field.. Stop. This also broke the buildbot mvebu/cortex-a53 builds. So, fix it by switching to SOURCE_VERSION instead. Signed-off-by: Robert Marko <robert.marko@sartura.hr>
* grub2: update to 2.12Weijie Gao2024-04-28
| | | | | | | | compile tested: x86_64,i386,loongarch64 Signed-off-by: Weijie Gao <hackpascal@gmail.com> {Refresh patches} Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
* uboot-mvebu: backport patch for Turris Omnia to enable LTOJosef Schlehofer2024-04-28
| | | | | | | | | | | | | | | | | Fixes issue while building package uboot-mvebu on OpenWrt 23.05: u-boot-with-spl.kwb exceeds file size limit: limit: 0xf0000 bytes actual: 0xf0100 bytes excess: 0x100 bytes make[3]: *** [Makefile:1466: u-boot-with-spl.kwb] Error 1 make[3]: *** Deleting file 'u-boot-with-spl.kwb' make[3]: Leaving directory '/workspaces/openwrt/build_dir/target-arm_cortex-a9+vfpv3-d16_musl_eabi/u-boot-omnia/u-boot-2024.04' make[2]: *** [Makefile:83: /workspaces/openwrt/build_dir/target-arm_cortex-a9+vfpv3-d16_musl_eabi/u-boot-omnia/u-boot-2024.04/.built] Error 2 Signed-off-by: Josef Schlehofer <pepe.schlehofer@gmail.com> Link: https://github.com/openwrt/openwrt/pull/15307 Signed-off-by: Robert Marko <robimarko@gmail.com>
* uboot-envtools: add env settings for Edgerouter-XTim Lunn2024-04-25
| | | | | | | | | | uboot-envtools is currently missing config for Edgerouter-X and its not immediately obvious what settings to manually apply. Provide default configuration for envtools on Edgerouter-X. Signed-off-by: Tim Lunn <tim@feathertop.org>
* oxnas: drop targetNick Hainke2024-04-24
| | | | | | | | | The Upstream Linux community has discontinued support for the target. Maintaining support for it downstream would require too much effort. Moreover, it seems that the supported hardware is no longer deemed worthy of it. Signed-off-by: Nick Hainke <vincent@systemli.org>
* ipq807x: add Spectrum SAX1V1KConnor Yoon2024-04-23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Spectrum SAX1V1K is a AX WIFI router with 3 1G and 1 2.5G ports. The router is provided to Spectrum customers. It is OEM of Askey RT5010W https://forum.openwrt.org/t/spectrum-sax1v1k-askey-rt5010w-openwrt-support/149923 It continues the original work by @MeisterLone to get this device supported. Specifications: ``` • CPU: Qualcomm IPQ8072A Quad core Cortex-A53 2.2GHz • RAM: 2048MB of DDR3 • Storage: 1024MB eMMC • Ethernet: 3x 1G RJ45 ports (QCA8075) + 1 2.5G Port (QCA8081) • WLAN: • 2.4GHz: Qualcomm QCN5024 4x4 802.11b/g/n/ax 1174 Mbps PHY rate • 5GHz: Qualcomm QCN5054 4x4 802.11a/b/g/n/ac/ax 2402 PHY rate • LED: 1 gpio-controlled dual color led (blue/red) • Buttons: 1x reset • Power: 12V DC jack ``` Notes: ``` • This commit adds only single partition support, that means sysupgrade is upgrading the current rootfs partition. • Installation can be done by serial connection only. • A poulated serial header is onboard https://forum.openwrt.org/t/spectrum-sax1v1k-askey-rt5010w-openwrt-support/149923/6 • RX/TX is working, u-boot bootwait is active, secure boot is enabled. ``` Installation Instructions: **Most part of the installation is performed from an initramfs image.** Boot initramfs : Using serial connection 1. Boot up the device and wait till it displays "VERIFY_IB: Success. verify IB ok" 2. Once that message appears, login with username 'root' password serial number of your router in uppercase. 3. Use vi to paste the 'open.sh' script from @MeisterLone github on your device https://github.com/MeisterLone/Askey-RT5010W-D187-REV6/blob/master/Patch/open.sh 4. chmod 755 open.sh 5. ./open.sh 6. Set your ip to 192.168.0.1 7. Run a TFTP server and host the initramfs image on the TFTP server and name it "recovery.img" 8. Reboot device. On boot it will try TFTP. Install OpenWrt from initramfs image: 1. Use SCP (or other way) to transfer OpenWrt factory image 2. Connect to device using SSH (on a LAN port) 3. Flash firmware: sysupgrade # sysupgrade -n -v /tmp/openwrt_sysupgrade.bin 4. Set U-boot env variable: bootcmd # fw_setenv bootcmd "run fix_uboot; run setup_and_boot" 5. Reboot the device # reboot 6. Once device is booted, residue of previous firmware will prevent openwrt to work properly. Factory Reset is MUST required # Once serial console is displaying to login, hold reset button for 10 sec 7. Now everything should be operational. Note: this PR adds only single partition support, that means sysupgrade is upgrading the current rootfs partition Signed-off-by: Connor Yoon <j_connor@taliaent.com>
* uboot-mvebu: update to version 2024.04Robert Marko2024-04-19
| | | | | | | | | Lets update to 2024.04 in order to drop all of the patches as they have been merged upstream. Tested on Methode eDPU. Signed-off-by: Robert Marko <robert.marko@sartura.hr>
* uboot-rockchip: Update to 2024.04Tianling Shen2024-04-14
| | | | | | Removed upstreamed patch. Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
* rkbin: bump to latest git HEADTianling Shen2024-04-14
| | | | | | | Fixed bugs for memory initialization/training, improved memory compatibility/stability. Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
* uboot-d1: define default BUILD_SUBTARGETTianling Shen2024-04-13
| | | | | | | | | As commit 3ce1e4c3d3da ("d1: define subtarget specifically") added the 'generic' subtarget, without 'BUILD_SUBTARGET' the correspond U-Boot package will be no longer selected automatically. Fixes: 3ce1e4c3d3da ("d1: define subtarget specifically") Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
* mediatek: filogic: add support for Edgecore EAP111Robert Marko2024-04-11
| | | | | | | | | | | | | | | | | | | HW specifications: * Mediatek MT7981A * 256MB SPI-NAND * 512MB DRAM * Uplink: 1 x 10/100/1000Base-T Ethernet, Auto MDIX, RJ-45 with 802.3at PoE (Built-in GBe PHY) * LAN: 1 x 10/100/1000Base-T Ethernet, Auto MDIX, RJ-45 (Airoha EN8801SC) * 1 Tricolor LED * Reset button * 12V/2.0A DC input Installation: Board comes with OpenWifi/TIP which is OpenWrt based, so sysupgrade can be used directly over SSH. Signed-off-by: Robert Marko <robert.marko@sartura.hr>
* at91bootstrap: update PKG_MIRROR_HASH to zstd for v3 at91bootstrapRobert Marko2024-04-07
| | | | | | | | | | | | So, when updating the hash for at91bootstrap it was done via CHECK_ALL=1 so that updated the PKG_MIRROR_HASH for the main v4 version hash, but at91bootstrap checkout version depends on the subtarget as well. Choosing to build for sam9x will change the at91bootstrap version to v3 and this hash was not refreshed thus causing the CI to fail. Fixes: 6918c637b797 ("treewide: package: update missed hashes after switch to ZSTD") Signed-off-by: Robert Marko <robimarko@gmail.com>
* treewide: package: update missed hashes after switch to ZSTDRobert Marko2024-04-07
| | | | | | | | With the switch to ZSTD for git clone packaging, hashes have changed so fixup remaining package hashes that were missed in the inital update. Fixes: b3c1c57 ("treewide: update PKG_MIRROR_HASH to zst") Signed-off-by: Robert Marko <robimarko@gmail.com>
* apm821xx: prepare WNDR4700 for 6.6 - add preliminary u-boot-env accessChristian Lamparter2024-04-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | With the default BUILD_BOT configuration on a linux 6.6 kernel, the WNDR4700's kernel no longer fits into the alloted ~3.5MiB, even with LZMA compression. Bigger kernels are possible, but there's a problem with Netgear's "bootcmd": > if loadn_dniimg 0 0x180000 0x4e0000 && chk_dniimg 0x4e0000; then nand read 0x800000 0x180000 0x20000;bootm 0x500000 - 0x800040;else fw_recovery; fi" This loads the dni-image starting offset 0x180000 from the NAND flash (which is the DTB partition) to 0x4e0000 in the RAM. It then checks whenever the provided image is "valid". If it is then it reads the DTB again to 0x800000 in the RAM and starts the extraction and boot process. (If the image wasn't valid then it starts the automated firmware recovery). The issues here are that first: the kernel image gets "squeezed" between 0x500040 and 0x7fffff... And second, the decompressor only has area 0x0 - 0x500000 for decompression. Hence the image now requires to update the bootcmd by providing new values (which have been successfully tested with the original Netgear WNDR4700 v1.0.0.56 firmware) for the RAM locations and make full use of the fact that loadn_dniimg loads the DTB as well. This needs to be done only once. Just connect a serial adapter to interface with uboot and overwrite (and save) the new bootcmd. WARNING: The serial port needs a TTL/RS-232 3.3v level converter! Steps: 0. Power-off the WNDR4700 1. Connect the serial interface (you need to open the WNDR4700) 2. Power-up the WNDR4700 3. Monitor the boot-sequence and hit "Enter"-key when it says: "Hit any key to stop autoboot" (Be quick, you have a ~2 second window) 4. in the Prompt enter the following commands (copy & paste) setenv bootcmd "if loadn_dniimg 0 0x180000 0xce0000 && chk_dniimg 0xce0000; then bootm 0xd00000 - 0xce0040;else fw_recovery; fi" saveenv run bootcmd Note: This new bootcmd will also unbrick devices that were bricked by the bigger 4.19-6.1 kernels. Note2: This method was tested with a WNDR4700. A big kernel with most debug features enabled on v6.6.22 measured 4.30 MiB when compressed with lzma. The uncompressed kernel is 12.34 MiB. This is over the 3 MiB, the device reserves for the kernel... But it booted! For bigger kernels, the device needs repartitioning of the the ubi partition due to the kernel+dtb not fitting into the partition. Note3: For initramfs development. I would advice to load the initramfs images to 0x800000 (or higher). i.e.: tftp 800000 wndr4700.bin Note4: the fw_recovery uboot command to transfer the factory image to the flash still works. Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
* qualcommax: ipq60xx: add yuncore fap650 supportIsaev Ruslan2024-04-04
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit adds support for the Yuncore FAP650 device. Specifications: - Qualcomm IPQ6018+QCA8075+QCN5022+QCN5052 - 512 MB of RAM (DDR3) - 8 MB of serial flash (SPI NOR) - 128 MB of parallel flash (NAND) - 2x2 2.4 GHz WiFi (IPQ6010) - 2x2 5 GHz WiFi (IPQ6010) - 2x 2dBi 2.4G MIMO antenna - 2x 3dBi 5.8G MIMO antenna - 5x 1 Gbps Ethernet (QCA8075) - POE: 48V (IEEE 802.3af) - power: 12V (~1.5A) - 1x passthru port (rj45 - rj45) - 1x cisco rj45 console port - size: 160mm*86mm*29mm BACKUP YOUR STOCK FIRMWARE: ``` export device=fap650 mkdir -p /tmp/fw_dump_$device cd /tmp/fw_dump_$device dmesg > dmesg_$device.log dtc -I fs /sys/firmware/devicetree/base > $device.dts cat /proc/device-tree/model > model cat /proc/mtd > proc_mtd while read p; do mtd_dev=$(echo $p | cut -d: -f1) echo $mtd_dev dd if=/dev/$mtd_dev of=$mtd_dev done < proc_mtd md5sum * > md5sum.log tar -cvzf ../$device.tar.gz . export sum=$(md5sum /tmp/$device.tar.gz | cut -d' ' -f1) mv ../$device.tar.gz /tmp/${device}_${sum}.tar.gz echo fw backup saved to: /tmp/${device}_${sum}.tar.gz ``` Upload your backup via tftp to the safe place. INSTALLATION: 1. stock firmware web ui Rename factory.bin fw image file to factory.ubin. Flash this image like ordinary stock fw upgrade. 2. stock firmware telnet method Enter telnet cli (login: root, password: 476t*_f0%g09y) and upload factory.bin fw image and rename it to factory.ubin `cd /tmp && wget <your_web_server_ip>/factory.ubin` `sysupgrade factory.ubin 3. initramfs method Put imitramfs image to your TFTP server and rename it for example to fap650.initram Enable serial console and enter to the u-boot cli. Exec these commands: `tftpboot <your_tftp_server_ip>:fap650.initram` `dhcp` When downloading is finished: `bootm` After booting the device, you need to upload to the device factory.ubi fw image. ``` cd /tmp && wget <your_web_server_ip>/factory.ubi` export rootfs=$(cat /proc/mtd | grep rootfs | cut -d: -f1) export rootfs_1=$(cat /proc/mtd | grep rootfs_1 | cut -d: -f1) ubiformat /dev/${rootfs} -y -f factory.ubi ubiformat /dev/${rootfs_1} -y -f factory.ubi reboot ``` 4. u-boot factory.ubi image method Put factory.ubi to your TFTP server Enter u-boot cli and exec these commands: `tftpboot <your_tftp_server_ip>:factory.ubi` `dhcp` After downloading is finished: `flash rootfs` `flash rootfs_1` `reset` STOCK FIRMWARE RECOVERY: Boot initramfs image. Upload your rootfs mtd partition to the device using scp or download it from the device using wget. Enter device ssh cli and exec: ``` cd /tmp && wget <your_web_server_ip>/rootfs_mtd` export rootfs=$(cat /proc/mtd | grep rootfs | cut -d: -f1) export rootfs_1=$(cat /proc/mtd | grep rootfs_1 | cut -d: -f1) ubiformat /dev/${rootfs} -y -f /tmp/rootfs_mtd ubiformat /dev/${rootfs_1} -y -f /tmp/rootfs_mtd reboot ``` Signed-off-by: Isaev Ruslan <legale.legale@gmail.com>
* mediatek: add support for OpenEmbed SOM7981Tianling Shen2024-03-31
| | | | | | | | | | | | | | | | | | | | | | | Hardware specification: SoC: MediaTek MT7981B 2x A53 Flash: 256 MiB SPI-NAND, 32 GB eMMC optional RAM: 0.5/1 GB DDR4 Ethernet: 1x 1GbE, 1x 2.5GbE (RTL8221B) WiFi: MediaTek MT7976C USB: 1x USB 3.0 GPIO: 26-Pin header UART: 6 GND, 8 TX, 10 RX (in Pin header) Button: Reset, WPS Power: Type-C PD Installation: The board comes with a third-party custom OpenWrt image, you can upload sysupgrade image via LuCI directly WITHOUT keeping configurations. Or power on the board with pressing reset button for 5 second, then visit http://192.168.1.1 and upload -factory.bin firmware. Signed-off-by: Tianling Shen <cnsztl@gmail.com>
* filogic: Add support for D-Link AQUILA PRO AI M30Roland Reinl2024-03-31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Specification: - MT7981 CPU using 2.4GHz and 5GHz WiFi (both AX) - MT7531 switch - 512MB RAM - 128MB NAND flash with two UBI partitions with identical size - 1 multi color LED (red, green, blue, white) connected via GCA230718 - 3 buttons (WPS, reset, LED on/off) - 1 1Gbit WAN port - 4 1Gbit LAN ports Disassembly: - There are four screws at the bottom: 2 under the rubber feets, 2 under the label. - After removing the screws, the white plastic part can be shifted out of the blue part. - Be careful because the antennas are mounted on the side and the top of the white part. Serial Interface - The serial interface can be connected to the 4 pin holes on the side of the board. - Pins (from front to rear): - 3.3V - RX - TX - GND - Settings: 115200, 8N1 MAC addresses: - WAN MAC is stored in partition "Odm" at offset 0x81 - LAN (as printed on the device) is WAN MAC + 1 - WLAN MAC (2.4 GHz) is WAN MAC + 2 - WLAN MAC (5GHz) is WAN MAC + 3 Flashing via Recovery Web Interface: - The recovery web interface always flashes to the currently active partition. - If OpenWrt is flahsed to the second partition, it will not boot. - Ensure that you have an OEM image available (encrypted and decrypted version). Decryption is described in the end. - Set your IP address to 192.168.200.10, subnetmask 255.255.255.0 - Press the reset button while powering on the device - Keep the reset button pressed until the LED blinks red - Open a Chromium based and goto http://192.168.200.1 (recovery web interface) - Download openwrt-mediatek-filogic-dlink_aquila-pro-ai-m30-a1-squashfs-recovery.bin - The recovery web interface always reports successful flashing, even if it fails - After flashing, the recovery web interface will try to forward the browser to 192.168.0.1 (can be ignored) - If OpenWrt was flashed to the first partition, OpenWrt will boot (The status LED will start blinking white and stay white in the end). In this case you're done and can use OpenWrt. - If OpenWrt was flashed to the second partition, OpenWrt won't boot (The status LED will stay red forever). In this case, the following steps are reuqired: - Start the web recovery interface again and flash the **decrypted OEM image**. This will be flashed to the second partition as well. The OEM firmware web interface is afterwards accessible via http://192.168.200.1. - Now flash the **encrypted OEM image** via OEM firmware web interface. In this case, the new firmware is flashed to the first partition. After flashing and the following reboot, the OEM firmware web interface should still be accessible via http://192.168.200.1. - Start the web recovery interface again and flash the OpenWrt recovery image. Now it will be flashed to the first partition, OpenWrt will boot correctly afterwards and is accessible via 192.168.1.1. Flashing via U-Boot: - Open the case, connect to the UART console - Set your IP address to 192.168.200.2, subnet mask 255.255.255.0. Connect to one of the LAN interfaces of the router - Run a tftp server which provides openwrt-mediatek-filogic-dlink_aquila-pro-ai-m30-a1-initramfs-kernel.bin. - Power on the device and select "7. Load image" in the U-Boot menu - Enter image file, tftp server IP and device IP (if they differ from the default). - TFTP download to RAM will start. After a few seconds OpenWrt initramfs should start - The initramfs is accessible via 192.168.1.1, change your IP address accordingly (or use multiple IP addresses on your interface) - Perform a sysupgrade using openwrt-mediatek-filogic-dlink_aquila-pro-ai-m30-a1-squashfs-sysupgrade.bin - Reboot the device. OpenWrt should start from flash now Revert back to stock using the Recovery Web Interface: - Set your IP address to 192.168.200.2, subnetmask 255.255.255.0 - Press the reset button while powering on the device - Keep the reset button pressed until the LED blinks red - Open a Chromium based and goto http://192.168.200.1 (recovery web interface) - Flash a decrypted firmware image from D-Link. Decrypting an firmware image is described below. Decrypting a D-Link firmware image: - Download https://github.com/RolandoMagico/firmware-utils/blob/M32/src/m32-firmware-util.c - Compile a binary from the downloaded file, e.g. gcc m32-firmware-util.c -lcrypto -o m32-firmware-util - Run ./m32-firmware-util M30 --DecryptFactoryImage <OriginalFirmware> <OutputFile> - Example for firmware M30A1_FW101B05: ./m32-firmware-util M30 --DecryptFactoryImage M30A1_FW101B05\(0725091522\).bin M30A1_FW101B05\(0725091522\)_decrypted.bin Flashing via OEM web interface is not possible, as it will change the active partition and OpenWrt is only running on the first UBI partition. Controlling the LEDs: - The LEDs are controlled by a chip called "GCA230718" which is connected to the main CPU via I2C (address 0x40) - I didn't find any documentation or driver for it, so the information below is purely based on my investigations - If there is already I driver for it, please tell me. Maybe I didn't search enough - I implemented a kernel module (leds-gca230718) to access the LEDs via DTS - The LED controller supports PWM for brightness control and ramp control for smooth blinking. This is not implemented in the driver - The LED controller supports toggling (on -> off -> on -> off) where the brightness of the LEDs can be set individually for each on cycle - Until now, only simple active/inactive control is implemented (like when the LEDs would have been connected via GPIO) - Controlling the LEDs requires three sequences sent to the chip. Each sequence consists of - A reset command (0x81 0xE4) written to register 0x00 - A control command (for example 0x0C 0x02 0x01 0x00 0x00 0x00 0xFF 0x01 0x00 0x00 0x00 0xFF 0x87 written to register 0x03) - The reset command is always the same - In the control command - byte 0 is always the same - byte 1 (0x02 in the example above) must be changed in every sequence: 0x02 -> 0x01 -> 0x03) - byte 2 is set to 0x01 which disables toggling. 0x02 would be LED toggling without ramp control, 0x03 would be toggling with ramp control - byte 3 to 6 define the brightness values for the LEDs (R,G,B,W) for the first on cycle when toggling - byte 7 defines the toggling frequency (if toggling enabled) - byte 8 to 11 define the brightness values for the LEDs (R,G,B,W) for the second on cycle when toggling - byte 12 is constant 0x87 Comparison to M32/R32: - The algorithms for decrypting the OEM firmware are the same for M30/M32/R32, only the keys differ - The keys are available in the GPL sources for the M32 - The M32/R32 contained raw data in the firmware images (kernel, rootfs), the R30 uses a sysupgrade tar instead - Creation of the recovery image is quite similar, only the header start string changes. So mostly takeover from M32/R32 for that. - Turned out that the bytes at offset 0x0E and 0x0F in the recovery image header are the checksum over the data area - This checksum was not checked in the recovery web interface of M32/R32 devices, but is now active in R30 - I adapted the recovery image creation to also calculate the checksum over the data area - The recovery image header for M30 contains addresses which don't match the memory layout in the DTS. The same addresses are also present in the OEM images - The recovery web interface either calculates the correct addresses from it or has it's own logic to determine where which information must be written Signed-off-by: Roland Reinl <reinlroland+github@gmail.com>
* ath79: add support for Huawei AP5030DNMarco von Rosenberg2024-03-31
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Huawei AP5030DN is a dual-band, dual-radio 802.11ac Wave 1 3x3 MIMO enterprise access point with two Gigabit Ethernet ports and PoE support. Hardware highlights: - CPU: QCA9550 SoC at 720MHz - RAM: 256MB DDR2 - Flash: 32MB SPI-NOR - Wi-Fi 2.4GHz: QCA9550-internal radio - Wi-Fi 5GHz: QCA9880 PCIe WLAN SoC - Ethernet 1: 10/100/1000 Mbps Ethernet through Broadcom B50612E PHY - Ethernet 2: 10/100/1000 Mbps Ethernet through Marvell 88E1510 PHY - PoE: input through Ethernet 1 port - Standalone 12V/2A power input - Serial console externally available through RJ45 port - External watchdog: SGM706 (1.6s timeout) Serial console: 9600n8 (9600 baud, no stop bits, no parity, 8 data bits) MAC addresses: Each device has 32 consecutive MAC addresses allocated by the vendor, which don't overlap between devices. This was confirmed with multiple devices with consecutive serial numbers. The MAC address range starts with the address on the label. To be able to distinguish between the interfaces, the following MAC address scheme is used: - eth0 = label MAC - eth1 = label MAC + 1 - radio0 (Wi-Fi 5GHz) = label MAC + 2 - radio1 (Wi-Fi 2.4GHz) = label MAC + 3 Installation: 0. Connect some sort of RJ45-to-USB adapter to "Console" port of the AP 1. Power up the AP 2. At prompt "Press f or F to stop Auto-Boot in 3 seconds", do what they say. Log in with default admin password "admin@huawei.com". 3. Boot the OpenWrt initramfs from TFTP using the hidden script "run ramboot". Replace IP address as needed: > setenv serverip 192.168.1.10 > setenv ipaddr 192.168.1.1 > setenv rambootfile openwrt-ath79-generic-huawei_ap5030dn-initramfs-kernel.bin > saveenv > run ramboot 4. Optional but recommended as the factory firmware cannot be downloaded publicly: Back up contents of "firmware" partition using the web interface or ssh: $ ssh root@192.168.1.1 cat /dev/mtd11 > huawei_ap5030dn_fw_backup.bin 5. Run sysupgrade using sysupgrade image. OpenWrt shall boot from flash afterwards. Return to factory firmware (using firmware upgrade package downloaded from non-public Huawei website): 1. Start a TFTP server in the directory where the firmware upgrade package is located 2. Boot to u-boot as described above 3. Install firmware upgrade package and format the config partitions: > update system FatAP5X30XN_SOMEVERSION.bin > format_fs Return to factory firmware (from previously created backup): 1. Copy over the firmware partition backup to /tmp, for example using scp 2. Use sysupgrade with force to restore the backup: sysupgrade -F huawei_ap5030dn_fw_backup.bin 3. Boot AP to U-Boot as described above Quirks and known issues ----------------------- - On initial power-up, the Huawei-modified bootloader suspends both ethernet PHYs (it sets the "Power Down" bit in the MII control register). Unfortunately, at the time of the initial port, the kernel driver for the B50612E/BCM54612E PHY behind eth0 doesn't have a resume callback defined which would clear this bit. This makes the PHY unusable since it remains suspended forever. This is why the backported kernel patches in this commit are required which add this callback and for completeness also a suspend callback. - The stock firmware has a semi dual boot concept where the primary kernel uses a squashfs as root partition and the secondary kernel uses an initramfs. This dual boot concept is circumvented on purpose to gain more flash space and since the stock firmware's flash layout isn't compatible with mtdsplit. - The external watchdog's timeout of 1.6s is very hard to satisfy during bootup. This is why the GPIO15 pin connected to the watchdog input is configured directly in the LZMA loader to output the CPU_CLK/4 signal which keeps the watchdog happy until the wdt-gpio kernel driver takes over. Because it would also take too long to read the whole kernel image from flash, the uImage header only includes the loader which then reads the kernel image from flash after GPIO15 is configured. Signed-off-by: Marco von Rosenberg <marcovr@selfnet.de> [fixed 6.6 backport patch naming] Signed-off-by: David Bauer <mail@david-bauer.net>
* uboot-envtools: ath79: remove D-Link DIR-8x9 and DAP-1720 env configShiji Yang2024-03-30
| | | | | | | The uboot-envtools can automatically parse the dts 'u-boot,env' compatible string. So the env config file is now useless. Signed-off-by: Shiji Yang <yangshiji66@qq.com>
* uboot-mediatek: add Netcore N60 supportChukun Pan2024-03-29
| | | | | | | The vendor uboot requires special fit verification. So add a custom uboot build for this device. Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
* sunxi: add support for Orange Pi Zero 3Chukun Pan2024-03-26
| | | | | | | | | | | | | | | | Key features: Allwinner H618 SoC (Quad core Cortex-A53) 1/1.5/2/4 GiB LPDDR4 DRAM 1 USB 2.0 type C port (Power + OTG) 1 USB 2.0 host port 1Gbps Ethernet port Micro-HDMI port MicroSD slot Installation: Write the image to SD Card with dd. Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
* uboot-sunxi: bump to 2024.01Chukun Pan2024-03-26
| | | | | | | | | | | | This version supports LPDDR4 DRAM of H618 SoC. Runtime-tested: Olimex Olinuxino Micro (A20) Orange Pi Zero 3 (H618) Pine64 SoPine (A64) Tested-by: Zoltan HERPAI <wigyori@uid0.hu> Signed-off-by: Chukun Pan <amadeus@jmu.edu.cn>
* treewide: update PKG_MIRROR_HASH after APK version schemaPaul Spooren2024-03-25
| | | | | | | | | | With the change in version schema the downloaded files changed, too, mostly the hash is now prefixed with a tilde `~` instead of a dash `-`. Since each downloaded archive contains folder with the same name as the archive, the checksum changed. Signed-off-by: Paul Spooren <mail@aparcar.org>
* kirkwood: add ix4-200d support to uboot-envtoolsSander van Deijck2024-03-23
| | | | | | This adds support for the Iomega ix4-200d device in uboot-envtools. Signed-off-by: Sander van Deijck <sander@vandeijck.com>
* uboot-rockchip: add Radxa E25 board supportMarius Durbaca2024-03-23
| | | | | | | add Radxa E25 board support in uboot-rockchip Signed-off-by: Marius Durbaca <mariusd84@gmail.com> Reviewed-by: Tianling Shen <cnsztl@immortalwrt.org>
* uboot-mediatek: add support for GD5F1GQ5UEChuanhong Guo2024-03-21
| | | | | | | This patch adds support for GigaDevice GD5F1GQ5UExxG to the mtk-snfi driver in u-boot. Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
* uboot-mediatek: add Redmi AX6S as UBI loaderChuanhong Guo2024-03-21
| | | | | | | | | Add support for Xiaomi Redmi AX6S to be used as a second-stage UBI loader. The defconfig/env is minimal: Boot fit from UBI. If that failed, load and boot initramfs image from TFTP. Signed-off-by: Chuanhong Guo <gch981213@gmail.com>
* kirkwood: add support for Netgear Stora (MS2000/2110) NASZoltan HERPAI2024-03-17
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Dual-slot NAS based on Marvell Kirkwood. Specifications: - Marvell 88F6281 @1GHz - 128Mb RAM - 256Mb NAND - 1x GbE LAN (Marvell 88E1116) - 1x USB 2.0 - 2x SATA - PCF8563 RTC - LM75 sensor - TC654 PWM fan controller - Serial on J2 (115200,8n1) - Newer bootROM so kwboot-ing via serial is possible Installation: 1. Serial console - Connect your levelshifter to the serial console on J2 (refer to the wiki page for pinout) 2. Update u-boot - Download the u-boot.kwb image for the device - Powercycle the NAS - Run "kwboot -b ./u-boot.kwb /dev/ttyUSB0 -p" - Connect to the serial console with minicom - tftp 0x0800000 netgear_stora-u-boot.kwb - nand erase 0x0 100000 - nand write 0x0800000 0x0 0x100000 - reset 3. Install OpenWrt - Boot up the initramfs image - tftpboot 0x800000 openwrt-kirkwood-netgear_stora-initramfs-uImage; bootm 0x800000 - Download the sysupgrade image and perform sysupgrade The fan is controlled in 3 stages by a script running every minute from cron, measuring the CPU temperature. Snippets taken from bodhi <mibodhi@gmail.com> Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
* uboot-mediatek: fix typo patch filenameDaniel Golle2024-03-11
| | | | | | 311-mt7986-select-roodisk.patch -> 311-mt7986-select-rootdisk.patch Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* uboot-mediatek: fix patch orderDaniel Golle2024-03-11
| | | | | | | Make sure patch sequence number is unique by moving patch 440-add-jdcloud_re-cp-03.patch -> 441-add-jdcloud_re-cp-03.patch Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* ramips: rename mtd partition of ipTIME NAND devicesSungbo Eo2024-03-10
| | | | | | | | | | | | Contrary to common ipTIME NOR devices, the "Config" partition of T5004 and AX2004M contain normal U-Boot environment variables. Renaming the partition into "u-boot-env" serves for better description, and it also conforms to common naming practice in OpenWrt. This patch might also be extended to A3004T, but its u-boot-env partition layout has not been confirmed yet. Signed-off-by: Sungbo Eo <mans0n@gorani.run>
* uboot-mediatek: add 'rootwait' to bootargs where neededDaniel Golle2024-03-09
| | | | | | | | Probing of the fitblk driver in some situations happens after Linux attempts to mount rootfs, which then fails. Always use 'rootwait' kernel parameter when using fitblk for rootfs. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* qualcommax: ipq60xx: add support for netgear wax214Dirk Buchwalder2024-03-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Netgear WAX214 is a 802.11 ax dual-band AP with PoE. (similar to Engenius EWS357APV3) Specifications: • CPU: Qualcomm IPQ6010 Quad core Cortex-A53 • RAM: 512MB of DDR3 • Storage: 128MB NAND (Macronix MX30UF1G18AC) • Ethernet: 1x 1G RJ45 port (QCA8072) PoE • WIFI: 2.4GHz: Qualcomm QCN5022 2x2 802.11b/g/n/ax 574 Mbps PHY rate 5GHz: Qualcomm QCN5052 2x2 802.11a/b/g/n/ac/ax 1201 PHY rate • LEDs: 4 x GPIO-controlled LEDs - 1 Power LED (orange) - 1 LAN LED (blue) - 1 WIFI 5g LED (blue) - 1 WIFI 2g LED (blue) black_small_square Buttons: 1x soft reset black_small_square Power: 12V DC jack or PoE (802.3af ) An populated serial header is onboard, format is 1.25mm 4p (DF13A-4P-1.25H) RX/TX is working, bootwait is active, secure boot is not enabled. The root password of the stock firmware is unknown, but failsafe mode can be entered to reset the password. Installation Instructions: - obtain serial access - stop auto boot (press "4", Entr boot command line interface) - setenv active_fw 0 (to boot from the primary rootfs, or set to 1 to boot from the secondary rootfs partition) - saveenv - tftpboot the initramfs image - bootm - copy openwrt-qualcommax-ipq60xx-netgear_wax214-squashfs-factory.ubi to the device - write the image to the NAND: - cat /proc/mtd and look for rootfs partition (should be mtd11, or mtd12 if you choose active_fw 1) - ubiformat /dev/mtd11 -f -y openwrt-qualcommax-ipq60xx-netgear_wax214-squashfs-factory.ubi - reboot Note: the firmware is senao-based. But I was unable to build a valid senao-header into the image. Maybe they changed the header format and senaoFW isn't working any more. Signed-off-by: Dirk Buchwalder <buchwalder@posteo.de>
* u-boot.mk: override default PATH to avoid pick hostpkg pythonTianling Shen2024-03-02
| | | | | | | | | | | hostpkg python from packages feed can be picked when do a incremental build because hostpkg has higher priority in PATH. It may lead build faliure as it's heavily trimmed (e.g. lacks necessary modules). For uboot which uses binman and intree dtc, this is forced as hostpkg python will never provide those modules by default. Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>
* uboot-mediatek: remove rootfs_data before attempting to replace fipDaniel Golle2024-03-01
| | | | | | | Make sure there is enough space to replace 'fip' volume and always remove rootfs_data before. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* uboot-d1: cleanup MakefileZoltan HERPAI2024-02-29
| | | | | | Clean up leftover PKG_HASH. Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
* uboot-d1: add bootloader for upcoming d1 targetZoltan HERPAI2024-02-29
| | | | | | | | | | | Add u-boot bootloader based on 2023.01 to support D1-based boards, currently: - Dongshan Nezha STU - LicheePi RV Dock - MangoPi MQ-Pro - Nezha D1 Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
* opensbi: allow building on upcoming d1 targetZoltan HERPAI2024-02-29
| | | | | | | | U-boot on D1 also uses OpenSBI as its payload. As the current version of OpenSBI already supports D1 with no further patches required, allow building it on the upcoming TARGET_d1 too. Signed-off-by: Zoltan HERPAI <wigyori@uid0.hu>
* uboot-mediatek: correct board name for BananaPi BPi-R3 MiniTianling Shen2024-02-28
| | | | | | | It should be "BananaPi BPi-R3 Mini" instead of just "BananaPi BPi-R3". Fixes: bc25519f98cd ("uboot-mediatek: add builds for BananaPi BPi-R3 mini") Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org>