aboutsummaryrefslogtreecommitdiffstats
path: root/target
Commit message (Collapse)AuthorAgeFilesLines
* treewide: provide global default for SUPPORTED_DEVICESAdrian Schmutzler2021-01-2322-22/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The majority of our targets provide a default value for the variable SUPPORTED_DEVICES, which is used in images to check against the compatible on a running device: SUPPORTED_DEVICES := $(subst _,$(comma),$(1)) At the moment, this is implemented in the Device/Default block of the individual targets or even subtargets. However, since we standardized device names and compatible in the recent past, almost all targets are following the same scheme now: device/image name: vendor_model compatible: vendor,model The equal redundant definitions are a symptom of this process. Consequently, this patch moves the definition to image.mk making it a global default. For the few targets not using the scheme above, SUPPORTED_DEVICES will be defined to a different value in Device/Default anyway, overwriting the default. In other words: This change is supposed to be cosmetic. This can be used as a global measure to get the current compatible with: $(firstword $(SUPPORTED_DEVICES)) (Though this is not precisely an achievement of this commit.) Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* kernel: mtdsplit_uimage: replace "edimax, uimage" parserBjørn Mork2021-01-229-106/+60
| | | | | | | | The "edimax,uimage"" parser can be replaced by the generic parser using device specific openwrt,partition-magic and openwrt,offset properties. Signed-off-by: Bjørn Mork <bjorn@mork.no>
* kernel: mtdsplit_uimage: add "openwrt, offset" and "openwrt, partition-magic"Bjørn Mork2021-01-221-12/+28
| | | | | | | | Some devices prepend a standard U-Boot Image with a vendor specific header, having its own magic. Adding two new properties will support validation of such images, including the additional magic. Signed-off-by: Bjørn Mork <bjorn@mork.no>
* kernel: mtdsplit_uimage: replace "netgear, uimage" parserBjørn Mork2021-01-2216-80/+44
| | | | | | | | | | | | | | | | | | | The "netgear,uimage" parser can be replaced by the generic parser using device specific openwrt,ih-magic and openwrt,ih-type properties. Device tree properties for the following devices have not been set, as they have been dropped from OpenWrt with the removal of the ar71xx target: FW_MAGIC_WNR2000V1 0x32303031 FW_MAGIC_WNR2000V4 0x32303034 FW_MAGIC_WNR1000V2_VC 0x31303030 FW_MAGIC_WPN824N 0x31313030 Tested-by: Sander Vanheule <sander@svanheule.net> # WNDR3700v2 Tested-by: Stijn Segers <foss@volatilesystems.org> # WNDR3700v1 Signed-off-by: Bjørn Mork <bjorn@mork.no>
* kernel: mtdsplit_uimage: add "openwrt, ih-type" device-tree propertyBjørn Mork2021-01-221-10/+14
| | | | | | | Some devices use uimage headers with a non-default ih_type. Add support for overriding this in device tree. Signed-off-by: Bjørn Mork <bjorn@mork.no>
* kernel: mtdsplit_uimage: replace "allnet, uimage" parserBjørn Mork2021-01-222-50/+2
| | | | | | | Convert users to the generic "openwrt,uimage" using device specific "openwrt,ih-magic" properties, and remove "allnet,uimage". Signed-off-by: Bjørn Mork <bjorn@mork.no>
* kernel: mtdsplit_uimage: replace "openwrt, okli" parserBjørn Mork2021-01-2212-63/+35
| | | | | | | | | The only difference between the "openwrt,okli" and the generic parser is the magic. Set this in device tree for all affected devices and remove the "openwrt,okli" parser. Tested-by: Michael Pratt <mcpratt@protonmail.com> # EAP300 v2, ENS202EXT and ENH202 Signed-off-by: Bjørn Mork <bjorn@mork.no>
* kernel: mtdsplit_uimage: add "openwrt, ih-magic" device-tree propertyBjørn Mork2021-01-221-18/+23
| | | | | | | Many devices use uimages with non-standard magic values. Let device tree override the default magic. Signed-off-by: Bjørn Mork <bjorn@mork.no>
* kernel: mtdsplit_uimage: replace "fonfxc" and "sge" parsersBjørn Mork2021-01-224-89/+16
| | | | | | | | Convert users of the "fonfxc" and "sge" parsers to the generic "openwrt,uimage", using device specific "openwrt,padding" properties. Tested-by: Stijn Segers <foss@volatilesystems.org> [DIR-878 A1] Signed-off-by: Bjørn Mork <bjorn@mork.no>
* kernel: mtdsplit_uimage: read extralen from device treeBjørn Mork2021-01-221-10/+14
| | | | | | | An "openwrt,padding" property in device tree can replace two device specific parsers. Signed-off-by: Bjørn Mork <bjorn@mork.no>
* dt-bindings: mtd: partitions: add OpenWrt defined U-Boot ImageBjørn Mork2021-01-222-0/+282
| | | | | | | Add devicetree bindings for vendor specific variants of U-Boot Images, as defined by OpenWrt. Signed-off-by: Bjørn Mork <bjorn@mork.no>
* kernel: add parser finding rootfs after CFE bootfsRafał Miłecki2021-01-224-1/+101
| | | | | | | | | | | | | | It's required for BCM4908. It cannot use "bcm-wfi-fw" parser because that one requires *two* JFFS2 partitions which is untested / unsupported on the BCM4908 architecture. With a single JFFS2 partition "bcm-wfi-fw" parser will: 1. Fail to find "vmlinux.lz" as it doesn't follow "1-openwrt" file 2. Create partitions that don't precisely match bootfs layout The new parser is described in details in the MTD_SPLIT_CFE_BOOTFS symbol help message. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* bcm4908: build valid Asus GT-AC5300 firmware imageRafał Miłecki2021-01-221-1/+11
| | | | | | Insert Asus specific tail that is required for image identification. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* bcm63xx: sync ethernet driver with net-nextSieng Piaw Liew2021-01-2215-191/+703
| | | | | | | | | | | | | | Sync ethernet driver code with upstream Linux kernel: -Reduce xmit_more code changes. -Combine rx cleanup code into a function. -Convert to build_skb. -Improve rx loop by optimizing loop tracking. https://lore.kernel.org/netdev/20210106144208.1935-1-liew.s.piaw@gmail.com/ Signed-off-by: Sieng Piaw Liew <liew.s.piaw@gmail.com> [Amend commit description, move patches to the top since they are going to be upstreamed] Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
* bcm63xx: nand: fix OOB R/W for non Hamming ECCÁlvaro Fernández Rojas2021-01-222-11/+34
| | | | | | | | Hamming ECC devices do not cover OOB data, as opposed to BCH ECC devices. Therefore, disabling ECC for all devices is preventing BCH devices from correctly reading and writing the OOB data. Signed-off-by: Álvaro Fernández Rojas <noltari@gmail.com>
* ramips: fix port labels for Xiaomi Mi Router 4Adrian Schmutzler2021-01-211-2/+2
| | | | | | | | The OEM assignment of LAN ports is swapped. Fixes: c2a7bb520a0f ("ramips: mt7621: add support for Xiaomi Mi Router 4") Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ramips: mt7621: add support for Xiaomi Mi Router 4Dmytro Oz2021-01-214-0/+106
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Xiaomi Mi Router 4 is the same as Xiaomi Mi Router 3G, except for the RAM (256Mib→128Mib), LEDs and gpio (MiNet button). Specifications: Power: 12 VDC, 1 A Connector type: barrel CPU1: MediaTek MT7621A (880 MHz, 4 cores) FLA1: 128 MiB (ESMT F59L1G81MA) RAM1: 128 MiB (ESMT M15T1G1664A) WI1 chip1: MediaTek MT7603EN WI1 802dot11 protocols: bgn WI1 MIMO config: 2x2:2 WI1 antenna connector: U.FL WI2 chip1: MediaTek MT7612EN WI2 802dot11 protocols: an+ac WI2 MIMO config: 2x2:2 WI2 antenna connector: U.FL ETH chip1: MediaTek MT7621A Switch: MediaTek MT7621A UART Serial [o] TX [o] GND [o] RX [ ] VCC - Do not connect it MAC addresses as verified by OEM firmware: use address source LAN *:c2 factory 0xe000 (label) WAN *:c3 factory 0xe006 2g *:c4 factory 0x0000 5g *:c5 factory 0x8000 Flashing instructions: 1.Create a simple http server (nginx etc) 2.set uart enable To enable writing to the console, you must reset to factory settings Then you see uboot boot, press the keyboard 4 button (enter uboot command line) If it is not successful, repeat the above operation of restoring the factory settings. After entering the uboot command line, type: setenv uart_en 1 saveenv boot 3.use shell in uart cd /tmp wget http://"your_computer_ip:80"/openwrt-ramips-mt7621-xiaomi_mir4-squashfs-kernel1.bin wget http://"your_computer_ip:80"/openwrt-ramips-mt7621-xiaomi_mir4-squashfs-rootfs0.bin mtd write openwrt-ramips-mt7621-xiaomi_mir4-squashfs-kernel1.bin kernel1 mtd write openwrt-ramips-mt7621-xiaomi_mir4-squashfs-rootfs0.bin rootfs0 nvram set flag_try_sys1_failed=1 nvram commit reboot 4.login to the router http://192.168.1.1/ Installation via Software exploit Find the instructions in the https://github.com/acecilia/OpenWRTInvasion Signed-off-by: Dmytro Oz <sequentiality@gmail.com> [commit message facelift, rebase onto shared DTSI/common device definition, bump uboot-envtools] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ramips: mt7621: create DTSI for Xiaomi NAND devicesAdrian Schmutzler2021-01-213-189/+111
| | | | | | | | | | | | This creates a DTSI for Xiaomi devices with 128M NAND. This allows to consolidate the partitions and a few other nodes for AC2100 family and Mi Router 3G. Note that the Mi Router 3 Pro has 256M NAND and differently sized partitions. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ramips: mt7621: reorganize shared device definitions for XiaomiAdrian Schmutzler2021-01-211-21/+13
| | | | | | | | | | This creates a shared device definition for Xiaomi devices with NAND and "separate" images, i.e. kernel1.bin and rootfs0.bin. This allows to consolidate similar/duplicate code for AC2100 family and Mi Router 3G. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ipq40xx: fix boards being shown twiceRobert Marko2021-01-211-2/+0
| | | | | | | | | | | | | | | | Since generic images have been split to their own Makefile boards are showing up twice in menuconfig as $(eval $(call BuildImage)) was not dropped from the new generic.mk. Hence $(eval $(call BuildImage)) was being called twice. So, lets simply drop it from generic.mk. Fixes: 378c7ff28210 ("ipq40xx: split generic images into own file") Signed-off-by: Robert Marko <robert.marko@sartura.hr>
* bcm4908: workaround NAND controller #WP issueRafał Miłecki2021-01-211-0/+34
| | | | | | | There seems to be a problem with setting #WP. On the other hand ignoring the #WP seems to work. rootfs_data UBI volume seems to persist changes. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* bcm4908: append UBI with rootfs to device imagesRafał Miłecki2021-01-212-3/+29
| | | | | | Also enable UBI kernel support. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* bcm4908: build flashable & bootable firmware imagesRafał Miłecki2021-01-215-0/+23
| | | | | | | | | | | | | BCM4908 bootloader requires firmware with JFFS2 image containing: 1. cferam.000 2. 94908.dtb 3. vmlinux.lz 4. device custom files cferam.000 can be obtained from the bcm63xx-cfe repository. device custom files are stored in images dir. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* bcm4908: set console in the CONFIG_CMDLINERafał Miłecki2021-01-211-1/+1
| | | | | | | | procd doesn't work with just serial specified in the DT (using chosen & stdout-path). It requires tty device to be explicitly specified in the cmdline. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* bcm4908: add DTS patches for USB PHY and partitionsRafał Miłecki2021-01-202-0/+201
| | | | Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* bcm4908: use backported brcmstb soc stubs patchRafał Miłecki2021-01-201-8/+21
| | | | | | Final version differs slightly - uses IS_ENABLED() Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* bcm4908: use backported switch & PMB DTS patchesRafał Miłecki2021-01-202-10/+8
| | | | | | Final versions differ slightly from what was used initially. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* bcm4908: add pending mtd patches for BCM4908 partitioningRafał Miłecki2021-01-203-0/+393
| | | | | | | BCM4908 can have multiple firmware partitions. MTD needs to detect which one is currently used. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* kernel: backport mtd commit converting partitions doc syntaxRafał Miłecki2021-01-202-0/+352
| | | | | | | 1. It's useful for developing & validating DTS files inside OpenWrt 2. This will allow backporting later changes that depend on it Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* kernel: bump 5.4 to 5.4.91John Audia2021-01-201-2/+2
| | | | | | | | | | | | | | All modification made by update_kernel.sh in a fresh clone without existing toolchains. Build system: x86_64 Build-tested: ipq806x/R7800, bcm27xx/bcm2711 Run-tested: ipq806x/R7800 No dmesg regressions, everything functional Signed-off-by: John Audia <graysky@archlinux.us> Tested-by: Curtis Deptuck <curtdept@me.com> [x86/64]
* ath79: Add support for OpenMesh MR1750 v2Sven Eckelmann2021-01-197-3/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Device specifications: ====================== * Qualcomm/Atheros QCA9558 ver 1 rev 0 * 720/600/240 MHz (CPU/DDR/AHB) * 128 MB of RAM * 16 MB of SPI NOR flash - 2x 7 MB available; but one of the 7 MB regions is the recovery image * 3T3R 2.4 GHz Wi-Fi (11n) * 3T3R 5 GHz Wi-Fi (11ac) * 6x GPIO-LEDs (2x wifi, 2x status, 1x lan, 1x power) * 1x GPIO-button (reset) * external h/w watchdog (enabled by default)) * TTL pins are on board (arrow points to VCC, then follows: GND, TX, RX) * 1x ethernet - AR8035 ethernet PHY (RGMII) - 10/100/1000 Mbps Ethernet - 802.3af POE - used as LAN interface * 12-24V 1A DC * internal antennas Flashing instructions: ====================== Various methods can be used to install the actual image on the flash. Two easy ones are: ap51-flash ---------- The tool ap51-flash (https://github.com/ap51-flash/ap51-flash) should be used to transfer the image to the u-boot when the device boots up. initramfs from TFTP ------------------- The serial console must be used to access the u-boot shell during bootup. It can then be used to first boot up the initramfs image from a TFTP server (here with the IP 192.168.1.21): setenv serverip 192.168.1.21 setenv ipaddr 192.168.1.1 tftpboot 0c00000 <filename-of-initramfs-kernel>.bin && bootm $fileaddr The actual sysupgrade image can then be transferred (on the LAN port) to the device via scp <filename-of-squashfs-sysupgrade>.bin root@192.168.1.1:/tmp/ On the device, the sysupgrade must then be started using sysupgrade -n /tmp/<filename-of-squashfs-sysupgrade>.bin Signed-off-by: Sven Eckelmann <sven@narfation.org> [rebase, add LED migration] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: Add support for OpenMesh MR1750 v1Sven Eckelmann2021-01-197-2/+37
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Device specifications: ====================== * Qualcomm/Atheros QCA9558 ver 1 rev 0 * 720/600/240 MHz (CPU/DDR/AHB) * 128 MB of RAM * 16 MB of SPI NOR flash - 2x 7 MB available; but one of the 7 MB regions is the recovery image * 3T3R 2.4 GHz Wi-Fi (11n) * 3T3R 5 GHz Wi-Fi (11ac) * 6x GPIO-LEDs (2x wifi, 2x status, 1x lan, 1x power) * 1x GPIO-button (reset) * external h/w watchdog (enabled by default)) * TTL pins are on board (arrow points to VCC, then follows: GND, TX, RX) * 1x ethernet - AR8035 ethernet PHY (RGMII) - 10/100/1000 Mbps Ethernet - 802.3af POE - used as LAN interface * 12-24V 1A DC * internal antennas Flashing instructions: ====================== Various methods can be used to install the actual image on the flash. Two easy ones are: ap51-flash ---------- The tool ap51-flash (https://github.com/ap51-flash/ap51-flash) should be used to transfer the image to the u-boot when the device boots up. initramfs from TFTP ------------------- The serial console must be used to access the u-boot shell during bootup. It can then be used to first boot up the initramfs image from a TFTP server (here with the IP 192.168.1.21): setenv serverip 192.168.1.21 setenv ipaddr 192.168.1.1 tftpboot 0c00000 <filename-of-initramfs-kernel>.bin && bootm $fileaddr The actual sysupgrade image can then be transferred (on the LAN port) to the device via scp <filename-of-squashfs-sysupgrade>.bin root@192.168.1.1:/tmp/ On the device, the sysupgrade must then be started using sysupgrade -n /tmp/<filename-of-squashfs-sysupgrade>.bin Signed-off-by: Sven Eckelmann <sven@narfation.org> [rebase, apply shared DTSI/device node, add LED migration] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: make OpenMesh MR900 DTSI more generalAdrian Schmutzler2021-01-193-13/+38
| | | | | | | | The OpenMesh MR900 and to-be-added MR1750 family are very similar. Make the existing MR900 DTSI more general so it can be used for the MR1750 devices as well. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: consolidate common definitions for OpenMesh devicesAdrian Schmutzler2021-01-191-51/+48
| | | | | | | | | | | | The shared image definitions for OpenMesh devices are currently organized based on device families. This introduces some duplicate code, as the image creation code is mostly the same for those. This patch thus derives two basic shared definitions that work for all devices and only requires a few variables to be moved back to the device definitions. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: apply Engenius ECB1750 style to OpenMesh MR900 RGMII cfgSven Eckelmann2021-01-191-6/+2
| | | | | | | | | | | | | | | The OpenMesh MR900 is a modified version of the Exx900/Exx1750 family. These devices are shipped with an AR803x PHY and had various problems with the delay configuration in ar71xx. These problems are now in the past [1] and parts of the delay configuration should now be done in the PHY only. Just switch to the configuration of the ECB1750 to have an already well tested configuration for ath79 with the newer kernel versions. [1] https://github.com/openwrt/openwrt/pull/3505#issuecomment-716050292 Reported-by: Michael Pratt <mcpratt@pm.me> Signed-off-by: Sven Eckelmann <sven@narfation.org>
* ath79: Add support for OpenMesh MR900 v2Sven Eckelmann2021-01-196-2/+21
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Device specifications: ====================== * Qualcomm/Atheros QCA9558 ver 1 rev 0 * 720/600/240 MHz (CPU/DDR/AHB) * 128 MB of RAM * 16 MB of SPI NOR flash - 2x 7 MB available; but one of the 7 MB regions is the recovery image * 3T3R 2.4 GHz Wi-Fi * 3T3R 5 GHz Wi-Fi * 6x GPIO-LEDs (2x wifi, 2x status, 1x lan, 1x power) * 1x GPIO-button (reset) * external h/w watchdog (enabled by default)) * TTL pins are on board (arrow points to VCC, then follows: GND, TX, RX) * 1x ethernet - AR8035 ethernet PHY (RGMII) - 10/100/1000 Mbps Ethernet - 802.3af POE - used as LAN interface * 12-24V 1A DC * internal antennas Flashing instructions: ====================== Various methods can be used to install the actual image on the flash. Two easy ones are: ap51-flash ---------- The tool ap51-flash (https://github.com/ap51-flash/ap51-flash) should be used to transfer the image to the u-boot when the device boots up. initramfs from TFTP ------------------- The serial console must be used to access the u-boot shell during bootup. It can then be used to first boot up the initramfs image from a TFTP server (here with the IP 192.168.1.21): setenv serverip 192.168.1.21 setenv ipaddr 192.168.1.1 tftpboot 0c00000 <filename-of-initramfs-kernel>.bin && bootm $fileaddr The actual sysupgrade image can then be transferred (on the LAN port) to the device via scp <filename-of-squashfs-sysupgrade>.bin root@192.168.1.1:/tmp/ On the device, the sysupgrade must then be started using sysupgrade -n /tmp/<filename-of-squashfs-sysupgrade>.bin Signed-off-by: Sven Eckelmann <sven@narfation.org> [rebase, add LED migration] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: Add support for OpenMesh MR900 v1Sven Eckelmann2021-01-197-1/+217
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Device specifications: ====================== * Qualcomm/Atheros QCA9558 ver 1 rev 0 * 720/600/240 MHz (CPU/DDR/AHB) * 128 MB of RAM * 16 MB of SPI NOR flash - 2x 7 MB available; but one of the 7 MB regions is the recovery image * 3T3R 2.4 GHz Wi-Fi * 3T3R 5 GHz Wi-Fi * 6x GPIO-LEDs (2x wifi, 2x status, 1x lan, 1x power) * 1x GPIO-button (reset) * external h/w watchdog (enabled by default)) * TTL pins are on board (arrow points to VCC, then follows: GND, TX, RX) * 1x ethernet - AR8035 ethernet PHY (RGMII) - 10/100/1000 Mbps Ethernet - 802.3af POE - used as LAN interface * 12-24V 1A DC * internal antennas Flashing instructions: ====================== Various methods can be used to install the actual image on the flash. Two easy ones are: ap51-flash ---------- The tool ap51-flash (https://github.com/ap51-flash/ap51-flash) should be used to transfer the image to the u-boot when the device boots up. initramfs from TFTP ------------------- The serial console must be used to access the u-boot shell during bootup. It can then be used to first boot up the initramfs image from a TFTP server (here with the IP 192.168.1.21): setenv serverip 192.168.1.21 setenv ipaddr 192.168.1.1 tftpboot 0c00000 <filename-of-initramfs-kernel>.bin && bootm $fileaddr The actual sysupgrade image can then be transferred (on the LAN port) to the device via scp <filename-of-squashfs-sysupgrade>.bin root@192.168.1.1:/tmp/ On the device, the sysupgrade must then be started using sysupgrade -n /tmp/<filename-of-squashfs-sysupgrade>.bin Signed-off-by: Sven Eckelmann <sven@narfation.org> [rebase, add LED migration] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: apply Engenius EAP600 style to OpenMesh MR600 RGMII cfgSven Eckelmann2021-01-191-2/+4
| | | | | | | | | | | | | | | The OpenMesh MR600 is a modified version of the EAP600 family. These devices are shipped with an AR803x PHY and had various problems with the delay configuration in ar71xx. These problems are now in the past [1] and parts of the delay configuration should now be done in the PHY only. Just switch to the configuration of the EAP600 to have an already well tested configuration for ath79 with the newer kernel versions. [1] https://github.com/openwrt/openwrt/pull/3505#issuecomment-716050292 Reported-by: Michael Pratt <mcpratt@pm.me> Signed-off-by: Sven Eckelmann <sven@narfation.org>
* ath79: Add support for OpenMesh MR600 v2Sven Eckelmann2021-01-196-1/+85
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Device specifications: ====================== * Qualcomm/Atheros AR9344 rev 2 * 560/450/225 MHz (CPU/DDR/AHB) * 128 MB of RAM * 16 MB of SPI NOR flash - 2x 7 MB available; but one of the 7 MB regions is the recovery image * 2T2R 2.4 GHz Wi-Fi * 2T2R 5 GHz Wi-Fi * 8x GPIO-LEDs (6x wifi, 1x wps, 1x power) * 1x GPIO-button (reset) * external h/w watchdog (enabled by default)) * TTL pins are on board (arrow points to VCC, then follows: GND, TX, RX) * 1x ethernet - AR8035 ethernet PHY (RGMII) - 10/100/1000 Mbps Ethernet - 802.3af POE - used as LAN interface * 12-24V 1A DC * internal antennas Flashing instructions: ====================== Various methods can be used to install the actual image on the flash. Two easy ones are: ap51-flash ---------- The tool ap51-flash (https://github.com/ap51-flash/ap51-flash) should be used to transfer the image to the u-boot when the device boots up. initramfs from TFTP ------------------- The serial console must be used to access the u-boot shell during bootup. It can then be used to first boot up the initramfs image from a TFTP server (here with the IP 192.168.1.21): setenv serverip 192.168.1.21 setenv ipaddr 192.168.1.1 tftpboot 0c00000 <filename-of-initramfs-kernel>.bin && bootm $fileaddr The actual sysupgrade image can then be transferred (on the LAN port) to the device via scp <filename-of-squashfs-sysupgrade>.bin root@192.168.1.1:/tmp/ On the device, the sysupgrade must then be started using sysupgrade -n /tmp/<filename-of-squashfs-sysupgrade>.bin Signed-off-by: Sven Eckelmann <sven@narfation.org> [rebase, add LED migration] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: Add support for OpenMesh MR600 v1Sven Eckelmann2021-01-197-0/+207
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Device specifications: ====================== * Qualcomm/Atheros AR9344 rev 2 * 560/450/225 MHz (CPU/DDR/AHB) * 128 MB of RAM * 16 MB of SPI NOR flash - 2x 7 MB available; but one of the 7 MB regions is the recovery image * 2T2R 2.4 GHz Wi-Fi * 2T2R 5 GHz Wi-Fi * 4x GPIO-LEDs (2x wifi, 1x wps, 1x power) * 1x GPIO-button (reset) * TTL pins are on board (arrow points to VCC, then follows: GND, TX, RX) * 1x ethernet - AR8035 ethernet PHY (RGMII) - 10/100/1000 Mbps Ethernet - 802.3af POE - used as LAN interface * 12-24V 1A DC * internal antennas Flashing instructions: ====================== Various methods can be used to install the actual image on the flash. Two easy ones are: ap51-flash ---------- The tool ap51-flash (https://github.com/ap51-flash/ap51-flash) should be used to transfer the image to the u-boot when the device boots up. initramfs from TFTP ------------------- The serial console must be used to access the u-boot shell during bootup. It can then be used to first boot up the initramfs image from a TFTP server (here with the IP 192.168.1.21): setenv serverip 192.168.1.21 setenv ipaddr 192.168.1.1 tftpboot 0c00000 <filename-of-initramfs-kernel>.bin && bootm $fileaddr The actual sysupgrade image can then be transferred (on the LAN port) to the device via scp <filename-of-squashfs-sysupgrade>.bin root@192.168.1.1:/tmp/ On the device, the sysupgrade must then be started using sysupgrade -n /tmp/<filename-of-squashfs-sysupgrade>.bin Signed-off-by: Sven Eckelmann <sven@narfation.org> [rebase, make WLAN LEDs consistent, add LED migration] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* kernel: bump 5.4 to 5.4.90John Audia2021-01-193-3/+3
| | | | | | | | | | | | | | All modification made by update_kernel.sh in a fresh clone without existing toolchains. Build system: x86_64 Build-tested: ipq806x/R7800, bcm27xx/bcm2711 Run-tested: ipq806x/R7800 No dmesg regressions, everything functional Signed-off-by: John Audia <graysky@archlinux.us> Tested-by: Curtis Deptuck <curtdept@me.com> [x86/64]
* ath79: rename UniFi AC kernel1 partitionDavid Bauer2021-01-181-1/+1
| | | | | | | These devices do not run Ubiquiti AirOS. Rename the partition to the name used by other UniFi devices with vendor dualboot support. Signed-off-by: David Bauer <mail@david-bauer.net>
* rockchip: use stable MAC-address for NanoPi R2SDavid Bauer2021-01-181-1/+8
| | | | | | | | | | | | | | | | The NanoPi R2S does not have a board specific MAC address written inside e.g. an EEPROM, hence why it is randomly generated on first boot. The issue with that however is the lack of a driver for the PRNG. It often results to the same MAC address used on multiple boards by default, as urngd is not active at this early stage resulting in low available entropy. There is however a semi-unique identifier available to us, which is the CID of the used SD card. It is unique to each SD card, hence we can use it to generate the MAC address used for LAN and WAN. Signed-off-by: David Bauer <mail@david-bauer.net>
* ipq40xx: mikrotik: enable MikroTik platform driverRobert Marko2021-01-171-0/+2
| | | | | | | | This enables the MikroTik platform driver, it enables us to parse valuable info from hard_config including WLAN calibration data extraction from sysfs. Signed-off-by: Robert Marko <robimarko@gmail.com>
* ipq40xx: mikrotik: enable MikroTik NOR parserRobert Marko2021-01-171-0/+1
| | | | | | Needed for SPI-NOR based MikroTik IPQ40xx devices like hAP ac2. Signed-off-by: Robert Marko <robimarko@gmail.com>
* ipq40xx: mikrotik: enable CONFIG_MTD_ROUTERBOOT_PARTSRobert Marko2021-01-171-0/+1
| | | | | | | | | This enables the new MikroTik specific partition parser. This avoids manually specifying the MikroTik specific partitions as they can be detected by their magic values. Signed-off-by: Robert Marko <robimarko@gmail.com>
* ipq40xx: add MikroTik subtargetRobert Marko2021-01-173-1/+5
| | | | | | | | | | | | | MikroTik devices require the use of raw vmlinux out of the self extracting compressed kernels. They also require 4K sectors, kernel2minor, partition parser as well as RouterBoard platform drivers. So in order to not add unnecessary code to the generic sub target lets introduce a MikroTik sub target. Signed-off-by: Robert Marko <robimarko@gmail.com>
* ipq40xx: kernel compressed boot: reset watchdog countdownJohn Thomson2021-01-171-0/+66
| | | | | | | | | | | | | | If the watchdog is enabled, set the timeout to 30 seconds before decompress is started. Mikrotik ipq40xx devices running with RouterBoot have the SoC watchdog enabled and running with a timeout that does not allow time for the kernel to decompress and manage the watchdog. On ipq40xx RouterBoot TFTP boot the watchdog countdown is reset before: Jumping to kernel Signed-off-by: John Thomson <git@johnthomson.fastmail.com.au>
* ipq40xx: arm: compressed: add appended DTB sectionRobert Marko2021-01-171-0/+48
| | | | | | | | | | | | | | | | | | | | This adds a appended_dtb section to the ARM decompressor linker script. This allows using the existing ARM zImage appended DTB support for appending a DTB to the raw ELF kernel. Its size is set to 1MB max to match the zImage appended DTB size limit. To use it to pass the DTB to the kernel, objcopy is used: objcopy --set-section-flags=.appended_dtb=alloc,contents \ --update-section=.appended_dtb=<target>.dtb vmlinux This is based off the following patch: https://github.com/openwrt/openwrt/commit/c063e27e02a9dcac0e7f5877fb154e58fa3e1a69 Signed-off-by: Robert Marko <robimarko@gmail.com>
* ipq40xx: split generic images into own fileAlexander Couzens2021-01-172-806/+810
| | | | | | | In preparation of the new mikrotik subtarget split the generic images into generic.mk Signed-off-by: Alexander Couzens <lynxis@fe80.eu>