Hello,
This board was shipped by Sercomm to the company i'm currently working at for development purposes, however it came preinstalled with an older (customized) OpenWrt version (Chaos Calmer if i'm not mistaken).
Since we really need Node.js running on it, i have to find a way to upgrade to OpenWrt 18.
Sercomm provided us with a confidential documentation of the board that was helpful enough to get most of OpenWrt 18 running on it - unfortunately i'm not sure whether i can disclose that documentation.
CPU: MT7621S
NAND Flash: 128Mbytes
DDR3 RAM: 256 Mbytes
Wifi 2.4GHz: MT7602E (via PCIe 1)
Wifi 5.0Ghz: MT7663E (via PCIe 0)
Bluetooth: MT7663E (via USB)
I made a lot of progress since yesterday and i'm happy that i got the two Wi-Fi chips (MT7603E & MT7662E) up and running. I've mapped the LEDs to the GPIO pins, same for the GPIO buttons, it's almost ready, except one thing.
The build process generates a squashfs-sysupgrade image and a initramfs-kernel and as expected, the initramfs-kernel runs just fine, however i need the configurations to persist over a reboot so i flashed the squashfs-sysupgrade and here's where the troubles started.
I've pasted the bootstrap process log starting from the kernel's effective bootstrap to the point it panics.
It seems it complaints about some magic number that's not being found by the JFFS2 system.
Am i missing a driver or the image i flashed was not packed the right way?
openwrt/target/linux/ramips/mt7621.mk: https://pastebin.com/uDEchAPA
root@OpenWrt:/# cat /proc/mtd
dev: size erasesize name
mtd0: 00080000 00020000 "uboot"
mtd1: 00080000 00020000 "config"
mtd2: 00040000 00020000 "factory"
mtd3: 02940000 00020000 "rootfs"
mtd4: 00100000 00020000 "user_storage"
mtd5: 01000000 00020000 "data"
mtd6: 03200000 00020000 "storage"
mtd7: 013c0000 00020000 "backup"
Thank you!
[ 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 sercomm,na502
[ 0.000000] Determined physical RAM map:
[ 0.000000] memory: 04000000 @ 00000000 (usable)
[ 0.000000] Initrd not found or empty - disabling initrd
[ 0.000000] VPE topology {2} total 2
[ 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-0x0000000003ffffff]
[ 0.000000] HighMem empty
[ 0.000000] Movable zone start for each node
[ 0.000000] Early memory node ranges
[ 0.000000] node 0: [mem 0x0000000000000000-0x0000000003ffffff]
[ 0.000000] Initmem setup node 0 [mem 0x0000000000000000-0x0000000003ffffff]
[ 0.000000] random: get_random_bytes called from start_kernel+0x90/0x4a4 with crng_init=0
[ 0.000000] percpu: Embedded 14 pages/cpu @81090000 s26704 r8192 d22448 u57344
[ 0.000000] Built 1 zonelists, mobility grouping on. Total pages: 16256
[ 0.000000] Kernel command line: console=ttyS0,57600 rootfstype=squashfs,jffs2
[ 0.000000] PID hash table entries: 256 (order: -2, 1024 bytes)
[ 0.000000] Dentry cache hash table entries: 8192 (order: 3, 32768 bytes)
[ 0.000000] Inode-cache hash table entries: 4096 (order: 2, 16384 bytes)
[ 0.000000] Writing ErrCtl register=00050030
[ 0.000000] Readback ErrCtl register=00050030
[ 0.000000] Memory: 58464K/65536K available (4499K kernel code, 228K rwdata, 1000K rodata, 276K init, 275K bss, 7072K reserved, 0K cma-reserved, 0K highmem)
[ 0.000000] SLUB: HWalign=32, Order=0-3, MinObjects=0, CPUs=2, Nodes=1
[ 0.000000] Hierarchical RCU implementation.
[ 0.000000] RCU restricting CPUs from NR_CPUS=4 to nr_cpu_ids=2.
[ 0.000000] RCU: Adjusting geometry for rcu_fanout_leaf=16, nr_cpu_ids=2
[ 0.000000] NR_IRQS: 256
[ 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.015484] Calibrating delay loop... 586.13 BogoMIPS (lpj=2930688)
[ 0.087788] pid_max: default: 32768 minimum: 301
[ 0.097078] Mount-cache hash table entries: 1024 (order: 0, 4096 bytes)
[ 0.110094] Mountpoint-cache hash table entries: 1024 (order: 0, 4096 bytes)
[ 0.125596] Hierarchical SRCU implementation.
[ 0.134825] smp: Bringing up secondary CPUs ...
[ 0.144407] Primary instruction cache 32kB, VIPT, 4-way, linesize 32 bytes.
[ 0.144420] Primary data cache 32kB, 4-way, PIPT, no aliases, linesize 32 bytes
[ 0.144433] MIPS secondary cache 256kB, 8-way, linesize 32 bytes.
[ 0.144563] CPU1 revision is: 0001992f (MIPS 1004Kc)
[ 0.204326] Synchronize counters for CPU 1: done.
[ 0.263981] smp: Brought up 1 node, 2 CPUs
[ 0.275456] clocksource: jiffies: mask: 0xffffffff max_cycles: 0xffffffff, max_idle_ns: 19112604462750000 ns
[ 0.294922] futex hash table entries: 512 (order: 2, 16384 bytes)
[ 0.307135] pinctrl core: initialized pinctrl subsystem
[ 0.318750] NET: Registered protocol family 16
[ 0.339523] pull PCIe RST: RALINK_RSTCTRL = 0
[ 0.648431] release PCIe RST: RALINK_RSTCTRL = 7000000
[ 0.658494] ***** Xtal 40MHz *****
[ 0.665224] release PCIe RST: RALINK_RSTCTRL = 7000000
[ 0.675433] Port 0 N_FTS = 1b102800
[ 0.682331] Port 1 N_FTS = 1b105000
[ 0.689258] Port 2 N_FTS = 1b105000
[ 1.847615] PCIE0 no card, disable it(RST&CLK)
[ 1.856307] -> 10207f2
[ 1.861125] PCIE1 enabled
[ 1.866321] PCIE2 enabled
[ 1.871507] PCI host bridge /pcie@1e140000 ranges:
[ 1.881026] MEM 0x0000000060000000..0x000000006fffffff
[ 1.891392] IO 0x000000001e160000..0x000000001e16ffff
[ 1.901751] PCI coherence region base: 0xbfbf8000, mask/settings: 0x60000000
[ 1.927342] mt7621_gpio 1e000600.gpio: registering 32 gpios
[ 1.938616] mt7621_gpio 1e000600.gpio: registering 32 gpios
[ 1.950022] mt7621_gpio 1e000600.gpio: registering 32 gpios
[ 1.962480] i2c-mt7621 1e000900.i2c: clock 100KHz, re-start not support
[ 1.976076] PCI host bridge to bus 0000:00
[ 1.984086] pci_bus 0000:00: root bus resource [mem 0x60000000-0x6fffffff]
[ 1.997738] pci_bus 0000:00: root bus resource [io 0xffffffff]
[ 2.009488] pci_bus 0000:00: root bus resource [??? 0x00000000 flags 0x0]
[ 2.022970] pci_bus 0000:00: No busn resource found for root bus, will use [bus 00-ff]
[ 2.040960] pci 0000:00:00.0: BAR 0: no space for [mem size 0x80000000]
[ 2.053984] pci 0000:00:00.0: BAR 0: failed to assign [mem size 0x80000000]
[ 2.067806] pci 0000:00:01.0: BAR 0: no space for [mem size 0x80000000]
[ 2.080930] pci 0000:00:01.0: BAR 0: failed to assign [mem size 0x80000000]
[ 2.094760] pci 0000:00:00.0: BAR 8: assigned [mem 0x60000000-0x600fffff]
[ 2.108241] pci 0000:00:00.0: BAR 9: assigned [mem 0x60100000-0x601fffff pref]
[ 2.122579] pci 0000:00:01.0: BAR 8: assigned [mem 0x60200000-0x602fffff]
[ 2.136060] pci 0000:00:00.0: BAR 1: assigned [mem 0x60300000-0x6030ffff]
[ 2.149548] pci 0000:00:01.0: BAR 1: assigned [mem 0x60310000-0x6031ffff]
[ 2.163024] pci 0000:01:00.0: BAR 0: assigned [mem 0x60000000-0x600fffff 64bit]
[ 2.177542] pci 0000:01:00.0: BAR 6: assigned [mem 0x60100000-0x6010ffff pref]
[ 2.191874] pci 0000:00:00.0: PCI bridge to [bus 01]
[ 2.201711] pci 0000:00:00.0: bridge window [mem 0x60000000-0x600fffff]
[ 2.215206] pci 0000:00:00.0: bridge window [mem 0x60100000-0x601fffff pref]
[ 2.229551] pci 0000:02:00.0: BAR 0: assigned [mem 0x60200000-0x602fffff]
[ 2.243021] pci 0000:00:01.0: PCI bridge to [bus 02]
[ 2.252860] pci 0000:00:01.0: bridge window [mem 0x60200000-0x602fffff]
[ 2.268397] clocksource: Switched to clocksource GIC
[ 2.279701] NET: Registered protocol family 2
[ 2.289038] TCP established hash table entries: 1024 (order: 0, 4096 bytes)
[ 2.302770] TCP bind hash table entries: 1024 (order: 1, 8192 bytes)
[ 2.315372] TCP: Hash tables configured (established 1024 bind 1024)
[ 2.328092] UDP hash table entries: 256 (order: 1, 8192 bytes)
[ 2.339593] UDP-Lite hash table entries: 256 (order: 1, 8192 bytes)
[ 2.352229] NET: Registered protocol family 1
[ 2.598346] 4 CPUs re-calibrate udelay(lpj = 2924544)
[ 2.609475] Crashlog allocated RAM at address 0x3f00000
[ 2.620203] workingset: timestamp_bits=30 max_order=14 bucket_order=0
[ 2.641253] squashfs: version 4.0 (2009/01/31) Phillip Lougher
[ 2.652754] jffs2: version 2.2 (NAND) (SUMMARY) (LZMA) (RTIME) (CMODE_PRIORITY) (c) 2001-2006 Red Hat, Inc.
[ 2.675960] io scheduler noop registered
[ 2.683822] io scheduler deadline registered (default)
[ 2.695106] Serial: 8250/16550 driver, 3 ports, IRQ sharing disabled
[ 2.709249] console [ttyS0] disabled
[ 2.716260] 1e000c00.uartlite: ttyS0 at MMIO 0x1e000c00 (irq = 14, base_baud = 3125000) is a 16550A
[ 2.734251] console [ttyS0] enabled
[ 2.734251] console [ttyS0] enabled
[ 2.748024] bootconsole [early0] disabled
[ 2.748024] bootconsole [early0] disabled
[ 2.765055] cacheinfo: Unable to detect cache hierarchy for CPU 0
**[ 2.778070] MediaTek Nand driver init, version v2.1 Fix AHB virt2phys error**
**[ 2.792092] Enable NFI Clock**
**[ 2.797810] # MTK NAND # : Use HW ECC**
**[ 2.805126] Device not found, ID: c2f1**
**[ 2.812584] Not Support this Device! **
**[ 2.820049] chip_mode=00000001**
**[ 2.826113] Support this Device in MTK table! c2f1 **
**[ 2.836000] [NAND]select ecc bit:4, sparesize :64 spare_per_sector=16**
**[ 2.848874] nand: device found, Manufacturer ID: 0xc2, Chip ID: 0xf1**
**[ 2.861523] nand: Macronix NAND 128MiB 3,3V 8-bit**
**[ 2.870887] nand: 128 MiB, SLC, erase size: 128 KiB, page size: 2048, OOB size: 64**
**[ 2.885973] Scanning device for bad blocks**
**[ 3.088467] Bad eraseblock 824 at 0x000006700000**
**[ 3.144612] 8 fixed-partitions partitions found on MTD device MT7621-NAND**
**[ 3.158123] Creating 8 MTD partitions on "MT7621-NAND":**
**[ 3.168534] 0x000000000000-0x000000080000 : "uboot"**
**[ 3.179350] 0x000000080000-0x000000100000 : "config"**
**[ 3.190322] 0x000000100000-0x000000140000 : "factory"**
**[ 3.201420] 0x000000140000-0x000002a80000 : "rootfs"**
**[ 3.212622] mtd: device 3 (rootfs) set to be root filesystem**
**[ 3.224501] mtdsplit: no squashfs found in "rootfs"**
**[ 3.234255] 0x000002940000-0x000002a40000 : "user_storage"**
**[ 3.246210] 0x000002a40000-0x000003a40000 : "data"**
**[ 3.256970] 0x000003a40000-0x000006c40000 : "storage"**
**[ 3.268496] 0x000006c40000-0x000008000000 : "backup"**
[ 3.279578] [mtk_nand] probe successfully!
[ 3.288459] Signature matched and data read!
[ 3.296942] load_fact_bbt success 1023
[ 3.305165] libphy: Fixed MDIO Bus: probed
[ 3.380953] libphy: mdio: probed
[ 4.787006] mtk_soc_eth 1e100000.ethernet: loaded mt7530 driver
[ 4.799517] mtk_soc_eth 1e100000.ethernet eth0: mediatek frame engine at 0xbe100000, irq 17
[ 4.818818] NET: Registered protocol family 10
[ 4.828993] Segment Routing with IPv6
[ 4.836351] NET: Registered protocol family 17
[ 4.845270] 8021q: 802.1Q VLAN Support v1.8
[ 4.856738] UBI error: no valid UBI magic found inside mtd5
[ 4.867916] hctosys: unable to open rtc device (rtc0)
**[ 4.880862] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000000: 0x0527 instead**
**[ 4.899838] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000004: 0x08fb instead**
**[ 4.918715] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000008: 0xb25b instead**
**[ 4.937589] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x0000000c: 0x1d00 instead**
**[ 4.956474] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000010: 0x0080 instead**
**[ 4.975349] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000014: 0x0080 instead**
**[ 4.994224] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000018: 0xcaa9 instead**
**[ 5.013105] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x0000001c: 0x0505 instead**
**[ 5.031981] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000020: 0x494d instead**
**[ 5.050856] jffs2: jffs2_scan_eraseblock(): Magic bitmask 0x1985 not found at 0x00000024: 0x4f20 instead**
[ .................. ]
[ 13.680164] jffs2: Old JFFS2 bitmask found at 0x00405798
[ 13.690735] jffs2: You cannot use older JFFS2 filesystems with newer kernels
[ 13.725402] jffs2: Empty flash at 0x004107ec ends at 0x00411000
[ 13.754331] jffs2: Empty flash at 0x00411004 ends at 0x00412000
[ 13.782134] jffs2: Empty flash at 0x00412004 ends at 0x00414000
[ 13.809063] jffs2_scan_eraseblock(): End of filesystem marker found at 0x420000
[ 13.823937] jffs2: Cowardly refusing to erase blocks on filesystem with no valid JFFS2 nodes
[ 13.840735] jffs2: empty_blocks 297, bad_blocks 0, c->nr_blocks 330
[ 13.853332] VFS: Cannot open root device "(null)" or unknown-block(31,3): error -5
[ 13.868437] Please append a correct "root=" boot option; here are the available partitions:
[ 13.885080] 1f00 512 mtdblock0
[ 13.885087] (driver?)
[ 13.898090] 1f01 512 mtdblock1
[ 13.898095] (driver?)
[ 13.911121] 1f02 256 mtdblock2
[ 13.911126] (driver?)
[ 13.924132] 1f03 42240 mtdblock3
[ 13.924138] (driver?)
[ 13.937137] 1f04 1024 mtdblock4
[ 13.937142] (driver?)
[ 13.950163] 1f05 16384 mtdblock5
[ 13.950168] (driver?)
[ 13.963174] 1f06 51200 mtdblock6
[ 13.963179] (driver?)
[ 13.976177] 1f07 20224 mtdblock7
[ 13.976182] (driver?)
[ 13.989202] Kernel panic - not syncing: VFS: Unable to mount root fs on unknown-block(31,3)
[ 14.010001] Rebooting in 1 seconds..