public inbox for linux-fsdevel@vger.kernel.org
 help / color / mirror / Atom feed
From: Chao Yu <chao@kernel.org>
To: Dmitry Antipov <dmantipov@yandex.ru>
Cc: Chao Yu <chao@kernel.org>, Jaegeuk Kim <jaegeuk@kernel.org>,
	linux-f2fs-devel@lists.sourceforge.net,
	linux-fsdevel@vger.kernel.org, lvc-project@linuxtesting.org,
	syzbot+5141f6db57a2f7614352@syzkaller.appspotmail.com
Subject: Re: [PATCH v2] f2fs: ensure that node info flags are always initialized
Date: Mon, 16 Dec 2024 21:47:27 +0800	[thread overview]
Message-ID: <c1022c8c-7b7f-4efd-aa11-281cc7b58f2c@kernel.org> (raw)
In-Reply-To: <20241212175748.1750854-1-dmantipov@yandex.ru>

On 2024/12/13 1:57, Dmitry Antipov wrote:
> Syzbot has reported the following KMSAN splat:
> 
> BUG: KMSAN: uninit-value in f2fs_new_node_page+0x1494/0x1630
>   f2fs_new_node_page+0x1494/0x1630
>   f2fs_new_inode_page+0xb9/0x100
>   f2fs_init_inode_metadata+0x176/0x1e90
>   f2fs_add_inline_entry+0x723/0xc90
>   f2fs_do_add_link+0x48f/0xa70
>   f2fs_symlink+0x6af/0xfc0
>   vfs_symlink+0x1f1/0x470
>   do_symlinkat+0x471/0xbc0
>   __x64_sys_symlink+0xcf/0x140
>   x64_sys_call+0x2fcc/0x3d90
>   do_syscall_64+0xd9/0x1b0
>   entry_SYSCALL_64_after_hwframe+0x77/0x7f
> 
> Local variable new_ni created at:
>   f2fs_new_node_page+0x9d/0x1630
>   f2fs_new_inode_page+0xb9/0x100
> 
> So adjust 'f2fs_get_node_info()' to ensure that 'flag'
> field of 'struct node_info' is always initialized.
> 
> Reported-by: syzbot+5141f6db57a2f7614352@syzkaller.appspotmail.com
> Closes: https://syzkaller.appspot.com/bug?extid=5141f6db57a2f7614352
> Fixes: e05df3b115e7 ("f2fs: add node operations")
> Suggested-by: Chao Yu <chao@kernel.org>
> Signed-off-by: Dmitry Antipov <dmantipov@yandex.ru>

Reviewed-by: Chao Yu <chao@kernel.org>

Thanks,

  reply	other threads:[~2024-12-16 13:47 UTC|newest]

Thread overview: 5+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-04  6:09 [PATCH] f2fs: ensure that node info flags are always initialized Dmitry Antipov
2024-12-12 14:59 ` Chao Yu
2024-12-12 17:57   ` [PATCH v2] " Dmitry Antipov
2024-12-16 13:47     ` Chao Yu [this message]
2024-12-16 16:40     ` [f2fs-dev] " patchwork-bot+f2fs

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=c1022c8c-7b7f-4efd-aa11-281cc7b58f2c@kernel.org \
    --to=chao@kernel.org \
    --cc=dmantipov@yandex.ru \
    --cc=jaegeuk@kernel.org \
    --cc=linux-f2fs-devel@lists.sourceforge.net \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=lvc-project@linuxtesting.org \
    --cc=syzbot+5141f6db57a2f7614352@syzkaller.appspotmail.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox