[SOLVED] ZBT-WG1602 Stuck Into boot loop

I have a ZBT-WG1602 router. I have added the device into build-Root using this document https://openwrt.org/docs/guide-developer/adding_new_device my firmware has been compiled successfully. The initramfs-kernel.bin file has been flashed successfully but when I am flashing the sysupgrade.bin file my router getting into the boot loop. Below are the serial logs.

U-Boot 1.1.3 (Apr 11 2015 - 20:07:37)

SoC:MediaTek MT7621
DRAM:  512MB(448MB LowMem,64MB HighMem)
relocate_code Pointer at: 9bfa8000

Config XHCI 40M PLL
******************************
Software System Reset Occurred
******************************
flash manufacture id: ef, device id 40 18
Flash:W25Q128BV Size:16MB
*** Warning - bad CRC, using default environment

 _______________________________________________________________
|    ____                 _                 ____               |
|   |  _ \ __ _ _ __   __| | ___  _ __ __ _| __ )  _____  __   |
|   | |_) / _` | '_ \ / _` |/ _ \| '__/ _` |  _ \ / _ \ \/ /   |
|   |  __/ (_| | | | | (_| | (_) | | | (_| | |_) | (_) >  <    |
|   |_|   \__,_|_| |_|\__,_|\___/|_|  \__,_|____/ \___/_/\_\   |
|                                                              |
|                PandoraBox Ralink/MTK Platform                |
|                 The best solution for you                    |
|          Copyright 2015 D-Team Technology Co.,Ltd. SZ        |
|                    Board:AmazingBox                          |
|                                                              |
|                 lintel<lintel.huang@gmail.com>               |
|______________________________________________________________|

===============Board Info==================
CPU Frequency:880MHz
Detected Memory:448MiB
Bootloader Version:4.3.1.0
--------------------------------------------
ASIC MT7621A DualCore (MAC to MT7530 Mode)
DRAM_CONF_FROM: Auto-Detection
DRAM_TYPE: DDR3
DRAM bus: 16 bit
Xtal Mode=3 OCP Ratio=1/3
Flash component: SPI Flash
Date:Apr 11 2015  Time:20:07:37
============================================
icache: sets:256, ways:4, linesz:32 ,total:32KiB
dcache: sets:256, ways:4, linesz:32 ,total:32KiB
============================================
#Reset_MT7530

GSW VLAN:LLLW
GPIO_MODE init:
        I2C:GPIO
        UART_F:GPIO
        GE2:GPIO
        WDT_RST:GPIO
GPIO_MODE_REGs: 0x4853d
READY_LED_BIT:14.
Please choose the operation:
   1: Load system code to SDRAM via TFTP.
   2: Load system code then write to Flash via TFTP.
   3: Boot system code via Flash (default).
   4: Entr boot command line interface.
   7: Load Boot Loader code then write to Flash via Serial.
   9: Load Boot Loader code then write to Flash via TFTP.                                                                                                   0

3: System Boot system code via Flash.

Press Reset button enter upgrade mode!
## Booting image at bc050000 ...
   Image Name:   MIPS OpenWrt Linux-4.14.241
   Image Type:   MIPS Linux Kernel Image (lzma compressed)
   Data Size:    1927586 Bytes =  1.8 MB
   Load Address: 80001000
   Entry Point:  80001000
   Verifying Checksum ... OK
   Uncompressing Kernel Image ... OK
No initrd
## Transferring control to Linux (at address 80001000) ...
## Giving linux memsize in MB, 512

Starting kernel ...

[    0.000000] Linux version 4.14.241 (root@firmware-dev) (gcc version 7.5.0 (OpenWrt GCC 7.5.0 r11364-ef56c85848)) #0 SMP Thu Jul 29 19:50:28 2021
[    0.000000] SoC Type: MediaTek MT7621 ver:1 eco:3
[    0.000000] bootconsole [early0] enabled
[    0.000000] CPU0 revision is: 0001992f (MIPS 1004Kc)
[    0.000000] MIPS: machine is ZBT-WG1602
[    0.000000] Determined physical RAM map:
[    0.000000]  memory: 10000000 @ 00000000 (usable)
[    0.000000] Initrd not found or empty - disabling initrd
[    0.000000] VPE topology {2,2} total 4
[    0.000000] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.000000] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.000000] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.000000] Zone ranges:
[    0.000000]   Normal   [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000]   HighMem  empty
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000] random: get_random_bytes called from start_kernel+0x94/0x4ac with crng_init=0
[    0.000000] percpu: Embedded 14 pages/cpu s26192 r8192 d22960 u57344
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 65024
[    0.000000] Kernel command line: console=ttyS0,115200 rootfstype=squashfs,jffs2
[    0.000000] PID hash table entries: 1024 (order: 0, 4096 bytes)
[    0.000000] Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
[    0.000000] Writing ErrCtl register=00002001
[    0.000000] Readback ErrCtl register=00002001
[    0.000000] Memory: 252212K/262144K available (4556K kernel code, 231K rwdata, 1012K rodata, 1292K init, 248K bss, 9932K reserved, 0K cma-reserved, 0K highmem)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000] NR_IRQS: 256
[    0.000000] CPU Clock: 880MHz
[    0.000000] clocksource: GIC: mask: 0xffffffffffffffff max_cycles: 0xcaf478abb4, max_idle_ns: 440795247997 ns
[    0.000000] clocksource: MIPS: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 4343773742 ns
[    0.000010] sched_clock: 32 bits at 440MHz, resolution 2ns, wraps every 4880645118ns
[    0.007825] Calibrating delay loop... 586.13 BogoMIPS (lpj=2930688)
[    0.073990] pid_max: default: 32768 minimum: 301
[    0.078765] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.085274] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.094142] Hierarchical SRCU implementation.
[    0.099310] smp: Bringing up secondary CPUs ...
[    0.105375] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.105384] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.105397] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.105533] CPU1 revision is: 0001992f (MIPS 1004Kc)
[    0.164049] Synchronize counters for CPU 1: done.
[    0.205241] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.205248] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.205256] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.205328] CPU2 revision is: 0001992f (MIPS 1004Kc)
[    0.255114] Synchronize counters for CPU 2: done.
[    0.286409] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.286418] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.286425] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.286503] CPU3 revision is: 0001992f (MIPS 1004Kc)
[    0.340301] Synchronize counters for CPU 3: done.
[    0.370155] smp: Brought up 1 node, 4 CPUs
[    0.377884] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.387679] futex hash table entries: 1024 (order: 3, 32768 bytes)
[    0.393977] pinctrl core: initialized pinctrl subsystem
[    0.400671] NET: Registered protocol family 16
[    0.416524] pull PCIe RST: RALINK_RSTCTRL = 0
[    0.721242] release PCIe RST: RALINK_RSTCTRL = 7000000
[    0.726276] ***** Xtal 40MHz *****
[    0.729647] release PCIe RST: RALINK_RSTCTRL = 7000000
[    0.734755] Port 0 N_FTS = 1b105000
[    0.738198] Port 1 N_FTS = 1b105000
[    0.741658] Port 2 N_FTS = 1b102800
[    1.896904] PCIE2 no card, disable it(RST&CLK)
[    1.901250]  -> 21007f2
[    1.903669] PCIE0 enabled
[    1.906276] PCIE1 enabled
[    1.908863] PCI host bridge /pcie@1e140000 ranges:
[    1.913626]  MEM 0x0000000060000000..0x000000006fffffff
[    1.918808]   IO 0x000000001e160000..0x000000001e16ffff
[    1.923981] PCI coherence region base: 0xbfbf8000, mask/settings: 0x60000000
[    1.940363] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.946198] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.951919] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.959302] PCI host bridge to bus 0000:00
[    1.963340] pci_bus 0000:00: root bus resource [mem 0x60000000-0x6fffffff]
[    1.970195] pci_bus 0000:00: root bus resource [io  0x1e160000-0x1e16ffff]
[    1.976973] pci_bus 0000:00: root bus resource [??? 0x00000000 flags 0x0]
[    1.983729] pci_bus 0000:00: No busn resource found for root bus, will use [bus 00-ff]
[    1.993813] pci 0000:00:00.0: BAR 0: no space for [mem size 0x80000000]
[    2.000326] pci 0000:00:00.0: BAR 0: failed to assign [mem size 0x80000000]
[    2.007274] pci 0000:00:01.0: BAR 0: no space for [mem size 0x80000000]
[    2.013806] pci 0000:00:01.0: BAR 0: failed to assign [mem size 0x80000000]
[    2.020739] pci 0000:00:00.0: BAR 8: assigned [mem 0x60000000-0x600fffff]
[    2.027463] pci 0000:00:01.0: BAR 8: assigned [mem 0x60100000-0x601fffff]
[    2.034217] pci 0000:00:01.0: BAR 9: assigned [mem 0x60200000-0x602fffff pref]
[    2.041366] pci 0000:00:00.0: BAR 1: assigned [mem 0x60300000-0x6030ffff]
[    2.048131] pci 0000:00:01.0: BAR 1: assigned [mem 0x60310000-0x6031ffff]
[    2.054861] pci 0000:01:00.0: BAR 0: assigned [mem 0x60000000-0x600fffff]
[    2.061614] pci 0000:00:00.0: PCI bridge to [bus 01]
[    2.066514] pci 0000:00:00.0:   bridge window [mem 0x60000000-0x600fffff]
[    2.073273] pci 0000:02:00.0: BAR 0: assigned [mem 0x60100000-0x601fffff 64bit]
[    2.080515] pci 0000:02:00.0: BAR 6: assigned [mem 0x60200000-0x6020ffff pref]
[    2.087699] pci 0000:00:01.0: PCI bridge to [bus 02]
[    2.092607] pci 0000:00:01.0:   bridge window [mem 0x60100000-0x601fffff]
[    2.099363] pci 0000:00:01.0:   bridge window [mem 0x60200000-0x602fffff pref]
[    2.107898] clocksource: Switched to clocksource GIC
[    2.114503] NET: Registered protocol family 2
[    2.118964] IP idents hash table entries: 4096 (order: 3, 32768 bytes)
[    2.126000] TCP established hash table entries: 2048 (order: 1, 8192 bytes)
[    2.132950] TCP bind hash table entries: 2048 (order: 2, 16384 bytes)
[    2.139345] TCP: Hash tables configured (established 2048 bind 2048)
[    2.145750] UDP hash table entries: 256 (order: 1, 8192 bytes)
[    2.151555] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[    2.158054] NET: Registered protocol family 1
[    2.397857] 4 CPUs re-calibrate udelay(lpj = 2924544)
[    2.404440] Crashlog allocated RAM at address 0x3f00000
[    2.410048] workingset: timestamp_bits=30 max_order=16 bucket_order=0
[    2.418873] random: fast init done
[    2.427028] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    2.432840] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.
[    2.446246] io scheduler noop registered
[    2.450153] io scheduler deadline registered (default)
[    2.456030] gpio-export gpio_export: 3 gpio(s) exported
[    2.462137] Serial: 8250/16550 driver, 3 ports, IRQ sharing disabled
[    2.469884] console [ttyS0] disabled
[    2.497c8CDCHLcRr3k3Qo6b1hNHB8ySdfnSwMBKfnhcNviT6GUftPy4uoNhDfPmkqAV4E2eGXa5eRNLoZnc4xkxbmij7PfENwd
[    2.482448] console [ttyS0] enabled
[    2.482448] console [ttyS0] enabled
[    2.489332] bootconsole [early0] disabled
[    2.489332] bootconsole [early0] disabled
[    2.499493] MediaTek Nand driver init, version v2.1 Fix AHB virt2phys error
[    2.506823] spi-mt7621 1e000b00.spi: sys_freq: 220000000
[    2.521884] m25p80 spi0.0: w25q128 (16384 Kbytes)
[    2.526633] 4 fixed-partitions partitions found on MTD device spi0.0
[    2.532976] Creating 4 MTD partitions on "spi0.0":
[    2.537755] 0x000000000000-0x000000030000 : "u-boot"
[    2.543734] 0x000000030000-0x000000040000 : "u-boot-env"
[    2.549999] 0x000000040000-0x000000050000 : "factory"
[    2.555926] 0x000000050000-0x000002000000 : "firmware"
[    2.561101] mtd: partition "firmware" extends beyond the end of device "spi0.0" -- size truncated to 0xfb0000
[    2.572657] libphy: Fixed MDIO Bus: probed
[    2.639925] libphy: mdio: probed
[    4.042907] mtk_soc_eth 1e100000.ethernet: loaded mt7530 driver
[    4.049635] mtk_soc_eth 1e100000.ethernet eth0: mediatek frame engine at 0xbe100000, irq 22
[    4.060819] NET: Registered protocol family 10
[    4.066880] Segment Routing with IPv6
[    4.070664] NET: Registered protocol family 17
[    4.075146] 8021q: 802.1Q VLAN Support v1.8
[    4.081847] hctosys: unable to open rtc device (rtc0)
[    4.087737] VFS: Cannot open root device "(null)" or unknown-block(0,0): error -6
[    4.095268] Please append a correct "root=" boot option; here are the available partitions:
[    4.103626] 1f00             192 mtdblock0
[    4.103633]  (driver?)
[    4.110161] 1f01              64 mtdblock1
[    4.110166]  (driver?)
[    4.116667] 1f02              64 mtdblock2
[    4.116671]  (driver?)
[    4.123193] 1f03           16064 mtdblock3
[    4.123198]  (driver?)
[    4.129716] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
[    4.139606] Rebooting in 1 seconds..

Below is the device definition.

define Device/zbt-wg1602
  DTS := ZBT-WG1602
  IMAGE_SIZE := $(ralink_default_fw_size_16M)
  DEVICE_TITLE := ZBT WG1602
  DEVICE_PACKAGES := kmod-usb2
endef
TARGET_DEVICES += zbt-wg1602

Help @musashino @juppin @hnyman
please help me. Thank You

Sounds like your file system / rootfs definitions are wrong. You may need to specify somthing more in DTS or in the bootcmd. (I have no knowledge about ramips or Pandorabox, so this is pure guess at the first glance)

As hnyman says, partition definitions are wrong.
Your device has a Winbond W25Q128 (or similar) flash chip and the capacity of it is 16 MiB. But in your definitions, the end of firmware partition is at the end of 32 MiB capacity. The above warning is due to it.

BTW:
If you want to merge it into the official repository, your code must be based on current master of official repository. Looking at the kernel version in the log and your image definition, it feels like it's based on 19.07 release.

Yes, It is based on 19.07 version. I will fix the dts file and then try to flash the firmware.

Hi, I have fixed the DTS file. Below is the DTS file.

/dts-v1/;
#include "mt7621.dtsi"

#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>

/ {
	model = "ZBT-WG1602";
	
	chosen {
		bootargs = "console=ttyS0,115200";
	};

	gpio-leds {
		compatible = "gpio-leds";

		4g2 {
			label = "4g2";
			gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
		};
		4g {
			label = "4g";
			gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
		};
		card {
			label = "card";
			gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
		};
	};
	
	gpio_export {
		compatible = "gpio-export";
		#size-cells = <0>;

		4g2 {
			gpio-export,name = "4g2";
			gpio-export,output = <0>;
			gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
		};
		4g {
			gpio-export,name = "4g";
			gpio-export,output = <0>;
			gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
		};
		usb_sw {
			gpio-export,name = "usb_sw";
			gpio-export,output = <1>;
			gpios = <&gpio0 6 GPIO_ACTIVE_HIGH>;
		};
	};


	gpio-keys-polled {
		compatible = "gpio-keys-polled";
		#address-cells = <1>;
		#size-cells = <0>;
		poll-interval = <20>;

		reset {
			label = "reset";
			gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
			linux,code = <KEY_RESTART>;
		};
	};
};

&sdhci {
	status = "okay";
};

&spi0 {
	status = "okay";

	m25p80@0 {
		#address-cells = <1>;
		#size-cells = <1>;
		compatible = "jedec,spi-nor";
		reg = <0>;
		spi-max-frequency = <10000000>;
		m25p,chunked-io = <32>;

		partition@0 {
			label = "u-boot";
			reg = <0x0 0x30000>;
			read-only;
		};

		partition@30000 {
			label = "u-boot-env";
			reg = <0x30000 0x10000>;
			read-only;
		};

		factory: partition@40000 {
			label = "factory";
			reg = <0x40000 0x10000>;
		};

		firmware: partition@50000 {
			label = "firmware";
			reg = <0x50000 0xfb0000>;
		};
	};
};

&pcie {
	status = "okay";
};

&ethernet {
	mtd-mac-address = <&factory 0xe000>;
};

&pinctrl {
	state_default: pinctrl0 {
		gpio {
			ralink,group = "wdt", "i2c", "uart2", "uart3", "rgmii2";
			ralink,function = "gpio";
		};
	};
};

But still, the router is getting into the boot loop. Below are the serial logs.

===============Board Info==================
CPU Frequency:880MHz
Detected Memory:448MiB
Bootloader Version:4.3.1.0
--------------------------------------------
ASIC MT7621A DualCore (MAC to MT7530 Mode)
DRAM_CONF_FROM: Auto-Detection
DRAM_TYPE: DDR3
DRAM bus: 16 bit
Xtal Mode=3 OCP Ratio=1/3
Flash component: SPI Flash
Date:Apr 11 2015  Time:20:07:37
============================================
icache: sets:256, ways:4, linesz:32 ,total:32KiB
dcache: sets:256, ways:4, linesz:32 ,total:32KiB
============================================
#Reset_MT7530

GSW VLAN:LLLW
GPIO_MODE init:
        I2C:GPIO
        UART_F:GPIO
        GE2:GPIO
        WDT_RST:GPIO
GPIO_MODE_REGs: 0x4853d
READY_LED_BIT:14.
Please choose the operation:
   1: Load system code to SDRAM via TFTP.
   2: Load system code then write to Flash via TFTP.
   3: Boot system code via Flash (default).
   4: Entr boot command line interface.
   7: Load Boot Loader code then write to Flash via Serial.
   9: Load Boot Loader code then write to Flash via TFTP.                                                                                                   0

3: System Boot system code via Flash.

Press Reset button enter upgrade mode!
## Booting image at bc050000 ...
   Image Name:   MIPS OpenWrt Linux-4.14.241
   Image Type:   MIPS Linux Kernel Image (lzma compressed)
   Data Size:    1927585 Bytes =  1.8 MB
   Load Address: 80001000
   Entry Point:  80001000
   Verifying Checksum ... OK
   Uncompressing Kernel Image ... OK
No initrd
## Transferring control to Linux (at address 80001000) ...
## Giving linux memsize in MB, 512

Starting kernel ...

[    0.000000] Linux version 4.14.241 (root@firmware-dev) (gcc version 7.5.0 (OpenWrt GCC 7.5.0 r11364-ef56c85848)) #0 SMP Thu Jul 29 19:50:28 2021
[    0.000000] SoC Type: MediaTek MT7621 ver:1 eco:3
[    0.000000] bootconsole [early0] enabled
[    0.000000] CPU0 revision is: 0001992f (MIPS 1004Kc)
[    0.000000] MIPS: machine is ZBT-WG1602
[    0.000000] Determined physical RAM map:
[    0.000000]  memory: 10000000 @ 00000000 (usable)
[    0.000000] Initrd not found or empty - disabling initrd
[    0.000000] VPE topology {2,2} total 4
[    0.000000] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.000000] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.000000] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.000000] Zone ranges:
[    0.000000]   Normal   [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000]   HighMem  empty
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000] random: get_random_bytes called from start_kernel+0x94/0x4ac with crng_init=0
[    0.000000] percpu: Embedded 14 pages/cpu s26192 r8192 d22960 u57344
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 65024
[    0.000000] Kernel command line: console=ttyS0,115200 rootfstype=squashfs,jffs2
[    0.000000] PID hash table entries: 1024 (order: 0, 4096 bytes)
[    0.000000] Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
[    0.000000] Writing ErrCtl register=00000000
[    0.000000] Readback ErrCtl register=00000000
[    0.000000] Memory: 252212K/262144K available (4556K kernel code, 231K rwdata, 1012K rodata, 1292K init, 248K bss, 9932K reserved, 0K cma-reserved, 0K highmem)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000] NR_IRQS: 256
[    0.000000] CPU Clock: 880MHz
[    0.000000] clocksource: GIC: mask: 0xffffffffffffffff max_cycles: 0xcaf478abb4, max_idle_ns: 440795247997 ns
[    0.000000] clocksource: MIPS: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 4343773742 ns
[    0.000009] sched_clock: 32 bits at 440MHz, resolution 2ns, wraps every 4880645118ns
[    0.007824] Calibrating delay loop... 586.13 BogoMIPS (lpj=2930688)
[    0.073991] pid_max: default: 32768 minimum: 301
[    0.078767] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.085277] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.094147] Hierarchical SRCU implementation.
[    0.099318] smp: Bringing up secondary CPUs ...
[    0.105387] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.105396] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.105409] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.105547] CPU1 revision is: 0001992f (MIPS 1004Kc)
[    0.164058] Synchronize counters for CPU 1: done.
[    0.205247] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.205255] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.205262] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.205334] CPU2 revision is: 0001992f (MIPS 1004Kc)
[    0.255119] Synchronize counters for CPU 2: done.
[    0.286414] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.286422] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.286430] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.286508] CPU3 revision is: 0001992f (MIPS 1004Kc)
[    0.340308] Synchronize counters for CPU 3: done.
[    0.370161] smp: Brought up 1 node, 4 CPUs
[    0.377890] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.387685] futex hash table entries: 1024 (order: 3, 32768 bytes)
[    0.393985] pinctrl core: initialized pinctrl subsystem
[    0.400574] NET: Registered protocol family 16
[    0.415413] pull PCIe RST: RALINK_RSTCTRL = 0
[    0.720125] release PCIe RST: RALINK_RSTCTRL = 7000000
[    0.725174] ***** Xtal 40MHz *****
[    0.728530] release PCIe RST: RALINK_RSTCTRL = 7000000
[    0.733627] Port 0 N_FTS = 1b105000
[    0.737094] Port 1 N_FTS = 1b105000
[    0.740541] Port 2 N_FTS = 1b102800
[    1.895774] PCIE2 no card, disable it(RST&CLK)
[    1.900137]  -> 21007f2
[    1.902542] PCIE0 enabled
[    1.905131] PCIE1 enabled
[    1.907736] PCI host bridge /pcie@1e140000 ranges:
[    1.912511]  MEM 0x0000000060000000..0x000000006fffffff
[    1.917663]   IO 0x000000001e160000..0x000000001e16ffff
[    1.922869] PCI coherence region base: 0xbfbf8000, mask/settings: 0x60000000
[    1.939244] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.945115] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.950833] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.958048] PCI host bridge to bus 0000:00
[    1.962089] pci_bus 0000:00: root bus resource [mem 0x60000000-0x6fffffff]
[    1.968951] pci_bus 0000:00: root bus resource [io  0x1e160000-0x1e16ffff]
[    1.975725] pci_bus 0000:00: root bus resource [??? 0x00000000 flags 0x0]
[    1.982483] pci_bus 0000:00: No busn resource found for root bus, will use [bus 00-ff]
[    1.992587] pci 0000:00:00.0: BAR 0: no space for [mem size 0x80000000]
[    1.999104] pci 0000:00:00.0: BAR 0: failed to assign [mem size 0x80000000]
[    2.006044] pci 0000:00:01.0: BAR 0: no space for [mem size 0x80000000]
[    2.012578] pci 0000:00:01.0: BAR 0: failed to assign [mem size 0x80000000]
[    2.019514] pci 0000:00:00.0: BAR 8: assigned [mem 0x60000000-0x600fffff]
[    2.026238] pci 0000:00:01.0: BAR 8: assigned [mem 0x60100000-0x601fffff]
[    2.032996] pci 0000:00:01.0: BAR 9: assigned [mem 0x60200000-0x602fffff pref]
[    2.040146] pci 0000:00:00.0: BAR 1: assigned [mem 0x60300000-0x6030ffff]
[    2.046905] pci 0000:00:01.0: BAR 1: assigned [mem 0x60310000-0x6031ffff]
[    2.053629] pci 0000:01:00.0: BAR 0: assigned [mem 0x60000000-0x600fffff]
[    2.060386] pci 0000:00:00.0: PCI bridge to [bus 01]
[    2.065291] pci 0000:00:00.0:   bridge window [mem 0x60000000-0x600fffff]
[    2.072058] pci 0000:02:00.0: BAR 0: assigned [mem 0x60100000-0x601fffff 64bit]
[    2.079295] pci 0000:02:00.0: BAR 6: assigned [mem 0x60200000-0x6020ffff pref]
[    2.086470] pci 0000:00:01.0: PCI bridge to [bus 02]
[    2.091377] pci 0000:00:01.0:   bridge window [mem 0x60100000-0x601fffff]
[    2.098135] pci 0000:00:01.0:   bridge window [mem 0x60200000-0x602fffff pref]
[    2.106690] clocksource: Switched to clocksource GIC
[    2.113357] NET: Registered protocol family 2
[    2.117821] IP idents hash table entries: 4096 (order: 3, 32768 bytes)
[    2.124861] TCP established hash table entries: 2048 (order: 1, 8192 bytes)
[    2.131803] TCP bind hash table entries: 2048 (order: 2, 16384 bytes)
[    2.138196] TCP: Hash tables configured (established 2048 bind 2048)
[    2.144603] UDP hash table entries: 256 (order: 1, 8192 bytes)
[    2.150406] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[    2.156907] NET: Registered protocol family 1
[    2.396633] 4 CPUs re-calibrate udelay(lpj = 2924544)
[    2.402907] Crashlog allocated RAM at address 0x3f00000
[    2.409001] workingset: timestamp_bits=30 max_order=16 bucket_order=0
[    2.421917] random: fast init done
[    2.423157] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    2.431071] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.
[    2.444398] io scheduler noop registered
[    2.448272] io scheduler deadline registered (default)
[    2.454128] gpio-export gpio_export: 3 gpio(s) exported
[    2.460260] Serial: 8250/16550 driver, 3 ports, IRQ sharing disabled
[    2.468014] console [ttyS0] disabled
[    2.497c8CDCHLcRr3k3Qo6b1hNHB8ySdfnSwMBKfnhcNviT6GUftPy4uoNhDfPmkqAV4E2eGXa5eRNLoZnc4xkxbmij7PfENwd
[    2.480556] console [ttyS0] enabled
[    2.480556] console [ttyS0] enabled
[    2.487426] bootconsole [early0] disabled
[    2.487426] bootconsole [early0] disabled
[    2.497577] MediaTek Nand driver init, version v2.1 Fix AHB virt2phys error
[    2.504896] spi-mt7621 1e000b00.spi: sys_freq: 220000000
[    2.519997] m25p80 spi0.0: w25q128 (16384 Kbytes)
[    2.524750] 4 fixed-partitions partitions found on MTD device spi0.0
[    2.531091] Creating 4 MTD partitions on "spi0.0":
[    2.535871] 0x000000000000-0x000000030000 : "u-boot"
[    2.541840] 0x000000030000-0x000000040000 : "u-boot-env"
[    2.548147] 0x000000040000-0x000000050000 : "factory"
[    2.554065] 0x000000050000-0x000001000000 : "firmware"
[    2.560791] libphy: Fixed MDIO Bus: probed
[    2.628702] libphy: mdio: probed
[    4.031616] mtk_soc_eth 1e100000.ethernet: loaded mt7530 driver
[    4.038345] mtk_soc_eth 1e100000.ethernet eth0: mediatek frame engine at 0xbe100000, irq 22
[    4.049517] NET: Registered protocol family 10
[    4.055548] Segment Routing with IPv6
[    4.059351] NET: Registered protocol family 17
[    4.063849] 8021q: 802.1Q VLAN Support v1.8
[    4.070693] hctosys: unable to open rtc device (rtc0)
[    4.076593] VFS: Cannot open root device "(null)" or unknown-block(0,0): error -6
[    4.084102] Please append a correct "root=" boot option; here are the available partitions:
[    4.092444] 1f00             192 mtdblock0
[    4.092450]  (driver?)
[    4.098971] 1f01              64 mtdblock1
[    4.098975]  (driver?)
[    4.105476] 1f02              64 mtdblock2
[    4.105480]  (driver?)
[    4.111999] 1f03           16064 mtdblock3
[    4.112003]  (driver?)
[    4.118517] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
[    4.128396] Rebooting in 1 seconds..

Please help.

You need to add compatible = "denx,uimage"; to firmware partition node.

Thanks but still the same issue is coming. Below are the serial logs and DTS file.

===============Board Info==================
CPU Frequency:880MHz
Detected Memory:448MiB
Bootloader Version:4.3.1.0
--------------------------------------------
ASIC MT7621A DualCore (MAC to MT7530 Mode)
DRAM_CONF_FROM: Auto-Detection
DRAM_TYPE: DDR3
DRAM bus: 16 bit
Xtal Mode=3 OCP Ratio=1/3
Flash component: SPI Flash
Date:Apr 11 2015  Time:20:07:37
============================================
icache: sets:256, ways:4, linesz:32 ,total:32KiB
dcache: sets:256, ways:4, linesz:32 ,total:32KiB
============================================
#Reset_MT7530

GSW VLAN:LLLW
GPIO_MODE init:
        I2C:GPIO
        UART_F:GPIO
        GE2:GPIO
        WDT_RST:GPIO
GPIO_MODE_REGs: 0x4853d
READY_LED_BIT:14.
Please choose the operation:
   1: Load system code to SDRAM via TFTP.
   2: Load system code then write to Flash via TFTP.
   3: Boot system code via Flash (default).
   4: Entr boot command line interface.
   7: Load Boot Loader code then write to Flash via Serial.
   9: Load Boot Loader code then write to Flash via TFTP.                                                                                                   0

3: System Boot system code via Flash.

Press Reset button enter upgrade mode!
## Booting image at bc050000 ...
   Image Name:   MIPS OpenWrt Linux-4.14.241
   Image Type:   MIPS Linux Kernel Image (lzma compressed)
   Data Size:    1927592 Bytes =  1.8 MB
   Load Address: 80001000
   Entry Point:  80001000
   Verifying Checksum ... OK
   Uncompressing Kernel Image ... OK
No initrd
## Transferring control to Linux (at address 80001000) ...
## Giving linux memsize in MB, 512

Starting kernel ...

[    0.000000] Linux version 4.14.241 (root@firmware-dev) (gcc version 7.5.0 (OpenWrt GCC 7.5.0 r11364-ef56c85848)) #0 SMP Thu Jul 29 19:50:28 2021
[    0.000000] SoC Type: MediaTek MT7621 ver:1 eco:3
[    0.000000] bootconsole [early0] enabled
[    0.000000] CPU0 revision is: 0001992f (MIPS 1004Kc)
[    0.000000] MIPS: machine is ZBT-WG1602
[    0.000000] Determined physical RAM map:
[    0.000000]  memory: 10000000 @ 00000000 (usable)
[    0.000000] Initrd not found or empty - disabling initrd
[    0.000000] VPE topology {2,2} total 4
[    0.000000] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.000000] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.000000] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.000000] Zone ranges:
[    0.000000]   Normal   [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000]   HighMem  empty
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000] random: get_random_bytes called from start_kernel+0x94/0x4ac with crng_init=0
[    0.000000] percpu: Embedded 14 pages/cpu s26192 r8192 d22960 u57344
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 65024
[    0.000000] Kernel command line: console=ttyS0,115200 rootfstype=squashfs,jffs2
[    0.000000] PID hash table entries: 1024 (order: 0, 4096 bytes)
[    0.000000] Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
[    0.000000] Writing ErrCtl register=00000021
[    0.000000] Readback ErrCtl register=00000021
[    0.000000] Memory: 252212K/262144K available (4556K kernel code, 231K rwdata, 1012K rodata, 1292K init, 248K bss, 9932K reserved, 0K cma-reserved, 0K highmem)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000] NR_IRQS: 256
[    0.000000] CPU Clock: 880MHz
[    0.000000] clocksource: GIC: mask: 0xffffffffffffffff max_cycles: 0xcaf478abb4, max_idle_ns: 440795247997 ns
[    0.000000] clocksource: MIPS: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 4343773742 ns
[    0.000010] sched_clock: 32 bits at 440MHz, resolution 2ns, wraps every 4880645118ns
[    0.007825] Calibrating delay loop... 586.13 BogoMIPS (lpj=2930688)
[    0.073990] pid_max: default: 32768 minimum: 301
[    0.078765] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.085274] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.094147] Hierarchical SRCU implementation.
[    0.099318] smp: Bringing up secondary CPUs ...
[    0.105383] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.105392] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.105405] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.105543] CPU1 revision is: 0001992f (MIPS 1004Kc)
[    0.164056] Synchronize counters for CPU 1: done.
[    0.205249] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.205256] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.205264] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.205335] CPU2 revision is: 0001992f (MIPS 1004Kc)
[    0.255122] Synchronize counters for CPU 2: done.
[    0.286417] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.286425] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[    0.286433] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.286511] CPU3 revision is: 0001992f (MIPS 1004Kc)
[    0.340308] Synchronize counters for CPU 3: done.
[    0.370162] smp: Brought up 1 node, 4 CPUs
[    0.377895] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[    0.387689] futex hash table entries: 1024 (order: 3, 32768 bytes)
[    0.393990] pinctrl core: initialized pinctrl subsystem
[    0.400695] NET: Registered protocol family 16
[    0.416386] pull PCIe RST: RALINK_RSTCTRL = 0
[    0.721103] release PCIe RST: RALINK_RSTCTRL = 7000000
[    0.726136] ***** Xtal 40MHz *****
[    0.729508] release PCIe RST: RALINK_RSTCTRL = 7000000
[    0.734616] Port 0 N_FTS = 1b105000
[    0.738059] Port 1 N_FTS = 1b105000
[    0.741518] Port 2 N_FTS = 1b102800
[    1.896772] PCIE2 no card, disable it(RST&CLK)
[    1.901118]  -> 21007f2
[    1.903538] PCIE0 enabled
[    1.906144] PCIE1 enabled
[    1.908731] PCI host bridge /pcie@1e140000 ranges:
[    1.913494]  MEM 0x0000000060000000..0x000000006fffffff
[    1.918676]   IO 0x000000001e160000..0x000000001e16ffff
[    1.923849] PCI coherence region base: 0xbfbf8000, mask/settings: 0x60000000
[    1.939766] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.945652] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.951417] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.958743] PCI host bridge to bus 0000:00
[    1.962784] pci_bus 0000:00: root bus resource [mem 0x60000000-0x6fffffff]
[    1.969614] pci_bus 0000:00: root bus resource [io  0x1e160000-0x1e16ffff]
[    1.976417] pci_bus 0000:00: root bus resource [??? 0x00000000 flags 0x0]
[    1.983179] pci_bus 0000:00: No busn resource found for root bus, will use [bus 00-ff]
[    1.993052] pci 0000:00:00.0: BAR 0: no space for [mem size 0x80000000]
[    1.999592] pci 0000:00:00.0: BAR 0: failed to assign [mem size 0x80000000]
[    2.006485] pci 0000:00:01.0: BAR 0: no space for [mem size 0x80000000]
[    2.013061] pci 0000:00:01.0: BAR 0: failed to assign [mem size 0x80000000]
[    2.019956] pci 0000:00:00.0: BAR 8: assigned [mem 0x60000000-0x600fffff]
[    2.026716] pci 0000:00:01.0: BAR 8: assigned [mem 0x60100000-0x601fffff]
[    2.033442] pci 0000:00:01.0: BAR 9: assigned [mem 0x60200000-0x602fffff pref]
[    2.040622] pci 0000:00:00.0: BAR 1: assigned [mem 0x60300000-0x6030ffff]
[    2.047357] pci 0000:00:01.0: BAR 1: assigned [mem 0x60310000-0x6031ffff]
[    2.054109] pci 0000:01:00.0: BAR 0: assigned [mem 0x60000000-0x600fffff]
[    2.060825] pci 0000:00:00.0: PCI bridge to [bus 01]
[    2.065769] pci 0000:00:00.0:   bridge window [mem 0x60000000-0x600fffff]
[    2.072495] pci 0000:02:00.0: BAR 0: assigned [mem 0x60100000-0x601fffff 64bit]
[    2.079776] pci 0000:02:00.0: BAR 6: assigned [mem 0x60200000-0x6020ffff pref]
[    2.086920] pci 0000:00:01.0: PCI bridge to [bus 02]
[    2.091858] pci 0000:00:01.0:   bridge window [mem 0x60100000-0x601fffff]
[    2.098582] pci 0000:00:01.0:   bridge window [mem 0x60200000-0x602fffff pref]
[    2.107201] clocksource: Switched to clocksource GIC
[    2.113710] NET: Registered protocol family 2
[    2.118235] IP idents hash table entries: 4096 (order: 3, 32768 bytes)
[    2.125266] TCP established hash table entries: 2048 (order: 1, 8192 bytes)
[    2.132204] TCP bind hash table entries: 2048 (order: 2, 16384 bytes)
[    2.138596] TCP: Hash tables configured (established 2048 bind 2048)
[    2.145000] UDP hash table entries: 256 (order: 1, 8192 bytes)
[    2.150786] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[    2.157277] NET: Registered protocol family 1
[    2.397150] 4 CPUs re-calibrate udelay(lpj = 2924544)
[    2.403597] Crashlog allocated RAM at address 0x3f00000
[    2.409223] workingset: timestamp_bits=30 max_order=16 bucket_order=0
[    2.422939] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    2.428746] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.
[    2.441275] random: fast init done
[    2.445374] io scheduler noop registered
[    2.449271] io scheduler deadline registered (default)
[    2.455104] gpio-export gpio_export: 3 gpio(s) exported
[    2.461270] Serial: 8250/16550 driver, 3 ports, IRQ sharing disabled
[    2.469016] console [ttyS0] disabled
[    2.497c8CDCHLcRr3k3Qo6b1hNHB8ySdfnSwMBKfnhcNviT6GUftPy4uoNhDfPmkqAV4E2eGXa5eRNLoZnc4xkxbmij7PfENwd
[    2.481584] console [ttyS0] enabled
[    2.481584] console [ttyS0] enabled
[    2.488461] bootconsole [early0] disabled
[    2.488461] bootconsole [early0] disabled
[    2.498636] MediaTek Nand driver init, version v2.1 Fix AHB virt2phys error
[    2.505950] spi-mt7621 1e000b00.spi: sys_freq: 220000000
[    2.521066] m25p80 spi0.0: w25q128 (16384 Kbytes)
[    2.525814] 3 fixed-partitions partitions found on MTD device spi0.0
[    2.532169] Creating 3 MTD partitions on "spi0.0":
[    2.536950] 0x000000000000-0x000000030000 : "u-boot"
[    2.542953] 0x000000030000-0x000000040000 : "u-boot-env"
[    2.549262] 0x000000040000-0x000000050000 : "factory"
[    2.555910] libphy: Fixed MDIO Bus: probed
[    2.629210] libphy: mdio: probed
[    4.032078] mtk_soc_eth 1e100000.ethernet: loaded mt7530 driver
[    4.038803] mtk_soc_eth 1e100000.ethernet eth0: mediatek frame engine at 0xbe100000, irq 22
[    4.049947] NET: Registered protocol family 10
[    4.055972] Segment Routing with IPv6
[    4.059785] NET: Registered protocol family 17
[    4.064270] 8021q: 802.1Q VLAN Support v1.8
[    4.070890] hctosys: unable to open rtc device (rtc0)
[    4.076740] VFS: Cannot open root device "(null)" or unknown-block(0,0): error -6
[    4.084262] Please append a correct "root=" boot option; here are the available partitions:
[    4.092618] 1f00             192 mtdblock0
[    4.092624]  (driver?)
[    4.099151] 1f01              64 mtdblock1
[    4.099157]  (driver?)
[    4.105658] 1f02              64 mtdblock2
[    4.105662]  (driver?)
[    4.112184] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(0,0)
[    4.122034] Rebooting in 1 seconds..

/dts-v1/;
#include "mt7621.dtsi"

#include <dt-bindings/gpio/gpio.h>
#include <dt-bindings/input/input.h>

/ {
	model = "ZBT-WG1602";
	
	chosen {
		bootargs = "console=ttyS0,115200";
	};

	gpio-leds {
		compatible = "gpio-leds";

		4g2 {
			label = "4g2";
			gpios = <&gpio0 10 GPIO_ACTIVE_LOW>;
		};
		4g {
			label = "4g";
			gpios = <&gpio0 12 GPIO_ACTIVE_LOW>;
		};
		card {
			label = "card";
			gpios = <&gpio0 4 GPIO_ACTIVE_LOW>;
		};
	};
	
	gpio_export {
		compatible = "gpio-export";
		#size-cells = <0>;

		4g2 {
			gpio-export,name = "4g2";
			gpio-export,output = <0>;
			gpios = <&gpio0 7 GPIO_ACTIVE_HIGH>;
		};
		4g {
			gpio-export,name = "4g";
			gpio-export,output = <0>;
			gpios = <&gpio0 8 GPIO_ACTIVE_HIGH>;
		};
		usb_sw {
			gpio-export,name = "usb_sw";
			gpio-export,output = <1>;
			gpios = <&gpio0 6 GPIO_ACTIVE_HIGH>;
		};
	};


	gpio-keys-polled {
		compatible = "gpio-keys-polled";
		#address-cells = <1>;
		#size-cells = <0>;
		poll-interval = <20>;

		reset {
			label = "reset";
			gpios = <&gpio0 18 GPIO_ACTIVE_LOW>;
			linux,code = <KEY_RESTART>;
		};
	};
};

&sdhci {
	status = "okay";
};

&spi0 {
	status = "okay";

	m25p80@0 {
		#address-cells = <1>;
		#size-cells = <1>;
		compatible = "jedec,spi-nor";
		reg = <0>;
		spi-max-frequency = <10000000>;
		m25p,chunked-io = <32>;

		partition@0 {
			label = "u-boot";
			reg = <0x0 0x30000>;
			read-only;
		};

		partition@30000 {
			label = "u-boot-env";
			reg = <0x30000 0x10000>;
			read-only;
		};

		factory: partition@40000 {
			label = "factory";
			reg = <0x40000 0x10000>;
		};

		firmware: partition@50000 {
			compatible = "denx,uimage";
			label = "firmware";
			reg = <0x50000 0xfb0000>;
		};
	};
};

&pcie {
	status = "okay";
};

&ethernet {
	mtd-mac-address = <&factory 0xe000>;
};

&pinctrl {
	state_default: pinctrl0 {
		gpio {
			ralink,group = "wdt", "i2c", "uart2", "uart3", "rgmii2";
			ralink,function = "gpio";
		};
	};
};

what's in your bootcmd in uboot?

sorry, I am a noob. Can you tell me how to find bootcmd in uboot?

then printenv.

I am pressing 4 but the bootcmd is not opening. :expressionless:
Can you suggest something else?

have you been able to interact with the console in the past, of have you just looked at the output ?

I haven't interacted with the U-Boot console.

you can always try to hammer the 4, before you actually see the menu through serial.

but you said initramfs worked, right ?
if that's the case install uboot-envtools, and use it to check the uboot env parameters from within openwrt.

yes, initramfs worked.
What will be the next step after getting the uboot env parameters?
Thanks.

opkg update
opkg install uboot-envtools
fw_printenv

if you're using your own initramfs, you could add the uboot-envtools package to your image.

you'll probably have to populate /etc/fw_env.config with the u-boot-env mtd values for fw_printenv to work.

hi @jinglei207 you had the same issue. please help me.

After editing the dts file. I have added the below root=1f02

		bootargs = "console=ttyS0,115200 root=1f02";

Now below is the serial logs.

===============Board Info==================
CPU Frequency:880MHz
Detected Memory:448MiB
Bootloader Version:4.3.1.0
--------------------------------------------
ASIC MT7621A DualCore (MAC to MT7530 Mode)
DRAM_CONF_FROM: Auto-Detection
DRAM_TYPE: DDR3
DRAM bus: 16 bit
Xtal Mode=3 OCP Ratio=1/3
Flash component: SPI Flash
Date:Apr 11 2015  Time:20:07:37
============================================
icache: sets:256, ways:4, linesz:32 ,total:32KiB
dcache: sets:256, ways:4, linesz:32 ,total:32KiB
============================================
#Reset_MT7530

GSW VLAN:LLLW
GPIO_MODE init:
        I2C:GPIO
        UART_F:GPIO
        GE2:GPIO
        WDT_RST:GPIO
GPIO_MODE_REGs: 0x4853d
READY_LED_BIT:14.
Please choose the operation:
   1: Load system code to SDRAM via TFTP.
   2: Load system code then write to Flash via TFTP.
   3: Boot system code via Flash (default).
   4: Entr boot command line interface.
   7: Load Boot Loader code then write to Flash via Serial.
   9: Load Boot Loader code then write to Flash via TFTP.                     0

3: System Boot system code via Flash.

Press Reset button enter upgrade mode!
## Booting image at bc050000 ...
   Image Name:   MIPS OpenWrt Linux-4.14.241
   Image Type:   MIPS Linux Kernel Image (lzma compressed)
   Data Size:    1927600 Bytes =  1.8 MB
   Load Address: 80001000
   Entry Point:  80001000
   Verifying Checksum ... OK
   Uncompressing Kernel Image ... OK
No initrd
## Transferring control to Linux (at address 80001000) ...
## Giving linux memsize in MB, 512

Starting kernel ...

[    0.000000] Linux version 4.14.241 (root@firmware-dev) (gcc version 7.5.0 (Op                                                                              enWrt GCC 7.5.0 r11364-ef56c85848)) #0 SMP Thu Jul 29 19:50:28 2021
[    0.000000] SoC Type: MediaTek MT7621 ver:1 eco:3
[    0.000000] bootconsole [early0] enabled
[    0.000000] CPU0 revision is: 0001992f (MIPS 1004Kc)
[    0.000000] MIPS: machine is ZBT-WG1602
[    0.000000] Determined physical RAM map:
[    0.000000]  memory: 10000000 @ 00000000 (usable)
[    0.000000] Initrd not found or empty - disabling initrd
[    0.000000] VPE topology {2,2} total 4
[    0.000000] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.000000] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 byt                                                                              es
[    0.000000] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.000000] Zone ranges:
[    0.000000]   Normal   [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000]   HighMem  empty
[    0.000000] Movable zone start for each node
[    0.000000] Early memory node ranges
[    0.000000]   node   0: [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000] Initmem setup node 0 [mem 0x0000000000000000-0x000000000fffffff]
[    0.000000] random: get_random_bytes called from start_kernel+0x94/0x4ac with                                                                               crng_init=0
[    0.000000] percpu: Embedded 14 pages/cpu s26192 r8192 d22960 u57344
[    0.000000] Built 1 zonelists, mobility grouping on.  Total pages: 65024
[    0.000000] Kernel command line: console=ttyS0,115200 root=1f02 rootfstype=sq                                                                              uashfs,jffs2
[    0.000000] PID hash table entries: 1024 (order: 0, 4096 bytes)
[    0.000000] Dentry cache hash table entries: 32768 (order: 5, 131072 bytes)
[    0.000000] Inode-cache hash table entries: 16384 (order: 4, 65536 bytes)
[    0.000000] Writing ErrCtl register=00000020
[    0.000000] Readback ErrCtl register=00000020
[    0.000000] Memory: 252212K/262144K available (4556K kernel code, 231K rwdata                                                                              , 1012K rodata, 1292K init, 248K bss, 9932K reserved, 0K cma-reserved, 0K highme                                                                              m)
[    0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=4, Nodes=1
[    0.000000] Hierarchical RCU implementation.
[    0.000000] NR_IRQS: 256
[    0.000000] CPU Clock: 880MHz
[    0.000000] clocksource: GIC: mask: 0xffffffffffffffff max_cycles: 0xcaf478ab                                                                              b4, max_idle_ns: 440795247997 ns
[    0.000000] clocksource: MIPS: mask: 0xffffffff max_cycles: 0xffffffff, max_i                                                                              dle_ns: 4343773742 ns
[    0.000010] sched_clock: 32 bits at 440MHz, resolution 2ns, wraps every 48806                                                                              45118ns
[    0.007823] Calibrating delay loop... 586.13 BogoMIPS (lpj=2930688)
[    0.073988] pid_max: default: 32768 minimum: 301
[    0.078760] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.085270] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[    0.094115] Hierarchical SRCU implementation.
[    0.099277] smp: Bringing up secondary CPUs ...
[    0.105337] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.105346] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 byt                                                                              es
[    0.105358] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.105494] CPU1 revision is: 0001992f (MIPS 1004Kc)
[    0.164011] Synchronize counters for CPU 1: done.
[    0.205131] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.205139] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 byt                                                                              es
[    0.205147] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.205218] CPU2 revision is: 0001992f (MIPS 1004Kc)
[    0.255037] Synchronize counters for CPU 2: done.
[    0.286330] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[    0.286338] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 byt                                                                              es
[    0.286345] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[    0.286423] CPU3 revision is: 0001992f (MIPS 1004Kc)
[    0.340222] Synchronize counters for CPU 3: done.
[    0.370076] smp: Brought up 1 node, 4 CPUs
[    0.377798] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, ma                                                                              x_idle_ns: 19112604462750000 ns
[    0.387591] futex hash table entries: 1024 (order: 3, 32768 bytes)
[    0.393889] pinctrl core: initialized pinctrl subsystem
[    0.400552] NET: Registered protocol family 16
[    0.416236] pull PCIe RST: RALINK_RSTCTRL = 0
[    0.720952] release PCIe RST: RALINK_RSTCTRL = 7000000
[    0.725985] ***** Xtal 40MHz *****
[    0.729357] release PCIe RST: RALINK_RSTCTRL = 7000000
[    0.734465] Port 0 N_FTS = 1b105000
[    0.737908] Port 1 N_FTS = 1b105000
[    0.741367] Port 2 N_FTS = 1b102800
[    1.896614] PCIE2 no card, disable it(RST&CLK)
[    1.900961]  -> 21007f2
[    1.903380] PCIE0 enabled
[    1.905987] PCIE1 enabled
[    1.908574] PCI host bridge /pcie@1e140000 ranges:
[    1.913335]  MEM 0x0000000060000000..0x000000006fffffff
[    1.918518]   IO 0x000000001e160000..0x000000001e16ffff
[    1.923691] PCI coherence region base: 0xbfbf8000, mask/settings: 0x60000000
[    1.939780] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.945628] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.951345] mt7621_gpio 1e000600.gpio: registering 32 gpios
[    1.958705] PCI host bridge to bus 0000:00
[    1.962742] pci_bus 0000:00: root bus resource [mem 0x60000000-0x6fffffff]
[    1.969597] pci_bus 0000:00: root bus resource [io  0x1e160000-0x1e16ffff]
[    1.976378] pci_bus 0000:00: root bus resource [??? 0x00000000 flags 0x0]
[    1.983133] pci_bus 0000:00: No busn resource found for root bus, will use [b                                                                              us 00-ff]
[    1.993189] pci 0000:00:00.0: BAR 0: no space for [mem size 0x80000000]
[    1.999701] pci 0000:00:00.0: BAR 0: failed to assign [mem size 0x80000000]
[    2.006649] pci 0000:00:01.0: BAR 0: no space for [mem size 0x80000000]
[    2.013181] pci 0000:00:01.0: BAR 0: failed to assign [mem size 0x80000000]
[    2.020114] pci 0000:00:00.0: BAR 8: assigned [mem 0x60000000-0x600fffff]
[    2.026839] pci 0000:00:01.0: BAR 8: assigned [mem 0x60100000-0x601fffff]
[    2.033592] pci 0000:00:01.0: BAR 9: assigned [mem 0x60200000-0x602fffff pref                                                                              ]
[    2.040741] pci 0000:00:00.0: BAR 1: assigned [mem 0x60300000-0x6030ffff]
[    2.047506] pci 0000:00:01.0: BAR 1: assigned [mem 0x60310000-0x6031ffff]
[    2.054236] pci 0000:01:00.0: BAR 0: assigned [mem 0x60000000-0x600fffff]
[    2.060990] pci 0000:00:00.0: PCI bridge to [bus 01]
[    2.065890] pci 0000:00:00.0:   bridge window [mem 0x60000000-0x600fffff]
[    2.072650] pci 0000:02:00.0: BAR 0: assigned [mem 0x60100000-0x601fffff 64bi                                                                              t]
[    2.079890] pci 0000:02:00.0: BAR 6: assigned [mem 0x60200000-0x6020ffff pref                                                                              ]
[    2.087075] pci 0000:00:01.0: PCI bridge to [bus 02]
[    2.091987] pci 0000:00:01.0:   bridge window [mem 0x60100000-0x601fffff]
[    2.098740] pci 0000:00:01.0:   bridge window [mem 0x60200000-0x602fffff pref                                                                              ]
[    2.107321] clocksource: Switched to clocksource GIC
[    2.113889] NET: Registered protocol family 2
[    2.118353] IP idents hash table entries: 4096 (order: 3, 32768 bytes)
[    2.125387] TCP established hash table entries: 2048 (order: 1, 8192 bytes)
[    2.132334] TCP bind hash table entries: 2048 (order: 2, 16384 bytes)
[    2.138729] TCP: Hash tables configured (established 2048 bind 2048)
[    2.145127] UDP hash table entries: 256 (order: 1, 8192 bytes)
[    2.150928] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[    2.157428] NET: Registered protocol family 1
[    2.397274] 4 CPUs re-calibrate udelay(lpj = 2924544)
[    2.403694] Crashlog allocated RAM at address 0x3f00000
[    2.409293] workingset: timestamp_bits=30 max_order=16 bucket_order=0
[    2.419971] random: fast init done
[    2.426280] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[    2.432093] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORIT                                                                              Y) (c) 2001-2006 Red Hat, Inc.
[    2.445318] io scheduler noop registered
[    2.449224] io scheduler deadline registered (default)
[    2.455043] gpio-export gpio_export: 3 gpio(s) exported
[    2.461153] Serial: 8250/16550 driver, 3 ports, IRQ sharing disabled
[    2.468917] console [ttyS0] disabled
[    2.472464] 1e000c00.uartlite: ttyS0 at MMIO 0x1e000c00 (irq = 19, base_baud                                                                               = 3125000) is a 16550A
[    2.481479] console [ttyS0] enabled
[    2.481479] console [ttyS0] enabled
[    2.488361] bootconsole [early0] disabled
[    2.488361] bootconsole [early0] disabled
[    2.498493] MediaTek Nand driver init, version v2.1 Fix AHB virt2phys error
[    2.505825] spi-mt7621 1e000b00.spi: sys_freq: 220000000
[    2.520940] m25p80 spi0.0: w25q128 (16384 Kbytes)
[    2.525683] 3 fixed-partitions partitions found on MTD device spi0.0
[    2.532042] Creating 3 MTD partitions on "spi0.0":
[    2.536820] 0x000000000000-0x000000030000 : "u-boot"
[    2.542801] 0x000000030000-0x000000040000 : "u-boot-env"
[    2.548997] 0x000000040000-0x000000050000 : "factory"
[    2.555462] libphy: Fixed MDIO Bus: probed
[    2.629347] libphy: mdio: probed
[    4.032203] mtk_soc_eth 1e100000.ethernet: loaded mt7530 driver
[    4.038896] mtk_soc_eth 1e100000.ethernet eth0: mediatek frame engine at 0xbe100000, irq 22
[    4.050082] NET: Registered protocol family 10
[    4.056148] Segment Routing with IPv6
[    4.059979] NET: Registered protocol family 17
[    4.064467] 8021q: 802.1Q VLAN Support v1.8
[    4.071218] hctosys: unable to open rtc device (rtc0)
[    4.078663] jffs2: Too few erase blocks (1)
[    4.082853] List of all partitions:
[    4.086336] 1f00             192 mtdblock0
[    4.086342]  (driver?)
[    4.092892] 1f01              64 mtdblock1
[    4.092898]  (driver?)
[    4.099437] 1f02              64 mtdblock2
[    4.099446]  (driver?)
[    4.105949] No filesystem could mount root, tried:
[    4.105953]  squashfs
[    4.110922]  jffs2
[    4.113181]
[    4.116658] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(31,2)
[    4.126622] Rebooting in 1 seconds..

try root=LABEL=factory

but what have you done so far ?
have you successfully ULed an openwrt image to the router ?
was it written, and then failed to boot afterwards ?

1:have you successfully ULed an openwrt image to the router ?
yes
2: was it written, and then failed to boot afterward?
yes i have created it and it worked. (On openwrt version 18)

buddy I have created an image for the same router on OpenWrt version 18 and it is working fine but I wanna upgrade to version 19.