[OpenWrt-Devel] [PATCH 3/3] ipq40xx: add support for FritzBox 7530
David Bauer
mail at david-bauer.net
Sun Feb 10 08:34:30 EST 2019
Hardware
--------
CPU: Qualcomm IPQ4019
RAM: 256M
FLASH: 128M NAND
ETH: QCA8075
VDSL: Intel/Lantiq VRX518 PCIe attached
currently not supported
DECT: Dialog SC14448
currently not supported
WiFi2: IPQ4019 2T2R 2SS b/g/n
WiFi5: IPQ4019 2T2R 2SS n/ac
LED: - Power/DSL green
- WLAN green
- FON/DECT green
- Connect/WPS green
- Info green
- Info red
BTN: - WLAN
- FON
- WPS/Connect
UART: 115200n8 3.3V (located under the Dialog chip)
VCC - RX - TX - GND (Square is VCC)
Installation
------------
1. Grab the uboot for the Device from the 'u-boot-fritz7530'
subdirectory. Place it in the same directory as the 'eva_ramboot.py'
script. It is located in the 'scripts/flashing' subdirectory of the
OpenWRT tree.
2. Assign yourself the IP address 192.168.178.10/24. Connect your
Computer to one of the boxes LAN ports.
3. Connect Power to the Box. As soon as the LAN port of your computer
shows link, load the U-Boot to the box using following command.
> ./eva_ramboot.py --offset 0x85000000 192.168.178.1 uboot-fritz7530.bin
4. The U-Boot will now start. Now assign yourself the IP address
192.168.1.70/24. Copy the OpenWRT initramfs (!) image to a TFTP
server root directory and rename it to 'FRITZ7530.bin'.
5. The Box will now boot OpenWRT from RAM. This can take up to two
minutes.
6. Copy the U-Boot and the OpenWRT sysupgrade (!) image to the Box using
scp. SSH into the Box and first write the Bootloader to both previous
kernel partitions.
> mtd write /path/to/uboot-fritz7530.bin uboot0
> mtd write /path/to/uboot-fritz7530.bin uboot1
7. Remove the AVM filesystem partitions to make room for our kernel +
rootfs + overlayfs.
> ubirmvol /dev/ubi0 --name=avm_filesys_0
> ubirmvol /dev/ubi0 --name=avm_filesys_1
8. Flash OpenWRT peristently using sysupgrade.
> sysupgrade -n /path/to/openwrt-sysupgrade.bin
Signed-off-by: David Bauer <mail at david-bauer.net>
---
package/boot/uboot-fritz4040/Makefile | 7 +-
package/firmware/ipq-wifi/Makefile | 3 +-
package/firmware/ipq-wifi/board-fritz7530.bin | Bin 0 -> 24324 bytes
.../ipq40xx/base-files/etc/board.d/01_leds | 1 +
.../ipq40xx/base-files/etc/board.d/02_network | 4 +
.../etc/hotplug.d/firmware/11-ath10k-caldata | 6 +
.../base-files/lib/upgrade/platform.sh | 3 +-
.../boot/dts/qcom-ipq4019-fritzbox-7530.dts | 281 ++++++++++++++++++
.../boot/dts/qcom-ipq4019-fritzbox-7530.dts | 281 ++++++++++++++++++
target/linux/ipq40xx/image/Makefile | 9 +
.../901-arm-boot-add-dts-files.patch | 3 +-
.../901-arm-boot-add-dts-files.patch | 3 +-
12 files changed, 596 insertions(+), 5 deletions(-)
create mode 100644 package/firmware/ipq-wifi/board-fritz7530.bin
create mode 100644 target/linux/ipq40xx/files-4.14/arch/arm/boot/dts/qcom-ipq4019-fritzbox-7530.dts
create mode 100644 target/linux/ipq40xx/files-4.19/arch/arm/boot/dts/qcom-ipq4019-fritzbox-7530.dts
diff --git a/package/boot/uboot-fritz4040/Makefile b/package/boot/uboot-fritz4040/Makefile
index 45f211527d..a53b7d010f 100644
--- a/package/boot/uboot-fritz4040/Makefile
+++ b/package/boot/uboot-fritz4040/Makefile
@@ -30,6 +30,11 @@ define U-Boot/fritz4040
BUILD_DEVICES:=avm_fritzbox-4040
endef
+define U-Boot/fritz7530
+ NAME:=FritzBox 7530
+ BUILD_DEVICES:=avm_fritzbox-7530
+endef
+
UBOOT_CONFIGURE_VARS += USE_PRIVATE_LIBGCC=yes
UBOOT_MAKE_FLAGS = USE_PRIVATE_LIBGCC=yes
export DTC
@@ -56,6 +61,6 @@ define Package/u-boot/install
$(INSTALL_BIN) $(PKG_BUILD_DIR)/upload-to-f4040.sh $(1)/
endef
-UBOOT_TARGETS := fritz4040
+UBOOT_TARGETS := fritz4040 fritz7530
$(eval $(call BuildPackage/U-Boot))
diff --git a/package/firmware/ipq-wifi/Makefile b/package/firmware/ipq-wifi/Makefile
index cf1ad042bf..6523b19a76 100644
--- a/package/firmware/ipq-wifi/Makefile
+++ b/package/firmware/ipq-wifi/Makefile
@@ -17,7 +17,7 @@ endef
# Please send a mail with your device-specific board files upstream.
# You can find instructions and examples on the linux-wireless wiki:
# <https://wireless.wiki.kernel.org/en/users/drivers/ath10k/boardfiles>
-ALLWIFIBOARDS:=engenius_eap1300 linksys_ea6350v3
+ALLWIFIBOARDS:=engenius_eap1300 linksys_ea6350v3 fritz7530
ALLWIFIPACKAGES:=$(foreach BOARD,$(ALLWIFIBOARDS),ipq-wifi-$(BOARD))
define Package/ipq-wifi-default
@@ -54,5 +54,6 @@ endef
#$(eval $(call generate-ipq-wifi-package,<devicename>,<filename>,<displayname>))
$(eval $(call generate-ipq-wifi-package,engenius_eap1300,board-engenius_eap1300.bin,EnGenius EAP1300))
$(eval $(call generate-ipq-wifi-package,linksys_ea6350v3,board-linksys_ea6350v3.bin,Linksys EA6350v3))
+$(eval $(call generate-ipq-wifi-package,fritz7530,board-fritz7530.bin,AVM FRITZ!Box 7530))
$(foreach PACKAGE,$(ALLWIFIPACKAGES),$(eval $(call BuildPackage,$(PACKAGE))))
diff --git a/package/firmware/ipq-wifi/board-fritz7530.bin b/package/firmware/ipq-wifi/board-fritz7530.bin
new file mode 100644
index 0000000000000000000000000000000000000000..905145f1da5ee91c481f30e6bd08b3cf8da0c2ed
GIT binary patch
literal 24324
zcmeHPT~HHQ7QR9LR8%?%e<3s>;U{rPfWSzEC?P~9ffg7R5u)oNqLKhZ1m(v#CFP<b
zMr1 at 80!ENRMSgl+rCgm+nOz;%+0vA|FZ1ThzRiPFSzBAath2Y%2 at pxf1Yr%(C)~d0
zp1$XvbHDB+-F-juMOLOTvq+hgm at Aa$XBH|zO-&7eqDvsQ0A#>Yex!cO-pca$@*0hB
zU!_JT)KqLqw6w}=_tsSqO>ts;!`?d0-Y*Yt$t>P3%q~<FspYjz!qm at _6KiO23=SNR
zlQ14gqk&b&=_$p;*c%6c7bpW at jb9+q1aQkuh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za+wR%3oPTx{?|!krHGh5l{{g(;
Bh^qhq
literal 0
HcmV?d00001
diff --git a/target/linux/ipq40xx/base-files/etc/board.d/01_leds b/target/linux/ipq40xx/base-files/etc/board.d/01_leds
index 9105bf2452..39383f4fa8 100755
--- a/target/linux/ipq40xx/base-files/etc/board.d/01_leds
+++ b/target/linux/ipq40xx/base-files/etc/board.d/01_leds
@@ -28,6 +28,7 @@ engenius,eap1300)
ucidef_set_led_wlan "wlan5g" "WLAN5G" "${boardname}:yellow:wlan5g" "phy1tpt"
ucidef_set_led_default "mesh" "MESH" "${boardname}:blue:mesh" "0"
;;
+avm,fritzbox-7530 |\
glinet,gl-b1300)
ucidef_set_led_wlan "wlan" "WLAN" "${boardname}:green:wlan" "phy0tpt"
;;
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 bcc5f4cec9..e8ccffca37 100755
--- a/target/linux/ipq40xx/base-files/etc/board.d/02_network
+++ b/target/linux/ipq40xx/base-files/etc/board.d/02_network
@@ -27,6 +27,10 @@ ipq40xx_setup_interfaces()
ucidef_add_switch "switch0" \
"0u at eth0" "1:lan" "2:lan" "3:lan" "4:lan"
;;
+ avm,fritzbox-7530)
+ ucidef_add_switch "switch0" \
+ "0u at eth0" "1:lan" "2:lan" "3:lan" "4:lan"
+ ;;
compex,wpj428)
ucidef_set_interface_lan "eth0 eth1"
;;
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 69b6c2591c..b4252f0ea6 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
@@ -126,6 +126,9 @@ case "$FIRMWARE" in
avm,fritzbox-4040)
/usr/bin/fritz_cal_extract -i 1 -s 0x400 -e 0x207 -l 12064 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader_config")
;;
+ avm,fritzbox-7530)
+ /usr/bin/fritz_cal_extract -i 1 -s 0x3C000 -e 0x207 -l 16384 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader0")
+ ;;
meraki,mr33)
ath10kcal_ubi_extract "ART" 4096 12064
ath10kcal_is_caldata_valid "202f" || ath10kcal_extract "ART" 4096 12064
@@ -164,6 +167,9 @@ case "$FIRMWARE" in
avm,fritzbox-4040)
/usr/bin/fritz_cal_extract -i 1 -s 0x400 -e 0x208 -l 12064 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader_config")
;;
+ avm,fritzbox-7530)
+ /usr/bin/fritz_cal_extract -i 1 -s 0x3C800 -e 0x208 -l 16384 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader1")
+ ;;
meraki,mr33)
ath10kcal_ubi_extract "ART" 20480 12064
ath10kcal_is_caldata_valid "202f" || ath10kcal_extract "ART" 20480 12064
diff --git a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh
index c5f06ffb3a..76f78dd032 100644
--- a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh
+++ b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh
@@ -46,7 +46,8 @@ zyxel_do_upgrade() {
platform_do_upgrade() {
case "$(board_name)" in
- 8dev,jalapeno)
+ 8dev,jalapeno|\
+ avm,fritzbox-7530)
nand_do_upgrade "$ARGV"
;;
asus,rt-ac58u)
diff --git a/target/linux/ipq40xx/files-4.14/arch/arm/boot/dts/qcom-ipq4019-fritzbox-7530.dts b/target/linux/ipq40xx/files-4.14/arch/arm/boot/dts/qcom-ipq4019-fritzbox-7530.dts
new file mode 100644
index 0000000000..ea2d70a8bd
--- /dev/null
+++ b/target/linux/ipq40xx/files-4.14/arch/arm/boot/dts/qcom-ipq4019-fritzbox-7530.dts
@@ -0,0 +1,281 @@
+// 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>
+
+/ {
+ model = "AVM FRITZ!Box 7530";
+ compatible = "avm,fritzbox-7530", "qcom,ipq4019";
+
+ aliases {
+ led-boot = &power_green;
+ led-failsafe = &info_red;
+ led-running = &power_green;
+ led-upgrade = &info_green;
+ };
+
+ soc {
+ mdio at 90000 {
+ status = "okay";
+ };
+
+ ess-psgmii at 98000 {
+ status = "okay";
+ };
+
+ tcsr at 1949000 {
+ compatible = "qcom,tcsr";
+ reg = <0x1949000 0x100>;
+ qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
+ };
+
+ tcsr at 194b000 {
+ compatible = "qcom,tcsr";
+ reg = <0x194b000 0x100>;
+ qcom,usb-hsphy-mode-select = <TCSR_USB_HSPHY_HOST_MODE>;
+ };
+
+ ess_tcsr at 1953000 {
+ compatible = "qcom,tcsr";
+ reg = <0x1953000 0x1000>;
+ qcom,ess-interface-select = <TCSR_ESS_PSGMII>;
+ };
+
+ tcsr at 1957000 {
+ compatible = "qcom,tcsr";
+ reg = <0x1957000 0x100>;
+ qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
+ };
+
+ usb3 at 8af8800 {
+ status = "okay";
+ };
+
+ crypto at 8e3a000 {
+ status = "okay";
+ };
+
+ watchdog at b017000 {
+ status = "okay";
+ };
+
+ ess-switch at c000000 {
+ status = "okay";
+ };
+
+ edma at c080000 {
+ status = "okay";
+ qcom,num_gmac = <1>;
+ };
+ };
+
+ keys {
+ compatible = "gpio-keys";
+
+ wlan {
+ label = "wlan";
+ gpios = <&tlmm 42 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&tlmm 41 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ dect {
+ label = "dect";
+ gpios = <&tlmm 43 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_PHONE>;
+ };
+ };
+
+ leds {
+ compatible = "gpio-leds";
+
+ info_red: info_red {
+ label = "fritzbox-7530:red:info";
+ gpios = <&tlmm 32 GPIO_ACTIVE_LOW>;
+ };
+
+ info_green: info {
+ label = "fritzbox-7530:green:info";
+ gpios = <&tlmm 33 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "fritzbox-7530:green:wlan";
+ gpios = <&tlmm 34 GPIO_ACTIVE_LOW>;
+ };
+
+ fon {
+ label = "fritzbox-7530:green:fon";
+ gpios = <&tlmm 35 GPIO_ACTIVE_LOW>;
+ };
+
+ power_green: power {
+ label = "fritzbox-7530:green:power";
+ gpios = <&tlmm 39 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "fritzbox-7530:green:wps";
+ gpios = <&tlmm 45 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&tlmm {
+ serial_0_pins: serial_pinmux {
+ mux {
+ pins = "gpio16", "gpio17";
+ function = "blsp_uart0";
+ 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;
+ };
+ };
+
+ usb-power {
+ line-name = "enable USB3 power";
+ gpios = <49 GPIO_ACTIVE_HIGH>;
+ gpio-hog;
+ output-high;
+ };
+};
+
+&nand {
+ pinctrl-0 = <&nand_pins>;
+ pinctrl-names = "default";
+ status = "okay";
+ cs-gpios = <&tlmm 54 GPIO_ACTIVE_HIGH>;
+
+ nand at 0 {
+ partitions {
+ compatible = "fixed-partitions";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ partition at 0 {
+ label = "MIBIB";
+ reg = <0x000000 0x80000>;
+ read-only;
+ };
+
+ partition at 80000 {
+ label = "MIBIB";
+ reg = <0x080000 0x80000>;
+ read-only;
+ };
+
+ partition at 100000 {
+ label = "QSEE";
+ reg = <0x100000 0x80000>;
+ read-only;
+ };
+
+ partition at 180000 {
+ label = "CDT";
+ reg = <0x180000 0x40000>;
+ read-only;
+ };
+
+ partition at 1c0000 {
+ label = "QSEE_B";
+ reg = <0x1c0000 0x80000>;
+ read-only;
+ };
+
+ partition at 240000 {
+ label = "urlader0";
+ reg = <0x240000 0x40000>;
+ read-only;
+ };
+
+ partition at 280000 {
+ label = "urlader1";
+ reg = <0x280000 0x40000>;
+ read-only;
+ };
+
+ partition at 2c0000 {
+ label = "nand-tffs";
+ reg = <0x2c0000 0x840000>;
+ read-only;
+ };
+
+ partition at b00000 {
+ /* 'kernel1' in AVM firmware */
+ label = "uboot0";
+ reg = <0xb00000 0x400000>;
+ };
+
+ partition at f00000 {
+ /* 'kernel2' in AVM firmware */
+ label = "uboot1";
+ reg = <0xf00000 0x400000>;
+ };
+
+ partition at 1300000 {
+ label = "ubi";
+ reg = <0x1300000 0x6d00000>;
+ };
+ };
+ };
+};
+
+&cryptobam {
+ status = "okay";
+};
+
+&blsp_dma {
+ status = "okay";
+};
+
+&blsp1_uart1 {
+ pinctrl-0 = <&serial_0_pins>;
+ pinctrl-names = "default";
+ status = "okay";
+};
+
+&usb3_ss_phy {
+ status = "okay";
+};
+
+&usb3_hs_phy {
+ status = "okay";
+};
+
+&qpic_bam {
+ status = "okay";
+};
+
+&wifi0 {
+ status = "okay";
+ qcom,ath10k-calibration-variant = "AVM-FRITZBox-7530";
+};
+
+&wifi1 {
+ status = "okay";
+ qcom,ath10k-calibration-variant = "AVM-FRITZBox-7530";
+};
diff --git a/target/linux/ipq40xx/files-4.19/arch/arm/boot/dts/qcom-ipq4019-fritzbox-7530.dts b/target/linux/ipq40xx/files-4.19/arch/arm/boot/dts/qcom-ipq4019-fritzbox-7530.dts
new file mode 100644
index 0000000000..ea2d70a8bd
--- /dev/null
+++ b/target/linux/ipq40xx/files-4.19/arch/arm/boot/dts/qcom-ipq4019-fritzbox-7530.dts
@@ -0,0 +1,281 @@
+// 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>
+
+/ {
+ model = "AVM FRITZ!Box 7530";
+ compatible = "avm,fritzbox-7530", "qcom,ipq4019";
+
+ aliases {
+ led-boot = &power_green;
+ led-failsafe = &info_red;
+ led-running = &power_green;
+ led-upgrade = &info_green;
+ };
+
+ soc {
+ mdio at 90000 {
+ status = "okay";
+ };
+
+ ess-psgmii at 98000 {
+ status = "okay";
+ };
+
+ tcsr at 1949000 {
+ compatible = "qcom,tcsr";
+ reg = <0x1949000 0x100>;
+ qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
+ };
+
+ tcsr at 194b000 {
+ compatible = "qcom,tcsr";
+ reg = <0x194b000 0x100>;
+ qcom,usb-hsphy-mode-select = <TCSR_USB_HSPHY_HOST_MODE>;
+ };
+
+ ess_tcsr at 1953000 {
+ compatible = "qcom,tcsr";
+ reg = <0x1953000 0x1000>;
+ qcom,ess-interface-select = <TCSR_ESS_PSGMII>;
+ };
+
+ tcsr at 1957000 {
+ compatible = "qcom,tcsr";
+ reg = <0x1957000 0x100>;
+ qcom,wifi_noc_memtype_m0_m2 = <TCSR_WIFI_NOC_MEMTYPE_M0_M2>;
+ };
+
+ usb3 at 8af8800 {
+ status = "okay";
+ };
+
+ crypto at 8e3a000 {
+ status = "okay";
+ };
+
+ watchdog at b017000 {
+ status = "okay";
+ };
+
+ ess-switch at c000000 {
+ status = "okay";
+ };
+
+ edma at c080000 {
+ status = "okay";
+ qcom,num_gmac = <1>;
+ };
+ };
+
+ keys {
+ compatible = "gpio-keys";
+
+ wlan {
+ label = "wlan";
+ gpios = <&tlmm 42 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_RFKILL>;
+ };
+
+ wps {
+ label = "wps";
+ gpios = <&tlmm 41 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_WPS_BUTTON>;
+ };
+
+ dect {
+ label = "dect";
+ gpios = <&tlmm 43 GPIO_ACTIVE_LOW>;
+ linux,code = <KEY_PHONE>;
+ };
+ };
+
+ leds {
+ compatible = "gpio-leds";
+
+ info_red: info_red {
+ label = "fritzbox-7530:red:info";
+ gpios = <&tlmm 32 GPIO_ACTIVE_LOW>;
+ };
+
+ info_green: info {
+ label = "fritzbox-7530:green:info";
+ gpios = <&tlmm 33 GPIO_ACTIVE_LOW>;
+ };
+
+ wlan {
+ label = "fritzbox-7530:green:wlan";
+ gpios = <&tlmm 34 GPIO_ACTIVE_LOW>;
+ };
+
+ fon {
+ label = "fritzbox-7530:green:fon";
+ gpios = <&tlmm 35 GPIO_ACTIVE_LOW>;
+ };
+
+ power_green: power {
+ label = "fritzbox-7530:green:power";
+ gpios = <&tlmm 39 GPIO_ACTIVE_LOW>;
+ };
+
+ wps {
+ label = "fritzbox-7530:green:wps";
+ gpios = <&tlmm 45 GPIO_ACTIVE_LOW>;
+ };
+ };
+};
+
+&tlmm {
+ serial_0_pins: serial_pinmux {
+ mux {
+ pins = "gpio16", "gpio17";
+ function = "blsp_uart0";
+ 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;
+ };
+ };
+
+ usb-power {
+ line-name = "enable USB3 power";
+ gpios = <49 GPIO_ACTIVE_HIGH>;
+ gpio-hog;
+ output-high;
+ };
+};
+
+&nand {
+ pinctrl-0 = <&nand_pins>;
+ pinctrl-names = "default";
+ status = "okay";
+ cs-gpios = <&tlmm 54 GPIO_ACTIVE_HIGH>;
+
+ nand at 0 {
+ partitions {
+ compatible = "fixed-partitions";
+ #address-cells = <1>;
+ #size-cells = <1>;
+
+ partition at 0 {
+ label = "MIBIB";
+ reg = <0x000000 0x80000>;
+ read-only;
+ };
+
+ partition at 80000 {
+ label = "MIBIB";
+ reg = <0x080000 0x80000>;
+ read-only;
+ };
+
+ partition at 100000 {
+ label = "QSEE";
+ reg = <0x100000 0x80000>;
+ read-only;
+ };
+
+ partition at 180000 {
+ label = "CDT";
+ reg = <0x180000 0x40000>;
+ read-only;
+ };
+
+ partition at 1c0000 {
+ label = "QSEE_B";
+ reg = <0x1c0000 0x80000>;
+ read-only;
+ };
+
+ partition at 240000 {
+ label = "urlader0";
+ reg = <0x240000 0x40000>;
+ read-only;
+ };
+
+ partition at 280000 {
+ label = "urlader1";
+ reg = <0x280000 0x40000>;
+ read-only;
+ };
+
+ partition at 2c0000 {
+ label = "nand-tffs";
+ reg = <0x2c0000 0x840000>;
+ read-only;
+ };
+
+ partition at b00000 {
+ /* 'kernel1' in AVM firmware */
+ label = "uboot0";
+ reg = <0xb00000 0x400000>;
+ };
+
+ partition at f00000 {
+ /* 'kernel2' in AVM firmware */
+ label = "uboot1";
+ reg = <0xf00000 0x400000>;
+ };
+
+ partition at 1300000 {
+ label = "ubi";
+ reg = <0x1300000 0x6d00000>;
+ };
+ };
+ };
+};
+
+&cryptobam {
+ status = "okay";
+};
+
+&blsp_dma {
+ status = "okay";
+};
+
+&blsp1_uart1 {
+ pinctrl-0 = <&serial_0_pins>;
+ pinctrl-names = "default";
+ status = "okay";
+};
+
+&usb3_ss_phy {
+ status = "okay";
+};
+
+&usb3_hs_phy {
+ status = "okay";
+};
+
+&qpic_bam {
+ status = "okay";
+};
+
+&wifi0 {
+ status = "okay";
+ qcom,ath10k-calibration-variant = "AVM-FRITZBox-7530";
+};
+
+&wifi1 {
+ status = "okay";
+ qcom,ath10k-calibration-variant = "AVM-FRITZBox-7530";
+};
diff --git a/target/linux/ipq40xx/image/Makefile b/target/linux/ipq40xx/image/Makefile
index a670380ab3..ca5a453b47 100644
--- a/target/linux/ipq40xx/image/Makefile
+++ b/target/linux/ipq40xx/image/Makefile
@@ -97,6 +97,15 @@ define Device/avm_fritzbox-4040
endef
TARGET_DEVICES += avm_fritzbox-4040
+define Device/avm_fritzbox-7530
+ $(call Device/FitImageLzma)
+ DEVICE_DTS := qcom-ipq4019-fritzbox-7530
+ DEVICE_TITLE := AVM Fritz!Box 7530
+ DEVICE_PACKAGES := fritz-caldata ipq-wifi-fritz7530
+ IMAGES := sysupgrade.bin
+endef
+TARGET_DEVICES += avm_fritzbox-7530
+
define Device/compex_wpj428
$(call Device/FitImage)
DEVICE_DTS := qcom-ipq4028-wpj428
diff --git a/target/linux/ipq40xx/patches-4.14/901-arm-boot-add-dts-files.patch b/target/linux/ipq40xx/patches-4.14/901-arm-boot-add-dts-files.patch
index e0619a64dd..6844b2b2cf 100644
--- a/target/linux/ipq40xx/patches-4.14/901-arm-boot-add-dts-files.patch
+++ b/target/linux/ipq40xx/patches-4.14/901-arm-boot-add-dts-files.patch
@@ -10,7 +10,7 @@ Signed-off-by: John Crispin <john at phrozen.org>
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
-@@ -697,7 +697,22 @@ dtb-$(CONFIG_ARCH_QCOM) += \
+@@ -697,7 +697,23 @@ dtb-$(CONFIG_ARCH_QCOM) += \
qcom-apq8074-dragonboard.dtb \
qcom-apq8084-ifc6540.dtb \
qcom-apq8084-mtp.dtb \
@@ -27,6 +27,7 @@ Signed-off-by: John Crispin <john at phrozen.org>
qcom-ipq4019-ap.dk01.1-c1.dtb \
+ qcom-ipq4019-a62.dtb \
+ qcom-ipq4019-ap.dk04.1-c1.dtb \
++ qcom-ipq4019-fritzbox-7530.dtb \
+ qcom-ipq4028-wpj428.dtb \
+ qcom-ipq4029-gl-b1300.dtb \
+ qcom-ipq4029-mr33.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 d0f892bc48..37dc78e971 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
@@ -10,7 +10,7 @@ Signed-off-by: John Crispin <john at phrozen.org>
--- a/arch/arm/boot/dts/Makefile
+++ b/arch/arm/boot/dts/Makefile
-@@ -785,11 +785,25 @@ dtb-$(CONFIG_ARCH_QCOM) += \
+@@ -785,11 +785,26 @@ dtb-$(CONFIG_ARCH_QCOM) += \
qcom-apq8074-dragonboard.dtb \
qcom-apq8084-ifc6540.dtb \
qcom-apq8084-mtp.dtb \
@@ -30,6 +30,7 @@ Signed-off-by: John Crispin <john at phrozen.org>
qcom-ipq4019-ap.dk07.1-c1.dtb \
qcom-ipq4019-ap.dk07.1-c2.dtb \
+ qcom-ipq4019-a62.dtb \
++ qcom-ipq4019-fritzbox-7530.dtb \
+ qcom-ipq4028-wpj428.dtb \
+ qcom-ipq4029-gl-b1300.dtb \
+ qcom-ipq4029-mr33.dtb \
--
2.20.1
_______________________________________________
openwrt-devel mailing list
openwrt-devel at lists.openwrt.org
https://lists.openwrt.org/mailman/listinfo/openwrt-devel
More information about the openwrt-devel
mailing list