aboutsummaryrefslogtreecommitdiffstats
path: root/target/linux/ath79/generic
diff options
context:
space:
mode:
authorMichael Pratt <mcpratt@pm.me>2023-01-25 11:24:00 -0500
committerHauke Mehrtens <hauke@hauke-m.de>2023-02-12 18:07:31 +0100
commitf9c28222c830fbd6abff7251c5760226be999181 (patch)
tree10181e4bd4b51f5ae03ab0311b6f430c3859d33f /target/linux/ath79/generic
parent96c2119dbaf3cc137d963c00035386934b7ed6e8 (diff)
downloadupstream-f9c28222c830fbd6abff7251c5760226be999181.tar.gz
upstream-f9c28222c830fbd6abff7251c5760226be999181.tar.bz2
upstream-f9c28222c830fbd6abff7251c5760226be999181.zip
ath79: add support for Senao Engenius ESR1200
FCC ID: A8J-ESR900 Engenius ESR1200 is an indoor wireless router with a gigabit ethernet switch, dual-band wireless, internal antenna plates, and a USB 2.0 port **Specification:** - QCA9557 SOC 2.4 GHz, 2x2 - QCA9882 WLAN PCIe mini card, 5 GHz, 2x2 - QCA8337N SW 4 ports LAN, 1 port WAN - 40 MHz clock - 16 MB FLASH MX25L12845EMI-10G - 2x 64 MB RAM - UART at J1 populated, RX grounded - 6 internal antenna plates (omni-directional) - 5 LEDs, 1 button (power, 2G, 5G, WAN, WPS) (reset) **MAC addresses:** Base MAC address labeled as "MAC ADDRESS" MAC "wanaddr" is not similar to "ethaddr" eth0 *:c8 MAC u-boot-env ethaddr phy0 *:c8 MAC u-boot-env ethaddr phy1 *:c9 --- u-boot-env ethaddr +1 WAN *:66:44 u-boot-env wanaddr **Serial Access:** RX on the board for UART is shorted to ground by resistor R176 therefore it must be removed to use the console but it is not necessary to remove to view boot log optionally, R175 can be replaced with a solder bridge short the resistors R175 and R176 are next to the UART RX pin **Installation:** Method 1: Firmware upgrade page OEM webpage at 192.168.0.1 username and password "admin" Navigate to Settings (gear icon) --> Tools --> Firmware select the factory.bin image confirm and wait 3 minutes Method 2: TFTP recovery Follow TFTP instructions using initramfs.bin use sysupgrade.bin to flash using openwrt web interface **Return to OEM:** MTD partitions should be backed up before flashing using TFTP to boot openwrt without overwriting flash Alternatively, it is possible to edit OEM firmware images to flash MTD partitions in openwrt to restore OEM firmware by removing the OEM header and writing the rest to "firmware" **TFTP recovery:** Requires serial console, reset button does nothing at boot rename initramfs.bin to 'uImageESR1200' make available on TFTP server at 192.168.99.8 power board, interrupt boot by pressing '4' rapidly execute tftpboot and bootm **Note on ETH switch registers** Registers must be written to the ethernet switch in order to set up the switch's MAC interface. U-boot can write the registers on it's own which is needed, for example, in a TFTP transfer. The register bits from OEM for the QCA8337 switch can be read from interrupted boot (tftpboot, bootm) by adding print lines in the switch driver ar8327.c before 'qca,ar8327-initvals' is parsed from DTS and written. for example: pr_info("0x04 %08x\n", ar8xxx_read(priv, AR8327_REG_PAD0_MODE)); Signed-off-by: Michael Pratt <mcpratt@pm.me>
Diffstat (limited to 'target/linux/ath79/generic')
-rw-r--r--target/linux/ath79/generic/base-files/etc/board.d/02_network2
-rw-r--r--target/linux/ath79/generic/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac1
-rw-r--r--target/linux/ath79/generic/base-files/lib/preinit/10_fix_eth_mac.sh1
3 files changed, 4 insertions, 0 deletions
diff --git a/target/linux/ath79/generic/base-files/etc/board.d/02_network b/target/linux/ath79/generic/base-files/etc/board.d/02_network
index fbdd8c493e..b20a3c13f8 100644
--- a/target/linux/ath79/generic/base-files/etc/board.d/02_network
+++ b/target/linux/ath79/generic/base-files/etc/board.d/02_network
@@ -287,6 +287,7 @@ ath79_setup_interfaces()
dlink,dir-842-c3|\
dlink,dir-859-a1|\
engenius,epg5000|\
+ engenius,esr1200|\
engenius,esr1750|\
engenius,esr900|\
sitecom,wlr-7100|\
@@ -668,6 +669,7 @@ ath79_setup_macs()
label_mac=$lan_mac
;;
engenius,epg5000|\
+ engenius,esr1200|\
engenius,esr1750|\
engenius,esr900)
lan_mac=$(mtd_get_mac_ascii u-boot-env ethaddr)
diff --git a/target/linux/ath79/generic/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac b/target/linux/ath79/generic/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac
index 1290c8b5fd..f4df2c4edb 100644
--- a/target/linux/ath79/generic/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac
+++ b/target/linux/ath79/generic/base-files/etc/hotplug.d/ieee80211/10_fix_wifi_mac
@@ -35,6 +35,7 @@ case "$board" in
[ "$PHYNBR" -eq 1 ] && \
mtd_get_mac_ascii bdcfg "wlanmac" > /sys${DEVPATH}/macaddress
;;
+ engenius,esr1200|\
engenius,esr1750|\
engenius,esr900)
macaddr_add "$(mtd_get_mac_ascii u-boot-env ethaddr)" "$PHYNBR" > /sys${DEVPATH}/macaddress
diff --git a/target/linux/ath79/generic/base-files/lib/preinit/10_fix_eth_mac.sh b/target/linux/ath79/generic/base-files/lib/preinit/10_fix_eth_mac.sh
index b98b047c93..def4417fbc 100644
--- a/target/linux/ath79/generic/base-files/lib/preinit/10_fix_eth_mac.sh
+++ b/target/linux/ath79/generic/base-files/lib/preinit/10_fix_eth_mac.sh
@@ -12,6 +12,7 @@ preinit_set_mac_address() {
ip link set dev eth0 address $(mtd_get_mac_ascii bdcfg "lanmac")
ip link set dev eth1 address $(mtd_get_mac_ascii bdcfg "wanmac")
;;
+ engenius,esr1200|\
engenius,esr1750|\
engenius,esr900)
ip link set dev eth0 address $(mtd_get_mac_ascii u-boot-env ethaddr)