Yes, you're right. The suqashfs ist readonly, and the jffs2 partition is created in the free space. File size was OK.
I think the NAS-4210-B and NAS-4220-B have the same flash layout, as posted before. My problem is kind of openWRT specific.
While booting the kernel, openWRT looks for a partition named 'rootfs' within it looks for the jffs2 special marker. But in the partition table of the NAS-4210-B, there is no partition with this name. The mechanism ist not working.
In previous openWRT releases, there was some kind of workaround. The flash layout was hard coded, the one or the other way. At the end, 2 more partitions were added, only to make openWRT detect the right one. This is what I expext:
|
Kaynak kod
|
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
|
[ 4.643675] of-flash 30000000.flash: initialized Gemini-specific physmap control
[ 4.688220] 30000000.flash: Found 1 x16 devices at 0x0 in 16-bit bank. Manufacturer ID 0x000001 Chip ID 0x002101
[ 4.749261] Amd/Fujitsu Extended Query Table at 0x0040
[ 4.780211] Amd/Fujitsu Extended Query version 1.3.
[ 4.810546] number of CFI chips: 1
[ 4.832623] 9 fixed-partitions partitions found on MTD device 30000000.flash
[ 4.875064] Creating 9 MTD partitions on "30000000.flash":
[ 4.908117] 0x000000000000-0x000000020000 : "RedBoot"
[ 4.943509] 0x000000020000-0x000000320000 : "Kernel"
[ 4.978906] 0x000000320000-0x000000920000 : "Ramdisk"
[ 5.015124] 0x000000920000-0x000000f20000 : "Application"
[ 5.053883] 0x000000f20000-0x000000f40000 : "VCTL"
[ 5.088507] 0x000000f40000-0x000000fe0000 : "CurConf"
[ 5.124837] 0x000000fe0000-0x000001000000 : "FIS directory"
[ 5.164787] 0x000000020000-0x000000f20000 : "firmware"
[ 5.202466] 0x000000320000-0x000000f20000 : "rootfs"
[ 5.237494] mtd: device 8 (rootfs) set to be root filesystem
[ 5.272959] 1 squashfs-split partitions found on MTD device rootfs
[ 5.310424] 0x000000740000-0x000000f20000 : "rootfs_data"
|
Have a look at the start and end addresses of the partitions firmware and rootfs. They overlay some of the other partitions.
In openWRT v19.07.7 / kernel 4.14, there was a
patch that added this to partitions to the device tree (dts) file.
There was a
ticket to a similar problem, but no solution.
In openWRT master / kernel 5.4, the fixed partitions in the device tree file have been replaced by an autodetect mechnism, see this
patch. This makes the two special entries missing and the magic doesn't work anymore.
I restarted my tests with openWRT v19.07.7 and created a working firmware for IB-NAS4210-B. I'll give a link as soon as I can. This nightly version is still not perfect, but it boots. Missing is hard disk access (mistake in device tree, I think) and the luci (webinterface) packages.
That's it for now. Live long and prosper!
Cpt. Spock