bcm53xx: enhance support for Linksys EA9500

1. Add leds and configs
2. Add network configs
3. Add script to clear partial boot flag
4. Hack to use port 5 as cpu port as port 8 connected to eth2
   wont pass any frames
5. Enable EA9500 image generation

Hardware Info:

- Processor - Broadcom BCM4709C0KFEBG dual-core @ 1.4 GHz
- Switch - BCM53012 in BCM4709C0KFEBG & external BCM53125
- DDR3 RAM - 256 MB
- Flash - 128 MB (Toshiba TC58BVG0S3HTA00)
- 2.4GHz - BCM4366 4×4 2.4/5G single chip 802.11ac SoC
- Power Amp - Skyworks SE2623L 2.4 GHz power amp (x4)
- 5GHz x 2 - BCM4366 4×4 2.4/5G single chip 802.11ac SoC
- Power Amp - PLX Technology PEX8603 3-lane, 3-port PCIe switch
- Ports - 8 Ports, 1 WAN Ports
- Antennas - 8 Antennas
- Serial Port - @j6 [GND,TX,RX] (VCC NC) 115200 8n1

Flashing Instructions:

1. Connect a USB-TTL table to J6 on the router as well as a
   ethernet cable to a lan port and your PC.
2. Power-on the router.
3. Use putty or a serial port program to view the terminal.
   Hit Ctrl+C and interrupt the CFE terminal terminal.
4. Setup a TFTP server on your local machine at setup you
   local IP to 192.168.1.2
5. Start the TFTP Server
6. Run following commands at the CFE terminal

   flash -noheader 192.168.1.2:/openwrt.trx nflash0.trx
   flash -noheader 192.168.1.2:/openwrt.trx nflash0.trx2
   nvram set bootpartition=0 && nvram set partialboots=0 && nvram commit

7. Reboot router to be presented by OpenWrt

Note: Only installation method via serial cable is supported at the moment.
The trx firmware has to be flashed to both the partitions using following
commands from CFE prompt. This will cover US and Non-US variants.

Signed-off-by: Vivek Unune <npcomplete13@gmail.com>
Signed-off-by: Rafał Miłecki <rafal@milecki.pl>
(cherry picked from commit 209c5918b5)
This commit is contained in:
Vivek Unune 2020-11-13 08:43:00 -05:00 committed by Rafał Miłecki
parent ca6a1d0dc8
commit 9aaa20d8ba
4 changed files with 22 additions and 3 deletions

View File

@ -31,6 +31,10 @@ bcm53xx_setup_interfaces()
ucidef_add_switch "switch0" \
"0:lan" "1:lan" "2:lan" "3:lan" "4:wan" "5t@eth0"
;;
linksys,panamera)
ucidef_add_switch "switch1" \
"0:lan" "1:lan:7" "2:lan:4" "3:lan:8" "4:wan" "5t@eth0"
;;
luxul,abr-4500-v1|\
luxul,xbr-4500-v1)
ucidef_add_switch "switch0" \
@ -84,6 +88,7 @@ bcm53xx_setup_macs()
case "$board" in
dlink,dir-885l | \
linksys,panamera | \
netgear,r7900 | \
netgear,r8000 | \
netgear,r8500)
@ -105,6 +110,7 @@ bcm53xx_setup_macs()
offset=1
;;
dlink,dir-885l | \
linksys,panamera | \
netgear,r7900 | \
netgear,r8000 | \
netgear,r8500)

View File

@ -0,0 +1,13 @@
#!/bin/sh /etc/rc.common
START=97
boot() {
. /lib/functions.sh
case $(board_name) in
linksys,panamera)
# clear partialboots
nvram set partialboots=0 && nvram commit
;;
esac
}

View File

@ -274,7 +274,6 @@ define Device/linksys_ea9500
DEVICE_MODEL := EA9500
DEVICE_PACKAGES := $(BRCMFMAC_4366C0) $(USB3_PACKAGES)
DEVICE_DTS := bcm47094-linksys-panamera
BROKEN := y
endef
TARGET_DEVICES += linksys_ea9500

View File

@ -21,7 +21,7 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
#include "b53_regs.h"
#include "b53_priv.h"
@@ -1587,6 +1588,28 @@ static int b53_switch_init(struct b53_de
@@ -1587,6 +1588,29 @@ static int b53_switch_init(struct b53_de
return ret;
}
@ -44,7 +44,8 @@ Signed-off-by: Rafał Miłecki <zajec5@gmail.com>
+ * For some reason it doesn't work (no packets on eth2).
+ */
+ if (of_machine_is_compatible("netgear,r7900") ||
+ of_machine_is_compatible("netgear,r8000"))
+ of_machine_is_compatible("netgear,r8000") ||
+ (of_machine_is_compatible("linksys,panamera") && dev->chip_id == BCM53012_DEVICE_ID))
+ sw_dev->cpu_port = 5;
+
dev->enabled_ports |= BIT(sw_dev->cpu_port);