UBIFS reboots issue

Boaz Ben-David boaz.bd at wellsense-tech.com
Wed Dec 22 12:35:32 EST 2010


Ok, got it.

Here is the ubiattach and mount outputs:

attaching mtd7 to ubi2
UBI: physical eraseblock size:   524288 bytes (512 KiB)
UBI: logical eraseblock size:    516096 bytes
UBI: smallest flash I/O unit:    4096
UBI: VID header offset:          4096 (aligned 4096)
UBI: data offset:                8192
UBI: attached mtd7 to ubi2
UBI: MTD device name:            "nand.db"
UBI: MTD device size:            1648 MiB
UBI: number of good PEBs:        3291
UBI: number of bad PEBs:         5
UBI: max. allowed volumes:       128
UBI: wear-leveling threshold:    4096
UBI: number of internal volumes: 1
UBI: number of user volumes:     1
UBI: available PEBs:             0
UBI: total number of reserved PEBs: 3291
UBI: number of PEBs reserved for bad PEB handling: 32
UBI: max/mean erase counter: 237/11
UBI: image sequence number: 0
UBI: background thread "ubi_bgt2d" started, PID 1326
UBI device number 2, total 3291 LEBs (1698471936 bytes, 1.6 GiB),
available 0 LEBs (0 bytes), LEB size 516096 bytes (504.0 KiB)
UBIFS: recovery needed
UnCorrectable RS-ECC Error
UBI error: ubi_io_read: error -74 while reading 516096 bytes from PEB
2237:8192, read 516096 bytes
UBIFS error (pid 1328): ubifs_check_node: bad node length 9
UBIFS error (pid 1328): ubifs_check_node: bad node at LEB 244:360448
Unable to handle kernel paging request at virtual address c93d5000
pgd = c56a8000
[c93d5000] *pgd=85618011, *pte=00000000, *ppte=00000000
Internal error: Oops: 7 [#1] PREEMPT
Modules linked in:
CPU: 0    Not tainted  (2.6.31-207-g7286c01-hg639121a71164-dirty #49)
PC is at hex_dump_to_buffer+0x164/0x270
LR is at hex_dump_to_buffer+0x48/0x270
pc : [<c03bb9a4>]    lr : [<c03bb888>]    psr: 80000013
sp : c56c9a80  ip : 0000000f  fp : 00000000
r10: 000000c8  r9 : 00000001  r8 : c56c9ac8
r7 : 00000020  r6 : c93d4ff0  r5 : 00000020  r4 : 00000030
r3 : 00000010  r2 : 00000033  r1 : c56c9afb  r0 : 00000020
Flags: Nzcv  IRQs on  FIQs on  Mode SVC_32  ISA ARM  Segment user
Control: 00c5387d  Table: 856a8008  DAC: 00000015
Process mount (pid: 1328, stack limit = 0xc56c8268)
Stack: (0xc56c9a80 to 0xc56ca000)
9a80: c93d4ff0 fffda019 00000020 00000020 00025fc0 c93d4ff0 c56c9ac8
c0627fe8 
9aa0: fffda019 c06450d3 00000002 c03bbb20 c56c9ac8 000000c8 00000000
c062e3f8 
9ac0: ffffffd8 00000000 66206666 66662066 20666620 66206666 66662066
20666620 
9ae0: 66206666 66662066 20666620 66206666 66662066 20666620 66206666
66662066 
9b00: 20666620 66206666 66662066 20666620 66206666 66662066 20666620
66206666 
9b20: 66662066 00666620 c56c9b30 c025630c ffffffff 60000013 ffffffff
ffffffff 
9b40: 00000000 00000000 ffffffff 0000000a ffffffff ffffffff 00000000
c56c9bf0 
9b60: 0000a78f c06f81dc 00058000 000000f4 c56ad3e0 c93af030 ffffffd9
c5312000 
9b80: 00058000 000000f4 c56ad3e0 00000000 00000009 c93af030 ffffffd9
c5312000 
9ba0: 00058000 000000f4 c56ad3e0 00000000 00000009 c03903ac 00000001
c93af030 
9bc0: ffffffd9 00000000 00000050 000000f4 c0694378 c93af000 ffffffea
c5312000 
9be0: 00058000 000000f4 c56ad3e0 00000000 0000004b 2000a78f c93af000
ffffffea 
9c00: c5312000 00058000 000000f4 c56ad3e0 00000000 c0366dc8 00058000
c93af000 
9c20: 06101831 c93af000 00058000 c5312000 000000f4 c036edf0 00000000
00000001 
9c40: c5312000 c93af000 c56c8000 000000f4 fffffffd c56ad3e0 00058000
c03865b0 
9c60: 00058000 00000000 00000000 00000000 c9357000 00026000 00000001
00058000 
9c80: c93af000 00026000 c0694378 c56c8000 00000000 c5312000 00000000
c59615a4 
9ca0: 00000002 000000f4 c56ad520 c036f7b8 00000001 c069f3b8 004f4dfa
00000000 
9cc0: 00000000 c56c9d44 00000000 00000000 0a78dace 00000000 00000020
c04348f4 
9ce0: 00000001 c596159c 00000040 00000000 004f4cbf 00000000 c5312844
00000000 
9d00: c56ad3e8 c5312850 00000002 c5960c9c 004f4daf 00000000 00000005
0000004b 
9d20: 0005a000 00000040 00078380 00000000 00000000 00000000 c56c8000
c036f21c 
9d40: 00000000 00000000 00000000 c5312000 c56c8000 c56ad3e8 c56ad3e0
00000005 
9d60: c56ad540 00000001 c5312850 c0370c5c 00000032 00000000 c56c9dec
c57c1400 
9d80: 00000400 c02b8898 c56c9da4 c02b8900 c56ad3a0 c02b8a04 00000400
00000000 
9da0: c56ad3e0 c57c15f8 c531276c c56ad3e8 c94e0000 00000001 00079000
00000002 
9dc0: c56c9de8 c02b8be8 00000020 c5312850 00000165 00000000 004f4dfc
00000000 
9de0: 00000000 00000001 c945a00c 00000000 00001000 c53126e0 c5312000
00000000 
9e00: c5320800 00000000 00000001 00000000 c531271c c0362f88 00000000
00000005 
9e20: c5320964 c0626c44 c06ed480 c5320964 00000005 c03b8bd8 c56c9e50
c56c8000 
9e40: 00000000 c06a80b0 c5320800 c02c77d0 c5216800 00000002 00000007
c5312724 
9e60: 00000003 c5312008 c5216800 c56ad1c0 c5320800 00008000 c06a80b0
c56c9edc 
9e80: c56b0000 c06a97f4 c56c9f48 c036448c c56c8000 c03b426c 00000002
00000000 
9ea0: 00000cb7 c02dca68 64212000 00000000 c569e000 00000003 00000000
00000000 
9ec0: 00000001 0007e000 00000004 c5320524 0f600001 c06eda30 c569e000
c569e005 
9ee0: c7f6c900 c569e000 c56b0000 00008000 c06a80b0 c7f06000 00008000
c02c6a30 
9f00: c7f6c900 00008000 c06a80b0 c7f06000 c56b0000 c569e000 00008000
c02c6ac0 
9f20: 00000000 00000020 c569e000 00008000 c56b0000 c02ddc40 c56c9f8c
c56c8000 
9f40: 00000003 00000000 c7e20000 c627c080 c029e408 c5317000 bef7ce39
00008000 
9f60: 00000000 c0232f44 c56c8000 00000003 00000000 c02ddd38 c56b0000
000a1000 
9f80: 000c2000 c569e000 c7f06000 c56b0000 bef7cb18 000a1018 bef7cb18
400214d0 
9fa0: 00000015 c0232dc0 000a1018 bef7cb18 bef7ce39 bef7ce43 bef7ce33
00008000 
9fc0: 000a1018 bef7cb18 400214d0 00000015 00000000 00000000 00000003
00000000 
9fe0: 000a1018 bef7ca34 0004076c 40101634 60000010 bef7ce39 00000000
00000000 
[<c03bb9a4>] (hex_dump_to_buffer+0x164/0x270) from [<c03bbb20>]
(print_hex_dump+0x70/0xf8)
[<c03bbb20>] (print_hex_dump+0x70/0xf8) from [<c03903ac>] (dbg_dump_node
+0xf50/0x13cc)
[<c03903ac>] (dbg_dump_node+0xf50/0x13cc) from [<c0366dc8>]
(ubifs_check_node+0x290/0x2e8)
[<c0366dc8>] (ubifs_check_node+0x290/0x2e8) from [<c036edf0>]
(ubifs_scan_a_node+0x21c/0x3d4)
[<c036edf0>] (ubifs_scan_a_node+0x21c/0x3d4) from [<c03865b0>]
(ubifs_recover_leb+0x16c/0xacc)
[<c03865b0>] (ubifs_recover_leb+0x16c/0xacc) from [<c036f7b8>]
(replay_buds+0xdc/0xb50)
[<c036f7b8>] (replay_buds+0xdc/0xb50) from [<c0370c5c>]
(ubifs_replay_journal+0xa30/0x127c)
[<c0370c5c>] (ubifs_replay_journal+0xa30/0x127c) from [<c0362f88>]
(ubifs_fill_super+0xc50/0x1e70)
[<c0362f88>] (ubifs_fill_super+0xc50/0x1e70) from [<c036448c>]
(ubifs_get_sb+0x2e4/0x358)
[<c036448c>] (ubifs_get_sb+0x2e4/0x358) from [<c02c6a30>]
(vfs_kern_mount+0x4c/0x98)
[<c02c6a30>] (vfs_kern_mount+0x4c/0x98) from [<c02c6ac0>] (do_kern_mount
+0x34/0xd8)
[<c02c6ac0>] (do_kern_mount+0x34/0xd8) from [<c02ddc40>] (do_mount
+0x710/0x784)
[<c02ddc40>] (do_mount+0x710/0x784) from [<c02ddd38>] (sys_mount
+0x84/0xcc)
[<c02ddd38>] (sys_mount+0x84/0xcc) from [<c0232dc0>] (ret_fast_syscall
+0x0/0x2c)
Code: e1570009 bafffff0 e3a07005 ea000013 (e7d6c003) 
---[ end trace 977c7948905d1436 ]---
note: mount[1328] exited with preempt_count 2
BUG: scheduling while atomic: mount/1328/0x40000002
Modules linked in:
[<c02375f8>] (unwind_backtrace+0x0/0xd0) from [<c0563f80>] (schedule
+0x78/0x3e4)
[<c0563f80>] (schedule+0x78/0x3e4) from [<c024f4d8>] (__cond_resched
+0x24/0x40)
[<c024f4d8>] (__cond_resched+0x24/0x40) from [<c05643b8>] (_cond_resched
+0x30/0x40)
[<c05643b8>] (_cond_resched+0x30/0x40) from [<c02b0238>] (unmap_vmas
+0x528/0x5d8)
[<c02b0238>] (unmap_vmas+0x528/0x5d8) from [<c02b2ce8>] (exit_mmap
+0xac/0x198)
[<c02b2ce8>] (exit_mmap+0xac/0x198) from [<c0252ff4>] (mmput+0x38/0xf8)
[<c0252ff4>] (mmput+0x38/0xf8) from [<c0256bb4>] (exit_mm+0x140/0x144)
[<c0256bb4>] (exit_mm+0x140/0x144) from [<c0258260>] (do_exit
+0x15c/0x6bc)
[<c0258260>] (do_exit+0x15c/0x6bc) from [<c0236500>] (die+0x168/0x188)
[<c0236500>] (die+0x168/0x188) from [<c02385c4>] (__do_kernel_fault
+0x64/0x74)
[<c02385c4>] (__do_kernel_fault+0x64/0x74) from [<c02387e8>]
(do_page_fault+0x214/0x230)
[<c02387e8>] (do_page_fault+0x214/0x230) from [<c023225c>] (do_DataAbort
+0x30/0x94)
[<c023225c>] (do_DataAbort+0x30/0x94) from [<c02329ec>] (__dabt_svc
+0x4c/0x60)
Exception stack(0xc56c9a38 to 0xc56c9a80)
9a20:                                                       00000020
c56c9afb 
9a40: 00000033 00000010 00000030 00000020 c93d4ff0 00000020 c56c9ac8
00000001 
9a60: 000000c8 00000000 0000000f c56c9a80 c03bb888 c03bb9a4 80000013
ffffffff 
[<c02329ec>] (__dabt_svc+0x4c/0x60) from [<c03bb9a4>]
(hex_dump_to_buffer+0x164/0x270)
[<c03bb9a4>] (hex_dump_to_buffer+0x164/0x270) from [<c03bbb20>]
(print_hex_dump+0x70/0xf8)
[<c03bbb20>] (print_hex_dump+0x70/0xf8) from [<c03903ac>] (dbg_dump_node
+0xf50/0x13cc)
[<c03903ac>] (dbg_dump_node+0xf50/0x13cc) from [<c0366dc8>]
(ubifs_check_node+0x290/0x2e8)
[<c0366dc8>] (ubifs_check_node+0x290/0x2e8) from [<c036edf0>]
(ubifs_scan_a_node+0x21c/0x3d4)
[<c036edf0>] (ubifs_scan_a_node+0x21c/0x3d4) from [<c03865b0>]
(ubifs_recover_leb+0x16c/0xacc)
[<c03865b0>] (ubifs_recover_leb+0x16c/0xacc) from [<c036f7b8>]
(replay_buds+0xdc/0xb50)
[<c036f7b8>] (replay_buds+0xdc/0xb50) from [<c0370c5c>]
(ubifs_replay_journal+0xa30/0x127c)
[<c0370c5c>] (ubifs_replay_journal+0xa30/0x127c) from [<c0362f88>]
(ubifs_fill_super+0xc50/0x1e70)
[<c0362f88>] (ubifs_fill_super+0xc50/0x1e70) from [<c036448c>]
(ubifs_get_sb+0x2e4/0x358)
[<c036448c>] (ubifs_get_sb+0x2e4/0x358) from [<c02c6a30>]
(vfs_kern_mount+0x4c/0x98)
[<c02c6a30>] (vfs_kern_mount+0x4c/0x98) from [<c02c6ac0>] (do_kern_mount
+0x34/0xd8)
[<c02c6ac0>] (do_kern_mount+0x34/0xd8) from [<c02ddc40>] (do_mount
+0x710/0x784)
[<c02ddc40>] (do_mount+0x710/0x784) from [<c02ddd38>] (sys_mount
+0x84/0xcc)
[<c02ddd38>] (sys_mount+0x84/0xcc) from [<c0232dc0>] (ret_fast_syscall
+0x0/0x2c)

Thanks!



On Wed, 2010-12-22 at 19:32 +0200, Boaz Ben-David wrote:
> I can't seem to post back...
> 
> On Wed, 2010-12-22 at 16:36 +0200, Boaz Ben-David wrote:
> > Hi all,
> > 
> > We have an embedded system using a Samsung 2GB MLC NAND and are using
> > UBIFS as the file system on it.
> > I have a question regarding UBIFS and hard reboots.
> > After some work with the flash (doing reads and writes to it), some
> > times one of our partitions would fail to mount.
> > I suspected this has something to do with a reboot which happens during
> > a write to the flash.
> > In order to test this I created a simple script which copies a file from
> > to the partition, syncs, then deletes it and does this repeatedly until 
> > a hard reboot occurs (using the watch dog to cause the boot).
> > This process repeats itself until the partition fails to mount.
> > When I performed the test mentioned above, after about 3-4 times the
> > partition would fail.
> > I am not sure if this behaviour is normal or not.
> > Did someone encounter similiar behaviour?
> > 
> > Thanks,
> > 
> > Boaz. 
> > ______________________________________________________
> > Linux MTD discussion mailing list
> > http://lists.infradead.org/mailman/listinfo/linux-mtd/
> 
> ______________________________________________________
> Linux MTD discussion mailing list
> http://lists.infradead.org/mailman/listinfo/linux-mtd/



More information about the linux-mtd mailing list