mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Edward Adam Davis <eadavis@qq.com>
To: syzbot+ddf8715339c89280b6fc@syzkaller.appspotmail.com
Cc: jack@suse.com, linux-kernel@vger.kernel.org,
	syzkaller-bugs@googlegroups.com
Subject: Re: [syzbot] [udf?] general protection fault in udf_read_folio
Date: Sun, 22 Sep 2024 12:56:56 +0800	[thread overview]
Message-ID: <tencent_8F67C9C6DBD2F6867309802EEE2ED84C8406@qq.com> (raw)
In-Reply-To: <66eefd0c.050a0220.3195df.0061.GAE@google.com>

In erofs_bread(),
	folio = read_mapping_folio(buf->mapping, index, NULL);
file is NULL, it triger this issue.

#syz test

diff --git a/fs/udf/inode.c b/fs/udf/inode.c
index 4726a4d014b6..fb8121edee8f 100644
--- a/fs/udf/inode.c
+++ b/fs/udf/inode.c
@@ -220,7 +220,7 @@ static void udf_adinicb_read_folio(struct folio *folio)
 
 static int udf_read_folio(struct file *file, struct folio *folio)
 {
-	struct udf_inode_info *iinfo = UDF_I(file_inode(file));
+	struct udf_inode_info *iinfo = UDF_I(folio->mapping->host);
 
 	if (iinfo->i_alloc_type == ICBTAG_FLAG_AD_IN_ICB) {
 		udf_adinicb_read_folio(folio);


  reply	other threads:[~2024-09-22  5:03 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-09-21 17:06 syzbot
2024-09-22  4:56 ` Edward Adam Davis [this message]
2024-09-22  5:17   ` syzbot
2024-10-21 23:47 ` [syzbot] retest repro if bug still valid syzbot
     [not found] <40b42775-ca29-4c63-b13c-7b02911379a1@gmail.com>
2024-10-22  0:04 ` [syzbot] [udf?] general protection fault in udf_read_folio syzbot
2024-10-22  0:19   ` Gianfranco Trad
2024-10-22  9:02     ` Jan Kara

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=tencent_8F67C9C6DBD2F6867309802EEE2ED84C8406@qq.com \
    --to=eadavis@qq.com \
    --cc=jack@suse.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=syzbot+ddf8715339c89280b6fc@syzkaller.appspotmail.com \
    --cc=syzkaller-bugs@googlegroups.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

all inboxes | Powered by JetHome®