aboutsummaryrefslogtreecommitdiff
path: root/target/linux/ipq40xx/files/arch
diff options
context:
space:
mode:
authorMarcin Gajda <mgajda@o2.pl>2024-02-11 16:20:21 +0100
committerRobert Marko <robimarko@gmail.com>2024-02-23 19:46:23 +0100
commit07b9186e88a2e5b2bd842b87d7063645a23e3fcb (patch)
treef3b2e814dc72a8932161cbf3803ffd56f648797e /target/linux/ipq40xx/files/arch
parentdf3d5fd3f212a0c0b5d479ca51dc3e2b0b24e8f5 (diff)
ipq40xx: Add support Netgear LBR20
**Netgear LBR20** is a router with two gigabit ethernets , three wifi radios and integrated LTE cat.18 modem. SoC Type: Qualcomm IPQ4019 RAM: 512 MiB Flash: 256 MiB , SLC NAND, 2 Gbit (Macronix MX30LF2G18AC) Bootloader: U-Boot Modem: LTE CAT.18 Quectel EG-18EA , Max. 1.2Gbps downlink / 150Mbps uplink WiFi class AC2200: - radio0 : 5G on QCA9888 , WiFi5- 802.11a/n/ac MU-MIMO 2x2 , 887Mbps , 80MHz - limited for low channels - radio1: 2,4G on IPQ4019 ,WiFi4- 802.11b/g/n MIMO2x2 300Mbps 40Mhz - radio2: 5G on IPQ4019 , WiFi5- 802.11a/n/ac MU-MIMO 2x2 , 887Mbps ,80Mhz - limited for high channels (from 100 up to 165) . Becouse of DFS remember to set country before turning on. Ethernet: 2x1GbE (WAN/LAN1, LAN2) LEDs: section power : green and red , section on top (orbi) drived by TLC59208F: red, green ,blue and white USB ports: No Buttons: 2 Reset and SYNC(WPS) Power: 12 VDC, 2,5 A Connector type: Barrel OpenWRT Installation 1. Simplest way is just do upgrade from webpage with *factory.img 2. You can also do it with standard tool for Netgear's debricking - NMPRFlash 3. Most advanced way is to open device , connect to UART console and : - Prepare OpenWrt initramfs image in TFTP server root (server IP 192.168.1.10) - Connect serial console (115200,8n1) to UART connector - Connect TFTP server to RJ-45 port - Stop in u-Boot and run u-Boot command: > setenv serverip 192.168.1.10 > set fdt_high 0x85000000 > tftpboot 0x83000000 openwrt-ipq40xx-generic-netgear_lbr20-initramfs-zImage.itb > bootm 0x83000000 - Login via ssh - upload or download *sysupgrade.bin ( like wget ... or scp transfer) - Install image via "sysupgrade -n" (like “sysupgrade -n /tmp/openwrt-ipq40xx-generic-netgear_lbr20-squashfs-sysupgrade.bin”) Back to Stock - Download firmware from official Netgear's webpage , it will be *.img file after decompressing. - Use NMRPFlash tool ( detailed insructions on project page https://github.com/jclehner/nmrpflash ) Open the case - Unscrew nuts and remove washers from antenna's conectors. - There are two Torx T10 screws under the label next to antenna conectors. You have to unglue this label from left and right corner to get it - Two parts of shell covers will slide out from eachother , you have to unglue two small rubber pads and namplate sticker on bottom to do that. - PCB is screwed with 4Pcs of Torx T10 screws - Before lifting up PCB remove pigtiles for LTE antennas and release them from PCB and radiator (black and white wires) - On other side of PCB ,in left bottom corner there is already soldered with 4 pins UART connector for console. Counting from left it is +3,3V , TX , RX ,GND (reffer to this picture: https://i.ibb.co/Pmrf9KB/20240116-103524.jpg ) BDF's files are in firmware_qca-wireless https://github.com/openwrt/firmware_qca-wireless/ and in parallel sent to ath10k@lists.infradead.org. Signed-off-by: Marcin Gajda <mgajda@o2.pl>
Diffstat (limited to 'target/linux/ipq40xx/files/arch')
-rw-r--r--target/linux/ipq40xx/files/arch/arm/boot/dts/qcom-ipq4019-lbr20.dts516
1 files changed, 516 insertions, 0 deletions
diff --git a/target/linux/ipq40xx/files/arch/arm/boot/dts/qcom-ipq4019-lbr20.dts b/target/linux/ipq40xx/files/arch/arm/boot/dts/qcom-ipq4019-lbr20.dts
new file mode 100644
index 0000000000..4e5497cbc3
--- /dev/null
+++ b/target/linux/ipq40xx/files/arch/arm/boot/dts/qcom-ipq4019-lbr20.dts
@@ -0,0 +1,516 @@
+// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
+
+#include "qcom-ipq4019.dtsi"
+#include <dt-bindings/gpio/gpio.h>
+#include <dt-bindings/input/input.h>
+#include <dt-bindings/soc/qcom,tcsr.h>
+#include <dt-bindings/leds/common.h>
+
+/ {
+ model = "Netgear LBR20";
+ compatible = "netgear,lbr20";
+
+ chosen {
+ bootargs-append = "ubi.mtd=ubi root=/dev/ubiblock0_0";
+ };
+
+ aliases {
+ led-boot = &led_backlight_white;
+ led-failsafe = &led_status_green;
+ led-running = &led_status_green;
+ led-upgrade = &led_status_red;
+ label-mac-device = &gmac;
+ };
+
+ keys {
+ compatible = "gpio-keys";
+
+ reset {
+ label = "reset";
+ gpios = <&tlmm 18 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RESTART>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&tlmm 49 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+ };
+
+ leds {
+ compatible = "gpio-leds";
+
+ led_status_green: led-status-green {
+ function = LED_FUNCTION_STATUS;
+ color = <LED_COLOR_ID_GREEN>;
+ gpios = <&tlmm 22 GPIO_ACTIVE_LOW>;
+ default-state = "keep";
+ };
+
+ led_status_red: led-status-red {
+ function = LED_FUNCTION_STATUS;
+ color = <LED_COLOR_ID_RED>;
+ gpios = <&tlmm 23 GPIO_ACTIVE_LOW>;
+ };
+ };
+
+ gpio_export {
+ compatible = "gpio-export";
+ #size-cells = <0>;
+
+ lte_rst {
+ gpio-export,name = "lte_rst";
+ gpio-export,output = <1>;
+ gpios = <&tlmm 28 GPIO_ACTIVE_HIGH>;
+ };
+
+ lte_pwrkey {
+ gpio-export,name = "lte_pwrkey";
+ gpio-export,output = <1>;
+ gpios = <&tlmm 29 GPIO_ACTIVE_HIGH>;
+ };
+
+ lte_usb_boot {
+ gpio-export,name = "lte_usb_boot";
+ gpio-export,output = <0>;
+ gpios = <&tlmm 30 GPIO_ACTIVE_HIGH>;
+ };
+
+ lte_pwm {
+ gpio-export,name = "lte_pwm";
+ gpio-export,output = <1>;
+ gpios = <&tlmm 31 GPIO_ACTIVE_HIGH>;
+ };
+
+ };
+
+ soc {
+
+ tcsr@1949000 {
+ compatible = "qcom,tcsr";
+ reg = <0x1949000 0x100>;
+ qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
+ };
+
+ tcsr@194b000 {
+ status = "okay";
+
+ compatible = "qcom,tcsr";
+ reg = <0x194b000 0x100>;
+ qcom,usb-hsphy-mode-select = <TCSR_USB_HSPHY_HOST_MODE>;
+ };
+
+ ess_tcsr@1953000 {
+ compatible = "qcom,tcsr";
+ reg = <0x1953000 0x1000>;
+ qcom,ess-interface-select = <TCSR_ESS_PSGMII>;
+ };
+
+ tcsr@1957000 {
+ compatible = "qcom,tcsr";
+ reg = <0x1957000 0x100>;
+ qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
+ };
+
+ };
+};
+
+&prng {
+ status = "okay";
+};
+
+&mdio {
+ status = "okay";
+ pinctrl-0 = <&mdio_pins>;
+ pinctrl-names = "default";
+};
+
+&crypto {
+ status = "okay";
+};
+
+&watchdog {
+ status = "okay";
+};
+
+&usb2_hs_phy {
+ status = "okay";
+};
+
+&usb2 {
+ status = "okay";
+};
+
+&usb3_ss_phy {
+ status = "okay";
+};
+
+&usb3_hs_phy {
+ status = "okay";
+};
+
+&usb3 {
+ status = "okay";
+};
+
+&blsp_dma {
+ status = "okay";
+};
+
+&qpic_bam {
+ status = "okay";
+};
+
+&tlmm {
+ mdio_pins: mdio-pinmux {
+ mux_mdio {
+ pins = "gpio6";
+ function = "mdio";
+ bias-pull-up;
+ };
+
+ mux_mdc {
+ pins = "gpio7";
+ function = "mdc";
+ bias-pull-up;
+ };
+ };
+
+ serial_pins: serial-pinmux {
+ function = "blsp_uart0";
+ pins = "gpio16", "gpio17";
+ bias-disable;
+ };
+
+ nand_pins: nand-pins {
+ pullups {
+ pins = "gpio52", "gpio53", "gpio58", "gpio59";
+ function = "qpic";
+ bias-pull-up;
+ };
+
+ pulldowns {
+ pins = "gpio54", "gpio55", "gpio56",
+ "gpio57", "gpio60", "gpio61",
+ "gpio62", "gpio63", "gpio64",
+ "gpio65", "gpio66", "gpio67",
+ "gpio68", "gpio69";
+ function = "qpic";
+ bias-pull-down;
+ };
+ };
+};
+
+&nand {
+ pinctrl-0 = <&nand_pins>;
+ pinctrl-names = "default";
+ status = "okay";
+
+ nand@0 {
+ partitions {
+ compatible = "fixed-partitions";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ partition@0 {
+ label = "0:SBL1";
+ reg = <0x00000000 0x00100000>;
+ read-only;
+ };
+
+ partition@100000 {
+ label = "0:MIBIB";
+ reg = <0x00100000 0x00100000>;
+ read-only;
+ };
+
+ partition@200000 {
+ label = "0:BOOTCONFIG";
+ reg = <0x00200000 0x00100000>;
+ read-only;
+ };
+
+ partition@300000 {
+ label = "0:QSEE";
+ reg = <0x00300000 0x00100000>;
+ read-only;
+ };
+
+ partition@400000 {
+ label = "0:QSEE_1";
+ reg = <0x00400000 0x00100000>;
+ read-only;
+ };
+
+ partition@500000 {
+ label = "0:CDT";
+ reg = <0x00500000 0x00080000>;
+ read-only;
+ };
+
+ partition@580000 {
+ label = "0:CDT_1";
+ reg = <0x00580000 0x00080000>;
+ read-only;
+ };
+
+ partition@600000 {
+ label = "0:BOOTCONFIG1";
+ reg = <0x00600000 0x00080000>;
+ read-only;
+ };
+
+ partition@680000 {
+ label = "0:APPSBLENV";
+ reg = <0x00680000 0x00080000>;
+ };
+
+ partition@700000 {
+ label = "0:APPSBL";
+ reg = <0x00700000 0x00200000>;
+ read-only;
+ };
+
+ partition@900000 {
+ label = "0:APPSBL_1";
+ reg = <0x00900000 0x00200000>;
+ read-only;
+ };
+
+ partition@b00000 {
+ label = "0:ART";
+ reg = <0x00b00000 0x00080000>;
+ read-only;
+
+ nvmem-layout {
+ compatible = "fixed-layout";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ precal_art_1000: precal@1000 {
+ reg = <0x1000 0x2f20>;
+ };
+
+ precal_art_5000: precal@5000 {
+ reg = <0x5000 0x2f20>;
+ };
+
+ precal_art_9000: precal@9000 {
+ reg = <0x9000 0x2f20>;
+ };
+
+ };
+ };
+
+ partition@b80000 {
+ label = "0:ART.bak";
+ reg = <0x00b80000 0x00080000>;
+ read-only;
+ };
+
+ partition@c00000 {
+ label = "config";
+ reg = <0x00c00000 0x00100000>;
+ read-only;
+ };
+
+ partition@d00000 {
+ label = "boarddata1";
+ reg = <0x00d00000 0x00080000>;
+ read-only;
+
+ nvmem-layout {
+ compatible = "fixed-layout";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ mac_address_lan: macaddr@0 {
+ compatible = "mac-base";
+ reg = <0x0 0x6>;
+ #nvmem-cell-cells = <1>;
+ };
+
+ mac_address_wan: macaddr@6 {
+ compatible = "mac-base";
+ reg = <0x6 0x6>;
+ #nvmem-cell-cells = <1>;
+ };
+
+ mac_address_wlan_5g: macaddr@c {
+ compatible = "mac-base";
+ reg = <0xc 0x6>;
+ #nvmem-cell-cells = <1>;
+ };
+
+ mac_address_wlan_2nd5g: macaddr@12 {
+ compatible = "mac-base";
+ reg = <0x12 0x6>;
+ #nvmem-cell-cells = <1>;
+ };
+
+ };
+ };
+
+ partition@d80000 {
+ label = "boarddata2";
+ reg = <0x00d80000 0x00040000>;
+ read-only;
+ };
+
+ partition@dc0000 {
+ label = "pot";
+ reg = <0x00dc0000 0x00100000>;
+ read-only;
+ };
+
+ partition@ec0000 {
+ label = "boarddata1.bak";
+ reg = <0x00ec0000 0x00080000>;
+ read-only;
+ };
+
+ partition@f40000 {
+ label = "boarddata2.bak";
+ reg = <0x00f40000 0x00040000>;
+ read-only;
+ };
+
+ partition@f80000 {
+ label = "language";
+ reg = <0x00f80000 0x00300000>;
+ read-only;
+ };
+
+ partition@1280000 {
+ label = "cert";
+ reg = <0x01280000 0x00080000>;
+ read-only;
+ };
+
+ partition@1300000 {
+ label = "ntgrdata";
+ reg = <0x01300000 0x09300000>;
+ };
+
+ partition@a600000 {
+ label = "kernel";
+ reg = <0x0a600000 0x00700000>;
+ };
+
+ partition@a9c0000 {
+ label = "ubi";
+ reg = <0x0ad00000 0x05300000>;
+ };
+
+ };
+ };
+};
+
+&blsp1_i2c3 {
+ status = "okay";
+
+ led-controller {
+ #address-cells = <1>;
+ #size-cells = <0>;
+ compatible = "ti,tlc59108"; /* really is tlc59208f */
+ reg = <0x27>;
+
+ led_backlight_green: led-backlight-green {
+ function = LED_FUNCTION_BACKLIGHT;
+ color = <LED_COLOR_ID_GREEN>;
+ reg = <0x0>;
+ linux,default-trigger = "default-off";
+ };
+
+ led_backlight_red: led-backlight-red {
+ function = LED_FUNCTION_BACKLIGHT;
+ color = <LED_COLOR_ID_RED>;
+ reg = <0x1>;
+ linux,default-trigger = "default-off";
+ };
+
+ led_backlight_blue: led-backlight-blue {
+ function = LED_FUNCTION_BACKLIGHT;
+ color = <LED_COLOR_ID_BLUE>;
+ reg = <0x2>;
+ linux,default-trigger = "default-off";
+ };
+
+ led_backlight_white: led-backlight-white {
+ function = LED_FUNCTION_BACKLIGHT;
+ color = <LED_COLOR_ID_WHITE>;
+ reg = <0x3>;
+ linux,default-trigger = "default-off";
+ };
+
+ };
+};
+
+&blsp1_uart1 {
+ status = "okay";
+ pinctrl-0 = <&serial_pins>;
+ pinctrl-names = "default";
+};
+
+&cryptobam {
+ status = "okay";
+};
+
+&gmac {
+ status = "okay";
+ nvmem-cell-names = "mac-address";
+ nvmem-cells = <&mac_address_lan 0>;
+};
+
+&switch {
+ status = "okay";
+};
+
+&swport4 {
+ status = "okay";
+ label = "lan1";
+};
+
+&swport5 {
+ status = "okay";
+ label = "lan2";
+};
+
+&pcie0 {
+ status = "okay";
+ perst-gpios = <&tlmm 38 GPIO_ACTIVE_LOW>;
+ wake-gpios = <&tlmm 50 GPIO_ACTIVE_LOW>;
+
+ bridge@0,0 {
+ reg = <0x00000000 0 0 0 0>;
+ #address-cells = <3>;
+ #size-cells = <2>;
+ ranges;
+
+ wifi@1,0 {
+ compatible = "qcom,ath10k";
+ status = "okay";
+ reg = <0x00010000 0 0 0 0>;
+ ieee80211-freq-limit = <5170000 5350000>;
+ nvmem-cell-names = "pre-calibration", "mac-address";
+ nvmem-cells = <&precal_art_9000>, <&mac_address_wlan_2nd5g 0>;
+ qcom,ath10k-calibration-variant = "Netgear-LBR20";
+ };
+ };
+};
+
+&wifi0 {
+ status = "okay";
+ nvmem-cell-names = "pre-calibration", "mac-address";
+ nvmem-cells = <&precal_art_1000>, <&mac_address_lan 0>;
+ qcom,ath10k-calibration-variant = "Netgear-LBR20";
+};
+
+&wifi1 {
+ status = "okay";
+ ieee80211-freq-limit = <5470000 5815000>;
+ nvmem-cell-names = "pre-calibration", "mac-address";
+ nvmem-cells = <&precal_art_5000>, <&mac_address_wlan_5g 0>;
+ qcom,ath10k-calibration-variant = "Netgear-LBR20";
+};