aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ath79
Commit message (Collapse)AuthorAgeFilesLines
* treewide: dts: Remove default-state=off property from all gpio LED nodesPetr Štetiar2018-12-1758-192/+0
| | | | | | | | | | | | | | | | | | >From the Documentation/devicetree/bindings/leds/common.txt: - default-state : The initial state of the LED. Valid values are "on", "off", and "keep". If the LED is already on or off and the default-state property is set the to same value, then no glitch should be produced where the LED momentarily turns off (or on). The "keep" setting will keep the LED at whatever its current state is, without producing a glitch. The default is off if this property is not present. So setting the default-state of the LEDs to `off` is redundant as `off` is default LED state anyway. We should remove it as almost every new PR/patch submission contains this property by default which seems to be just copy&paste from some DTS file already present in the tree. Signed-off-by: Petr Štetiar <ynezz@true.cz>
* ath79: add support for TP-Link Archer A7Karl-Felix Glatzer2018-12-176-0/+273
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This patch adds support for TP-Link Archer A7 Specification: - SOC: QCA9563 - Flash: 16 MiB (SPI) - RAM: 128 MiB (DDR2) - Ethernet: 4x 1Gbps LAN + 1x 1Gbps WAN - Wireless: - 2.4GHz (bgn) SoC internal - 5GHz (ac) QCA988x - USB: 1x USB 2.0 port - Button: 1x power, 1x reset, 1x wps - LED: 10x LEDs - UART: holes in PCB - Vcc, GND, RX, TX from ethernet port side - 115200n8 Flash instructions: Upload openwrt-ath79-generic-tplink_archer-a7-v5-squashfs-factory.bin via the Webinterface. Flash instruction using tftp recovery: 1. Connect the computer to one of the LAN ports of the Archer A7 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 ArcherC7v5_tp_recovery.bin 2. Connect power cable to Archer A7, press and hold the reset button and turn the router on 3. Keep the reset button pressed for ~5 seconds 4. Wait ~150 seconds to complete flashing Changes since first revision: - Flash instructions using stock image webinterface - Changed "Version 5" in model string to "v5" - Split DTS file in qca9563_tplink_archer-x7-v5.dtsi and qca9563_tplink_archer-a7-v5.dts - Firmware image is now build with dynamic partitioning - Default to ath10k-ct Changes since second revision: - Changed uboot@0 to uboot@20000 in DTS file - Fixed ordering issue in board led script - Specify firmware partition format in DTS file - Rebased Makefile device definition on common Device/tplink-safeloader-uimage definition - Merged switch section in network script (same configuration as tplink,tl-wdr3600 and tplink,tl-wdr4300) Signed-off-by: Karl-Felix Glatzer <karl.glatzer@gmx.de>
* ath79, brcm63xx: Fix debounce-interval properties in gpio-keys-polled nodesPetr Štetiar2018-12-171-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | This patch fixes wrong usage of debounce-interval subnode property of gpio-keys-polled nodes, which was used inproperly in parent node, but it belongs to the subnodes, excerpt from the docs: Optional subnode-properties: - debounce-interval: Debouncing interval time in milliseconds. If not specified defaults to 5. And the docs are up to date as the source code matches that description as well: if (fwnode_property_read_u32(child, "debounce-interval", &button->debounce_interval)) button->debounce_interval = 5; While at it, I've also re-formatted gpio-keys-polled nodes, usually just adding new lines after every key subnode. Cc: Tomasz Maciej Nowak <tomek_n@o2.pl> Cc: Matt Merhar <mattmerhar@protonmail.com> Cc: Jonas Gorski <jonas.gorski@gmail.com> Signed-off-by: Petr Štetiar <ynezz@true.cz>
* ath79: ag71xx: Fix code formatting in ag71xx_probePetr Štetiar2018-12-171-2/+2
| | | | Signed-off-by: Petr Štetiar <ynezz@true.cz>
* ath79: ag71xx: Unify debug output with ar71xx and make debugging easierPetr Štetiar2018-12-171-16/+32
| | | | | | | | | Currently it's quite hard to diff debugging output between ar71xx and ath79, so this patch tries to improve it by adding the same ag71xx_dump_regs function and placing debugging output from the registers to relatively same places. Signed-off-by: Petr Štetiar <ynezz@true.cz>
* ath79: add d-link dir-825-c1 and dir-835-a1Sebastian Kemper2018-12-177-8/+332
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit ports both dir-825-c1 and dir-835-a1 from ar71xx to ath79. They're pretty much identical, except dir-835-a1 has less LEDs. The routers come with 128 MByte of RAM and 16 MBytes of flash and sport 2.4GHz and 5.0GHz wireless. Both routers have entries already in OpenWrt's TOH. Please check there for more information on these antiquities. https://openwrt.org/toh/hwdata/d-link/d-link_dir-825_c1 https://openwrt.org/toh/hwdata/d-link/d-link_dir-835_a1 Installation: 1. Connect to the web interface of the vendor firmware (usually listening on 192.168.0.1). 2. Go to "Tools", then "Firmware". 3. In the "Firmware Upgrade" box click "Browse". 4. Select the OpenWrt factory image for your router. 5. Click "Upload", confirm the popups if you agree to flash the file you selected. 6. Wait for firmware upgrade to complete. It takes about 5 minutes. Run-tested on dir-825-c1. dir-835-a1 should work as well, but I don't have this router so I can't confirm. Signed-off-by: Sebastian Kemper <sebastian_ml@gmx.net> Signed-off-by: Christian Lamparter <chunkeey@gmail.com> [trivial changes]
* ath79: add support for TP-Link TL-WR842N/ND v1 routerMarcin Jurkowski2018-12-154-0/+175
| | | | | | | | | | | | | | | | | | This ports support for TP-Link TL-WR842N/ND v1 from ar71xx. CPU: Atheros AR7241 400 MHz RAM: 32 MiB FLASH: 8 MiB PORTS: 4 Port 100/10 Switch, 1 Port 100/10 Wan WiFi: Atheros AR9287 LED: SYS, WiFi, LAN, WAN, 3G, QSS BTN: WiFi, Reset/WPS AR71xx target used "tl-mr3420" as board id so force flag is needed if upgrading from old target. Signed-off-by: Marcin Jurkowski <marcin1j@gmail.com> Signed-off-by: Christian Lamparter <chunkeey@gmail.com> [trivial cleanup]
* ath79: fix dtc compiler warningsMathias Kresin2018-12-123-7/+7
| | | | | | | | | | | | The qca9557/qca956x reset-controller aren't a simple bus. A simple bus would require node unit addresses. Add the node unit addresses for the qca9557 usb phys. Add the regs for the USB_PWRCTL and USB_CONFIG registers even not yet used. Fix the wrong ar7100 pcie controller node unit address as well. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath79: dts: Use PowerCloud CAP324 bicolor status LEDDaniel F. Dickinson2018-12-061-3/+3
| | | | | | | | | PowerCloud Systems CAP324 has a bicolor power LED and OpenWrt DTS files / base files support using both colours to better inform user of state and to better match stock firmware, so use green power to indicate normal operation. Signed-off-by: Daniel F. Dickinson <cshored@thecshore.com>
* ath79: add support for I-O DATA WN-AG300DGRINAGAKI Hiroshi2018-12-065-2/+245
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | I-O DATA WN-AG300DGR is a 2T2R 2.4/5 GHz 11n router, based on Atheros AR1022. WN-AG300DGR does not have an LED to indicates power or system status, I set "router" LED as OpenWrt status LED. There is no eeprom data for 5 GHz wlan in "art" partition. Specification: - Atheros AR1022 - 64 MB of RAM (DDR2) - 8 MB of Flash (SPI-NOR) - 2T2R 2.4/5GHz wifi - 2.4 GHz: SoC internal - 5 GHz: Atheros AR93x2 - 5x 10/100/1000 Mbps Ethernet - 6x LEDs, 6x keys (4x buttons, 1x slide switch) - 1x USB 2.0 Type-A - UART through-hole on PCB - Vcc, GND, TX, RX from ethernet port side - 115200n8 Flash instruction using factory image: 1. Connect the computer to the LAN port on WN-AG300DGR 2. Connect power cable to WN-AG300DGR and turn it 3. Access to "http://192.168.0.1/" and open firmware update page ("ファームウェア") 4. Select the OpenWrt factory image and click update ("更新") button 5. Wait ~150 seconds to complete flashing Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
* ath79: add support for Winchannel WB2000Chuanhong Guo2018-12-064-2/+235
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | WB2000 is a dual-band 11N AP using AR9344. The factory firmware used the original DB120 partition table with a small kernel partition at the end of firmware and the kernel will easily get oversized in the future. Since it has to be flashed using UART I also swapped kernel/rootfs and changed the default load address. Specification: - SoC: Atheros AR9344 - RAM: 128 MB - Flash: 16 MB - Ethernet: 10/100/1000 Mbps (Atheros AR8035) - 2x USB 2.0 - WIFI: AR9344(2G) + AR9382(5G) - RTC: DS1338 Known issue: 5G ath9k led doesn't work due to commit ccab68f. Flash instruction: Set up a TFTP server on your computer and configure static IP. Connect UART (J11 TX/GND/RX) and press any key to enter U-boot shell. 1. Change the default boot command: setenv bootcmd 'bootm 0x9f050000 || bootm 0x9fd50000' saveenv 2. Set your router ipaddr and server ipaddr. e.g.: setenv ipaddr 192.168.1.1 setenv serverip 192.168.1.50 3. Load and flash the firmware: tftp 0x80060000 fw.bin erase 0x9f050000 +$filesize cp.b $fileaddr 0x9f050000 $filesize 4. Reset your router: reset Signed-off-by: Chuanhong Guo <gch981213@gmail.com> [Drop the i2c node unit address. Move the ath9k-leds node out of the spi node, it doesn't belong there. Add the #gpio-cells property to the pci wifi node. All fix dtc compiler warnings] Signed-off-by: Mathias Kresin <dev@kresin.me> merge
* ath79: fix ethernet configurations for I-O DATA ETG3-RINAGAKI Hiroshi2018-12-061-1/+13
| | | | | | | | | | | | This commit fixes several issues in eth0 on ETG3-R, and solve slowdown in NA(P)T speed. - add gmac-config with correct configurations - fix pll-data value And I added ref clock-frequency. Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
* ath79: drop unused mtd splitterMathias Kresin2018-12-061-2/+0
| | | | | | | Neither the seama nor the wrgg splitter are used at the moment. Drop them for now to not bloat the target from the beginning. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath79: remove duplicate image build variablesMathias Kresin2018-12-066-19/+9
| | | | | | | Remove image build variables which are set to the same value as the default image build recipe. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath79: fix GL.iNet GL-AR300M sysupgradeMathias Kresin2018-12-065-7/+14
| | | | | | | | | | | The userspace boardname derived from the dts compatible was out of sync with the expected board added to the image metadata. This way a sysupgrade is refused. Sync the userspace boardname and the baordname used in the image metdata to allow a seamless sasupgrade. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath79: add SoC or family compatibleMathias Kresin2018-12-0626-30/+24
| | | | | | | Add missing SoC specific compatibles and/or inherit the family compatibles like "ubnt,xm". Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath79: add AVM EVA firmware partition compatibleDavid Bauer2018-12-062-0/+2
| | | | | | | | | | This commit adds firmware partition compatible for the AVM FRITZ!Box 4020 and AVM FRITZ!WLAN Repeater 300E. This allows to select the correct mtdsplit parser instead of trying all available ones one by one. Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: Define firmware partition format to all boards where applicablePetr Štetiar2018-12-0637-0/+37
| | | | | | | | | | Parsing "firmware" partition (to create kernel + rootfs) was implemented using OpenWrt downstream code enabled by CONFIG_MTD_SPLIT_FIRMWARE. With recent upstream mtd changes we can do it in a more clean way for DTS targets. It just requires adding a proper "compatible" string to the "firmware" partition node. Signed-off-by: Petr Štetiar <ynezz@true.cz>
* ath79: rename qca9533.dtsi to qca953x.dtsiChuanhong Guo2018-12-068-11/+11
| | | | | | | | | qca9533 is a costdown version of qca9531 which doesn't have USB and PCIE. Rename the misleading dtsi names and fix the SoC type of gl-ar300m. Signed-off-by: Chuanhong Guo <gch981213@gmail.com> [apply the changes for the gl-x750 as well] Signed-off-by: Mathias Kresin <dev@kresin.me>
* apm821xx, ath79, ipq40xx, ipq806x, lantiq, ramips: base-files: Use generic ↵Petr Štetiar2018-12-061-45/+0
| | | | | | | | | | | | | | | | | | | | | | | | | | diag.sh I wanted to add status LEDs support to my imx6 based board and have found out, that I could use diag.sh script found in ramips platform, which seems to be also shared in a few other platforms: 4801276bc2078c5bcf03003c831e3b0a target/linux/ramips/base-files/etc/diag.sh 4801276bc2078c5bcf03003c831e3b0a target/linux/ipq40xx/base-files/etc/diag.sh 4801276bc2078c5bcf03003c831e3b0a target/linux/ath79/base-files/etc/diag.sh And @chunkeey suggested to me, that I can also add lantiq, ipq806x and apm821xx to the list of platforms which could share this generic diag.sh. I've extended the base diag.sh in a way, that if it detects any of the DTS LED aliases, then it would use the generic DTS set_led_state code. The code in platform's diag.sh has moved to base-files package in this commit: base-files: diag.sh: Make it more generic towards DTS so it could be reused Signed-off-by: Petr Štetiar <ynezz@true.cz> Tested-by: Christian Lamparter <chunkeey@gmail.com> (apm821xx and ipq40xx)
* ath79: add support for Ubiquiti AirRouterRussell Senior2018-12-034-1/+48
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Indoor low-power router with 2.4 GHz radio CPU: Atheros AR7241 rev 1 RAM: 32 MB Flash: 8 MB NOR SPI Switch: Atheros AR7240 Ports: 1x WAN, 4x LAN 10/100 Ethernet WLAN: Atheros AR9285 (2.4 GHz) USB: 1x USB2 host port Note: Ethernet WAN/LAN port naming is reversed from ar71xx. WAN is eth0; LAN is eth1.1. UART settings: 115200, 8N1 LEDs +-------------------------- | | | | | | | | VCC | x x RX | * x | x x | x x TX | * x GND | * x | | | | +-------------------------- ETHERNET PORTS Installation from Ubiquiti firmware, is as for other ubnt-xm AirOs devices. Signed-off-by: Russell Senior <russell@personaltelco.net>
* ath79: split ubnt outdoor device leds into separate dtsiRussell Senior2018-12-035-31/+39
| | | | | | Move common LED configuration into a separate includible dtsi. Signed-off-by: Russell Senior <russell@personaltelco.net>
* ath79: ubnt-xw: Change DTS license to GPL-2.0-or-later OR MITPetr Štetiar2018-11-291-1/+1
| | | | | | | | Having MIT as alternative is sometimes preferred by upstream maintainers and allows sharing that simple code with other projects. We don't really want multiple DTS versions for the same device. Signed-off-by: Petr Štetiar <ynezz@true.cz>
* ath79: ubnt-bullet-m-xw: Change DTS license to GPL-2.0-or-later OR MITPetr Štetiar2018-11-291-1/+1
| | | | | | | | Having MIT as alternative is sometimes preferred by upstream maintainers and allows sharing that simple code with other projects. We don't really want multiple DTS versions for the same device. Signed-off-by: Petr Štetiar <ynezz@true.cz>
* ath79: add support for ROSINSON WR818 boardRosy Song2018-11-273-0/+178
| | | | | | | | | | | | | | | | | | | | | | | | | | | This commit adds support for the ROSINSON WR818 WiFi-Router SoC: Qualcomm Atheros QCA9563, FLASH: Winbond W25Q128FV 16MBytes, WiFi: QCA9563 b/g/n 3x3 450Mbit/s, USB: 1x USB 2.0 Type A, 1x USB2.0 Type C, IN: WPS/Reset button GPIO1, OUT: Power LED red, Internet LED red, WLAN LED red, LAN1 LED red, LAN2 LED red, System LED red, UART: RX-GPIO18, TX-GPIO22, Tested and working: - Ethernet (LAN + WAN) - WiFi - OpenWRT sysupgrade - Button - LEDs Installation of OpenWRT from vendor firmware: - Connect to the Web-interface at http://192.168.1.1 - Go to "Administration" -> "Firmware Upgrade" - Upload the OpenWrt sysupgrade image Signed-off-by: Rosy Song <rosysong@rosinson.com>
* ath79: merge glinet gl-x750 dtsi and dtsMathias Kresin2018-11-272-101/+97
| | | | | | | | | The board doesn't come in different flash type flavours, hence there is no need to keep a dtsi + dts for this purpose. While at it, fix some whitespace issues. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath79: rename glinet x750Mathias Kresin2018-11-276-8/+8
| | | | | | The boardname is gl-x750 and is already used for the led names. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath79: add Archer C58/C59 partition compatibleDavid Bauer2018-11-262-0/+2
| | | | | | | | | | This commit adds firmware partition compatible for the TP-Link Archer C58 v1 and Archer C59 v1. Since a22311e this allows to select the correct mtdsplit parser instead of trying all available ones one by one. Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: add firmware partition compatible for OCEDODavid Bauer2018-11-262-0/+2
| | | | | | | | | | This commit adds firmware partition compatible for the OCEDO Raccoon and OCEDO Koala. Since a22311e this allows to select the correct mtdsplit parser instead of trying all available ones one by one. Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: specify "firmware" partition format for I-O DATA devicesINAGAKI Hiroshi2018-11-262-0/+2
| | | | | | | | | | | | Specify firmware partition format (denx,uimage) by compatible string for I-O DATA devices. affected devices (&run tested) - WN-AC1167DGR - WN-AC1600DGR2 Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
* ath79: specify "firmware" partition format for ELECOM WRC-300GHBK2-IINAGAKI Hiroshi2018-11-261-0/+1
| | | | | | | Specify firmware partition format (denx,uimage) by compatible string for ELECOM WRC-300GHBK2-I. Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
* ath79: fix shebangMathias Kresin2018-11-261-1/+1
| | | | | | | The shebang was accidentally changed with 9989fd5154fd ("ath79: add support for GL-iNet GL-X750"). Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath79: modify mtd partitions for Buffalo BHR-4GRV2INAGAKI Hiroshi2018-11-264-31/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit modifies mtd partitions define for Buffalo BHR-4GRV2 and move it to generic subtarget. In Buffalo BHR-4GRV2, "kernel" partition is located behined "rootfs" partition in the stock firmware. This causes the size of the kernel to be limited by the fixed value. 0x50000 0xe80000 0xff0000 +-------------------------------+--------------+ | rootfs | kernel | | (14528k) | (1472k) | +-------------------------------+--------------+ After ar71xx was updated to Kernel 4.14, the kernel size of BHR-4GRV2 exceeded the limit, and it breaks builds on official buildbot. Since this issue was also confirmed in ath79, I modified the mtd partitions to get rid of that limitation. 0x50000 0xff0000 +----------------------------------------------+ | firmware | | (16000k) | +----------------------------------------------+ However, this commit breaks compatibility with ar71xx firmware, so I dropped "SUPPORTED_DEVICES += bhr-4grv2". This commit requires new flash instruction instead of the old one. Flash instruction using initramfs image: 1. Connect the computer to the LAN port of BHR-4GRV2 2. Set the IP address of the computer to 192.168.12.10 3. Rename the OpenWrt initramfs image to "bhr4grv2-uImage-initramfs-gzip.bin" and place it into the TFTP directory 4. Start the tftp server on the computer 5. While holding down the "ECO" button, connect power cable to BHR-4GRV2 and turn on it 6. Flashing (orange) diag LED and release the finger from the button, BHR-4GRV2 downloads the intiramfs image from TFTP server and boot with it 7. On the initramfs image, create "/etc/fw_env.config" file with following contents /dev/mtd1 0x0 0x10000 0x10000 8. Execute following commands to add environment variables for u-boot fw_setenv ipaddr 192.168.12.1 fw_setenv serverip 192.168.12.10 fw_setenv ethaddr 00:aa:bb:cc:dd:ee fw_setenv bootcmd "bootm 0x9f050000 || bootm 0x9fe80000" 9. Perform sysupgrade with squashfs-sysupgrade image 10. Wait ~150 seconds to complete flashing And this commit includes small fix; BHR-4GRV2 has QCA9557 as a SoC, not QCA9558. Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
* ath79: Remove source-only flagRobert Marko2018-11-261-1/+1
| | | | | | | Remove the source-only flag from ath79, its supposed to replace ar71xx after next stable release but buildbots are not currently generating images for it. So in order to expand testing as much as possible and prepare for moving to ath79 lets enable the buildbots to actually build the target. Signed-off-by: Robert Marko <robimarko@gmail.com>
* ath79: specify "firmware" partition format for Buffalo devicesINAGAKI Hiroshi2018-11-264-0/+4
| | | | | | | | | | | | | | Specify firmware partition format (denx,uimage) by compatible string for Buffalo devices. affected devices (&run tested): - BHR-4GRV - WHR-G301N - WZR-HP-AG300H - WZR-HP-G302H A1A0 - WZR-HP-G450H (WZR-450HP) Signed-off-by: INAGAKI Hiroshi <musashino.open@gmail.com>
* ath79: add support for Archer C58/C59 v1David Bauer2018-11-269-1/+441
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit adds support for the Archer C58 v1 and C59 v1, previously supported in the ar71xx target. CPU: Qualcomm QCA9561 RAM: 64M (C58) / 128M (C59) FLASH: 8M (C58) / 16M (C59) WiFi: QCA9561 bgn 3x3:3 QCA9888 nac 2x2:2 LED: Power, WiFi 2.4, WiFi 5, WAN green, WAN amber, LAN, WPS Only C59: USB BTN: WPS, WiFi, Reset Installation ------------ Via Web-UI: Update factory image via Web-UI. Via TFTP: Rename factory image to "tp_recovery.bin" and place it in the root-dir of your tftp server. Configure to listen on 192.168.0.66. Power up the router while holding down the reset-button. The router will flash itself and reboot. Note: For TFTP, you might need a switch between router and computer, as link establishment might take to long. Signed-off-by: David Bauer <mail@david-bauer.net>
* ath79: add support for GL-iNet GL-X750Luo chongjun2018-11-266-2/+159
| | | | | | | | | | | | | | | | | | | this patch adds supports for GL-X750. Specification: - SOC: QCA9531 (650MHz) - Flash: 16 MiB (W25Q128FVSG) - RAM: 128 MiB DDR2 - Ethernet: 10/100: 1xLAN + 10/100: 1xWAN - Wireless: 2.4GHz (bgn) and 5GHz (ac) - USB: 1x USB 2.0 port - Button: 1x reset button - LED: 5x LEDS (green) Flash instruction: The original firmware is openwrt, so both LuCI or sysupgrade can be used. Signed-off-by: Luo chongjun <luochongjun@gl-inet.com>
* ath79: ubnt-m-xw: Fix factory image flashing using TFTP recovery methodPetr Štetiar2018-11-261-2/+8
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Ubiquity allows flashing of unsigned factory images via TFTP recovery method[1]. They claim in airOS v6.0.7 release changelog[2] following: All future airOS versions will be signed in this way and not allow unsigned firmware to be loaded except via TFTP. U-boot bootloader on M-XW devices expects factory image revision version in specific format. On airOS v6.1.7 with `U-Boot 1.1.4-s1039 (May 24 2017 - 15:58:18)` bootloader checks if the revision major(?) number is actually a number, but in currently generated images there's OpenWrt text and so the check fails: Hit any key to stop autoboot: 0 Setting default IP 192.168.1.20 Starting TFTP server... Receiving file from 192.168.1.25:38438 Received 4981148 bytes Firmware check failed! (1) By placing arbitrary correct number first in major version, we make the bootloader happy and we can flash factory images over TFTP again: Received 3735964 bytes Firmware Version: XW.ar934x.v6.0.4-42.r8474-56aa1ac-OpenWrt Setting U-Boot environment variables Un-Protected 1 sectors Erasing Flash.... done Patch provided by AREDN[3] project, tested on Bullet M2 XW (ynezz) and Nanostation M5 XW (ae6xe). 1. https://help.ubnt.com/hc/en-us/articles/204910124-UniFi-TFTP-Recovery-for-Bricked-Access-Points 2. https://dl.ubnt.com/firmwares/XW-fw/v6.0.7/changelog.txt 3. https://github.com/aredn Signed-off-by: Petr Štetiar <ynezz@true.cz>
* ath79: Add support for Ubiquity Bullet M (XW)Petr Štetiar2018-11-265-0/+171
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | CPU: AR9342 SoC RAM: 64 MB DDR2 Flash: 8 MB NOR SPI Ports: 100 MBit (24V PoE in) WLAN: 2.4/5 GHz UART: 1 UART on PCB marked as J1 with 115200 8N1 config LEDs: Power, Ethernet, 4x RSSI LEDs (orange, red, 2x green) Buttons: Reset UART connection details .---------------------------------. | | [ETH] J1 [ANT] | o VCC o RX o TX o GND | `---------------------------------' Flashing instructions A) Serial console, U-Boot and TFTP 1. Connect to serial header J1 on the PCB 2. Power on device and enter U-Boot console 3. Set up TFTP server serving an OpenWrt initramfs build 4. Load initramfs build using the command tftpboot in the U-Boot cli 5. Boot the loaded image using the command bootm 6. Copy squashfs OpenWrt sysupgrade build to the booted device 7. Use mtd to write sysupgrade to partition "firmware" 8. Reboot and enjoy B) Experimental factory image flashing over SSH from airOS v6.1.7 1. You need to flash your UBNT M2HP with airOS v6.1.7 firmware no other airOS version is currently supported 2. git clone https://github.com/true-systems/ubnt-bullet-m2hp-openwrt-flashing 3. cd ubnt-bullet-m2hp-openwrt-flashing 4. make flash-factory FW_OWRT=/path/to/your/openwrt-ath79-generic-ubnt_bullet-m-xw-squashfs-factory.bin Tested only on Bullet M2HP. Signed-off-by: Petr Štetiar <ynezz@true.cz>
* ath79: specify "firmware" partition format for Ubiquiti UniFiRafał Miłecki2018-11-241-0/+1
| | | | | | | | | | | | This affects: 1. Ubiquiti UniFi-AC-LITE/LR 2. Ubiquiti UniFi-AC-PRO 3. Ubiquiti UniFi-AC-MESH 4. Ubiquiti UniFi-AC-MESH PRO Succesfully tested on UniFi AP AC Pro. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* ath79: specify "firmware" partition format for WNDR3700 and v2Hannu Nyman2018-11-242-0/+2
| | | | | | | | Specify the new "firmware" partition format for Netgear WNDR3700 and WNDR3700v2 similarly as ffd082aa did for WNDR3800, the third device in the family. Signed-off-by: Hannu Nyman <hannu.nyman@iki.fi>
* ath79: specify "firmware" partition format for TP-LINK Archer C7 v2Rafał Miłecki2018-11-241-1/+2
| | | | | | With this change it doesn't require trying parsers one by one. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* ath79: specify "firmware" partition format for Netgear WNDR3800Rafał Miłecki2018-11-241-0/+1
| | | | | | It doesn't require trying parsers one by one. Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
* kernel: bump 4.14 to 4.14.79Koen Vandeputte2018-11-053-3/+3
| | | | | | | | | Refreshed all patches. Compile-tested on: ar71xx, cns3xxx, imx6, x86_64 Runtime-tested on: ar71xx, cns3xxx, imx6, x86_64 Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
* ath79: fix PQI Air Pen supportMathias Kresin2018-10-281-0/+0
| | | | | | Use the correct dts filename. It has to be <soc>_<manufacturer>_<device>. Signed-off-by: Mathias Kresin <dev@kresin.me>
* ath79: add support for PQI Air PenYuheiOKAWA2018-10-284-0/+160
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SoC: AR9330 (or AR9331 revision?) Ethernet x1, Wireless 2.4G, uSD card slot x1. USB Power, include Li-Po Battery. Flash 8MiB. (factory is dual image) 1. write image is use half 4MiB size from factory. write initramfs image to mtd6 and mtd7. 2. change next boot setting. next is mtd6 boot. echo -ne "\x01" | dd of=/dev/mtdblock8 conv=notrunc bs=1 count=1 seek=0 3. rewrite sysupgrade image. change next boot setting. next is mtd4. echo -ne "\x00" | dd of=/dev/mtdblock8 conv=notrunc bs=1 count=1 seek=0 OEM mtd. dev: size erasesize name mtd0: 00040000 00010000 "u-boot" mtd1: 00010000 00010000 "u-boot-env" mtd2: 00010000 00010000 "ART" mtd3: 00010000 00010000 "NVRAM" mtd4: 00140000 00010000 "uImage" mtd5: 00280000 00010000 "rootfs" mtd6: 00140000 00010000 "uImage2" mtd7: 00280000 00010000 "rootfs2" mtd8: 00010000 00010000 "CONF" Signed-off-by: YuheiOKAWA <tochiro.srchack@gmail.com>
* ath79: Add support for Ubiquiti LiteAP ac (LAP-120)Roger Pueyo Centelles2018-10-284-0/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | This commit adds support for the Ubiquiti LiteAP ac (LAP-120), an outdoor 5 GHz AC access point with an integrated 120° 16 dBi antenna. The device was previously known as LiteBeam AP ac but was later rebranded. CPU: Atheros AR9342 SoC RAM: 64 MB DDR2 Flash: 16 MB NOR SPI Ports: 1 GbE port (PoE in) WLAN: 5 GHz QCA899X (PCI) The integrated QCA899X is a Ubiquiti branded part with modified vendor and product id (0777:11ac9). It is very similar to the NanoStation loco AC, except for the 2.4 GHz management radio (missing here). Installation procedure is the same as the NanoStation [loco] AC: 1. Connect to serial header on device 2. Power on device and enter uboot console 3. Set up tftp server serving an openwrt initramfs build 4. Load initramfs build using the command tftpboot in the uboot cli 5. Boot the loaded image using the command bootm 6. Copy squashfs openwrt sysupgrade build to the booted device 7. Use mtd to write sysupgrade to partition "firmware" 8. Reboot and enjoy Signed-off-by: Roger Pueyo Centelles <roger.pueyo@guifi.net>
* ar71xx/ath79: fix mtd corruptionFabio Bettoni2018-10-171-0/+64
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | In commit fec8fe806963 ("kernel: bump 4.9 to 4.9.116") [1], the following patch for removed: - 403-mtd_fix_cfi_cmdset_0002_status_check.patch This patch contained fixes for both write and erase functions. While the chip-detects for erase got fixed upstream [2], some modifications are still required, even with the fixes applied. While at it, also apply the same fix for target ath79, which suffers the same issue. Not doing so results in following errors seen: Collected errors: * pkg_write_filelist: Failed to open //usr/lib/opkg/info/luci-lib-ip.list: I/O error. * opkg_install_pkg: Failed to extract data files for luci-lib-ip. Package debris may remain! * opkg_install_cmd: Cannot install package luci-ssl. * opkg_conf_write_status_files: Can't open status file //usr/lib/opkg/status: I/O error. [ 0.780920] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc. [ 8.406396] jffs2: notice: (415) jffs2_build_xattr_subsystem: complete building xattr subsystem, 0 of xdatum (0 unchecked, 0 orphan) and 0 of xref (0 dead, 0 orphan) found. [ 8.423476] mount_root: switching to jffs2 overlay [ 270.902671] jffs2: Write of 1989 bytes at 0x005ce6f8 failed. returned -5, retlen 962 [ 270.931965] jffs2: Write of 1989 bytes at 0x005ceec0 failed. returned -5, retlen 0 [ 270.939631] jffs2: Not marking the space at 0x005ceec0 as dirty because the flash driver returned retlen zero [ 270.950397] jffs2: Write of 68 bytes at 0x005ceec0 failed. returned -5, retlen 0 [ 270.957838] jffs2: Not marking the space at 0x005ceec0 as dirty because the flash driver returned retlen zero [ 270.968584] jffs2: Write of 68 bytes at 0x005ceec0 failed. returned -5, retlen 0 [ 270.976027] jffs2: Not marking the space at 0x005ceec0 as dirty because the flash driver returned retlen zero [ 270.986735] jffs2: Write of 68 bytes at 0x005ceec0 failed. returned -5, retlen 0 [ 270.994225] jffs2: Not marking the space at 0x005ceec0 as dirty because the flash driver returned retlen zero [1] https://git.openwrt.org/?p=openwrt/openwrt.git;a=commit;h=fec8fe806963c96a6506c2aebc3572d3a11f285f [2] https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v4.9.133&id=a0239d83e1cb60de5e78452d4708c083b9e3dcbe Fixes: fec8fe806963 ("kernel: bump 4.9 to 4.9.116") Signed-off-by: Fabio Bettoni <fbettoni@gmail.com> Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>
* treewide: use wpad-basic for not small flash targetsMathias Kresin2018-10-164-1/+7
| | | | | | | | | | | | Add out of the box support for 802.11r and 802.11w to all targets not suffering from small flash. Signed-off-by: Mathias Kresin <dev@kresin.me> Mathias did all the heavy lifting on this, but I'm the one who should get shouted at for committing. Signed-off-by: Kevin Darbyshire-Bryant <ldir@darbyshire-bryant.me.uk>
* kernel: bump 4.14 to 4.14.75Koen Vandeputte2018-10-101-1/+1
| | | | | | | | | Refreshed all patches. Compile-tested on: ar71xx, cns3xxx, imx6 Runtime-tested on: ar71xx, cns3xxx, imx6 Signed-off-by: Koen Vandeputte <koen.vandeputte@ncentric.com>