IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+ee250a...@syzkaller.appspotmail.com Fixes: eede846af512 ("f2fs: f2fs_get_meta_page_nofail should not be failed")
INFO: task syz-executor178:6870 can't die for more than 143 seconds.
task:syz-executor178 state:R
stack:26960 pid: 6870 ppid: 6869 flags:0x00004006
Call Trace:
Showing all locks held in the system:
1 lock held by khungtaskd/1179:
#0: ffffffff8a554da0 (rcu_read_lock){....}-{1:2}, at: debug_show_all_locks+0x53/0x260 kernel/locking/lockdep.c:6242
1 lock held by systemd-journal/3920:
1 lock held by in:imklog/6769:
#0: ffff88809eebc130 (&f->f_pos_lock){+.+.}-{3:3}, at: __fdget_pos+0xe9/0x100 fs/file.c:930
1 lock held by syz-executor178/6870:
#0: ffff8880925120e0 (&type->s_umount_key#47/1){+.+.}-{3:3}, at: alloc_super+0x201/0xaf0 fs/super.c:229
=============================================
Kernel panic - not syncing: hung_task: blocked tasks
CPU: 0 PID: 1179 Comm: khungtaskd Not tainted 5.9.0-rc8-next-20201006-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Call Trace:
__dump_stack lib/dump_stack.c:77 [inline]
dump_stack+0x198/0x1fb lib/dump_stack.c:118
panic+0x382/0x7fb kernel/panic.c:231
check_hung_uninterruptible_tasks kernel/hung_task.c:257 [inline]
watchdog.cold+0x23e/0x248 kernel/hung_task.c:339
kthread+0x3af/0x4a0 kernel/kthread.c:292
ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296
Kernel Offset: disabled
Rebooting in 86400 seconds..
---
This report is generated by a bot. It may contain errors.
See https://goo.gl/tpsmEJ for more information about syzbot.
syzbot engineers can be reached at syzk...@googlegroups.com.
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Jaegeuk Kim, ch...@kernel.org, linux-f2...@lists.sourceforge.net, syzkall...@googlegroups.com, linux-...@vger.kernel.org, syzbot+ee250a...@syzkaller.appspotmail.com
Jaegeuk, it looks like the loop you added in the above commit doesn't terminate
if the requested page is beyond the end of the device.
- Eric
jae...@kernel.org
unread,
Oct 7, 2020, 5:53:07 PM10/7/20
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Eric Biggers, ch...@kernel.org, linux-f2...@lists.sourceforge.net, syzkall...@googlegroups.com, linux-...@vger.kernel.org, syzbot+ee250a...@syzkaller.appspotmail.com
Yes, that will go infinite loop. Otherwise, it will trigger a panic during
the device reboot. Let me think how to avoid that before trying to get the
wrong lba access.
>
> - Eric
Chao Yu
unread,
Oct 8, 2020, 9:42:07 PM10/8/20
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to jae...@kernel.org, Eric Biggers, syzbot+ee250a...@syzkaller.appspotmail.com, syzkall...@googlegroups.com, linux-...@vger.kernel.org, linux-f2...@lists.sourceforge.net
Delivering f2fs_get_sum_page()'s return value needs a lot of codes change, I think
we can just zeroing sum_page in error case, as we have already shutdown f2fs via
calling f2fs_stop_checkpoint(), then f2fs_cp_error() will stop all updates to
filesystem data including summary pages.
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Chao Yu, Eric Biggers, syzbot+ee250a...@syzkaller.appspotmail.com, syzkall...@googlegroups.com, linux-...@vger.kernel.org, linux-f2...@lists.sourceforge.net
That sounds like one solution tho, I'm afraid of getting another panic by
wrong zero'ed summary page.
Chao Yu
unread,
Oct 8, 2020, 10:37:07 PM10/8/20
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to jae...@kernel.org, Eric Biggers, syzbot+ee250a...@syzkaller.appspotmail.com, syzkall...@googlegroups.com, linux-...@vger.kernel.org, linux-f2...@lists.sourceforge.net
What case do you mean? maybe I missed some corner cases?
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Chao Yu, Eric Biggers, syzbot+ee250a...@syzkaller.appspotmail.com, syzkall...@googlegroups.com, linux-...@vger.kernel.org, linux-f2...@lists.sourceforge.net
I sent v2 to fix syzbot issue, which fixes wrong use of
f2fs_get_meta_page_nofail.
Chao Yu
unread,
Oct 9, 2020, 3:05:34 AM10/9/20
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to jae...@kernel.org, Eric Biggers, syzbot+ee250a...@syzkaller.appspotmail.com, syzkall...@googlegroups.com, linux-...@vger.kernel.org, linux-f2...@lists.sourceforge.net
I agreed to fix that case, however we may encounter deadloop in other
places where we call f2fs_get_meta_page_nofail()? like the case that
filesystem will always see EIO after we shutdown device via dmflakey?
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Chao Yu, Eric Biggers, syzbot+ee250a...@syzkaller.appspotmail.com, syzkall...@googlegroups.com, linux-...@vger.kernel.org, linux-f2...@lists.sourceforge.net
We may need another option to deal with this. At least, however, it's literally
_nofail function which should guarantee no error, instead of hiding the error
with zero'ed page.
Chao Yu
unread,
Oct 12, 2020, 10:30:41 PM10/12/20
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to jae...@kernel.org, Eric Biggers, syzbot+ee250a...@syzkaller.appspotmail.com, syzkall...@googlegroups.com, linux-...@vger.kernel.org, linux-f2...@lists.sourceforge.net
Jaegeuk,
I guess you missed sending last applied patch to mailing list?
Thanks,
> .
>
jae...@kernel.org
unread,
Oct 12, 2020, 11:08:48 PM10/12/20
Reply to author
Sign in to reply to author
Forward
Sign in to forward
Delete
You do not have permission to delete messages in this group
Copy link
Report message
Show original message
Either email addresses are anonymous for this group or you need the view member email addresses permission to view the original message
to Chao Yu, Eric Biggers, syzbot+ee250a...@syzkaller.appspotmail.com, syzkall...@googlegroups.com, linux-...@vger.kernel.org, linux-f2...@lists.sourceforge.net
On 10/13, Chao Yu wrote:
> Jaegeuk,
>
> I guess you missed sending last applied patch to mailing list?
I was testing locally and supposed to post it soon before pull request. Putting
it in -dev can give some soak time in -next.