mediatek: add stock layout for CMCC A10
This board is also as known as SuperElectron ZN-M5 and ZN-M8. However, for ZN-M5 and ZN-M8, there's another version uses ZX279128 as CPU chip, which is unsupported. You can check it in "高级设置" > "系统日志" > "内核日志" page from webUI. Stock layout flash instructions: Login into webUI and upload sysupgrade firmware in "系统管理" > "升级固件" page. Remember to unselect "保留配置" ("Keep configurations") first before doing that. OpenWrt U-Boot layout flash instructions: 1. Flash stock layout firmware first. 2. Connect to the device via SSH, and backup everything, especially 'Factory' partition. 3. Unlock MTD partitions: opkg update && opkg install kmod-mtd-rw insmod mtd-rw i_want_a_brick=1 4. Write new BL2 and FIP: mtd write immortalwrt-mediatek-filogic-cmcc_a10-preloader.bin bl2 mtd write immortalwrt-mediatek-filogic-cmcc_a10-bl31-uboot.fip fip 5. Set static IP on your PC: IP 192.168.1.254/24, GW 192.168.1.1 6. Serve ImmortalWrt initramfs image using TFTP server. 7. Cut off the power and re-engage, wait for TFTP recovery to complete. 8. After ImmortalWrt has booted, perform sysupgrade. Signed-off-by: Tianling Shen <cnsztl@immortalwrt.org> (cherry picked from commit 4e9240e7332f8a00713f284b0b0f4901d6b2b16c)
This commit is contained in:
parent
25885c7eff
commit
ecb9798dc1
52
target/linux/mediatek/dts/mt7981b-cmcc-a10-stock.dts
Normal file
52
target/linux/mediatek/dts/mt7981b-cmcc-a10-stock.dts
Normal file
@ -0,0 +1,52 @@
|
||||
// SPDX-License-Identifier: GPL-2.0-or-later OR MIT
|
||||
|
||||
/dts-v1/;
|
||||
#include "mt7981b-cmcc-a10.dts"
|
||||
|
||||
|
||||
/ {
|
||||
model = "CMCC A10 (stock layout)";
|
||||
compatible = "cmcc,a10-stock", "mediatek,mt7981";
|
||||
};
|
||||
|
||||
&partitions {
|
||||
partition@4580000 {
|
||||
label = "firmware_backup";
|
||||
reg = <0x4580000 0x2000000>;
|
||||
read-only;
|
||||
};
|
||||
|
||||
partition@6580000 {
|
||||
label = "zrsave";
|
||||
reg = <0x6580000 0x100000>;
|
||||
read-only;
|
||||
};
|
||||
|
||||
partition@6680000 {
|
||||
label = "config2";
|
||||
reg = <0x6680000 0x100000>;
|
||||
read-only;
|
||||
};
|
||||
};
|
||||
|
||||
&spi0_flash_pins {
|
||||
conf-pu {
|
||||
/delete-property/ mediatek,pull-up-adv;
|
||||
bias-pull-up = <MTK_PUPD_SET_R1R0_11>;
|
||||
};
|
||||
|
||||
conf-pd {
|
||||
/delete-property/ mediatek,pull-up-adv;
|
||||
bias-pull-down = <MTK_PUPD_SET_R1R0_11>;
|
||||
};
|
||||
};
|
||||
|
||||
&spi_nand {
|
||||
mediatek,nmbm;
|
||||
mediatek,bmt-max-ratio = <1>;
|
||||
mediatek,bmt-max-reserved-blocks = <64>;
|
||||
};
|
||||
|
||||
&ubi {
|
||||
reg = <0x580000 0x4000000>;
|
||||
};
|
@ -135,7 +135,7 @@
|
||||
spi-tx-bus-width = <4>;
|
||||
spi-rx-bus-width = <4>;
|
||||
|
||||
partitions {
|
||||
partitions: partitions {
|
||||
compatible = "fixed-partitions";
|
||||
#address-cells = <1>;
|
||||
#size-cells = <1>;
|
||||
|
@ -32,6 +32,7 @@ mediatek_setup_interfaces()
|
||||
cetron,ct3003-stock|\
|
||||
cetron,ct3003-ubootmod|\
|
||||
cmcc,a10|\
|
||||
cmcc,a10-stock|\
|
||||
cmcc,a10-ubootmod|\
|
||||
confiabits,mt7981|\
|
||||
cudy,wr3000-v1|\
|
||||
|
@ -394,6 +394,12 @@ define Device/cmcc_a10
|
||||
DEVICE_MODEL := A10
|
||||
DEVICE_DTS := mt7981b-cmcc-a10
|
||||
DEVICE_VARIANT := (OpenWrt U-Boot layout)
|
||||
DEVICE_ALT0_VENDOR := SuperElectron
|
||||
DEVICE_ALT0_MODEL := ZN-M5
|
||||
DEVICE_ALT0_VARIANT := (OpenWrt U-Boot layout)
|
||||
DEVICE_ALT1_VENDOR := SuperElectron
|
||||
DEVICE_ALT1_MODEL := ZN-M8
|
||||
DEVICE_ALT1_VARIANT := (OpenWrt U-Boot layout)
|
||||
DEVICE_DTS_DIR := ../dts
|
||||
DEVICE_PACKAGES := kmod-mt7981-firmware mt7981-wo-firmware
|
||||
UBINIZE_OPTS := -E 5
|
||||
@ -414,10 +420,45 @@ define Device/cmcc_a10
|
||||
endef
|
||||
TARGET_DEVICES += cmcc_a10
|
||||
|
||||
define Device/cmcc_a10-stock
|
||||
DEVICE_VENDOR := CMCC
|
||||
DEVICE_MODEL := A10
|
||||
DEVICE_VARIANT := (stock layout)
|
||||
DEVICE_ALT0_VENDOR := SuperElectron
|
||||
DEVICE_ALT0_MODEL := ZN-M5
|
||||
DEVICE_ALT0_VARIANT := (stock layout)
|
||||
DEVICE_ALT1_VENDOR := SuperElectron
|
||||
DEVICE_ALT1_MODEL := ZN-M8
|
||||
DEVICE_ALT1_VARIANT := (stock layout)
|
||||
DEVICE_DTS := mt7981b-cmcc-a10-stock
|
||||
DEVICE_DTS_DIR := ../dts
|
||||
SUPPORTED_DEVICES += mediatek,mt7981-spim-snand-rfb
|
||||
DEVICE_PACKAGES := kmod-mt7981-firmware mt7981-wo-firmware
|
||||
UBINIZE_OPTS := -E 5
|
||||
BLOCKSIZE := 128k
|
||||
PAGESIZE := 2048
|
||||
IMAGE_SIZE := 65536k
|
||||
KERNEL_IN_UBI := 1
|
||||
IMAGES += factory.bin
|
||||
IMAGE/factory.bin := append-ubi | check-size $$$$(IMAGE_SIZE)
|
||||
IMAGE/sysupgrade.bin := sysupgrade-tar | append-metadata
|
||||
KERNEL = kernel-bin | lzma | \
|
||||
fit lzma $$(KDIR)/image-$$(firstword $$(DEVICE_DTS)).dtb
|
||||
KERNEL_INITRAMFS = kernel-bin | lzma | \
|
||||
fit lzma $$(KDIR)/image-$$(firstword $$(DEVICE_DTS)).dtb with-initrd
|
||||
endef
|
||||
TARGET_DEVICES += cmcc_a10-stock
|
||||
|
||||
define Device/cmcc_a10-ubootmod
|
||||
DEVICE_VENDOR := CMCC
|
||||
DEVICE_MODEL := A10
|
||||
DEVICE_VARIANT := (custom U-Boot layout)
|
||||
DEVICE_ALT0_VENDOR := SuperElectron
|
||||
DEVICE_ALT0_MODEL := ZN-M5
|
||||
DEVICE_ALT0_VARIANT := (custom U-Boot layout)
|
||||
DEVICE_ALT1_VENDOR := SuperElectron
|
||||
DEVICE_ALT1_MODEL := ZN-M8
|
||||
DEVICE_ALT1_VARIANT := (custom U-Boot layout)
|
||||
DEVICE_DTS := mt7981b-cmcc-a10-ubootmod
|
||||
DEVICE_DTS_DIR := ../dts
|
||||
DEVICE_PACKAGES := kmod-mt7981-firmware mt7981-wo-firmware
|
||||
|
Loading…
x
Reference in New Issue
Block a user