Hi Jaegeuk, 01.09.2016, 23:16, "Jaegeuk Kim" <[email protected]>: > On Thu, Sep 01, 2016 at 10:37:36PM +0300, Alexander Gordeev wrote: >> Hi , >> >> 01.09.2016, 21:25, "Jaegeuk Kim" <[email protected]>: >> > Hello, >> > >> > On Thu, Sep 01, 2016 at 08:40:07PM +0300, Alexander Gordeev wrote: >> > ... >> >> >> [ 49.274678] ------------[ cut here ]------------ >> >> >> [ 49.280216] WARNING: at >> /home/alex/work/s2l/amb_S2l_SDK_2.5/SDK2.5/s2l_linux_sdk/ambarella/kernel/linux-3.10/fs/f2fs/segment.c:1105 >> new_curseg+0x268/0x394 [f2fs]() >> >> > >> >> > This means there is no free segment. >> >> > Could you print out the below information before this f2fs_bug_on? >> >> > - prefree_segments(sbi) >> >> > - free_segments(sbi) >> >> > >> >> >> ... >> >> >> [ 49.518054] ---[ end trace 49dca462b4f988ff ]--- >> >> >> [ 49.522689] ------------[ cut here ]------------ >> >> >> [ 49.527375] WARNING: at >> /home/alex/work/s2l/amb_S2l_SDK_2.5/SDK2.5/s2l_linux_sdk/ambarella/kernel/linux-3.10/fs/f2fs/segment.c:1144 >> new_curseg+0x2f0/0x394 [f2fs]() >> >> > >> >> > This is caused by the above segno which was -1. >> >> > >> >> >> ... >> >> >> [ 49.764853] ---[ end trace 49dca462b4f98900 ]--- >> >> >> [ 49.857344] ------ segno = 7540, next_blkoff = 0, next_segno = >> 4294967295 -------- >> >> >> [ 49.913664] ------ blkaddr = 3889152 -------- >> >> >> [ 49.918173] Unable to handle kernel NULL pointer dereference at >> virtual address 00000000 >> >> > >> >> > Also, we can see next_segno was -1, which incur no se entry for this >> segment. >> >> > At this moment, I'd really like to see its >> /sys/kernel/debug/f2fs/status whether >> >> > there is really not enough free segments. >> >> >> >> I collected both /sys/kernel/debug/f2fs/status and numbers of blocks. >> >> The oops happens only when I try to delete anything. Also it can be >> caused >> >> by GC, but I turned background GC off. So I mounted the fs, dumped the >> status >> >> and then tried to remove a file. Here is what I got: >> >> >> >> =====[ partition info(sda). #0, RW]===== >> >> [SB: 1] [CP: 2] [SIT: 2] [NAT: 34] [SSA: 16] [MAIN: 7540(OverProv:424 >> Resv:50)] >> > >> > Could you check your mkfs.f2fs version? >> > I want to check ovp and resv numbers. >> >> I currently used mkfs.f2fs from my board's SDK. It prints this: >> F2FS-tools: mkfs.f2fs Ver: 1.4.1 (2015-03-04) >> >> Should I upgrade it? >> I think the problem will go away if I recreate the FS. At the moment >> it reproduces every time. I wonder if we need it again. > > Yes, please upgrade to the latest version to make sure. > And, it needs to format it again. > Seems there is no further information that we can use from the old partition.
Ok, thanks! I upgraded f2fs-tools and recreated the FS. Works fine so far! Still IMHO this might be a problem, if someone with a specially crafted FS on a USB stick can cause a kernel oops on any modern Linux system. Isn't it? -- Alexander ------------------------------------------------------------------------------ _______________________________________________ Linux-f2fs-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/linux-f2fs-devel
