mirror of
https://github.com/coolsnowwolf/lede.git
synced 2025-04-18 17:33:31 +00:00
ipq40xx: add support for ASUS RT-ACRH17 v5.4
This commit is contained in:
parent
0c95d8abf1
commit
8e012e7da4
@ -18,6 +18,16 @@ asus,rt-ac58u)
|
||||
ucidef_set_led_netdev "wan" "WAN" "${boardname}:blue:wan" "eth1"
|
||||
ucidef_set_led_switch "lan" "LAN" "${boardname}:blue:lan" "switch0" "0x1e"
|
||||
;;
|
||||
asus,rt-acrh17)
|
||||
ucidef_set_led_default "status" "STATUS" "${boardname}:blue:status" "1"
|
||||
ucidef_set_led_wlan "wlan2g" "WLAN2G" "${boardname}:blue:wlan2g" "phy1tpt"
|
||||
ucidef_set_led_wlan "wlan5g" "WLAN5G" "${boardname}:blue:wlan5g" "phy0tpt"
|
||||
ucidef_set_led_switch "wan" "WAN(blue)" "${boardname}:blue:wan" "switch0" "0x20"
|
||||
ucidef_set_led_switch "lan1" "LAN1" "${boardname}:blue:lan1" "switch0" "0x02"
|
||||
ucidef_set_led_switch "lan2" "LAN2" "${boardname}:blue:lan2" "switch0" "0x04"
|
||||
ucidef_set_led_switch "lan3" "LAN3" "${boardname}:blue:lan3" "switch0" "0x08"
|
||||
ucidef_set_led_switch "lan4" "LAN4" "${boardname}:blue:lan4" "switch0" "0x10"
|
||||
;;
|
||||
avm,fritzbox-4040)
|
||||
ucidef_set_led_wlan "wlan" "WLAN" "fritz4040:green:wlan" "phy0tpt" "phy1tpt"
|
||||
ucidef_set_led_netdev "wan" "WAN" "fritz4040:green:wan" "eth1"
|
||||
|
@ -42,6 +42,7 @@ ipq40xx_setup_interfaces()
|
||||
openmesh,a62)
|
||||
ucidef_set_interfaces_lan_wan "eth1" "eth0"
|
||||
;;
|
||||
asus,rt-acrh17|\
|
||||
asus,rt-ac58u|\
|
||||
zyxel,nbg6617)
|
||||
ucidef_set_interfaces_lan_wan "eth0" "eth1"
|
||||
@ -113,6 +114,7 @@ ipq40xx_setup_macs()
|
||||
8dev,habanero-dvk)
|
||||
label_mac=$(mtd_get_mac_binary "ART" 0x1006)
|
||||
;;
|
||||
asus,rt-acrh17|\
|
||||
asus,rt-ac58u)
|
||||
CI_UBIPART=UBI_DEV
|
||||
wan_mac=$(mtd_get_mac_binary_ubi Factory 0x1006)
|
||||
|
@ -23,6 +23,10 @@ case "$FIRMWARE" in
|
||||
ln -sf /lib/firmware/ath10k/pre-cal-pci-0000\:00\:00.0.bin \
|
||||
/lib/firmware/ath10k/QCA9888/hw2.0/board.bin
|
||||
;;
|
||||
asus,rt-acrh17)
|
||||
CI_UBIPART=UBI_DEV
|
||||
caldata_extract_ubi "Factory" 0x9000 0x2f20
|
||||
;;
|
||||
avm,fritzrepeater-3000)
|
||||
/usr/bin/fritz_cal_extract -i 1 -s 0x3D000 -e 0x212 -l 12064 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader0") || \
|
||||
/usr/bin/fritz_cal_extract -i 1 -s 0x3C800 -e 0x212 -l 12064 -o /lib/firmware/$FIRMWARE $(find_mtd_chardev "urlader0") || \
|
||||
@ -64,6 +68,7 @@ case "$FIRMWARE" in
|
||||
asus,map-ac2200)
|
||||
caldata_extract_ubi "Factory" 0x1000 0x2f20
|
||||
;;
|
||||
asus,rt-acrh17|\
|
||||
asus,rt-ac58u)
|
||||
CI_UBIPART=UBI_DEV
|
||||
caldata_extract_ubi "Factory" 0x1000 0x2f20
|
||||
|
@ -2,6 +2,7 @@
|
||||
|
||||
preinit_set_mac_address() {
|
||||
case $(board_name) in
|
||||
asus,rt-acrh17|\
|
||||
asus,map-ac2200)
|
||||
base_mac=$(mtd_get_mac_binary_ubi Factory 0x1006)
|
||||
ip link set dev eth0 address $(macaddr_add "$base_mac" +1)
|
||||
|
@ -198,6 +198,7 @@ platform_do_upgrade() {
|
||||
CI_KERNPART="linux"
|
||||
nand_do_upgrade "$1"
|
||||
;;
|
||||
asus,rt-acrh17|\
|
||||
asus,rt-ac58u)
|
||||
local magic=$(get_magic_long "$1")
|
||||
CI_UBIPART="UBI_DEV"
|
||||
|
@ -0,0 +1,276 @@
|
||||
/* Copyright (c) 2015, The Linux Foundation. All rights reserved.
|
||||
* Copyright (C) 2019 X-WRT <dev@x-wrt.com>
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for any
|
||||
* purpose with or without fee is hereby granted, provided that the above
|
||||
* copyright notice and this permission notice appear in all copies.
|
||||
*
|
||||
* THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
||||
* WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
||||
* MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
||||
* ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
||||
* WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
||||
* ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
||||
* OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
||||
*
|
||||
*/
|
||||
|
||||
#include "qcom-ipq4019.dtsi"
|
||||
#include <dt-bindings/gpio/gpio.h>
|
||||
#include <dt-bindings/input/input.h>
|
||||
#include <dt-bindings/soc/qcom,tcsr.h>
|
||||
|
||||
/ {
|
||||
model = "ASUS RT-ACRH17";
|
||||
compatible = "asus,rt-acrh17";
|
||||
|
||||
memory {
|
||||
device_type = "memory";
|
||||
reg = <0x80000000 0x10000000>;
|
||||
};
|
||||
|
||||
aliases {
|
||||
led-boot = &power;
|
||||
led-failsafe = &power;
|
||||
led-running = &power;
|
||||
led-upgrade = &power;
|
||||
};
|
||||
|
||||
chosen {
|
||||
bootargs-append = " ubi.mtd=UBI_DEV";
|
||||
};
|
||||
|
||||
soc {
|
||||
rng@22000 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
mdio@90000 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
ess-psgmii@98000 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
tcsr@1949000 {
|
||||
compatible = "qcom,tcsr";
|
||||
reg = <0x1949000 0x100>;
|
||||
qcom,wifi_glb_cfg = <TCSR_WIFI_GLB_CFG>;
|
||||
};
|
||||
|
||||
tcsr@194b000 {
|
||||
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>;
|
||||
};
|
||||
|
||||
usb2@60f8800 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
usb3@8af8800 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
crypto@8e3a000 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
watchdog@b017000 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
ess-switch@c000000 {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
edma@c080000 {
|
||||
status = "okay";
|
||||
};
|
||||
};
|
||||
|
||||
keys {
|
||||
compatible = "gpio-keys";
|
||||
|
||||
reset {
|
||||
label = "reset";
|
||||
gpios = <&tlmm 18 GPIO_ACTIVE_LOW>;
|
||||
linux,code = <KEY_RESTART>;
|
||||
};
|
||||
|
||||
wps {
|
||||
label = "wps";
|
||||
gpios = <&tlmm 11 GPIO_ACTIVE_LOW>;
|
||||
linux,code = <KEY_WPS_BUTTON>;
|
||||
};
|
||||
};
|
||||
|
||||
leds {
|
||||
compatible = "gpio-leds";
|
||||
|
||||
power: status {
|
||||
label = "rt-acrh17:blue:status";
|
||||
gpios = <&tlmm 40 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
lan1 {
|
||||
label = "rt-acrh17:blue:lan1";
|
||||
gpios = <&tlmm 45 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
lan2 {
|
||||
label = "rt-acrh17:blue:lan2";
|
||||
gpios = <&tlmm 43 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
lan3 {
|
||||
label = "rt-acrh17:blue:lan3";
|
||||
gpios = <&tlmm 42 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
lan4 {
|
||||
label = "rt-acrh17:blue:lan4";
|
||||
gpios = <&tlmm 49 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
wan_blue {
|
||||
label = "rt-acrh17:blue:wan";
|
||||
gpios = <&tlmm 61 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
wan_red {
|
||||
label = "rt-acrh17:red:wan";
|
||||
gpios = <&tlmm 68 GPIO_ACTIVE_HIGH>;
|
||||
};
|
||||
|
||||
wlan2g {
|
||||
label = "rt-acrh17:blue:wlan2g";
|
||||
gpios = <&tlmm 52 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
|
||||
wlan5g {
|
||||
label = "rt-acrh17:blue:wlan5g";
|
||||
gpios = <&tlmm 54 GPIO_ACTIVE_LOW>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&cryptobam {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&blsp_dma {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&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 = "Bootloader";
|
||||
reg = <0x000000000000 0x000000400000>;
|
||||
read-only;
|
||||
};
|
||||
partition@400000 {
|
||||
label = "UBI_DEV";
|
||||
reg = <0x000000400000 0x000007C00000>;
|
||||
};
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&tlmm {
|
||||
serial_pins: serial_pinmux {
|
||||
mux {
|
||||
pins = "gpio16", "gpio17";
|
||||
function = "blsp_uart0";
|
||||
bias-disable;
|
||||
};
|
||||
};
|
||||
|
||||
nand_pins: nand_pins {
|
||||
pullups {
|
||||
pins = "gpio53", "gpio58",
|
||||
"gpio59";
|
||||
function = "qpic";
|
||||
bias-pull-up;
|
||||
};
|
||||
|
||||
pulldowns {
|
||||
pins = "gpio55", "gpio56",
|
||||
"gpio57", "gpio60",
|
||||
"gpio62", "gpio63", "gpio64",
|
||||
"gpio65", "gpio66", "gpio67",
|
||||
"gpio69";
|
||||
function = "qpic";
|
||||
bias-pull-down;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&pcie0 {
|
||||
status = "okay";
|
||||
perst-gpio = <&tlmm 38 GPIO_ACTIVE_LOW>;
|
||||
wake-gpio = <&tlmm 50 GPIO_ACTIVE_LOW>;
|
||||
|
||||
bridge@0,0 {
|
||||
reg = <0x00000000 0 0 0 0>;
|
||||
#address-cells = <3>;
|
||||
#size-cells = <2>;
|
||||
ranges;
|
||||
|
||||
wifi2: wifi@1,0 {
|
||||
compatible = "qcom,ath10k";
|
||||
status = "okay";
|
||||
reg = <0x00010000 0 0 0 0>;
|
||||
};
|
||||
};
|
||||
};
|
||||
|
||||
&wifi0 {
|
||||
status = "okay";
|
||||
qcom,ath10k-calibration-variant = "RT-ACRH17";
|
||||
};
|
||||
|
||||
&blsp1_uart1 {
|
||||
pinctrl-0 = <&serial_pins>;
|
||||
pinctrl-names = "default";
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usb3_ss_phy {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usb3_hs_phy {
|
||||
status = "okay";
|
||||
};
|
||||
|
||||
&usb2_hs_phy {
|
||||
status = "okay";
|
||||
};
|
@ -204,6 +204,24 @@ define Device/asus_rt-ac58u
|
||||
endef
|
||||
TARGET_DEVICES += asus_rt-ac58u
|
||||
|
||||
define Device/asus_rt-acrh17
|
||||
$(call Device/FitImageLzma)
|
||||
DEVICE_VENDOR := ASUS
|
||||
DEVICE_MODEL := RT-ACRH17
|
||||
SOC := qcom-ipq4019
|
||||
BLOCKSIZE := 128k
|
||||
PAGESIZE := 2048
|
||||
DTB_SIZE := 65536
|
||||
IMAGE_SIZE := 20439364
|
||||
FILESYSTEMS := squashfs
|
||||
UIMAGE_NAME:=$(shell echo -e '\03\01\01\01RT-AC82U')
|
||||
KERNEL_INITRAMFS := $$(KERNEL) | uImage none
|
||||
KERNEL_INITRAMFS_SUFFIX := -factory.trx
|
||||
IMAGES := sysupgrade.bin
|
||||
DEVICE_PACKAGES := ath10k-firmware-qca9984-ct ipq-wifi-asus_rt-acrh17 kmod-usb-ledtrig-usbport
|
||||
endef
|
||||
TARGET_DEVICES += asus_rt-acrh17
|
||||
|
||||
define Device/avm_fritzbox-4040
|
||||
$(call Device/FitImageLzma)
|
||||
DEVICE_VENDOR := AVM
|
||||
|
@ -10,7 +10,7 @@ Signed-off-by: John Crispin <john@phrozen.org>
|
||||
|
||||
--- a/arch/arm/boot/dts/Makefile
|
||||
+++ b/arch/arm/boot/dts/Makefile
|
||||
@@ -785,11 +785,47 @@ dtb-$(CONFIG_ARCH_QCOM) += \
|
||||
@@ -785,11 +785,48 @@ dtb-$(CONFIG_ARCH_QCOM) += \
|
||||
qcom-apq8074-dragonboard.dtb \
|
||||
qcom-apq8084-ifc6540.dtb \
|
||||
qcom-apq8084-mtp.dtb \
|
||||
@ -48,6 +48,7 @@ Signed-off-by: John Crispin <john@phrozen.org>
|
||||
+ qcom-ipq4019-e2600ac-c2.dtb \
|
||||
+ qcom-ipq4019-rtl30vw.dtb \
|
||||
+ qcom-ipq4019-u4019-32m.dtb \
|
||||
+ qcom-ipq4019-rt-acrh17.dtb \
|
||||
+ qcom-ipq4019-wpj419.dtb \
|
||||
+ qcom-ipq4028-wpj428.dtb \
|
||||
+ qcom-ipq4029-ap-303.dtb \
|
||||
|
@ -10,7 +10,7 @@ Signed-off-by: John Crispin <john@phrozen.org>
|
||||
|
||||
--- a/arch/arm/boot/dts/Makefile
|
||||
+++ b/arch/arm/boot/dts/Makefile
|
||||
@@ -837,11 +837,48 @@ dtb-$(CONFIG_ARCH_QCOM) += \
|
||||
@@ -837,11 +837,49 @@ dtb-$(CONFIG_ARCH_QCOM) += \
|
||||
qcom-apq8074-dragonboard.dtb \
|
||||
qcom-apq8084-ifc6540.dtb \
|
||||
qcom-apq8084-mtp.dtb \
|
||||
@ -49,6 +49,7 @@ Signed-off-by: John Crispin <john@phrozen.org>
|
||||
+ qcom-ipq4019-habanero-dvk.dtb \
|
||||
+ qcom-ipq4019-rtl30vw.dtb \
|
||||
+ qcom-ipq4019-u4019-32m.dtb \
|
||||
+ qcom-ipq4019-rt-acrh17.dtb \
|
||||
+ qcom-ipq4019-wpj419.dtb \
|
||||
+ qcom-ipq4028-wpj428.dtb \
|
||||
+ qcom-ipq4029-ap-303.dtb \
|
||||
|
Loading…
Reference in New Issue
Block a user