openwrt/target/linux
Mikhail Zhilkin ebdaee7194 ramips: add support for Sercomm CPJ routers
This commit adds support for following wireless routers:
 - Rostelecom RT-FL-1 (Serсomm RT-FL-1)
 - Rostelecom S1010 (Serсomm S1010.RT)

The devices are almost identical and the only difference is one bit in the
factory image PID (thanks to Maximilian Weinmann <x1@disroot.org>
(@MaxS0niX) for the info and idea to make one PR for two devices at once).

Devices specification
---------------------
   SoC:          MediaTek MT7620A, MIPS
   RAM:          64 MB
   Flash:        16 MB SPI NOR
   Wireless 2.4: MT7620 (b/g/n, 2x2)
   Wireless 5:   MT7612EN (a/n/ac, 2x2)
   Ethernet:     5xFE (WAN, LAN1-4)
   BootLoader:   U-Boot
   Buttons:      2 (wps, reset)
   LEDs:         1 amber and 1 green status GPIO leds
                 5 green ethernet GPIO leds
                 1 green GPIO 2.4 GHz WLAN led
                 1 green PHY 5 GHz WLAN led
                 1 green unmanaged power led
   USB ports:    No
   Power:        12 VDC, 1 A
   Connector:    Barrel

OEM easy installation
---------------------
1. Remove all dots from the factory image filename (except the dot
   before file extension)
2. Upload and update the firmware via the original web interface
3. Wait until green status led stops blinking (can take several minutes)
4. Login to OpenWrt initramsfs. It's recommended to make a backup of the
   mtd partitions at this point.
4. Perform sysupgrade using the following command (or use Luci):
   sysupgrade -n sysupgrade.bin
5. Wait until green status les stops blinking (can take several minutes)
6. Mission acomplished

Return to Stock
---------------
Option 1. Restore firmware Slot1 from a backup (firmware2.bin):
   cd /tmp
   mtd -e Firmware2 write firmware2.bin Firmware2
   printf 1 | dd bs=1 seek=$((0x18007)) count=1 of=/dev/mtdblock2
   reboot

Option 2. Decrypt, ungzip and split stock firmware image into the parts,
take Slot1 parts (kernel2.bin, rootfs2.bin) and write them:
   cd /tmp
   mtd -e Kernel2 write kernel2.bin Kernel2
   mtd -e RootFS2 write rootfs2.bin RootFS2
   printf 1 | dd bs=1 seek=$((0x18007)) count=1 of=/dev/mtdblock2
   reboot
More about stock firmware decryption:
Link: https://github.com/Psychotropos/sercomm_fwutils/

Debricking
----------
Use sercomm-recovery tool. You can use "ALL" mtd partition backup as a
recovery image.
Link: https://github.com/danitool/sercomm-recovery

MAC addresses
-------------
+---------+-------------------+-----------+
|         | MAC               | Algorithm |
+---------+-------------------+-----------+
| label   | 48:3e:xx:xx:xx:1e | label     |
| LAN     | 48:3e:xx:xx:xx:1e | label     |
| WAN     | 48:3e:xx:xx:xx:28 | label+10  |
| WLAN 2g | 48:3e:xx:xx:xx:20 | label+2   |
| WLAN 5g | 48:3e:xx:xx:xx:24 | label+6   |
+---------+-------------------+-----------+

Co-authored-by: Vadzim Vabishchevich <bestmc2009@gmail.com>
Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
(cherry picked from commit 1b091311aa)
[fix rt2800_wmac eeprom load]
Signed-off-by: Mikhail Zhilkin <csharper2005@gmail.com>
2023-11-27 02:02:35 +01:00
..
airoha kernel: bump 5.15 to 5.15.125 2023-08-10 21:07:50 +02:00
apm821xx apm821xx: WNDR4700: fix broken sysupgrade, factory images 2023-10-21 16:42:26 +02:00
archs38 treewide: remove files for building 5.10 kernel 2023-05-12 13:02:43 +02:00
armsr armsr: preserve configuration during sysupgrade 2023-10-20 00:41:41 +02:00
at91 treewide: remove files for building 5.10 kernel 2023-05-12 13:02:43 +02:00
ath25 kernel: bump 5.15 to 5.15.131 2023-09-25 23:04:37 +02:00
ath79 kernel: bump 5.15 to 5.15.138 2023-11-19 14:44:36 +01:00
bcm27xx kernel: bump 5.15 to 5.15.138 2023-11-19 14:44:36 +01:00
bcm47xx kernel: bump 5.15 to 5.15.133 2023-10-08 16:52:48 +02:00
bcm53xx bcm53xx: add the latest fix version of brcm_nvram 2023-11-02 09:45:16 +01:00
bcm63xx kernel: bump 5.15 to 5.15.125 2023-08-10 21:07:50 +02:00
bcm4908 kernel: bump 5.15 to 5.15.137 2023-10-29 13:00:28 +01:00
bmips kernel: bump 5.15 to 5.15.125 2023-08-10 21:07:50 +02:00
gemini treewide: remove files for building 5.10 kernel 2023-05-12 13:02:43 +02:00
generic kernel: bump 5.15 to 5.15.139 2023-11-25 20:17:09 +01:00
imx kernel: backport NVMEM patches queued for the v6.5 2023-07-10 12:54:53 +02:00
ipq40xx kernel: backport v6.6 nvmem changes 2023-11-02 09:37:19 +01:00
ipq806x kernel: backport v6.6 nvmem changes 2023-11-02 09:37:19 +01:00
ipq807x kernel: bump 5.15 to 5.15.139 2023-11-25 20:17:09 +01:00
kirkwood kirkwood: add support for Iomega Storcenter ix4-200d 2023-05-20 15:35:37 +02:00
lantiq kernel: bump 5.15 to 5.15.138 2023-11-19 14:44:36 +01:00
layerscape treewide: fix shell errors during dump stage 2023-11-13 14:02:38 +01:00
malta treewide: remove files for building 5.10 kernel 2023-05-12 13:02:43 +02:00
mediatek kernel: bump 5.15 to 5.15.138 2023-11-19 14:44:36 +01:00
mpc85xx kernel: backport v6.6 nvmem changes 2023-11-02 09:37:19 +01:00
mvebu kernel: bump 5.15 to 5.15.139 2023-11-25 20:17:09 +01:00
mxs mxs: rework image generation 2023-07-06 17:04:13 +02:00
octeon kernel: bump 5.15 to 5.15.125 2023-08-10 21:07:50 +02:00
octeontx kernel: bump 5.15 to 5.15.138 2023-11-19 14:44:36 +01:00
omap treewide: remove files for building 5.10 kernel 2023-05-12 13:02:43 +02:00
oxnas kernel: bump 5.15 to 5.15.133 2023-10-08 16:52:48 +02:00
pistachio kernel: fix mtd/NVMEM regression affecting U-Boot env NVMEM driver 2023-11-02 09:45:08 +01:00
qoriq kernel: fix handling of CONFIG_DYNAMIC_DEBUG 2023-05-03 10:26:17 -07:00
ramips ramips: add support for Sercomm CPJ routers 2023-11-27 02:02:35 +01:00
realtek realtek: add support for HPE 1920-8g-poe+ (65W) 2023-10-14 20:15:05 +02:00
rockchip rockchip: fix setup network config for nanopi r2c 2023-06-17 12:21:13 +02:00
sifiveu kernel: bump 5.15 to 5.15.117 2023-06-17 12:09:03 +02:00
sunxi sunxi: fixes led for nanopi boards 2023-10-31 00:44:03 +01:00
tegra treewide: remove files for building 5.10 kernel 2023-05-12 13:02:43 +02:00
uml kernel: bump 5.15 to 5.15.132 2023-09-25 23:04:37 +02:00
x86 kernel: bump 5.15 to 5.15.139 2023-11-25 20:17:09 +01:00
zynq generic: enable CONFIG_ARM_CRYPTO for 32bit arm targets 2023-05-10 19:01:45 +02:00
Makefile build: fix issues with targets installed via feeds 2022-09-27 13:41:12 +02:00