JFFS2 / NAND erase / garbage collection totally broken?

Andy Green andy at openmoko.com
Wed Feb 6 12:31:29 CET 2008


-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

Hi folks -

I noticed the failure to fork garbage collector (513) error returns if I
boot without a battery (zero idea why that should be).  This results in
a failed boot because it can't find stuff in / after that somehow, even
/dev or /bin/sh.

This prompted me to stick JFFS2 debug up to 9 and to look at the
gigabytes of spew that generates.

I notice that for many many inodes, JFFS2 is seeing and processing a
large number of deprecated "versions" of the inode.  To avoid the hit of
immediate erase and allow to recover from partial erase, JFFS2 has a
"version #" on the blocks it writes, it can figure out which was the
latest even if the old guys didn't get erased yet, since it bumps the
version # each time there is a new write there.

I mean consider the career of inode #787 when it is being mounted:

[  259.570000] jffs2_scan_dirent_node(): Node at 0x0059dba4
[  259.575000] [JFFS2 DBG] (1) jffs2_alloc_full_dirent: c7e099e0
[  259.580000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cce8 is (0059d7dc,c7e1ccdc)
[  259.585000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1ccf4
(fffffffe becomes 0059dba6,00000000) len 0x30
[  259.590000] [JFFS2 DBG] (1) jffs2_add_fd_to_list: add dirent
"iwconfig", ino #787
[  259.595000] [JFFS2 DBG] (1) jffs2_sum_add_mem: dirent (787) added to
summary
[  259.600000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  259.605000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x00580000
[  259.610000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x00580000, last_node is c7e1ccf4 (0059dba6,c7e1ccc4)
[  259.615000] jffs2_scan_inode_node(): Node at 0x0059dbd4
[  259.620000] [JFFS2 DBG] (1) jffs2_alloc_inode_cache: c7e19d70
[  259.625000] [JFFS2 DBG] (1) jffs2_add_ino_cache: add c7e19d70 (ino #787)
[  259.630000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ccf4 is (0059dba6,c7e1ccc4)
[  259.635000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cd00
(fffffffe becomes 0059dbd4,00000000) len 0x3b8
[  259.640000] Node is ino #787, version 1. Range 0x0-0x800
[  259.645000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  259.650000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  259.655000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x00580000
[  259.660000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Allocating
new refblock linked from c7e1cd18
[  259.665000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x00580000, last_node is c7e1cd00 (0059dbd4,c7e19d70)
[  259.670000] jffs2_scan_inode_node(): Node at 0x0059df8c
[  259.675000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cd00 is (0059dbd4,c7e19d70)
[  259.680000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cd0c
(fffffffe becomes 0059df8c,00000000) len 0x438
[  259.685000] Node is ino #787, version 2. Range 0x800-0x1000
[  259.690000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  259.695000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  259.700000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x00580000
[  259.705000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x00580000, last_node is c7e1cd0c (0059df8c,c7e1cd00)
[  259.710000] jffs2_scan_inode_node(): Node at 0x0059e3c4
[  259.715000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cd0c is (0059df8c,c7e1cd00)
[  259.720000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cb2c
(fffffffe becomes 0059e3c4,00000000) len 0x5a8
[  259.725000] Node is ino #787, version 3. Range 0x1000-0x1800
[  259.730000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  259.735000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  259.740000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x00580000
[  259.750000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x00580000, last_node is c7e1cb2c (0059e3c4,c7e1cd0c)
[  259.755000] jffs2_scan_inode_node(): Node at 0x0059e96c
[  259.760000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cb2c is (0059e3c4,c7e1cd0c)
[  259.765000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cb38
(fffffffe becomes 0059e96c,00000000) len 0x600
[  259.770000] Node is ino #787, version 4. Range 0x1800-0x2000
[  259.775000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  259.780000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  259.785000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x00580000
[  259.790000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x00580000, last_node is c7e1cb38 (0059e96c,c7e1cb2c)
[  259.795000] jffs2_scan_inode_node(): Node at 0x0059ef6c
[  259.800000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cb38 is (0059e96c,c7e1cb2c)
[  259.805000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cb44
(fffffffe becomes 0059ef6c,00000000) len 0x55c
[  259.810000] Node is ino #787, version 5. Range 0x2000-0x2800
[  259.815000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  259.820000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  259.825000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x00580000
[  259.830000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x00580000, last_node is c7e1cb44 (0059ef6c,c7e1cb38)
[  259.835000] jffs2_scan_inode_node(): Node at 0x0059f4c8
[  259.840000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cb44 is (0059ef6c,c7e1cb38)
[  259.845000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cb50
(fffffffe becomes 0059f4c8,00000000) len 0x510
[  259.850000] Node is ino #787, version 6. Range 0x2800-0x3000
[  259.855000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  259.860000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  259.865000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x00580000
[  259.870000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x00580000, last_node is c7e1cb50 (0059f4c8,c7e1cb44)
[  259.875000] jffs2_scan_inode_node(): Node at 0x0059f9d8
[  259.880000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cb50 is (0059f4c8,c7e1cb44)
[  259.885000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cb5c
(fffffffe becomes 0059f9d8,00000000) len 0x5d4
[  259.890000] Node is ino #787, version 7. Range 0x3000-0x3800
[  259.895000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  259.900000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  259.905000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x00580000
[  259.910000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x00580000, last_node is c7e1cb5c (0059f9d8,c7e1cb50)
[  259.920000] Found empty flash at 0x0059ffb0
[  259.920000] Empty flash to end of buffer at 0x0059ffb0
[  259.925000] Reading another 0x50 at 0x0059ffb0
[  259.930000] Empty flash to end of buffer at 0x005a0000
[  259.935000] Empty flash at 0059ffac runs to end of block. Treating as
free_space
[  259.940000] [JFFS2 DBG] (1) jffs2_scan_eraseblock: There is not
enough space for summary information, disabling for this jeb!
[  259.945000] [JFFS2 DBG] (1) jffs2_sum_disable_collecting: called
[  259.950000] Block at 0x00580000: free 0x00000054, dirty 0x00000000,
unchecked 0x0001fd98, used 0x00000214, wasted 0x00000000
[  259.955000] [JFFS2 DBG] (1) jffs2_sum_reset_collected: called
[  259.960000] [JFFS2 DBG] (1) jffs2_sum_clean_collected: already empty
[  259.965000] jffs2_scan_eraseblock(): Scanning block at 0x5a0000
[  259.970000] jffs_check_nand_cleanmarker returned 0
[  259.975000] [JFFS2 DBG] (1) jffs2_scan_eraseblock: no summary found
in jeb 0x005a0000. Apply original scan.
[  259.980000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  259.985000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  259.990000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Allocating
new refblock linked from c7db0950
[  259.995000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1ca30 (fffffffe,00000000)
[  260.000000] jffs2_scan_inode_node(): Node at 0x005a0000
[  260.005000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ca30 is (fffffffe,00000000)
[  260.010000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1ca30
(fffffffe becomes 005a0000,00000000) len 0x59c
[  260.015000] Node is ino #787, version 8. Range 0x3800-0x4000
[  260.020000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.025000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.030000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.035000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1ca30 (005a0000,c7e1cb5c)
[  260.040000] Fewer than 12 bytes (node header) left to end of buf.
Reading 0x1fa64 at 0x005a059c
[  260.070000] jffs2_scan_inode_node(): Node at 0x005a059c
[  260.075000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ca30 is (005a0000,c7e1cb5c)
[  260.080000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1ca3c
(fffffffe becomes 005a059c,00000000) len 0x538
[  260.085000] Node is ino #787, version 9. Range 0x4000-0x4800
[  260.090000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.095000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.100000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.105000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1ca3c (005a059c,c7e1ca30)
[  260.110000] jffs2_scan_inode_node(): Node at 0x005a0ad4
[  260.115000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ca3c is (005a059c,c7e1ca30)
[  260.120000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1ca48
(fffffffe becomes 005a0ad4,00000000) len 0x588
[  260.125000] Node is ino #787, version 10. Range 0x4800-0x5000
[  260.130000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.135000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.140000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.145000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1ca48 (005a0ad4,c7e1ca3c)
[  260.150000] jffs2_scan_inode_node(): Node at 0x005a105c
[  260.155000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ca48 is (005a0ad4,c7e1ca3c)
[  260.160000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1ca54
(fffffffe becomes 005a105c,00000000) len 0x5d8
[  260.165000] Node is ino #787, version 11. Range 0x5000-0x5800
[  260.170000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.175000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.180000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.185000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1ca54 (005a105c,c7e1ca48)
[  260.190000] jffs2_scan_inode_node(): Node at 0x005a1634
[  260.195000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ca54 is (005a105c,c7e1ca48)
[  260.200000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1ca60
(fffffffe becomes 005a1634,00000000) len 0x598
[  260.205000] Node is ino #787, version 12. Range 0x5800-0x6000
[  260.210000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.215000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.220000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.230000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1ca60 (005a1634,c7e1ca54)
[  260.235000] jffs2_scan_inode_node(): Node at 0x005a1bcc
[  260.240000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ca60 is (005a1634,c7e1ca54)
[  260.245000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1ca6c
(fffffffe becomes 005a1bcc,00000000) len 0x558
[  260.250000] Node is ino #787, version 13. Range 0x6000-0x6800
[  260.255000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.260000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.265000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.270000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1ca6c (005a1bcc,c7e1ca60)
[  260.275000] jffs2_scan_inode_node(): Node at 0x005a2124
[  260.280000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ca6c is (005a1bcc,c7e1ca60)
[  260.285000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1ca78
(fffffffe becomes 005a2124,00000000) len 0x56c
[  260.290000] Node is ino #787, version 14. Range 0x6800-0x7000
[  260.295000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.300000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.305000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.310000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1ca78 (005a2124,c7e1ca6c)
[  260.315000] jffs2_scan_inode_node(): Node at 0x005a2690
[  260.320000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ca78 is (005a2124,c7e1ca6c)
[  260.325000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1ca84
(fffffffe becomes 005a2690,00000000) len 0x618
[  260.330000] Node is ino #787, version 15. Range 0x7000-0x7800
[  260.335000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.340000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.345000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.350000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1ca84 (005a2690,c7e1ca78)
[  260.355000] jffs2_scan_inode_node(): Node at 0x005a2ca8
[  260.360000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ca84 is (005a2690,c7e1ca78)
[  260.365000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1ca90
(fffffffe becomes 005a2ca8,00000000) len 0x5f8
[  260.370000] Node is ino #787, version 16. Range 0x7800-0x8000
[  260.375000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.380000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.385000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.390000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1ca90 (005a2ca8,c7e1ca84)
[  260.395000] jffs2_scan_inode_node(): Node at 0x005a32a0
[  260.400000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ca90 is (005a2ca8,c7e1ca84)
[  260.405000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1ca9c
(fffffffe becomes 005a32a0,00000000) len 0x5dc
[  260.410000] Node is ino #787, version 17. Range 0x8000-0x8800
[  260.420000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.425000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.430000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.435000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1ca9c (005a32a0,c7e1ca90)
[  260.440000] jffs2_scan_inode_node(): Node at 0x005a387c
[  260.445000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1ca9c is (005a32a0,c7e1ca90)
[  260.450000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1caa8
(fffffffe becomes 005a387c,00000000) len 0x5e4
[  260.455000] Node is ino #787, version 18. Range 0x8800-0x9000
[  260.460000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.465000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.470000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.475000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1caa8 (005a387c,c7e1ca9c)
[  260.480000] jffs2_scan_inode_node(): Node at 0x005a3e60
[  260.485000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1caa8 is (005a387c,c7e1ca9c)
[  260.490000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cab4
(fffffffe becomes 005a3e60,00000000) len 0x57c
[  260.495000] Node is ino #787, version 19. Range 0x9000-0x9800
[  260.500000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.505000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.510000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.515000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1cab4 (005a3e60,c7e1caa8)
[  260.520000] jffs2_scan_inode_node(): Node at 0x005a43dc
[  260.525000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cab4 is (005a3e60,c7e1caa8)
[  260.530000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cac0
(fffffffe becomes 005a43dc,00000000) len 0x50c
[  260.535000] Node is ino #787, version 20. Range 0x9800-0xa000
[  260.540000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.545000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.550000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.555000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1cac0 (005a43dc,c7e1cab4)
[  260.560000] jffs2_scan_inode_node(): Node at 0x005a48e8
[  260.565000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cac0 is (005a43dc,c7e1cab4)
[  260.570000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cacc
(fffffffe becomes 005a48e8,00000000) len 0x574
[  260.575000] Node is ino #787, version 21. Range 0xa000-0xa800
[  260.580000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.585000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.590000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.595000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1cacc (005a48e8,c7e1cac0)
[  260.600000] jffs2_scan_inode_node(): Node at 0x005a4e5c
[  260.605000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cacc is (005a48e8,c7e1cac0)
[  260.610000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cad8
(fffffffe becomes 005a4e5c,00000000) len 0x514
[  260.615000] Node is ino #787, version 22. Range 0xa800-0xb000
[  260.620000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.625000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.630000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.635000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1cad8 (005a4e5c,c7e1cacc)
[  260.640000] jffs2_scan_inode_node(): Node at 0x005a5370
[  260.650000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cad8 is (005a4e5c,c7e1cacc)
[  260.655000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cae4
(fffffffe becomes 005a5370,00000000) len 0x5a8
[  260.660000] Node is ino #787, version 23. Range 0xb000-0xb800
[  260.665000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.670000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.675000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.680000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1cae4 (005a5370,c7e1cad8)
[  260.685000] jffs2_scan_inode_node(): Node at 0x005a5918
[  260.690000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cae4 is (005a5370,c7e1cad8)
[  260.695000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1caf0
(fffffffe becomes 005a5918,00000000) len 0x57c
[  260.700000] Node is ino #787, version 24. Range 0xb800-0xc000
[  260.705000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.710000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.715000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.720000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1caf0 (005a5918,c7e1cae4)
[  260.725000] jffs2_scan_inode_node(): Node at 0x005a5e94
[  260.730000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1caf0 is (005a5918,c7e1cae4)
[  260.735000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cafc
(fffffffe becomes 005a5e94,00000000) len 0x3bc
[  260.740000] Node is ino #787, version 25. Range 0xc000-0xc800
[  260.745000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.750000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.755000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.760000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1cafc (005a5e94,c7e1caf0)
[  260.765000] jffs2_scan_inode_node(): Node at 0x005a6250
[  260.770000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cafc is (005a5e94,c7e1caf0)
[  260.775000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cb08
(fffffffe becomes 005a6250,00000000) len 0x3d0
[  260.780000] Node is ino #787, version 26. Range 0xc800-0xd000
[  260.785000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.790000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.795000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.800000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Allocating
new refblock linked from c7e1cb20
[  260.805000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1cb08 (005a6250,c7e1cafc)
[  260.810000] jffs2_scan_inode_node(): Node at 0x005a6620
[  260.815000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cb08 is (005a6250,c7e1cafc)
[  260.820000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1cb14
(fffffffe becomes 005a6620,00000000) len 0x3a0
[  260.825000] Node is ino #787, version 27. Range 0xd000-0xd800
[  260.830000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.835000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.840000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.845000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1cb14 (005a6620,c7e1cb08)
[  260.850000] jffs2_scan_inode_node(): Node at 0x005a69c0
[  260.855000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1cb14 is (005a6620,c7e1cb08)
[  260.860000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1c934
(fffffffe becomes 005a69c0,00000000) len 0x344
[  260.865000] Node is ino #787, version 28. Range 0xd800-0xe000
[  260.875000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.880000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.885000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.890000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1c934 (005a69c0,c7e1cb14)
[  260.895000] jffs2_scan_inode_node(): Node at 0x005a6d04
[  260.900000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1c934 is (005a69c0,c7e1cb14)
[  260.905000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1c940
(fffffffe becomes 005a6d04,00000000) len 0x38c
[  260.910000] Node is ino #787, version 29. Range 0xe000-0xe800
[  260.915000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.920000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.925000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.930000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1c940 (005a6d04,c7e1c934)
[  260.935000] jffs2_scan_inode_node(): Node at 0x005a7090
[  260.940000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1c940 is (005a6d04,c7e1c934)
[  260.945000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1c94c
(fffffffe becomes 005a7090,00000000) len 0x468
[  260.950000] Node is ino #787, version 30. Range 0xe800-0xf000
[  260.955000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  260.960000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  260.965000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  260.970000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1c94c (005a7090,c7e1c940)
[  260.980000] jffs2_scan_inode_node(): Node at 0x005a74f8
[  260.985000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1c94c is (005a7090,c7e1c940)
[  260.990000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1c958
(fffffffe becomes 005a74f8,00000000) len 0x380
[  260.995000] Node is ino #787, version 31. Range 0xf000-0xf800
[  261.000000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  261.005000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  261.010000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  261.015000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1c958 (005a74f8,c7e1c94c)
[  261.020000] jffs2_scan_inode_node(): Node at 0x005a7878
[  261.025000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1c958 is (005a74f8,c7e1c94c)
[  261.030000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1c964
(fffffffe becomes 005a7878,00000000) len 0x328
[  261.035000] Node is ino #787, version 32. Range 0xf800-0x10000
[  261.040000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  261.050000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  261.055000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  261.060000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1c964 (005a7878,c7e1c958)
[  261.065000] jffs2_scan_inode_node(): Node at 0x005a7ba0
[  261.070000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1c964 is (005a7878,c7e1c958)
[  261.075000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1c970
(fffffffe becomes 005a7ba0,00000000) len 0x160
[  261.080000] Node is ino #787, version 33. Range 0x10000-0x1028f
[  261.085000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (787) added to
summary
[  261.090000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  261.095000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  261.100000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1c970 (005a7ba0,c7e1c964)
[  261.110000] jffs2_scan_dirent_node(): Node at 0x005a7d00
[  261.115000] [JFFS2 DBG] (1) jffs2_alloc_full_dirent: c7e08e60
[  261.120000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1c970 is (005a7ba0,c7e1c964)
[  261.125000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1c97c
(fffffffe becomes 005a7d02,00000000) len 0x30
[  261.130000] [JFFS2 DBG] (1) jffs2_add_fd_to_list: add dirent
"iwgetid", ino #788
[  261.135000] [JFFS2 DBG] (1) jffs2_sum_add_mem: dirent (788) added to
summary
[  261.140000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  261.145000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  261.150000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1c97c (005a7d02,c7e1ccf4)
[  261.155000] jffs2_scan_inode_node(): Node at 0x005a7d30
[  261.160000] [JFFS2 DBG] (1) jffs2_alloc_inode_cache: c7e19d58
[  261.165000] [JFFS2 DBG] (1) jffs2_add_ino_cache: add c7e19d58 (ino #788)
[  261.170000] [JFFS2 DBG] (1) jffs2_link_node_ref: Last node at
c7e1c97c is (005a7d02,c7e1ccf4)
[  261.175000] [JFFS2 DBG] (1) jffs2_link_node_ref: New ref is c7e1c988
(fffffffe becomes 005a7d30,00000000) len 0x4c
[  261.180000] Node is ino #788, version 1. Range 0x0-0x8
[  261.185000] [JFFS2 DBG] (1) jffs2_sum_add_mem: inode (788) added to
summary
[  261.190000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: 2
[  261.195000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserving 2
refs for block @0x005a0000
[  261.200000] [JFFS2 DBG] (1) jffs2_prealloc_raw_node_refs: Reserved 2
refs for block @0x005a0000, last_node is c7e1c988 (005a7d30,c7e19d58)
[  261.205000] jffs2_scan_dirent_node(): Node at 0x005a7d7c

It means we saw all 33 versions of that inode, because none of them had
been garbage collected -- ever.  Lots of inodes have this "feature".
I'm all for lazy erase but is this normal?  Is it possible that we never
erased anything in JFFS2 for some time because it is broken and it all
seems to work just because of the incrementing version #?

Or did I miss the point somewhere?

- -Andy
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.7 (GNU/Linux)
Comment: Using GnuPG with Fedora - http://enigmail.mozdev.org

iD8DBQFHqZqROjLpvpq7dMoRAty1AKCL9wmXbQlaHeaXjvqI4wWobhSjhQCgjChS
Fn2MfH+XNU6Xjv5VUVvQDrk=
=mV5A
-----END PGP SIGNATURE-----




More information about the openmoko-kernel mailing list