aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ath79/dts
Commit message (Collapse)AuthorAgeFilesLines
* ath79: use upstream properties to disable EEEDavid Bauer2020-01-224-4/+8
| | | | | | | | | | | | | The hack-patch which introduced the "at803x-disable-smarteee" for disabling SmartEEE did in fact not disable SmartEEE but rather disabled 802.3az "standard" EEE. This can be done by using the upstream properties "eee-broken-100tx" and "eee-broken-1000t". EEE is then disabled by the PHY subsystem. Tested on devolo WiFi pro 1200e. Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: add support for TP-Link TL-WA850RE v1Adrian Schmutzler2020-01-222-0/+161
| | | | | | | | | | | | | | | | | | | | | | This ports support for the TL-WA850RE v1 range extender from ar71xx to ath79. Specifications: Board: AP123 / AR9341 rev. 3 Flash/RAM: 4/32 MiB CPU: 535 MHz WiFi: 2.4 GHz b/g/n Ethernet: 1 port (100M) Flashing instructions: Upload the factory image via the vendor firmware upgrade option. Recovery: Note that this device does not provide TFTP via ethernet like many other TP-Link devices do. You will have to open the case if you require recovery beyond failsafe. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link TL-MR6400Enrico Mioso2020-01-211-0/+167
| | | | | | | | | | | | | | | | | | | | | | | | | | This device is an LTE router supported in ar71xx so far. As per original commit, hardware specifications (v1.0 EU): - SoC: QCA9531 - Flash: Winbond W25Q64FV (8MiB) - RAM: EtronTech EM6AB160TSE-5G (64MiB) - Wireless: SoC platform only (2.4GHz b/g/n, 2x internal antenna) - Ethernet: 2NIC (3x100M + 1x100M) - WWAN: TP-LINK LTE MODULE (2x external detachable antenna) - Power: DC 12V 1A Flashing instructions: You can flash via tftp recovery (serve factory image as /mr6400_tp_recovery.bin on 192.168.0.66/24, connect to any ethernet port and power on device while holding the reset button). Flashing via OEM web interface does not work. Known issues: - LTE module does not always come up during boot (showing USB enumeration errors). Similar behavior has been reported at least from one user for ar71xx, too. Turning USB off and on again will serve as a workaround. - eth0 (LAN) always shows carrier as 1 even if no cable is plugged in (this works "correctly" on ar71xx) Signed-off-by: Enrico Mioso <mrkiko.rs@gmail.com> [several adjustments] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de> Tested-by: Filip Moc <lede@moc6.cz>
* ath79: add led_ prefix for Phicomm K2T LED labelAdrian Schmutzler2020-01-181-5/+5
| | | | | | | Using the led_ prefix for the node label is now common in ath79, so also apply it here. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: use rssihigh LED instead of WAN LED for status indicationAdrian Schmutzler2020-01-182-10/+10
| | | | | | | | | | | | Using the LED of network interfaces for status (boot/failsafe/...) indication is somewhat misleading, as the blinking might be mistaken for network activity. This uses rssi LEDs instead, which do not blink normally and thus are less ambiguous. The rssihigh LED has also been used consistently for the TP-Link CPE devices. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: ar934x: use reset for usb-phy-analogJohann Neuhauser2020-01-151-2/+2
| | | | | | | | | | | | This was already available on ar71xx, but is missing on ath79. This solves the slow usb speed on TP-Link WDR3600/WDR4300 and similar, as reported in Flyspray [0], OpenWRT Forum [1] and GitHub PR [2]. [0] https://bugs.openwrt.org/index.php?do=details&task_id=2567 [1] https://forum.openwrt.org/t/usb-wdr4300-low-speed-on-external-storage/46794 [2] https://github.com/openwrt/openwrt/pull/964 Signed-off-by: Johann Neuhauser <johann@it-neuhauser.de>
* ath79: use caldata partition label consistentlyAdrian Schmutzler2020-01-152-8/+8
| | | | | | | Change the caldata partition DTS node label to be consistent with the label property for some Netgear WNDR devices. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Netgear WNDR4500 v3Michal Cieslakiewicz2020-01-151-0/+41
| | | | | | | | | | | | | | | | | | | This patch introduces support for Netgear WNDR4500v3. Router is very similar to WNDR4300v2 and is based on the same PCB. Information gathered from various Internet sources (including https://patchwork.ozlabs.org/patch/809227/) shows following differences to WNDR4300v2: * two USB 2.0 ports with separate LEDs * USB LEDs soldered to secondary pads * WPS and RFKILL buttons soldered to secondary pads * described as N900 device with 3x3:3 MIMO for 2.4GHz radio * power supply requirement is DC 12V 2.5A * vendor HW ID suffix differs in one digit * bigger chassis Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
* ath79: add support for Netgear WNDR4300 v2Michal Cieslakiewicz2020-01-152-0/+275
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch introduces support for Netgear WNDR4300v2. Specification ============= * Description: Netgear WNDR4300 v2 * Loader: U-boot * SOC: Qualcomm Atheros QCA9563 (775 MHz) * RAM: 128 MiB * Flash: 2 MiB SPI-NOR + 128 MiB SPI-NAND - NOR: U-boot binary: 256 KiB - NOR: U-boot environment: 64 KiB - NOR: ART Backup: 64 KiB - NOR: Config: 64 KiB - NOR: Traffic Meter: 64 KiB - NOR: POT: 64 KiB - NOR: Reserved: 1408 KiB - NOR: ART: 64 KiB - NAND: Firmware: 25600 KiB (see notes for OpenWrt) - NAND: Language: 2048 KiB - NAND: mtdoops Crash Dump: 128 KiB - NAND: Reserved: 103296 KiB * Ethernet: 5 x 10/100/1000 (4 x LAN, 1 x WAN) (AR8337) * Wireless: - 2.4 GHz b/g/n (internal) - 5 GHz a/n (AR9580) * USB: yes, 1 x USB 2.0 * Buttons: - Reset - WiFi (rfkill) - WPS * LEDs: - Power (amber/green) - WAN (amber/green) - WLAN 2G (green) - WLAN 5G (blue) - 4 x LAN (amber/green) - USB (green) - WPS (green) * UART: 4-pin connector JP1, 3.3V (Vcc, TX, RX, GND), 115200 8N1 * Power supply: DC 12V 1.5A * MAC addresses: LAN=WLAN2G on case label, WAN +1, WLAN5G +2 Important Notes =============== 0. NOR Flash (2 MiB) is not touched by OpenWrt installation. 1. NAND Flash (128 MiB) layout under OpenWrt is changed as follows: all space is split between 4 MiB kernel and 124 MiB UBI areas; vendor partitions (language and mtdoops) are removed; kernel space size can be further expanded if needed; maximum image size is set to 25600k for compatibility reasons and can also be increased. 2. CPU clock is 775 MHz, not 750 MHz. 3. 5 GHz wireless radio chip is Atheros AR9580-AR1A with bogus PCI device ID 0xabcd. For ath9k driver to load successfully, this is overriden in DTS with correct value for this chip, 0x0033. 4. RFKILL button is wired to AR9580 pin 9 which is normally disabled by chip definition in ath9k code (0x0000F4FF gpio mask). Therefore 'qca,gpio-mask=<0xf6ff>' hack must be used for button to work properly. 5. USB port is always on, no GPIO for 5V power control has been identified. Installation ============ * TFTP recovery * TFTP via U-boot prompt * sysupgrade * Web interface Test build configuration ======================== CONFIG_TARGET_ath79=y CONFIG_TARGET_ath79_nand=y CONFIG_TARGET_ath79_nand_DEVICE_netgear_wndr4300-v2=y CONFIG_ALL_KMODS=y CONFIG_DEVEL=y CONFIG_CCACHE=y CONFIG_COLLECT_KERNEL_DEBUG=y CONFIG_IMAGEOPT=y Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
* ath79: WNDR4300: increase kernel partition to 4MMichal Cieslakiewicz2020-01-151-5/+5
| | | | | | | | | Increase kernel partition from 2 MiB to 4 MiB for Netgear WNDR routers with NAND flash. Change affects following devices: * Netgear WNDR3700 v4 * Netgear WNDR4300 Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
* ath79: add support for D-Link DIR-505David Bauer2020-01-151-0/+149
| | | | | | | | | | | | | | | | | | | | | | | This commit adds support for the D-Link DIR-505, previously supported in ar71xx. Hardware -------- SoC: Atheros AR9330 FLASH: 8M SPI-NOR RAM: 64M WIFI: 1T1R 1SS Atheros AR9330 LED: Power green, Status red BTN: WPS, Reset Installation ------------ Currently, installation is only possible by sysupgrading from an earlier OpenWrt version, U-Boot TFTP or a modded U-Boot. I do not have the original bootloader from D-Link on my device anymore, so i cannot test the factory image. Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: add support for Ubiquiti EdgeSwitch/ToughSwitch 5XPTobias Schramm2020-01-141-0/+77
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The Ubiquiti ToughSwitch 5XP is a 5-port PoE Gigabit switch with a single Fast-Ethernet management port. It supports both 24V passive PoE out on all five ports. Flash: 8 MB RAM: 64 MB SoC: AR7242 Switch: ar8327 USB: 1x USB 2.0 Ethernet: 5x GbE, 1x FE Installation of the firmware is possible either via serial + tftpboot or the factory firmware update function via webinterface. By default the single Fast-Ethernet port labeled "MGMT" is configured as the WAN port. Thus access to the device is only possible via the five switch ports. Serial: 3v3 115200 8n1 The serial header is located in the lower left corner of the switches PCB: ``` | | | | o | o RX | o TX | o GND | | ++ +-++-+ ++ ++ + +--+ ++ +--++--++--+ ``` Signed-off-by: Tobias Schramm <tobleminer@gmail.com> [remove ubnt,sw compatible - fix spelling - wrap commit message - remove superfluous phy-mode property] Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: add generic dtsi for Ubiquiti SW boardsTobias Schramm2020-01-142-133/+143
| | | | | | Signed-off-by: Tobias Schramm <tobleminer@gmail.com> [remove ubnt,sw compatible] Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: add support for Ubiquiti ToughSwitch/EdgeSwitch 8XPTobias Schramm2020-01-121-0/+322
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Flash: 8 MB RAM: 64 MB SoC: AR7242 Switch: bcm53128 USB: 1x USB 2.0 Ethernet: 8x GbE, 1x FE The Ubiquiti ToughSwitch 8XP is a 8-port PoE Gigabit switch with a single Fast-Ethernet management port. It supports both 24V passive PoE and 48V 802.11af/at PoE out on all eight ports. By default the single Fast-Ethernet port labeled "MGMT" is configured as the WAN port. Thus access to the device is only possible via the eight switch ports. Installation of the firware is possible either via serial + tftpboot or the factory firmware update function via webinterface. Serial: 3v3 115200 8n1 The serial header is located in the lower left corner of the switches PCB: | | | | o | o RX | o TX | o GND | | ++ +-++-+ ++ ++ + +--+ ++ +--++--++--+ Signed-off-by: Tobias Schramm <tobleminer@gmail.com> [fix whitespace issue] Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: fix MAC address setup for TP-Link TL-WDR3600/TL-WDR4300Sungbo Eo2019-12-211-1/+0
| | | | | | | | | | | | | | | | | | | | | | | The current ethernet MAC address setup of TL-WDR4300 board is different from the setup of stock firmware: OpenWrt: lan = label_mac -2, wan = label_mac -2 stock: lan = label_mac, wan = label_mac +1 The full address assignment is as follows: LAN label WAN label + 1 5G label 2G label - 1 This patch changes all devices using TL-WDR4300 board: TL-WDR3600 v1 (checked on device) TL-WDR4300 v1 (checked on device) TL-WDR4300 v1 (IL) Signed-off-by: Sungbo Eo <mans0n@gorani.run> [rephrase/extend commit title/message] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add D-Link DIR-615 E4Paul Fertser2019-12-191-0/+170
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Specifications: - FCC ID: KA2IR615E3 - SoC: MIPS32 24K 400 MHz Atheros AR7240 - RAM: 32 MiB DDR SDRAM ESMT M13S2561616A-5T - Flash: 4 MiB NOR SPI Macronix MX25L3208E - Wireless: AR9287 2.4 GHz 802.11n 2T2R, 2x RP-SMA connectors - Ethernet: 5x 100BASE-TX Fast Ethernet - LEDs: 9x GPIO, 1x ath9k - Buttons: 2x tactile switches - UART: 3.3 V, 115200 8n1 - USB: simple hardware modification required, 1x USB 1.1 Full Speed Partitioning notes: Vendor firmware (based on CameoAP99) defines two additional partitions: "mac" @0x3b0000, size 0x10000 and "lp" @0x3c0000, size 0x30000. The "mac" partition stores LAN MAC address and hardware board name. However, the vendor firmware uses addresses from "nvram" partition, and the board name is used only for informational purposes in the Web interface (included in the pages' header), not affecting the firmware image check. The "lp" partition is supposed to contain a "language pack" (which can be used to add an additional language support to the Web interface) and is flashed separately, using the vendor firmware upgrade page. Since these partitions are absolutely useless for OpenWrt and overwriting them doesn't prevent downgrading to obsolete vendor firmware, this patch appends the valueable space to "firmware". Installation instructions: - Upgrade from OpenWrt ar71xx with "sysupgrade -f -n" or - Upload as a firmware update via the vendor Web-interface or - Connect UART and use "loady" to upload and run OpenWrt initramfs image, then sysupgrade from it (TFTP client doesn't work) or - Before powering up hold "reset" button and keep it pressed for about 15 seconds after, then access fail safe Web server on 192.168.0.1 (the old uIP TCP/IP protocol stack is not compatible with modern Linux, the kernel, so you'll need to use some other OS to do this). Can be performed without a Web-browser too: curl http://192.168.0.1/cgi/index \ -F Send=@openwrt-ath79-tiny-dlink_dir-615-e4-squashfs-factory.bin Signed-off-by: Paul Fertser <fercerpav@gmail.com>
* ath79: enable all space on Netgear ar9344-based WNDR routersMichal Cieslakiewicz2019-12-191-5/+20
| | | | | | | | | | | Netgear WNDR routers (AR9344 models) like WNDR4300 have 128 MiB of flash memory but only first 32 MiB are used now - both by vendor's firmware and OpenWrt. This patch concatenates two regions of flash memory: ubi part of firmware partition and reserved (unused) space beyond 'caldata_backup' while preserving ART backup. No data is wiped or moved away. This increases area for OS ubi volumes from 23 to 119 Megabytes. Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
* ath79: restore gpio-export on TL-WDR3600/4300Lech Perczak2019-12-191-30/+28
| | | | | | | | | | | | | | | | | | This partially reverts commit 32144ba275d163ce6e7d93546ab4414f03f508fb. This commit replaced gpio-exports in favor of gpio-hogs for enabling USB power at boot, but this rids the user of control of the USB port power present on this device for a long time. It was agreed on a mailing list [1] that this is not the way to go, and this patch breaks a very common use-case of WWAN modem reset by power cycle, used on a lot USB equipped routers, hence revert this change until a better solution can be found. [1] http://lists.infradead.org/pipermail/openwrt-devel/2019-November/020151.html Tested-by: Sungbo Eo <mans0n@gorani.run> Signed-off-by: Lech Perczak <lech.perczak@gmail.com> [adjusted commit title] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link TL-WR902AC v1Lech Perczak2019-12-191-0/+188
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TP-Link TL-WR902AC v1 is a pocket-size, dual-band (AC750), successor of TL-MR3020 (both devices use very similar enclosure, in same size). New device is based on Qualcomm QCA9531 v2 + QCA9887. FCC ID: TE7WR902AC. Specification: - 650/391/216 MHz (CPU/DDR/AHB) - 1x 10/100 Mbps Ethernet - 1x USB 2.0 (GPIO-controlled power) - 64 MB of RAM (DDR2) - 8 MB of FLASH - 2T2R 2.4 GHz (QCA9531) - 1T1R 5 GHz (QCA9887) - 5x LED (GPIO-controlled), 2x button, 1x 3-pos switch - UART pads on PCB (TP1 -> TX, TP2 -> RX, TP3 -> GND, TP4 -> 3V3, jumper resitors are missing on TX/RX lines) - 1x micro USB (for power only) Flash instructions: Use "factory" image under vendor GUI. Recovery instructions: This device contains tftp recovery mode inside U-Boot. You can use it to flash OpenWrt (use "factory" image) or vendor firmware. 1. Configure PC with static IP 192.168.0.66/24 and tftp server. 2. Rename "openwrt-ath79-generic-tplink_tl-wr902ac-v1-squashfs-factory.bin" to "wr902acv1_un_tp_recovery.bin" and place it in tftp server dir. 3. Connect PC with LAN port, press the reset button, power up the router and keep button pressed until WPS LED lights up. 4. Router will download file from server, write it to flash and reboot. MAC Address summary: - wlan1 (2.4GHz Wi-Fi): Label MAC - wlan0 (5GHz Wi-Fi): Offset -1 from label - eth0 (Wired): Offset +1 from label Root access over serial line in vendor firmware: root/sohoadmin. Based on support in ar71xx target by: Piotr Dymacz <pepe2k@gmail.com> Signed-off-by: Lech Perczak <lech.perczak@gmail.com> [remove size-cells from gpio-export] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link TL-WDR4300 v1 (IL)Adrian Schmutzler2019-12-121-0/+9
| | | | | | | | The TL-WDR4300 v1 sold in Israel has a different TPLINK_HWID. Thanks to Josh4300 for testing on device. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: fix typos in DTSDENG Qingfang2019-12-114-11/+11
| | | | | | Replace "usb_ochi" with "usb_ohci", and "usb_echi" with "usb_ehci". Signed-off-by: DENG Qingfang <dengqf6@mail2.sysu.edu.cn>
* treewide: remove dts-v1 identifier from DTSI filesAdrian Schmutzler2019-12-0836-38/+0
| | | | | | | | | | | | | | | | The "/dts-v1/;" identifier is supposed to be put once at the beginning of a device tree file. Thus, it makes no sense to provide it a second time in to-be-included DTSI files. This removes the identifier from all DTSI files in /target/linux. Most of the DTS files in OpenWrt do contain the "/dts-v1/;". It is missing for most of the following targets, though: mvebu, ipq806x, mpc85xx, ipq40xx This does not touch ipq806x for now, as the bump to 4.19 is close. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: fix WNDR3700/WNDR3800 wifi reg sizeChristian Lamparter2019-12-071-2/+2
| | | | | | | | "[...] the size component shall be zero." (See "PCI Bus Binding to: IEEE Std 1275-1994 Rev 2.1" section "4.1.1 Open Firmware-defined Properties for Child Nodes") Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
* ath79: add support for Ubiquiti LiteBeam AC Gen2Stijn Tintel2019-12-041-0/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Hardware: * SoC: Atheros AR9342-BL1A * RAM: 64MB DDR2 (Winbond W9751G6KB-25) * Flash: 16MB SPI NOR (Macronix MX25L12835FZ2I-10G) * Ethernet: 1x 10/100/1000 Mbps (Atheros AR8035-A) with 24V PoE support * Wifi 2.4GHz: Atheros AR9340 v2 * WiFi 5GHz: Ubiquiti U-AME-G1-BR4A (rebranded QCA988X v2) * LEDs: 1x Power, 1x Ethernet * Buttons: 1x Reset * UART: 1x TTL 115200n8, 3.3V RX TX GND, 3.3V pin closest to RJ45 port The LEDs do not seem to be connected to any GPIO, so there is currently no way to control them. Installation via U-Boot, TFTP and serial console: * Configure your TFTP server with IP 192.168.1.254 * Connect serial console and power up the device * Hit any key to stop autoboot * tftpboot 0x81000000 openwrt-ath79-generic-ubnt_litebeam-ac-gen2-initramfs-kernel.bin * bootm 0x81000000 * copy openwrt-ath79-generic-ubnt_litebeam-ac-gen2-squashfs-sysupgrade.bin to /tmp * sysupgrade /tmp/openwrt-ath79-generic-ubnt_litebeam-ac-gen2-squashfs-sysupgrade.bin Signed-off-by: Stijn Tintel <stijn@linux-ipv6.be> Acked-by: Petr Štetiar <ynezz@true.cz> Acked-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link Archer C6 v2 (US) and A6 (US/TW)Anderson Vulczak2019-11-273-117/+250
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch is based on #1689 and adds support for TP-Link Archer C6 v2 (US) and A6 (US/TW). The hardware is the same as EU and RU variant, except for GPIOs (LEDS/Buttons), flash(chip/partitions) and UART being available on the board. - SOC: Qualcomm QCA9563 @ 775MHz - Flash: GigaDevice GD25Q127CS1G (16MiB) - RAM: Zentel A3R1GE40JBF (128 MiB DDR2) - Ethernet: Qualcomm QCA8337N: 4x 1Gbps LAN + 1x 1Gbps WAN - Wireless: - 2.4GHz (bgn) QCA9563 integrated (3x3) - 5GHz (ac) Qualcomm QCA9886 (2x2) - Button: 1x power, 1x reset, 1x wps - LED: 6x LEDs: power, wlan2g, wlan5g, lan, wan, wps - UART: 115200, 8n1 (header available on board) Known issues: - Wireless: 5GHz is known to have lower RSSI signal, it affects speed and range. Flash instructions: Upload openwrt-ath79-generic-tplink_archer-c6-v2-us-squashfs-factory.bin via the router Web interface. Flash instruction using tftp recovery: 1. Connect the computer to one of the LAN ports of the router 2. Set the computer IP to 192.168.0.66 3. Start a tftp server with the OpenWrt factory image in the tftp root directory renamed to ArcherA6v2_tp_recovery.bin. 4. Connect power cable to router, press and hold the reset button and turn the router on 5. Keep the reset button pressed until the WPS LED lights up 6. Wait ~150 seconds to complete flashing Flash partitioning: I've followed #1689 for defining the partition layout for this patch. The partition named as "tplink" @ 0xfd0000 is marked as read only as it is where some config for stock firmware are stored. On stock firmware those stock partitions starts at 0xfd9400 however I had not been able to make it functional starting on the same address as on stock fw, so it has been partitioned following #1689 and not the stock partition layout for this specific partition. Due to that firmware/rootfs partition lenght is 0xf80000 and not 0xf89400 as stock. According to the GPL code, the EU/RU/JP variant does have different GPIO pins assignment to LEDs and buttons, also the flash memory layout is different. GPL Source Code: https://static.tp-link.com/resources/gpl/gpl-A6v2_us.tar.gz Signed-off-by: Anderson Vulczak <andi@andi.com.br> [wrap commit message, remove soft_ver change for C6 v2 EU, move LED aliases to DTS files, remove dts-v1 in DTSI, node/property reorder in DTSI] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: rename EEPROM to artAdrian Schmutzler2019-11-2710-22/+22
| | | | | | | | | | | | | This renames all remaining occurrences of "EEPROM" to "art" to further harmonize the partition labelling in ath79. This will help to reduce the amount of user-space code and might be beneficial when code is copy/pasted in the future. Affected are only devices from Ubiquiti, where the XM board is already using "art" in ath79. Acked-by: Piotr Dymacz <pepe2k@gmail.com> Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for YunCore XD4200 and A782Piotr Dymacz2019-11-253-0/+186
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | YunCore XD4200 ('XD4200_W6.0' marking on PCB) is Qualcomm/Atheros based (QCA9563, QCA9886, QCA8334) dual-band, Wave-2 AC1200 ceiling AP with PoE (802.3at) support. A782 model ('T750_V5.1' marking on PCB) is a smaller version of the XD4200, with similar specification but lower TX power. Specification: - QCA9563 (775 MHz) - 128 MB of RAM (DDR2) - 16 MB of FLASH (SPI NOR) - 2x 10/100/1000 Mbps Ethernet (QCA8334), with 802.3at PoE support (WAN) - Wi-Fi 2.4 GHz: - XD4200: 2T2R (QCA9563), with ext. PA (SKY65174-21) and LNA - A782: 2T2R (QCA9563), with ext. FEM (SKY85329-11) - Wi-Fi 5 GHz: - XD4200: 2T2R (QCA9886), with ext. FEM (SKY85728-11) - A782: 2T2R (QCA9886), with ext. FEM (SKY85735-11) - LEDs: - XD4200: 5x (2x driven by SOC, 1x driven by AC radio, 2x Ethernet) - A782: 3x (1x RGB, driven by SOC and radio, 2x Ethernet) - 1x button (reset) - 1x UART (4-pin, 2.54 mm pitch) header on PCB - 1x DC jack (12 V) Flash instructions: If your device comes with generic QSDK based firmware, you can login over telnet (login: root, empty password, default IP: 192.168.188.253), issue first (important!) 'fw_setenv' command and then perform regular upgrade, using 'sysupgrade -n -F ...' (you can use 'wget' to download image to the device, SSH server is not available): fw_setenv bootcmd "bootm 0x9f050000 || bootm 0x9fe80000" sysupgrade -n -F openwrt-...-yuncore_...-squashfs-sysupgrade.bin In case your device runs firmware with YunCore custom GUI, you can use U-Boot recovery mode: 1. Set a static IP 192.168.0.141/24 on PC and start TFTP server with 'tftp' image renamed to 'upgrade.bin' 2. Power the device with reset button pressed and release it after 5-7 seconds, recovery mode should start downloading image from server (unfortunately, there is no visible indication that recovery got enabled - in case of problems check TFTP server logs) Signed-off-by: Piotr Dymacz <pepe2k@gmail.com>
* ath79: improve TP-Link CPE DTSI names for ar9344 SOCAdrian Schmutzler2019-11-2312-11/+11
| | | | | | | | | | | The initial DTSI names for the TP-Link CPE devices have become quite confusing, as several non-V1 devices now use the *-v1.dtsi, the *cpe510-v1.dts does not use the cpe510.dtsi, etc. This introduces a new naming scheme based on whether devices have one or two ports, which should be easier to grasp. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: DTS style improvement for Ubiquiti XM and BZ devicesAdrian Schmutzler2019-11-234-21/+13
| | | | | | | | | | This applies minor style improvements and removes commented pll clock adjustments from ubnt_xm DTSI. The latter were introduced (already commented out) when adding ath79 target and have never been touched since then. For Unifi (BZ board), similar clock adjustments are employed and used. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for the TP-LINK WBS510 V1Andrew Cameron2019-11-221-0/+13
| | | | | | | | | | | | | | | | | | | | | | This adds support for a popular low-cost 5GHz N based AP Specifications: - SoC: Atheros AR9344 - RAM: 64MB - Storage: 8 MB SPI NOR - Wireless: 5GHz 300 Mbps, 2x RP-SMA connector, 27 dBm TX power - Ethernet: 1x 10/100 Mbps with 24V POE IN, 1x 10/100 Mbps Installation: Flash factory image through stock firmware WEB UI or through TFTP To get to TFTP recovery just hold reset button while powering on for around 4-5 seconds and release. Rename factory image to recovery.bin Stock TFTP server IP:192.168.0.100 Stock device TFTP adress:192.168.0.254 Signed-off-by: Andrew Cameron <apcameron@softhome.net>
* ath79: add support for the TP-LINK WBS510 V2Andrew Cameron2019-11-221-0/+13
| | | | | | | | | | | | | | | | | | | | | | This adds support for a popular low-cost 5GHz N based AP Specifications: - SoC: Atheros AR9344 - RAM: 64MB - Storage: 8 MB SPI NOR - Wireless: 5GHz 300 Mbps, 2x RP-SMA connector, 27 dBm TX power - Ethernet: 1x 10/100 Mbps with 24V POE IN, 1x 10/100 Mbps Installation: Flash factory image through stock firmware WEB UI or through TFTP To get to TFTP recovery just hold reset button while powering on for around 4-5 seconds and release. Rename factory image to recovery.bin Stock TFTP server IP:192.168.0.100 Stock device TFTP adress:192.168.0.254 Signed-off-by: Andrew Cameron <apcameron@softhome.net>
* ath79: fix DTS node names for Ubiquiti XM partitionsAdrian Schmutzler2019-11-191-2/+2
| | | | | | Some node names were inconsistent with the reg property. Fix it. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: remap D-Link DIR-859 A1 WPS button to WPSChristian Lamparter2019-11-161-1/+1
| | | | | | | | The WPS button was mapped to the restart/reset. This patch changes it to emit the KEY_WPS_BUTTON keycode so pressing the WPS button does initiate WPS. Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
* ath79: fix firmware partition attributes for GL-AR300M16 and -LiteJeff Kletsky2019-11-162-0/+10
| | | | | | | | | | | | | | | | | | | During the introduction of the ath79/nand images for the GL-AR300M series the firmware partition label and compatible were altered, but the necessary adjustments have not been made for the GL-AR300M16 and the GL-AR300M-Lite. This will result in a non-bootable partition setup for these devices. This patch adds the necessary definitions to those two devices. Fixes: 55e6c903ae20 ("ath79: GL-AR300M: provide NAND support; increase to 4 MB kernel") Fixes: b591cabd3989 ("ath79: add GL.iNet GL-AR300M16 as NOR-only board") Signed-off-by: Jeff Kletsky <git-commits@allycomm.com> [extend commit message, alter commit title] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for Netgear WNDR3700v4Paul Blazejowski2019-11-141-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds ath79 support for Netgear WNDR3700v4. Router was previously supported by ar71xx target only. Note: device requires 'ar934x-nand' driver in kernel. Specification ============= * Description: Netgear WNDR3700v4 * Loader: U-boot * SOC: Atheros AR9344 (560 MHz) * RAM: 128 MiB * Flash: 128 MiB (NAND) - U-boot binary: 256 KiB - U-boot environment: 256 KiB - ART: 256 KiB - POT: 512 KiB - Language: 2 MiB - Config: 512 KiB - Traffic Meter: 3 MiB - Firmware: 25 MiB - ART Backup: 256 KiB - Reserved: 96 MiB * Ethernet: 5 x 10/100/1000 (4 x LAN, 1 x WAN) (AR8327) * Wireless: - 2.4 GHz b/g/n (internal) - 5 GHz a/n (AR9580) * USB: yes, 1 x USB 2.0 * Buttons: - Reset - WiFi (rfkill) - WPS * LEDs: - Power (amber/green) - WAN (amber/green) - WLAN 2G (green) - WLAN 5G (blue) - 4 x LAN (amber/green) - USB (green) - WPS (amber/green) * UART: 4-pin connector JP1, 3.3V (Vcc, TX, RX, GND), 115200 8N1 * Power supply: DC 12V 2.5A * MAC addresses: LAN=WLAN2G on case label, WAN +1, WLAN5G +2 Installation ============ * TFTP recovery * TFTP via U-boot prompt * sysupgrade * Web interface Note about partitioning: firmware partition offset (0x6c0000) is hardcoded into vendor's u-boot, so this partition cannot be moved and resized to include Netgear-specific flash areas (pot, language, config, traffic_meter) not used by OpenWrt. Test build configuration ======================== CONFIG_TARGET_ath79=y CONFIG_TARGET_ath79_nand=y CONFIG_TARGET_ath79_nand_DEVICE_netgear_wndr3700-v4=y CONFIG_ALL_KMODS=y CONFIG_DEVEL=y CONFIG_CCACHE=y CONFIG_COLLECT_KERNEL_DEBUG=y CONFIG_IMAGEOPT=y Signed-off-by: Paul Blazejowski <paulb@blazebox.homeip.net>
* ath79: split dts file for Netgear WNDR4300Michal Cieslakiewicz2019-11-142-285/+291
| | | | | | | Move board configuration to dtsi file in preparation for WNDR3700v4 router support. Signed-off-by: Michal Cieslakiewicz <michal.cieslakiewicz@wp.pl>
* ath79: fix indent in TP-Link TL-WDR4900 v2 DTSAdrian Schmutzler2019-11-141-1/+1
| | | | Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: improve common DTSI name for TP-Link Archer C5, C7 v1/v2Adrian Schmutzler2019-11-144-3/+3
| | | | | | | | As the former qca9558_tplink_archer-c7.dtsi is also used for Archer C5 v1 this patch removes the number from the DTSI name to indicate that. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: GL-AR750S: provide NAND support; increase kernel to 4 MBJeff Kletsky2019-11-143-40/+100
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The GL.iNet GL-AR750S has been supported by the ar71xx and ath79 platforms with access to its 16 MB NOR flash, but not its 128 MB SPI NAND flash. This commit provides support for the NAND through the upstream SPI-NAND framework. At this time, the OEM U-Boot appears to only support loading the kernel from NOR. This configuration is preserved as this time, with the glinet,gl-ar750s-nand name reserved for a potential, future, NAND-only boot. The family of GL-AR750S devices on the ath79 platform now includes: * glinet,gl-ar750m-nor-nand "nand" target * glinet,gl-ar750m-nor "nand" target (NAND-aware) NB: This commit increases the kernel size from 2 MB to 4 MB "Force-less" sysupgrade is presently supported from the current versions of following NOR-based firmwre images to the version of glinet,gl-ar750s-nor firmware produced by this commit: * glinet,gl-ar750s -- OpenWrt 19.07 ar71xx * glinet,gl-ar750s -- OpenWrt 19.07 ath79 Users who have sucessfully upgraded to glinet,gl-ar750m-nor may then flash glinet,gl-ar750m-nor-nand with sysupgrade to transtion to the NAND-based variant. Other upgrades to these images, including directly to the NAND-based glinet,gl-ar750s-nor-nand firmware, can be accomplished through U-Boot. NB: See "ath79: restrict GL-AR750S kernel build-size to 2 MB" which enables flashing of NAND factory.img with the current GL-iNet U-Boot, "U-Boot 1.1.4-gcf378d80-dirty (Aug 16 2018 - 07:51:15)" The GL-AR750S OEM U-Boot allows upload and flashing of either NOR firmware (sysupgrade.bin) or NAND firmware (factory.img) through its HTTP-based GUI. Serial connectivity is not required. The glinet,gl-ar750s-nor and glinet,gl-ar750s-nor-nand images generated after this commit flash each other directly. This commit changes the control of the USB VBUS to gpio-hog from regulator-fixed introduced by commit 0f6b944c92. This reduces the compressed kernel size by ~14 kB, with no apparent loss of functionality. No other ath79-nand boards are using regulator-fixed at this time. Note: mtd_get_mac_binary art 0x5006 does not return the proper MAC and the GL.iNet source indicates that only the 0x0 offset is valid The ar71xx targets are unmodified. Cc: Alexander Wördekemper <alexwoerde@web.de> Signed-off-by: Jeff Kletsky <git-commits@allycomm.com>
* ath79: add GL.iNet GL-AR300M16 as NOR-only boardJeff Kletsky2019-11-141-0/+12
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The GL.iNet GL-AR300M series of devices includes variants without NAND and only the 16 MB NOR flash. These include the GL-AR300M16 and the GL-AR300M-Lite (already with its own board name). This board-name addition provides disambiguation from the NAND-bearing GL-AR300M devices, both for OpenWrt code and for end users. Kernel and firmware support for NAND and UBI will add ~320 kB to the overall firmware size at this time. This NOR-only option continues to provide more compact firmware for both the GL-AR300M16 as well as those who wish to use it as an alternate or primary, NOR-resident firmware on the GL-AR300M. The ar71xx targets are unmodified. Installation ------------ Install through OEM U-Boot (HTTP-based) or `sysupgrade --force` when booted from NOR and running OEM or OpenWrt, NOR-based firmware. As one of the intentions is disambiguation from NAND-bearing units, users who have flashed this firmware onto a device with NAND would need to use U-Boot or `sysupgrade --force` to flash firmware that again supports NAND. There are no additional SUPPORTED_DEVICES as it is not possible to determine if a device does or does not have NAND based on either the OEM's or OpenWrt's board names prior to this patch. Signed-off-by: Jeff Kletsky <git-commits@allycomm.com>
* ath79: GL-AR300M: provide NAND support; increase to 4 MB kernelJeff Kletsky2019-11-144-31/+47
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The GL.iNet GL-AR300M has been supported by the ar71xx and ath79 platforms with access to its 16 MB NOR flash, but not its 128 MB SPI NAND flash. This commit provides support for the NAND through the upstream SPI-NAND framework. Devices with both NOR and NAND flash can support independent firmware on each, with U-Boot able to boot from either. The OEM U-Boot will fall back to the NOR firmware after three "unsuccessful" boots. The family of GL-AR300M devices on the ath79 platform now includes: * glinet,gl-ar300m-lite "generic" target, NOR-only board * glinet,gl-ar300m-nand "nand" target * glinet,gl-ar300m-nor "nand" target (NAND-aware) NB: This commit increases the kernel size from 2 MB to 4 MB "Force-less" sysupgrade is presently supported from the current versions of following NOR-based firmwre images to the version of glinet,gl-ar300m-nor firmware produced by this commit: * gl-ar300m -- OEM v3 NOR ar71xx (openwrt-ar300m16-*.bin) * gl-ar300m -- OpenWrt 18.06 ar71xx * gl-ar300m -- OpenWrt 19.07 ar71xx Other upgrades to these images should be performed through U-Boot. The GL-AR300M OEM U-Boot allows upload and flashing of either NOR firmware (sysupgrade.bin) or NAND firmware (factory.img) through its HTTP-based GUI. Serial connectivity is not required. The glinet,gl-ar300m-nand and glinet,gl-ar300m-nor images generated after this commit should safely flash each other using sysupgrade. The boot counter is implemented by the OEM using u-boot-env. At this time, it does not appear that the switch on the side of the unit can be used to select NOR vs. NAND boot and the fail-over is only from NAND to NOR. To save flash wear, it is only reset when running the glinet,gl-ar300m-nand firmware. NAND-specific base-files are used to remove impact on existing generic and tiny targets. As there is now no "generic" build appropriate for the GL-AR300M16, (or for users of the GL-AR300M that do not need access to NAND) it will be introduced in a subsequent commit. Note: `mtd_get_mac_binary art 0x6` does not return the proper MAC and the GL.iNet source indicates that only the 0x0 offset is valid The ar71xx targets are unmodified. Signed-off-by: Jeff Kletsky <git-commits@allycomm.com>
* ath79: replace generic button node namesAdrian Schmutzler2019-11-0718-30/+30
| | | | | | | | | | In several DTS files, button nodes are just named buttonX or xxx_button. This replaces the names with more specific names matching the majority of key definitions. While at it, fix name of keys node in one case. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: move eth0 to parent DTSI for ar9344 TP-Link CPE devicesAdrian Schmutzler2019-11-064-28/+11
| | | | | | | | The &eth0 node is the same for all TP-Link CPE devices in ar9344, so move it to parent DTSI. While at it, do some minor DTS harmonizations. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for the TP-LINK CPE220 V3Andrew Cameron2019-11-063-125/+168
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This adds support for a popular low-cost 2.4GHz N based AP Specifications: SoC: Qualcomm Atheros QCA9533 (650MHz) RAM: 64MB Storage: 8 MB SPI NOR Wireless: 2.4GHz N based built into SoC 2x2 Ethernet: 2x 100/10 Mbps, integrated into SoC Installation: Flash factory image through stock firmware WEB UI or through TFTP To get to TFTP recovery just hold reset button while powering on for around 4-5 seconds and release. Rename factory image to recovery.bin Stock TFTP server IP:192.168.0.100 Stock device TFTP adress:192.168.0.254 This also applies some minor changes to the common DTSI: - use &wmac for label-mac-device, as this one is actually set up in common DTSI - move &eth0 to parent DTSI - fix several leading spaces, added/removed newlines Signed-off-by: Andrew Cameron <apcameron@softhome.net> [DTS style fixes/improvements, updated commit message/title] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: DTS file style update and harmonizationAdrian Schmutzler2019-11-06120-660/+749
| | | | | | | | | | | | | | | | | | This applies several style adjustments that have been requested in recent reviews to older DTS files. Despite making the code base more consistent, this will also help to reduce review time when DTSes are copy/pasted. Applied changes: - Rename gpio-keys/gpio-leds to keys/leds - Remove node labels that are not used - Use label property for partitions - Prefix led node labels with "led_" - Remove redundant includes - Harmonize new lines after status property - Several smaller style fixes Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link WBS210 v2Bernhard Geier2019-11-035-6/+30
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | TP-Link WBS210 v2 is an outdoor wireless CPE for 2.4 GHz with two Ethernet ports based on Atheros AR9344 The device is the same as TP-Link CPE220 v2, but with higher TX power (27 dBm instead of 12 dBm) and two antenna connectors instead of built-in antennas. Specifications: - SoC: Atheros AR9344 - RAM: 64MB - Storage: 8 MB SPI NOR - Wireless: 2.4GHz 300 Mbps, 2x RP-SMA connector, 27 dBm TX power - Ethernet: 1x 10/100 Mbps with 24V POE IN, 1x 10/100 Mbps Installation: Flash factory image through stock firmware WEB UI or through TFTP To get to TFTP recovery just hold reset button while powering on for around 4-5 seconds and release. Rename factory image to recovery.bin Stock TFTP server IP: 192.168.0.100 Stock device TFTP adress: 192.168.0.254 The TP-Link WBS devices use the same GPIOs as the CPE devices, except for the link4 LED. For this one, WBS devices use "2", while CPE devices use "16". (Tested on WBS210 v2) Signed-off-by: Bernhard Geier <freifunk@geierb.de> [added comment about GPIO] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: add support for TP-Link TL-WR1045ND v2Rasim Kalimullin2019-11-031-0/+9
| | | | | | | | | | | | | | | | | | | | | | | | | | | Specifications: - QCA9558 Soc - 720/800 (CPU/DDR) - 1x 10/100/1000 Mbps WAN Ethernet - 4x 10/100/1000 Mbps LAN Ethernet - 64 MB RAM (DDR2) - 8 MB FLASH - QCA9558 2.4 GHz 802.11bgn - 1x USB 2.0 Flash instruction WebUI: Download *-factory.bin image, rename to tp_firmware.bin and upload it via the firmwary upgrade function of the stock firmware WebUI. Tftp: Rename OpenWRT or original firmware to wr1045v2_tp_recovery.bin and Change your computer ip in 192.168.0.66 and subnet mask in 255.255.255.0. Router will obtain IP 192.168.0.86 for a few seconds while loading, when reset button pressed at power On. Signed-off-by: Rasim Kalimullin <neutrino.vm@gmail.com> [rebased onto base-files split] Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: remove wmac mtd-mac-address for UniFi AC familyRoger Pueyo Centelles2019-11-031-1/+1
| | | | | | | | | | | | | | | | The MAC address for the wmac 2.4 GHz radio of the Ubiquiti UniFi AC family of devices is actually embedded in the mtd-cal-data, so there is no need for mtd-mac-address (which was incorrectly forcing wmac to have the same MAC as eth0). This makes it coherent with the stock firmware and the ar71xx target: · XX:XX:XX:X0:XX:XX eth0 · XX:XX:XX:X1:XX:XX ath0/wlan1 (2.4 GHz) · XX:XX:XX:X2:XX:XX ath1/wlan0 (5 GHz) Checked on a UniFi AC Mesh, a UniFi AC LR and a UniFi Lite. Signed-off-by: Roger Pueyo Centelles <roger.pueyo@guifi.net>
* ath79: remove further redundant mtd-mac-address for wmacAdrian Schmutzler2019-11-024-4/+0
| | | | | | | | | | | | | | | For several devices, wmac MAC address is set from art 0x1002 explicitly by using mtd-mac-address although mtd-cal-data is pulled from art 0x1000. With the MAC address in 0x1002, the driver should automatically use it when reading caldata from 0x1000. Thus, remove the redundant mtd-mac-address for those devices. This patch addresses the cases where the calibration data partition is not labelled art, having been overlooked in the first patch. Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>
* ath79: fix several issues for ZyXEL NBG6716Adrian Schmutzler2019-11-021-11/+11
| | | | | | | | | | | | | This fixes several issues introduced with ZyXEL NBG6716 support: - Inhomogeneous indent - Wrong ath10k MAC patching function - Wrong brackets for pad-to in nand.mk - Add missing DEVICE_MODEL - Remove k2t.sh include (copy/paste leftover) Fixes: 99835e09992b ("ath79: add support for ZyXEL NBG6716") Signed-off-by: Adrian Schmutzler <freifunk@adrianschmutzler.de>