From 4a77a060ab6219f830390cd53c2817b621f39760 Mon Sep 17 00:00:00 2001 From: Yanase Yuki Date: Wed, 29 Jan 2020 19:27:25 +0900 Subject: [PATCH] ipq40xx: add support for Buffalo WTR-M2133HP Buffalo WTR-M2133HP is a Tri-Band router based on IPQ4019. Specification ------------- - SoC: Qualcomm IPQ4019 - RAM: 512MiB - Flash Memory: NAND 128MiB (MXIC MX30LF1G18AC) - Wi-Fi: Qualcomm IPQ4019 (2.4GHz, 1ch - 13ch) - Wi-Fi: Qualcomm IPQ4019 (5GHz, 36ch - 64ch) - Wi-Fi: Qualcomm QCA9984 (2T2R, 5GHz, 100ch - 140ch) - Ethernet: 4x 10/100/1000 Mbps (1x WAN, 3x LAN) - LED: 4x white LED, 4x orange LED, 1x blue LED - USB: 1x USB 3.0 port - Input: 2x tactile switch, 2x slide switch (2x SP3T) - Serial console: 115200bps, pinheader JP5 on PCB - Power: DC 12V 2A Flash instruction ----------------- 1. Set up a TFTP server (IP address: 192.168.11.10) 2. Rename "initramfs-fit-uImage.itb" to "WTR-M2133HP-initramfs.uImage" and put it into the TFTP server directory. 3. Connect the TFTP server and WTR-M2133HP. 4. Hold down the AOSS button, then power on the router. 5. After booting OpenWrt initramfs image, connect to the router by SSH. 6. Transfer "squashfs-nand-factory.ubi" to the router. 7. Execute the following commands. # ubidetach -p /dev/mtd15 # ubiformat /dev/mtd15 -f /tmp/openwrt-ipq40xx-generic-buffalo_wtr-m2133hp-squashfs-nand-factory.ubi # fw_setenv bootcmd bootipq 8. Perform reboot. Recover to stock firmware ------------------------- 1. Execute the following command. # fw_setenv bootcmd bootbf 2. Reboot and wait several minutes. Signed-off-by: Yanase Yuki --- package/boot/uboot-envtools/files/ipq40xx | 3 + package/firmware/ipq-wifi/Makefile | 2 + .../board-buffalo_wtr-m2133hp.qca4019 | Bin 0 -> 24332 bytes .../board-buffalo_wtr-m2133hp.qca9984 | Bin 0 -> 12172 bytes .../ipq40xx/base-files/etc/board.d/02_network | 5 + .../etc/hotplug.d/firmware/11-ath10k-caldata | 12 + .../base-files/lib/upgrade/platform.sh | 1 + .../arm/boot/dts/qcom-ipq4019-wtr-m2133hp.dts | 419 ++++++++++++++++++ target/linux/ipq40xx/image/Makefile | 12 + .../901-arm-boot-add-dts-files.patch | 1 + .../901-arm-boot-add-dts-files.patch | 1 + 11 files changed, 456 insertions(+) create mode 100644 package/firmware/ipq-wifi/board-buffalo_wtr-m2133hp.qca4019 create mode 100644 package/firmware/ipq-wifi/board-buffalo_wtr-m2133hp.qca9984 create mode 100644 target/linux/ipq40xx/files/arch/arm/boot/dts/qcom-ipq4019-wtr-m2133hp.dts diff --git a/package/boot/uboot-envtools/files/ipq40xx b/package/boot/uboot-envtools/files/ipq40xx index 7bcad00b01..f427661cf7 100644 --- a/package/boot/uboot-envtools/files/ipq40xx +++ b/package/boot/uboot-envtools/files/ipq40xx @@ -37,6 +37,9 @@ openmesh,a42 |\ openmesh,a62) ubootenv_add_uci_config "/dev/mtd5" "0x0" "0x10000" "0x10000" ;; +buffalo,wtr-m2133hp) + ubootenv_add_uci_config "/dev/mtd8" "0x0" "0x40000" "0x20000" + ;; linksys,ea6350v3) ubootenv_add_uci_config "/dev/mtd7" "0x0" "0x20000" "0x20000" ;; diff --git a/package/firmware/ipq-wifi/Makefile b/package/firmware/ipq-wifi/Makefile index 4868b75d16..ee7b194601 100644 --- a/package/firmware/ipq-wifi/Makefile +++ b/package/firmware/ipq-wifi/Makefile @@ -28,6 +28,7 @@ ALLWIFIBOARDS:= \ 8dev_habanero-dvk \ aruba_ap-303 \ avm_fritzrepeater-1200 \ + buffalo_wtr-m2133hp \ cellc_rtl30vw \ dlink_dap2610 \ engenius_eap2200 \ @@ -101,6 +102,7 @@ endef $(eval $(call generate-ipq-wifi-package,8dev_habanero-dvk,8devices Habanero DVK)) $(eval $(call generate-ipq-wifi-package,aruba_ap-303,Aruba AP-303)) $(eval $(call generate-ipq-wifi-package,avm_fritzrepeater-1200,AVM FRITZRepeater 1200)) +$(eval $(call generate-ipq-wifi-package,buffalo_wtr-m2133hp,Buffalo WTR-M2133HP)) $(eval $(call generate-ipq-wifi-package,cellc_rtl30vw, Cell C RTL30VW)) $(eval $(call generate-ipq-wifi-package,dlink_dap2610,D-Link DAP-2610)) $(eval $(call generate-ipq-wifi-package,engenius_eap2200,EnGenius EAP2200)) diff --git a/package/firmware/ipq-wifi/board-buffalo_wtr-m2133hp.qca4019 b/package/firmware/ipq-wifi/board-buffalo_wtr-m2133hp.qca4019 new file mode 100644 index 0000000000000000000000000000000000000000..8305ba0166a2c07054d0789f1abaf3119c7c31bf GIT binary patch literal 24332 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 S+N+$ubtLzGvG1Cu$NxVG<{kV1 literal 0 HcmV?d00001 diff --git a/package/firmware/ipq-wifi/board-buffalo_wtr-m2133hp.qca9984 b/package/firmware/ipq-wifi/board-buffalo_wtr-m2133hp.qca9984 new file mode 100644 index 0000000000000000000000000000000000000000..656cb99cbb2b6de86639ae8dc8eee73c5c7cb490 GIT binary patch literal 12172 zcmeHMYfuwc6ut={h*+{oL=CvSb$k#Zp@14*ks_5_udf5lX@?4@DwWdTYFAyIniscvQ<%#zn3`Yg@ zbGN;V(mE0m-#j)dm`52i+B=W;y}`$>^TD}u^8sz_fR|_likKteh9X35lX#|^o12S^ z3xz^~wN(JXdcLf^~g`f-1y zvLqud4NHyzG@8elbIi)n;GiIX*!%03pPrA7E`plXMi`&}`h@E0`nScG0w6xiiudwz z9mD74WeBad7cYJvv(08BYm?Qr!GN-3b!|i;Vh7I=nT`hpMUX@^5s5$}5Lxk&W0fcB z&YYd90N$8%JEhQ3I-CB0j<8S`n}yL(8nOiCqkK010Uz0nZf0-B63_%B1?8X|Hs=8c zS&yz~ugAjCa3lsDpM?6-^y>JWc)amhk?NG^GZRV}DB~#u@kM>vzSu@|Boa^+F5fGP z9~soQs=k!(5v?Ntr-%^@Cbd>kCEX`TGTbLL@vf9ueV@9$v`U* zuhhxq$}1^?4kSw?OAZ(yUkwMuykvHorI*lThhzYp?91umU0&JbbG*{<$yIIxsz792 zCfSWGEvssMOIy1o*EgwGR4*yk4;;O-<(gk5B5%2Kpq*aM zaoe`$)zz$$#{S*k#p(QU`jPts{EI7apU=GW)!mZzC{=(0DZJ2?-x{g(FQer*4@>Vv zYXg)>>A=t??JDJxQrdof->&xP^Zr$gVp%)?TxjLuq6Nb0q4ciR%}Y-%EV?pu;C7V8 z{}fW(a4%K2s(wkC_r7m?cD6<~EIUdstmxU%5!%2!<|U~##%Y7SYFMP zdF|;p#We*h82i04Zw!}oZ@v~#OFw+ZnB20wmRaPLJ=C|MDX;>OdWu?ZORk33vJQKT zHN%JQ32ua6WR@!oyz>E-A4omZ+f0%UcKy<_g*j*LWq0tJS>+$>BVQqs0g{2a%Yd8v z`~?fW5yqm$OMREwt;~onv0nH$ai1*H(4Z;LN(dM_D&U}@p&{@L4hjqi4h#$m6uNoX za+K4+W@w^NUEHXE>f$=j-33CZ?(>LkHg|U_Y~0;lhz7jcXEA3n;!oei*@SGPM{}Z) zc)Ev8z>e(tOE-Hb*S4jL=)2}F)YB0QAG z=3$Yuw!WSi)fvr)GDowHrn(QooUe?~Zr literal 0 HcmV?d00001 diff --git a/target/linux/ipq40xx/base-files/etc/board.d/02_network b/target/linux/ipq40xx/base-files/etc/board.d/02_network index cd336a9e6a..61d02a17bc 100755 --- a/target/linux/ipq40xx/base-files/etc/board.d/02_network +++ b/target/linux/ipq40xx/base-files/etc/board.d/02_network @@ -65,6 +65,11 @@ ipq40xx_setup_interfaces() engenius,eap2200) ucidef_set_interface_lan "eth0 eth1" ;; + buffalo,wtr-m2133hp) + ucidef_set_interfaces_lan_wan "eth0" "eth1" + ucidef_add_switch "switch0" \ + "0u@eth0" "2:lan:3" "3:lan:2" "4:lan:1" + ;; cellc,rtl30vw) ucidef_set_interface_lan "eth0" ucidef_add_switch "switch0" \ diff --git a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata index b95bab7cae..8df7990f2e 100644 --- a/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata +++ b/target/linux/ipq40xx/base-files/etc/hotplug.d/firmware/11-ath10k-caldata @@ -31,6 +31,10 @@ case "$FIRMWARE" in /usr/bin/fritz_cal_extract -i 1 -s 0x3C800 -e 0x212 -l 12064 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader1") || \ /usr/bin/fritz_cal_extract -i 1 -s 0x3C000 -e 0x212 -l 12064 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader1") ;; + buffalo,wtr-m2133hp) + caldata_extract "ART" 0x9000 0x2f20 + ath10k_patch_mac $(mtd_get_mac_binary ORGDATA 0x32) + ;; engenius,eap2200 |\ openmesh,a62) caldata_extract "0:ART" 0x9000 0x2f20 @@ -82,6 +86,10 @@ case "$FIRMWARE" in /usr/bin/fritz_cal_extract -i 1 -s 0x3C800 -e 0x207 -l 12064 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader1") || \ /usr/bin/fritz_cal_extract -i 1 -s 0x3D000 -e 0x207 -l 12064 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader1") ;; + buffalo,wtr-m2133hp) + caldata_extract "ART" 0x1000 0x2f20 + ath10k_patch_mac $(mtd_get_mac_binary ORGDATA 0x26) + ;; cellc,rtl30vw |\ compex,wpj419 |\ compex,wpj428 |\ @@ -171,6 +179,10 @@ case "$FIRMWARE" in /usr/bin/fritz_cal_extract -i 1 -s 0x3D000 -e 0x208 -l 12064 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader1") || \ /usr/bin/fritz_cal_extract -i 1 -s 0x3C000 -e 0x208 -l 12064 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader1") ;; + buffalo,wtr-m2133hp) + caldata_extract "ART" 0x5000 0x2f20 + ath10k_patch_mac $(mtd_get_mac_binary ORGDATA 0x2c) + ;; cellc,rtl30vw |\ compex,wpj419 |\ compex,wpj428 |\ diff --git a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh index 2abff3bd00..5b89710a22 100644 --- a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh +++ b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh @@ -64,6 +64,7 @@ platform_do_upgrade() { avm,fritzbox-7530 |\ avm,fritzrepeater-1200 |\ avm,fritzrepeater-3000 |\ + buffalo,wtr-m2133hp |\ cilab,meshpoint-one |\ engenius,eap2200 |\ mobipromo,cm520-79f |\ diff --git a/target/linux/ipq40xx/files/arch/arm/boot/dts/qcom-ipq4019-wtr-m2133hp.dts b/target/linux/ipq40xx/files/arch/arm/boot/dts/qcom-ipq4019-wtr-m2133hp.dts new file mode 100644 index 0000000000..1977358525 --- /dev/null +++ b/target/linux/ipq40xx/files/arch/arm/boot/dts/qcom-ipq4019-wtr-m2133hp.dts @@ -0,0 +1,419 @@ +// SPDX-License-Identifier: ISC +/* + * Copyright (c) 2015 - 2016, The Linux Foundation. All rights reserved. + * Copyright (c) 2020 Yanase Yuki + */ + +#include "qcom-ipq4019.dtsi" +#include +#include +#include + +/ { + model = "Buffalo WTR-M2133HP"; + compatible = "buffalo,wtr-m2133hp", "qcom,ipq4019"; + + memory { + device_type = "memory"; + reg = <0x80000000 0x20000000>; + }; + + chosen { + /* + * U-Boot adds "ubi.mtd=rootfs root=mtd:ubi_rootfs" to + * kernel command line. But we use different partition names, + * so we have to set correct parameters. + */ + bootargs-append = " ubi.mtd=ubi root=/dev/ubiblock0_1"; + }; + + aliases { + led-boot = &led_power_blue; + led-failsafe = &led_power_orange; + led-running = &led_power_white; + led-upgrade = &led_power_blue; + label-mac-device = &gmac0; + }; + + soc { + rng@22000 { + status = "okay"; + }; + + tcsr@1949000 { + compatible = "qcom,tcsr"; + reg = <0x1949000 0x100>; + qcom,wifi_glb_cfg = ; + }; + + tcsr@194b000 { + compatible = "qcom,tcsr"; + reg = <0x194b000 0x100>; + qcom,usb-hsphy-mode-select = ; + status = "okay"; + }; + + ess_tcsr@1953000 { + compatible = "qcom,tcsr"; + reg = <0x1953000 0x1000>; + qcom,ess-interface-select = ; + }; + + tcsr@1957000 { + compatible = "qcom,tcsr"; + reg = <0x1957000 0x100>; + qcom,wifi_noc_memtype_m0_m2 = ; + }; + + crypto@8e3a000 { + status = "okay"; + }; + + watchdog@b017000 { + status = "okay"; + }; + + ess-switch@c000000 { + status = "okay"; + switch_lan_bmp = <0x1c>; + }; + + ess-psgmii@98000 { + status = "okay"; + }; + + edma@c080000 { + status = "okay"; + }; + + usb3@8af8800 { + status = "okay"; + }; + }; + + leds { + compatible = "gpio-leds"; + + led_power_white: power_white { + label = "wtr-m2133hp:white:power"; + gpios = <&tlmm 40 GPIO_ACTIVE_HIGH>; + }; + + led_power_orange: power_orange { + label = "wtr-m2133hp:orange:power"; + gpios = <&tlmm 25 GPIO_ACTIVE_HIGH>; + }; + + led_power_blue: power_blue { + label = "wtr-m2133hp:blue:power"; + gpios = <&tlmm 43 GPIO_ACTIVE_HIGH>; + }; + + router_white { + label = "wtr-m2133hp:white:router"; + gpios = <&tlmm 28 GPIO_ACTIVE_HIGH>; + }; + + router_orange { + label = "wtr-m2133hp:orange:router"; + gpios = <&tlmm 46 GPIO_ACTIVE_HIGH>; + }; + + internet_white { + label = "wtr-m2133hp:white:internet"; + gpios = <&tlmm 27 GPIO_ACTIVE_HIGH>; + }; + + internet_orange { + label = "wtr-m2133hp:orange:internet"; + gpios = <&tlmm 45 GPIO_ACTIVE_HIGH>; + }; + + wireless_white { + label = "wtr-m2133hp:white:wireless"; + gpios = <&tlmm 24 GPIO_ACTIVE_HIGH>; + }; + + wireless_orange { + label = "wtr-m2133hp:orange:wireless"; + gpios = <&tlmm 44 GPIO_ACTIVE_HIGH>; + }; + }; + + keys { + compatible = "gpio-keys"; + + auto_mode { + label = "auto_mode"; + gpios = <&tlmm 9 GPIO_ACTIVE_LOW>; + linux,code = ; + linux,input-type = ; + }; + + router_mode { + label = "router_mode"; + gpios = <&tlmm 10 GPIO_ACTIVE_LOW>; + linux,code = ; + linux,input-type = ; + }; + + ap_mode { + label = "ap_mode"; + gpios = <&tlmm 11 GPIO_ACTIVE_LOW>; + linux,code = ; + linux,input-type = ; + }; + + reset { + label = "reset"; + gpios = <&tlmm 18 GPIO_ACTIVE_LOW>; + linux,code = ; + }; + + wps { + label = "AOSS Button"; + gpios = <&tlmm 32 GPIO_ACTIVE_LOW>; + linux,code = ; + }; + }; +}; + +&tlmm { + serial_0_pins: serial0_pinmux { + mux { + pins = "gpio16", "gpio17"; + function = "blsp_uart0"; + bias-disable; + }; + }; + + mdio_pins: mdio_pinmux { + mux_1 { + pins = "gpio6"; + function = "mdio"; + bias-pull-up; + }; + + mux_2 { + pins = "gpio7"; + function = "mdc"; + bias-pull-up; + }; + }; + + 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; + }; + }; + + usb_power { + line-name = "USB power"; + gpios = <34 GPIO_ACTIVE_HIGH>; + gpio-hog; + output-high; + }; +}; + +&blsp_dma { + status = "okay"; +}; + +&blsp1_uart1 { + pinctrl-0 = <&serial_0_pins>; + pinctrl-names = "default"; + status = "okay"; +}; + +&cryptobam { + status = "okay"; +}; + +&pcie0 { + status = "okay"; + + bridge@0,0 { + reg = <0x00000000 0 0 0 0>; + #address-cells = <3>; + #size-cells = <2>; + ranges; + + wifi@0,0 { + compatible = "qcom,ath10k"; + reg = <0 0 0 0 0>; + + qcom,ath10k-calibration-variant = "Buffalo-WTR-M2133HP"; + }; + }; +}; + +&qpic_bam { + status = "okay"; +}; + +&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 = "SBL1"; + reg = <0x0000000 0x0100000>; + read-only; + }; + + partition@100000 { + label = "MIBIB"; + reg = <0x0100000 0x0100000>; + read-only; + }; + + partition@200000 { + label = "BOOTCONFIG"; + reg = <0x0200000 0x0100000>; + read-only; + }; + + partition@300000 { + label = "QSEE"; + reg = <0x0300000 0x0100000>; + read-only; + }; + + partition@400000 { + label = "QSEE_1"; + reg = <0x0400000 0x0100000>; + read-only; + }; + + partition@500000 { + label = "CDT"; + reg = <0x0500000 0x0080000>; + read-only; + }; + + partition@580000 { + label = "CDT_1"; + reg = <0x0580000 0x0080000>; + read-only; + }; + + partition@600000 { + label = "BOOTCONFIG1"; + reg = <0x0600000 0x0080000>; + read-only; + }; + + partition@680000 { + label = "APPSBLENV"; + reg = <0x0680000 0x0080000>; + }; + + partition@700000 { + label = "APPSBL"; + reg = <0x0700000 0x0200000>; + read-only; + }; + + partition@900000 { + label = "APPSBL_1"; + reg = <0x0900000 0x0200000>; + read-only; + }; + + art: partition@b00000 { + label = "ART"; + reg = <0x0b00000 0x0080000>; + read-only; + }; + + partition@b80000 { + label = "ART_1"; + reg = <0x0b80000 0x0080000>; + read-only; + }; + + orgdata: partition@c00000 { + label = "ORGDATA"; + reg = <0x0c00000 0x0080000>; + read-only; + }; + + partition@c80000 { + label = "ORGDATA_1"; + reg = <0x0c80000 0x0080000>; + read-only; + }; + + partition@d00000 { + label = "ubi"; + reg = <0x0d00000 0x2900000>; + }; + + partition@3600000 { + label = "rootfs_recover"; + reg = <0x3600000 0x2900000>; + read-only; + }; + + partition@5f00000 { + label = "user_property"; + reg = <0x5f00000 0x1a20000>; + read-only; + }; + }; + }; +}; + +&wifi0 { + status = "okay"; + qcom,ath10k-calibration-variant = "Buffalo-WTR-M2133HP"; + ieee80211-freq-limit = <2400000 2483000>; +}; + +&wifi1 { + status = "okay"; + qcom,ath10k-calibration-variant = "Buffalo-WTR-M2133HP"; +}; + +&mdio { + status = "okay"; + pinctrl-0 = <&mdio_pins>; + pinctrl-names = "default"; + reset-gpios = <&tlmm 47 GPIO_ACTIVE_LOW>; +}; + +&gmac0 { + mtd-mac-address = <&orgdata 0x20>; +}; + +&gmac1 { + mtd-mac-address = <&orgdata 0x20>; +}; + +&usb3_ss_phy { + status = "okay"; +}; + +&usb3_hs_phy { + status = "okay"; +}; diff --git a/target/linux/ipq40xx/image/Makefile b/target/linux/ipq40xx/image/Makefile index 5336649c3d..51e8bcc7e3 100644 --- a/target/linux/ipq40xx/image/Makefile +++ b/target/linux/ipq40xx/image/Makefile @@ -245,6 +245,18 @@ define Device/avm_fritzrepeater-3000 endef TARGET_DEVICES += avm_fritzrepeater-3000 +define Device/buffalo_wtr-m2133hp + $(call Device/FitImage) + $(call Device/UbiFit) + DEVICE_VENDOR := Buffalo + DEVICE_MODEL := WTR-M2133HP + SOC := qcom-ipq4019 + DEVICE_PACKAGES := uboot-envtools ath10k-firmware-qca9984-ct ipq-wifi-buffalo_wtr-m2133hp + BLOCKSIZE := 128k + PAGESIZE := 2048 +endef +TARGET_DEVICES += buffalo_wtr-m2133hp + define Device/cellc_rtl30vw KERNEL_SUFFIX := -fit-uImage.itb KERNEL_INITRAMFS = kernel-bin | gzip | fit gzip $$(DTS_DIR)/$$(DEVICE_DTS).dtb diff --git a/target/linux/ipq40xx/patches-4.19/901-arm-boot-add-dts-files.patch b/target/linux/ipq40xx/patches-4.19/901-arm-boot-add-dts-files.patch index fb358ed184..924715c9aa 100644 --- a/target/linux/ipq40xx/patches-4.19/901-arm-boot-add-dts-files.patch +++ b/target/linux/ipq40xx/patches-4.19/901-arm-boot-add-dts-files.patch @@ -49,6 +49,7 @@ Signed-off-by: John Crispin + qcom-ipq4019-rtl30vw.dtb \ + qcom-ipq4019-u4019-32m.dtb \ + qcom-ipq4019-wpj419.dtb \ ++ qcom-ipq4019-wtr-m2133hp.dtb \ + qcom-ipq4028-wpj428.dtb \ + qcom-ipq4029-ap-303.dtb \ + qcom-ipq4029-ap-303h.dtb \ diff --git a/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch b/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch index 2db36aa597..c5b0981f49 100644 --- a/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch +++ b/target/linux/ipq40xx/patches-5.4/901-arm-boot-add-dts-files.patch @@ -50,6 +50,7 @@ Signed-off-by: John Crispin + qcom-ipq4019-rtl30vw.dtb \ + qcom-ipq4019-u4019-32m.dtb \ + qcom-ipq4019-wpj419.dtb \ ++ qcom-ipq4019-wtr-m2133hp.dtb \ + qcom-ipq4028-wpj428.dtb \ + qcom-ipq4029-ap-303.dtb \ + qcom-ipq4029-ap-303h.dtb \ -- 2.30.2