diff options
Diffstat (limited to 'target/linux/ipq40xx/base-files')
6 files changed, 20 insertions, 11 deletions
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 16039c8c42..26acfb6037 100644 --- a/target/linux/ipq40xx/base-files/etc/board.d/01_leds +++ b/target/linux/ipq40xx/base-files/etc/board.d/01_leds @@ -12,6 +12,12 @@ case "$board" in alfa-network,ap120c-ac) ucidef_set_led_netdev "wan" "WAN" "amber:wan" "eth1" ;; +asus,rt-ac42u) + ucidef_set_led_switch "lan1" "LAN1" "blue:lan" "switch0" "0x02" + ucidef_set_led_switch "lan2" "LAN2" "blue:lan_1" "switch0" "0x04" + ucidef_set_led_switch "lan3" "LAN3" "blue:lan_2" "switch0" "0x08" + ucidef_set_led_switch "lan4" "LAN4" "blue:lan_3" "switch0" "0x10" + ;; asus,rt-ac58u) ucidef_set_led_netdev "wan" "WAN" "blue:wan" "eth1" ucidef_set_led_switch "lan" "LAN" "blue:lan" "switch0" "0x1e" 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 c37fc58b22..2b908c800f 100644 --- a/target/linux/ipq40xx/base-files/etc/board.d/02_network +++ b/target/linux/ipq40xx/base-files/etc/board.d/02_network @@ -50,6 +50,7 @@ ipq40xx_setup_interfaces() openmesh,a62) ucidef_set_interfaces_lan_wan "eth1" "eth0" ;; + asus,rt-ac42u|\ asus,rt-ac58u|\ mikrotik,hap-ac2|\ mikrotik,hap-ac3|\ @@ -153,7 +154,6 @@ ipq40xx_setup_macs() label_mac=$(mtd_get_mac_binary "ART" 0x1006) ;; asus,rt-ac58u) - CI_UBIPART=UBI_DEV wan_mac=$(mtd_get_mac_binary_ubi Factory 0x1006) lan_mac=$(mtd_get_mac_binary_ubi Factory 0x5006) label_mac=$wan_mac 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 d368475ffc..12061eadf5 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 @@ -26,6 +26,9 @@ 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-ac42u) + 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") || \ @@ -81,11 +84,9 @@ case "$FIRMWARE" in caldata_extract "ART" 0x1000 0x2f20 ath10k_patch_mac $(mtd_get_mac_binary mfginfo 0x1D) ;; - asus,map-ac2200) - caldata_extract_ubi "Factory" 0x1000 0x2f20 - ;; + asus,map-ac2200 |\ + asus,rt-ac42u |\ asus,rt-ac58u) - CI_UBIPART=UBI_DEV caldata_extract_ubi "Factory" 0x1000 0x2f20 ;; avm,fritzbox-4040) @@ -203,11 +204,8 @@ case "$FIRMWARE" in caldata_extract "ART" 0x5000 0x2f20 ath10k_patch_mac $(macaddr_add $(mtd_get_mac_binary mfginfo 0x1D) 1) ;; - asus,map-ac2200) - caldata_extract_ubi "Factory" 0x5000 0x2f20 - ;; + asus,map-ac2200 |\ asus,rt-ac58u) - CI_UBIPART=UBI_DEV caldata_extract_ubi "Factory" 0x5000 0x2f20 ;; avm,fritzbox-4040) diff --git a/target/linux/ipq40xx/base-files/lib/preinit/05_set_iface_mac_ipq40xx.sh b/target/linux/ipq40xx/base-files/lib/preinit/05_set_iface_mac_ipq40xx.sh index d1fcd804d9..2609a55d27 100644 --- a/target/linux/ipq40xx/base-files/lib/preinit/05_set_iface_mac_ipq40xx.sh +++ b/target/linux/ipq40xx/base-files/lib/preinit/05_set_iface_mac_ipq40xx.sh @@ -7,6 +7,10 @@ preinit_set_mac_address() { ip link set dev eth0 address $(macaddr_add "$base_mac" 1) ip link set dev eth1 address $(macaddr_add "$base_mac" 3) ;; + asus,rt-ac42u) + ip link set dev eth0 address $(mtd_get_mac_binary_ubi Factory 0x1006) + ip link set dev eth1 address $(mtd_get_mac_binary_ubi Factory 0x9006) + ;; engenius,eap2200) base_mac=$(cat /sys/class/net/eth0/address) ip link set dev eth1 address $(macaddr_add "$base_mac" 1) diff --git a/target/linux/ipq40xx/base-files/lib/preinit/06_set_preinit_iface_ipq40xx.sh b/target/linux/ipq40xx/base-files/lib/preinit/06_set_preinit_iface_ipq40xx.sh index e97133f105..18c13c602c 100644 --- a/target/linux/ipq40xx/base-files/lib/preinit/06_set_preinit_iface_ipq40xx.sh +++ b/target/linux/ipq40xx/base-files/lib/preinit/06_set_preinit_iface_ipq40xx.sh @@ -3,6 +3,7 @@ set_preinit_iface() { case $(board_name) in aruba,ap-303| \ + asus,rt-ac42u| \ asus,rt-ac58u| \ avm,fritzbox-4040| \ ezviz,cs-w3-wd1200g-eup| \ diff --git a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh index 357e02000a..b0493e10ba 100644 --- a/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh +++ b/target/linux/ipq40xx/base-files/lib/upgrade/platform.sh @@ -6,8 +6,8 @@ RAMFS_COPY_DATA='/etc/fw_env.config /var/lock/fw_printenv.lock' platform_check_image() { case "$(board_name)" in + asus,rt-ac42u |\ asus,rt-ac58u) - CI_UBIPART="UBI_DEV" local ubidev=$(nand_find_ubi $CI_UBIPART) local asus_root=$(nand_find_volume $ubidev jffs2) @@ -117,8 +117,8 @@ platform_do_upgrade() { CI_KERNPART="linux" nand_do_upgrade "$1" ;; + asus,rt-ac42u |\ asus,rt-ac58u) - CI_UBIPART="UBI_DEV" CI_KERNPART="linux" nand_do_upgrade "$1" ;; |