aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ipq40xx
Commit message (Collapse)AuthorAgeFilesLines
* ipq4019: fix support for AVM FRITZ!Repeater 3000Alexander Friese2023-07-271-0/+3
| | | | | | | | | new versions of the device have NAND with 8bit ECC which was not yet supported before. This change removes ECC restrictions. Signed-off-by: Alexander Friese <af944580@googlemail.com> (cherry picked from commit 6b11f0ec83ceb9747dcbb0ffca0882b90da46b59)
* ipq40xx: add support for Teltonika RUTX50David Bauer2023-07-265-2/+203
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Hardware -------- CPU: Qualcomm IPQ4018 RAM: 256M Flash: 16MB SPI-NOR (W25Q128) 128MB SPI-NAND (XTX) WiFi: 2T2R (2GHz 802.11n ; 5 GHz 802.11ac) ETH: 4x LAN ; 1x WAN (Gigabit) CELL: Quectel RG501Q 3G/4G/5G UART: Available on the goldfinger connector (Pinout silkscreened) 115200 8N1 3V3 - Only connect RX / TX / GND Installation ------------ 1. Enable SSH in the Teltonika UI (System --> Administration --> Access Control) 2. Check from which partition set the device is currently running from. $ cat /proc/boot_info/rootfs/primaryboot In case this output reads 0, install a Software update from Teltonika first. After upgrade completion, check this file now reads 1 before continuing. 2. Transfer the OpenWrt factory image to the device using scp. Use the same password (user root!) as used for the Web-UI. $ scp -O openwrt-factory.bin root@192.168.1.1:/tmp 3. Connect to the device using ssh as the root user. 4. Install OpenWrt by writing the factory image to flash. $ ubiformat /dev/mtd16 -y -f /tmp/openwrt-factory.bin 5. Instruct the bootloaer to boot from the first partition set. $ echo 0 > /proc/boot_info/rootfs/primaryboot $ cat /proc/boot_info/getbinary_bootconfig > /tmp/bootconfig.bin $ cat /proc/boot_info/getbinary_bootconfig1 > /tmp/bootconfig1.bin $ mtd write /tmp/bootconfig.bin /dev/mtd2 $ mtd write /tmp/bootconfig1.bin /dev/mtd3 6. Reboot the device. $ reboot Signed-off-by: David Bauer <mail@david-bauer.net> (cherry picked from commit 844bb4bfad84cc6267f9b138d1f63b07ed3b77d0)
* ipq40xx: move Teltonika RUT STM32 IO to specific DTSDavid Bauer2023-07-262-37/+37
| | | | | | | Prepare to re-use the DTS for the RUTX50. Signed-off-by: David Bauer <mail@david-bauer.net> (cherry picked from commit dbc4be142e206e681ac53afa3fd1e4018e7843b7)
* ipq-wifi: fix upstream board-2.bin ZTE M289F snafuChristian Lamparter2023-07-041-1/+1
| | | | | | | | | | | | | | | | | | | | | The upstream board-2.bin file in the linux-firmware.git repository for the QCA4019 contains a packed board-2.bin for this device for both 2.4G and 5G wifis. This isn't something that the ath10k driver supports. Until this feature either gets implemented - which is very unlikely -, or the upstream boardfile is mended (both, the original submitter and ath10k-firmware custodian have been notified). OpenWrt will go back and use its own bespoke boardfile. This unfortunately means that 2.4G and on some revisions the 5G WiFi is not available in the initramfs image for this device. Fixes: #12886 Reported-by: Christian Heuff <christian@heuff.at> Debugged-by: Georgios Kourachanis <geo.kourachanis@gmail.com> Signed-off-by: Christian Lamparter <chunkeey@gmail.com> (cherry picked from commit 75505c5ec724b9b961dcb411bac1d4b9aede3e1d)
* ipq4019: add support for ZTE MF287+ aka DreiNeoAndreas Böhler2023-07-014-0/+408
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The ZTE MF287+ is a LTE router used (exclusively?) by the network operator "3". The MF287 (i.e. non-plus aka 3Neo) is also supported (the only difference is the LTE modem) Specifications ============== SoC: IPQ4018 RAM: 256MiB Flash: 8MiB SPI-NOR + 128MiB SPI-NAND LAN: 4x GBit LAN LTE: ZTE Cat12 (MF287+) / ZTE Cat6 (MF287) WiFi: 802.11a/b/g/n/ac SoC-integrated MAC addresses ============= LAN: from config + 2 WiFi 1: from config WiFi 2: from config + 1 Installation ============ Option 1 - TFTP --------------- TFTP installation using UART is preferred. Disassemble the device and connect serial. Put the initramfs image as openwrt.bin to your TFTP server and configure a static IP of 192.168.1.100. Load the initramfs image by typing: setenv serverip 192.168.1.100 setenv ipaddr 192.168.1.1 tftpboot 0x82000000 openwrt.bin bootm 0x82000000 From this intiramfs boot you can take a backup of the currently installed partitions as no vendor firmware is available for download: ubiattach -m14 cat /dev/ubi0_0 > /tmp/ubi0_0 cat /dev/ubi0_1 > /tmp/ubi0_1 Copy the files /tmp/ubi0_0 and /tmp/ubi0_1 somewhere save. Once booted, transfer the sysupgrade image and run sysupgrade. You might have to delete the stock volumes first: ubirmvol /dev/ubi0 -N ubi_rootfs ubirmvol /dev/ubi0 -N kernel Option 2 - From stock firmware ------------------------------ The installation from stock requires an exploit first. The exploit consists of a backup file that forces the firmware to download telnetd via TFTP from 192.168.0.22 and run it. Once exploited, you can connect via telnet and login as admin:admin. The exploit will be available at the device wiki page. Once inside the stock firmware, you can transfer the -factory.bin file to /tmp by using "scp" from the stock frmware or "tftp". ZTE has blocked writing to the NAND. Fortunately, it's easy to allow write access - you need to read from one file in /proc. Once done, you need to erase the UBI partition and flash OpenWrt. Before performing the operation, make sure that mtd13 is the partition labelled "rootfs" by calling "cat /proc/mtd". Complete commands: cd /tmp tftp -g -r factory.bin 192.168.0.22 cat /proc/driver/sensor_id flash_erase /dev/mtd13 0 0 dd if=/tmp/factory.bin of=/dev/mtdblock13 bs=131072 Afterwards, reboot your device and you should have a working OpenWrt installation. Restore Stock ============= Option 1 - via UART ------------------- Boot an OpenWrt initramfs image via TFTP as for the initial installation. Transfer the two backed-up files to your box to /tmp. Then, run the following commands - replace $kernel_length and $rootfs_size by the size of ubi0_0 and ubi0_1 in bytes. ubiattach -m 14 ubirmvol /dev/ubi0 -N kernel ubirmvol /dev/ubi0 -N rootfs ubirmvol /dev/ubi0 -N rootfs_data ubimkvol /dev/ubi0 -N kernel -s $kernel_length ubimkvol /dev/ubi0 -N ubi_rootfs -s $rootfs_size ubiupdatevol /dev/ubi0_0 /tmp/ubi0_0 ubiupdatevol /dev/ubi0_1 /tmp/ubi0_1 Option 2 - from within OpenWrt ------------------------------ This option requires to flash an initramfs version first so that access to the flash is possible. This can be achieved by sysupgrading to the recovery.bin version and rebooting. Once rebooted, you are again in a default OpenWrt installation, but no partition is mounted. Follow the commands from Option 1 to flash back to stock. LTE Modem ========= The LTE modem is similar to other ZTE devices and controls some more LEDs and battery management. Configuring the connection using uqmi works properly, the modem provides three serial ports and a QMI CDC ethernet interface. Signed-off-by: Andreas Böhler <dev@aboehler.at> (cherry picked from commit f70ee53b08466f612546f699c556cbdaa39e1466)
* ipq40xx: Enable gpio-restart in kernel configurationAndreas Böhler2023-07-011-0/+1
| | | | | | | | Some ZTE devices require the gpio-restart driver to support restarting the LTE modem along with OpenWrt Signed-off-by: Andreas Böhler <dev@aboehler.at> (cherry picked from commit 9ffdaa7fa1478146b5d8c77d4b3a5d4d4007a487)
* ipq40xx: meraki-mr33, meraki-mr74: disable image generationLech Perczak2023-06-251-0/+2
| | | | | | | | | | | | | | After migrating to kernel 5.15, upgrading causes the units to become soft-bricked, hanging forever at the kernel startup. Kernel size limitation of 4000000 bytes is suspected here, but this is not fully confirmed. Disable the images to protect users from inadvertent bricking of units, because recovery of those is painful with Cisco's U-boot, until the root cause is found and fixed. Signed-off-by: Lech Perczak <lech.perczak@gmail.com> (cherry picked from commit 9d64cc068fbb15d9e6498c1eba79851823b2f4f5)
* ipq40xx: convert Buffalo WTR-M2133HP to DSAYanase Yuki2023-06-083-2/+31
| | | | | | | This commit convert WTR-M2133HP to DSA setup. Signed-off-by: Yanase Yuki <dev@zpc.sakura.ne.jp> (cherry picked from commit edb3a4162c0763ecc9d5e7660700a68a25bf28e3)
* ipq40xx: e2600ac-c1 remove KERNEL_SIZE张 鹏2023-05-311-2/+0
| | | | | | | | | | Currently, e2600ac-c1 cannot be built as the kernel is larger than the defined KERNEL_SIZE, however, there is no bootloader limit for the kernel size so remove KERNEL_SIZE completely. Signed-off-by: 张 鹏 <sd20@qxwlan.com> [ improve commit title, fix merge conflict ] Signed-off-by: Christian Marangi <ansuelsmth@gmail.com> (cherry picked from commit b764268acb7ed410d1d81e783f1b0ce407efda82)
* ipq40xx: add e2600ac c2 to dsa张 鹏2023-05-313-2/+44
| | | | | | | | | Convert E2600ac c2 to DSA and enable it. Signed-off-by: 张 鹏 <sd20@qxwlan.com> [ rename port to more generic name ] Signed-off-by: Christian Marangi <ansuelsmth@gmail.com> (cherry picked from commit 0dca52cf595cedcabec5d384ddc83f1954cca46d)
* ipq40xx: add e2600ac c1 to dsa张 鹏2023-05-313-2/+36
| | | | | | | | | Convert E2600ac c1 to DSA and enable it. Signed-off-by: 张 鹏 <sd20@qxwlan.com> [ rename port to more generic name ] Signed-off-by: Christian Marangi <ansuelsmth@gmail.com> (cherry picked from commit 7f2ecab0f4623e9b437b1a6656275695ac063fe4)
* kernel: remove obsolete kernel version switchesAleksander Jan Bajkowski2023-05-202-77/+0
| | | | | | | This removes unneeded kernel version switches from the targets after kernel 5.10 has been dropped. Signed-off-by: Aleksander Jan Bajkowski <olek2@wp.pl>
* ipq40xx: convert EZVIZ CS-W3-WD1200G-EUP to DSAChristian Lamparter2023-05-203-2/+38
| | | | | | Convert the repeater to DSA. Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
* ipq40xx: fix rebooting after 5.15.111Robert Marko2023-05-181-0/+27
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Kernel 5.15.111 includes backport of commit ("firmware: qcom_scm: Clear download bit during reboot") which is causing reboot on ipq40xx to stop working, more precisely the board will hang after reboot is called with: root@OpenWrt:/# reboot root@OpenWrt:/# [ 76.473541] device lan1 left promiscuous mode [ 76.474204] br-lan: port 1(lan1) entered disabled state [ 76.527975] device lan2 left promiscuous mode [ 76.530301] br-lan: port 2(lan2) entered disabled state [ 76.579376] device lan3 left promiscuous mode [ 76.581698] br-lan: port 3(lan3) entered disabled state [ 76.638434] device lan4 left promiscuous mode [ 76.638777] br-lan: port 4(lan4) entered disabled state [ 76.978489] qca8k-ipq4019 c000000.switch wan: Link is Down [ 76.978883] device eth0 left promiscuous mode [ 76.987077] ipqess-edma c080000.ethernet eth0: Link is Down [ Format: Log Type - Time(microsec) - Message - Optional Info Log Type: B - Since Boot(Power On Reset), D - Delta, S - Statistic S - QC_IMAGE_VERSION_STRING=BOOT.BF.3.1.1-00123 S - IMAGE_VARIANT_STRING=DAABANAZA S - OEM_IMAGE_VERSION_STRING=CRM S - Boot Config, 0x00000021 S - Reset status Config, 0x00000010 S - Core 0 Frequency, 0 MHz B - 261 - PBL, Start B - 1339 - bootable_media_detect_entry, Start B - 1679 - bootable_media_detect_success, Start B - 1693 - elf_loader_entry, Start B - 5076 - auth_hash_seg_entry, Start B - 7223 - auth_hash_seg_exit, Start B - 578349 - elf_segs_hash_verify_entry, Start B - 696356 - PBL, End B - 696380 - SBL1, Start B - 787236 - pm_device_init, Start D - 7 - pm_device_init, Delta B - 788701 - boot_flash_init, Start D - 52782 - boot_flash_init, Delta B - 845625 - boot_config_data_table_init, Start D - 3836 - boot_config_data_table_init, Delta - (419 Bytes) B - 852841 - clock_init, Start D - 7566 - clock_init, Delta B - 864883 - CDT version:2,Platform ID:9,Major ID:0,Minor ID:0,Subtype:64 B - 868413 - sbl1_ddr_set_params, Start B - 873402 - cpr_init, Start D - 2 - cpr_init, Delta B - 877842 - Pre_DDR_clock_init, Start D - 4 - Pre_DDR_clock_init, Delta D - 13234 - sbl1_ddr_set_params, Delta B - 891155 - pm_driver_init, Start D - 2 - pm_driver_init, Delta B - 909105 - Image Load, Start B - 1030210 - Boot error ocuured!. Error code: 303d So, until a proper fix is found, lets revert the culprit patch to have reboot working again. Fixes: 228e0e10398b ("kernel: bump 5.15 to 5.15.111") Signed-off-by: Robert Marko <robimarko@gmail.com>
* ipq-wifi: drop upstreamed board-2.binChristian Lamparter2023-05-181-20/+10
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The BDFs for the: Aruba AP-365 Devolo Magic 2 WiFi next Edgecore ECW5410 Edgecore OAP100 Extreme Networks WS-AP3915i GL.iNet GL-A1300 GL.iNet GL-AP1300 GL.iNet GL-S1300 Linksys EA8300 Linksys WHW03v2 Nokia Wi4A AC400i P&W R619AC Pakedge WR-1 Qxwlan E2600AC C1 Sony NCP-HG100/Cellular Teltonika RUTX10 ZTE MF18A were upstreamed to the ath10k-firmware repository and landed in linux-firmware.git. Furthermore the BDFs for the: 8devices Habanero 8devices Jalapeno Qxwlan E2600AC C2 have been updated. Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
* ipq40xx: 5.15: add patch commenting unused sdhci functionChristian Marangi2023-05-121-0/+108
| | | | | | | | | | | | Add patch commenting unused sdhci function, hopin this will be dropped when the problem is actually found. Fix compilation warning: drivers/mmc/host/sdhci-msm.c:1781:13: error: 'sdhci_msm_set_clock' defined but not used [-Werror=unused-function] 1781 | static void sdhci_msm_set_clock(struct sdhci_host *host, unsigned int clock) | ^~~~~~~~~~~~~~~~~~~ cc1: all warnings being treated as errors Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq40xx: add PSGMII PHY mode to phylink_get_linkmodes()Robert Marko2023-05-121-4/+12
| | | | | | | | | | | | | | | Upstream commit ("net: phylink: add generic validate implementation") was backported, however PSGMII PHY mode patch for ipq40xx was not updated to add PSGMII to phylink_get_linkmodes() so the following warning would be printed during kernel compilation: drivers/net/phy/phylink.c: In function 'phylink_get_linkmodes': drivers/net/phy/phylink.c:360:9: error: enumeration value 'PHY_INTERFACE_MODE_PSGMII' not handled in switch [-Werror=switch] 360 | switch (interface) { | ^~~~~~ Resolve the warning by adding the PSGMII mode to phylink_get_linkmodes(). Signed-off-by: Robert Marko <robimarko@gmail.com>
* kernel: improve handling of CONFIG_IO_URINGTony Ambardar2023-05-031-1/+0
| | | | | | | | | | | | | | | | | | | | | | Kernel setting CONFIG_IO_URING supports high-performance I/O for file access and servers, generally for more performant platforms, and adds ~45 KB to kernel sizes. The need for this on less "beefy" devices is questionable, as is the size cost considering many platforms have kernel size limits which require tricky repartitioning if outgrown. The size cost is also large relative to the ~180 KB bump expected between major OpenWRT kernel releases. No OpenWrt packages have hard dependencies on this; samba4 and mariadb can take advantage if available (+KERNEL_IO_URING:liburing) but otherwise build and work fine. Since CONFIG_IO_URING is already managed via the KERNEL_IO_URING setting in Config-kernel.in (default Y), remove it from those target configs which unconditionally enable it, and update the defaults to enable it conditionally only on more powerful 64-bit x86 and arm devices. It may still be manually enabled as needed for high-performance custom builds. Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
* kernel: fix handling of CONFIG_DYNAMIC_DEBUGTony Ambardar2023-05-031-1/+0
| | | | | | | | | | Since CONFIG_DYNAMIC_DEBUG is already managed via the KERNEL_DYNAMIC_DEBUG setting in Config-kernel.in (default N), remove or disable it in target configs which unconditionally enable it, along with the related setting CONFIG_DYNAMIC_DEBUG_CORE. This saves several KB in the kernels for ipq40xx, ipq806x, filogic, mt7622, qoriq, and sunxi. Signed-off-by: Tony Ambardar <itugrok@yahoo.com>
* ipq40xx: convert AVM FRITZ!Repeater 3000 to DSANick Hainke2023-05-033-2/+22
| | | | | | Convert the repeater to DSA. Signed-off-by: Nick Hainke <vincent@systemli.org>
* kernel: bump 5.15 to 5.15.109John Audia2023-04-301-1/+1
| | | | | | | | | | | | | | | Removed upstreamed: backport-5.15/743-v6.3-0005-net-dsa-b53-mmap-add-phy-ops.patch[1] All other patches automatically rebased. 1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.109&id=357fa038d93d0e9159a0f0d45bae0f8654e2ade5 Build system: x86_64 Build-tested: bcm2711/RPi4B, ramips/tplink_archer-a6-v3, filogic/xiaomi_redmi-router-ax6000-ubootmod Run-tested: bcm2711/RPi4B, ramips/tplink_archer-a6-v3, filogic/xiaomi_redmi-router-ax6000-ubootmod Signed-off-by: John Audia <therealgraysky@proton.me>
* ipq40xx: convert GL-AP1300 to DSANick Hainke2023-04-244-6/+37
| | | | | | | | | | Convert GL-AP1300 to DSA and enable it. While working on it rename the GL-AP1300 leds from green to white. Tested-by: Rob White <rob@blue-wave.net> Tested-by: Robert Sommer <frauhottelmann@gmail.com> Signed-off-by: Nick Hainke <vincent@systemli.org>
* ipq40xx: convert AP-365 to DSADavid Bauer2023-04-152-2/+2
| | | | | | | | | Re-enable the Aruba AP-365 with DSA support. Changes are trvivial, as the board design is pretty much the already updated AP-303. Run-tested on the device. Signed-off-by: David Bauer <mail@david-bauer.net>
* base-files: fix Linksys upgrade, restore config stepMichael Trinidad2023-04-111-1/+1
| | | | | | | | | | | | | It appears that the refactor of the upgrade process for NAND devices resulted in the nand_do_upgrade_success step not being called for devices using the linksys.sh script. As a result, configuration was not preserved over sysupgrade steps. This corrects a typo in the call of nand_do_upgrade_failed for ipq40xx and ipq806x devices using the linksys.sh script. Fixes: 8634c1080d50 ("ipq40xx: Fix Linksys upgrade, restore config step") Fixes: 2715aff5df83 ("ipq806x: Fix Linksys upgrade, restore config step") Signed-off-by: Michael Trinidad <trinidude4@hotmail.com>
* ipq40xx: add LED functions for Google WiFiJan-Niklas Burfeind2023-03-311-2/+9
| | | | | | | | | | | | | | | | | Add LED function properties for the LED controller to avoid failing driver probe with kernel 5.15. While at it, also define the OpenWrt LED indicator patterns for this device. Ref commit 583ac0e11df7 ("mpc85xx: update lp5521 led-controller node for 5.10") Google uses white for running and red for an issue Signed-off-by: Jan-Niklas Burfeind <git@aiyionpri.me> Tested-by: Andrijan Möcker <amo@ct.de> Reviewed-by: Brian Norris <computersforpeace@gmail.com> Signed-off-by: David Bauer <mail@david-bauer.net>
* ipq40xx: add reset button for Google WiFi (Gale)Jan-Niklas Burfeind2023-03-311-1/+14
| | | | | | | | | | Add the external reset button for use with OpenWrt. Co-authored-by: Brian Norris <computersforpeace@gmail.com> Signed-off-by: Jan-Niklas Burfeind <git@aiyionpri.me> Reviewed-by: Brian Norris <computersforpeace@gmail.com> Tested-by: Brian Norris <computersforpeace@gmail.com> Signed-off-by: David Bauer <mail@david-bauer.net>
* ipq40xx: Fix Linksys upgrade, restore config stepJeff Kletsky2023-03-261-1/+6
| | | | | | | | | | | | | | | | | | | | It appears that the refactor of the upgrade process for NAND devices resulted in the nand_do_upgrade_success step not being called for devices using the linksys.sh script. As a result, configuration was not preserved over sysupgrade steps. This was restored for some devices in commit 84ff6c90dda1 ("base-files: bring back nand_do_upgrade_success"). This restored preservation of config for ipq40xx devices using the linksys.sh script. Other devices and targets have not been examined. Closes: #11677 Fixes: e25e6d8e54 ("base-files: fix and clean up nand sysupgrade code") Tested-on: EA8300 Signed-off-by: Jeff Kletsky <git-commits@allycomm.com> (checkpatch nitpick) Signed-off-by: Christian Lamparter <chunkeey@gmail.com>
* ipq40xx: add support for Wallystech DR40x9Robert Marko2023-03-215-1/+441
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Adds support for the Wallys DR40x9 series boards. They come in IPQ4019 and IPQ4029 versions. IPQ4019/4029 only differ in that that IPQ4029 is the industrial version that is rated to higher temperatures. Specifications are: * CPU: Qualcomm IPQ40x9 (4x ARMv7A Cortex A7) at 716 MHz * RAM: 512 MB * Storage: 2MB of SPI-NOR, 128 MB of parallel NAND * USB 3.0 TypeA port for users * MiniPCI-E with PCI-E 2.0 link * MiniPCI-E for LTE modems with only USB2.0 link * 2 SIM card slots that are selected via GPIO11 * MicroSD card slot * Ethernet: 2x GBe with 24~48V passive POE * SFP port (Does not work, I2C and GPIO's not connected on hardware) * DC Jack * UART header * WLAN: In-SoC 2x2 802.11b/g/n and 2x2 802.11a/n/ac * 4x MMCX connectors for WLAN * Reset button * 8x LED-s Installation instructions: Connect to UART, pins are like this: -> 3.3V | TX | RX | GND Settings are 115200 8n1 Boot initramfs from TFTP: tftpboot 0x84000000 openwrt-ipq40xx-generic-wallys_dr40x9-initramfs-fit-uImage.itb bootm Then copy the sysupgrade image to the /tmp folder and execute sysupgrade -n <image_name> The board file binary was provided from Wallystech on March 14th 2023 including full permission to use and distribute. Signed-off-by: Robert Marko <robert.marko@sartura.hr> Signed-off-by: Koen Vandeputte <koen.vandeputte@citymesh.com>
* ipq40xx: mf18a: rename wifi0 calibration variant to ZTE-MF18AChristian Marangi2023-03-181-1/+1
| | | | | | | Rename wifi0 calibration variant to ZTE-MF18A to allign to BDF changes for ZTE MF18A. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq40xx: rutx10: Add missing variant to ath10k wifiChristian Marangi2023-03-181-0/+10
| | | | | | | Add missing variant to ath10k wifi to allign to BDF changes for Teltonika RUTX10. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq40xx: mf18a: Add missing variant to PCI ath10k cardChristian Marangi2023-03-181-0/+1
| | | | | | | Add missing variant to PCI ath10k card to allign to BDF changes for ZTE MF18A. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq40xx: update Crisis Innovation Lab MeshPoint.One BDFMantas Pucka2023-03-171-1/+1
| | | | | | | | | | Make sure it uses updated Jalapeno BDF inherited from Device/8dev_jalapeno-common Fixes: 146eb4925c7f ("ipq40xx: add support for Crisis Innovation Lab MeshPoint.One") Signed-off-by: Mantas Pucka <mantas@8devices.com> [ fix Fixes tag to correct format and fix commit title ] Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq40xx: set specific BDF file for 8devices Habanero/JalapenoMantas Pucka2023-03-171-0/+2
| | | | | | | | | Set specific BDF file for 8devices Habanero/Jalapeno in ipq40xx generic.mk Signed-off-by: Mantas Pucka <mantas@8devices.com> [ split ipq40xx changes in separate commit ] Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* ipq40xx: convert Netgear EX6100/EX6150 v2 to DSADavid Bauer2023-03-083-5/+19
| | | | Signed-off-by: David Bauer <mail@david-bauer.net>
* ipq40xx: Linksys MR8300: fix the USB port powerDaniel González Cabanelas2023-02-251-1/+11
| | | | | | | | | | | | | The USB port on the MR8300 randomly fails to feed bus-powered devices. This is caused by a misconfigured pinmux. The GPIO68 should be used to enable the USB power (active low), but it's inside the NAND pinmux. This GPIO pin was found in the original firmware at a startup script in both MR8300 and EA8300. Therefore apply the fix for both boards. Signed-off-by: Daniel González Cabanelas <dgcbueu@gmail.com> Reviewed-by: Robert Marko <robimarko@gmail.com>
* ipq40xx: chromium: Enable kmod-ramoops by defaultBrian Norris2023-02-181-1/+5
| | | | | | | | Chromium devices (like Google WiFi) have ramoops memory reserved by the bootloader. Let's enable the ramoops kernel module by default, so we get better crash logging. Signed-off-by: Brian Norris <computersforpeace@gmail.com>
* treewide: replace /sys/devices/virtual/ubi by /sys/class/ubiDaniel Golle2023-02-151-1/+1
| | | | | | | | | | Starting from Linux Kernel version 6.3 UBI devices will no longer be considered virtual, but rather have an MTD device parent. Hence they will no longer be listed under /sys/devices/virtual/ubi which is used in multiple places in OpenWrt. Prepare for future kernels by using /sys/class/ubi instead of /sys/devuces/virtual/ubi. Signed-off-by: Daniel Golle <daniel@makrotopia.org>
* ipq40xx: fix dts whitespaceFelix Baumann2023-02-092-2/+2
| | | | | | Remove whitespace from otherwise empty lines Signed-off-by: Felix Baumann <felix.bau@gmx.de>
* ipq4019: fix dts white-spaceFelix Baumann2023-02-088-438/+438
| | | | | | | Replace blanks with tabs Remove whitespace from otherwise empty lines Signed-off-by: Felix Baumann <felix.bau@gmx.de>
* ipq40xx: fix assignment of lan port numbers for Cell C RTL30VWCezary Jackiewicz2023-02-061-2/+2
| | | | | | After switching to DSA, the LAN ports in Cell C RTL30VW have swapped numbers. Assigning the right numbers. Signed-off-by: Cezary Jackiewicz <cezary@eko.one.pl>
* treewide: replace wpad-basic-wolfssl defaultRosen Penev2023-02-041-1/+1
| | | | | | | The newly merged mbedtls backend is smaller and has fewer ABI related issues than the wolfSSL one. Signed-off-by: Rosen Penev <rosenp@gmail.com>
* ipq40xx: convert Extreme AP3915i to DSAJames Andrewartha2023-01-173-2/+16
| | | | | | Convert and re-enabled Extreme AP3915i to DSA. Signed-off-by: James Andrewartha <trs80@ucc.asn.au>
* ipq40xx: add DSL support for FritzBox 7530Martin Schiller2023-01-164-6/+34
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Set up MAC, LED, settings and default packages for DSL usage, similar to the lantiq target. Due to licensing uncertainty, we do not include the firmware files for the DSL drivers. To have a working DSL setup, follow the instructions below. Download the firmware files locally: mkdir -p files/lib/firmware/09a9 wget -P files/lib/firmware/09a9 https://gitlab.com/prpl-foundation/intel/vrx518_aca_fw/-/raw/ugw-8.5.2/platform/xrx500/aca_fw.bin wget -P files/lib/firmware https://gitlab.com/prpl-foundation/intel/vrx518_ppe_fw/-/raw/ugw_8.5.2.10/platform/xrx500/ppe_fw.bin wget -P files/lib/firmware https://gitlab.com/prpl-foundation/intel/dsl_vr11_firmware_xdsl/-/raw/ugw-8.5.2/xcpe_8D1507_8D0901.bin ln -s xcpe_8D1507_8D0901.bin files/lib/firmware/vdsl.bin For people building their own images: Run the above commands in the root of your local OpenWrt clone, and the firmware files will be part of the resulting images. For people downloading images: Copy the firmware files onto the router once it's booted up: scp -O -r files/lib/firmware root@fritz:/lib Reboot the device afterwards. Signed-off-by: Martin Schiller <ms.3headeddevs@gmail.com> [cleaned up] Signed-off-by: Andre Heider <a.heider@gmail.com> [set up LED] Signed-off-by: Jan Hoffmann <jan@3e8.eu> Signed-off-by: Andre Heider <a.heider@gmail.com>
* ipq40xx: fritzbox-7530.dts: increase dma coherent pool sizeMartin Schiller2023-01-161-0/+4
| | | | | | | This is needed by the mei driver to be able to download the firmware. Signed-off-by: Martin Schiller <ms.3headeddevs@gmail.com> Signed-off-by: Andre Heider <a.heider@gmail.com>
* ipq40xx: add Intel/Lantiq ATM hacksMartin Schiller2023-01-162-0/+180
| | | | | | | | | | Similar to the lantiq platform, these are required for DSL support. Signed-off-by: Martin Schiller <ms.3headeddevs@gmail.com> [switch to kernel 5.10 and 5.15] Signed-off-by: Jan Hoffmann <jan@3e8.eu> [update patches based on UGW 8.5.2.10, remove 5.10 support] Signed-off-by: Andre Heider <a.heider@gmail.com>
* ipq40xx: add support for Linksys WHW03 V2Vincent Tremblay2023-01-155-2/+541
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | SOC: Qualcomm IPQ4019 WiFi 1: QCA4019 IEEE 802.11b/g/n WiFi 2: QCA4019 IEEE 802.11a/n/ac WiFi 3: QCA8888 IEEE 802.11a/n/ac Bluetooth: Qualcomm CSR8811 (A12U) Zigbee: Silicon Labs EM3581 NCP + Skyworks SE2432L Ethernet: Qualcomm Atheros QCA8072 (2-port) Flash 1: Mactronix MX30LF4G18AC-XKI RAM (NAND): SK hynix H5TC4G63CFR-PBA (512MB) LED Controller: NXP PCA9633 (I2C) Buttons: Single reset button (GPIO). - The three WiFis were fully tested and are configured with the same settings as in the vendor firmware. - The specific board files were submitted to the ATH10k mailing list but I'm still waiting for a reply. They can be removed once they are approved upstream. - Two ethernet ports are accessible on the device. By default one is configured as WAN and the other one is LAN. They are fully working. Bluetooth: ======== - Fully working with the following caveats: - RFKILL need to be enabled in the kernel. - An older version of bluez is needed as bccmd is needed to configure the chip. Zigbee: ====== - The spidev device is available in the /dev directory. - GPIOs are configured the same way as in the vendor firmware. - Tests are on-going. I am working on getting access to the Silicon Labs stack to validate that it is fully working. Installation: ========= The squash-factory image can be installed via the Linksys Web UI: 1. Open "http://192.168.1.1/ca" (Change the IP with the IP of your device). 2. Login with your admin password. 3. To enter into the support mode, click on the "CA" link and the bottom of the page. 4. Open the "Connectivity" menu and upload the squash-factory image with the "Choose file" button. 5. Click start. Ignore all the prompts and warnings by click "yes" in all the popups. The device uses a dual partition mechanism. The device automatically revert to the previous partition after 3 failed boot attempts. If you want to force the previous firmware to load, you can turn off and then turn on the device for 2 seconds, 3 times in a row. It can also be done via TFTP: 1. Setup a local TFTP server and configure its IP to 192.168.1.100. 2. Rename your image to "nodes_v2.img" and put it to the TFTP root of your server. 3. Connect to the device through the serial console. 4. Power on device and press enter when prompted to drop into U-Boot. 5. Flash the partition of your choice by typing "run flashimg" or "run flashimg2". 6. Once flashed, enter "reset" to reboot the device. Reviewed-by: Robert Marko <robimarko@gmail.com> Signed-off-by: Vincent Tremblay <vincent@vtremblay.dev>
* ipq40xx: Add support ZTE MF18AMarcin Gajda2023-01-144-0/+498
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | Light and small router ( In Poland operators sells together with MC7010 outdoor modem to provide WIFI inside home). Device specification SoC Type: Qualcomm IPQ4019 RAM: 256 MiB Flash: 128 MiB SPI NAND (Winbond W25N01GV) ROM: 2MiB SPI Flash (GD25Q16) Wireless 2.4 GHz (IP4019): b/g/n, 2x2 Wireless 5 GHz (QCA9982): a/n/ac, 3x3 Ethernet: 2xGbE (WAN/LAN1, LAN2) USB ports: No Button: 2 (Reset/WPS) LEDs: 3 external leds: Power (blue) , WiFI (blue and red), SMARTHOME (blue and red) and 1 internal (blue) -- NOTE: Power controls all external led (if down ,all others also not lights even signal is up) Power: 5VDC, 2,1A via USB-C socket Bootloader: U-Boot On board ZWave and Zigbee (EFR32 MG1P232GG..) modules ( not supported by orginal software ) Installation 1.Open MF18A case by ungluing rubber pad under the router and unscrew screws, and connect to serial console port, with the following pinout, starting from pin 1, which is the topmost pin when the board is upright (reset button on the bottom) : VCC (3.3V). Do not use unless you need to source power for the converer from it. TX RX GND Default port configuration in U-boot as well as in stock firmware is 115200-8-N-1. 2.Place OpenWrt initramfs image for the device on a TFTP in the server's root. This example uses Server IP: 192.168.0.2 3.Connect TFTP server to RJ-45 port (WAN/LAN1). 4.Power on MF18A , stop in u-Boot (using ESC button) and run u-Boot commands: setenv serverip 192.168.0.2 setenv ipaddr 192.168.0.1 set fdt_high 0x85000000 tftpboot 0x84000000 openwrt-ipq40xx-generic-zte_mf18a-initramfs-fit-zImage.itb bootm 0x84000000 5.Please make backup of original partitions, if you think about revert to stock, specially mtd8 (Web UI) and mtd9 (rootFS). Use /tmp as temporary storage and do: WEB PARITION cat /dev/mtd8 > /tmp/mtd8.bin scp /tmp/mtd8.bin root@YOURSERVERIP:/ rm /tmp/mtd8.bin ROOT PARITION cat /dev/mtd9 > /tmp/mtd9.bin scp /tmp/mtd9.bin root@YOURSERVERIP:/ rm /tmp/mtd9.bin If you are sure ,that you want to flash openwrt, from uBoot, before bootm, clean rootfs partition with command: nand erase 0x1800000 0x1D00000 6.Login via ssh or serial and remove stock partitions (default IP 192.168.1.1): ubiattach -m 9 # it could return error if ubi was attached before or rootfs part was erased before ubirmvol /dev/ubi0 -N ubi_rootfs # it could return error if rootfs part was erased before ubirmvol /dev/ubi0 -N ubi_rootfs_data # some devices doesn't have it 7. Install image via : sysupgrade -n /tmp/openwrt-ipq40xx-generic-zte_mf18a-squashfs-sysupgrade.bin previously wgeting bin. Sometimes it could print ubi attach error, but please ignore it if process goes forward. Back to Stock (!!! need original dump taken from initramfs !!!) ------------- Place mtd8.bin and mtd9.bin initramfs image for the device on a TFTP in the server's root. This example uses Server IP: 192.168.0.2 Connect serial console (115200,8n1) to serial console connector . Connect TFTP server to RJ-45 port (WAN/LAN1). rename mtd8.bin to web.img and mtd9.bin to root_uImage_s Stop in u-Boot (using ESC button) and run u-Boot commands: This will erase Web and RootFS: nand erase 0x1000000 0x800000 nand erase 0x1800000 0x1D00000 This will restore RootFS: tftpboot 0x84000000 root_uImage_s nand erase 0x1800000 0x1D00000 nand write 0x84000000 0x1800000 0x1D00000 This will restore Web Interface: tftpboot 0x84000000 web.img nand erase 0x1000000 0x800000 nand write 0x84000000 0x1000000 0x800000 After first boot on stock firwmare, do a factory reset. Push reset button for 5 seconds so all parameters will be reverted to the one printed on label on bottom of the router As reference was taken MF289F support by Giammarco Marzano stich86@gmail.com and MF286D by Pawel Dembicki paweldembicki@gmail.com Signed-off-by: Marcin Gajda <mgajda@o2.pl>
* kernel: bump 5.15 to 5.15.87John Audia2023-01-131-1/+1
| | | | | | | | | | | | | Removed upstreamed: generic/hack-5.15/290-net-dsa-mv88e6xxx-depend-on-PTP-conditionally.patch[1] Build system: x86_64 Build-tested: bcm2711/RPi4B, filogic/xiaomi_redmi-router-ax6000-ubootmod Run-tested: bcm2711/RPi4B, filogic/xiaomi_redmi-router-ax6000-ubootmod 1. https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git/commit/?h=v5.15.87&id=945e58bdaf6faf6e3f957d182244fa830acddab4 Signed-off-by: John Audia <therealgraysky@proton.me>
* Revert "TODROP: test for ipq4019 target"Christian Marangi2023-01-111-1/+1
| | | | | | | | This reverts commit 4eb587f7e0a49b9c404857b18571f45981b3a7fc. Pushed by mistake while merging a pr using script. Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>
* TODROP: test for ipq4019 targetChristian Marangi2023-01-111-1/+1
| | | | | | COMMIT TO DROP Signed-off-by: Christian Marangi <ansuelsmth@gmail.com>