public inbox for linux-kernel@vger.kernel.org
 help / color / mirror / Atom feed
From: Hillf Danton <hdanton@sina.com>
To: syzbot <syzbot+c0673e1f1f054fac28c2@syzkaller.appspotmail.com>
Cc: linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com
Subject: Re: [syzbot] [mm?] WARNING in __folio_rmap_sanity_checks (2)
Date: Sun, 29 Dec 2024 14:42:10 +0800	[thread overview]
Message-ID: <20241229064212.638-1-hdanton@sina.com> (raw)
In-Reply-To: <676f84f5.050a0220.2f3838.0493.GAE@google.com>

On Fri, 27 Dec 2024 20:56:21 -0800
> syzbot has found a reproducer for the following issue on:
> 
> HEAD commit:    8155b4ef3466 Add linux-next specific files for 20241220
> git tree:       linux-next
> syz repro:      https://syzkaller.appspot.com/x/repro.syz?x=1652fadf980000

#syz test

--- x/mm/filemap.c
+++ y/mm/filemap.c
@@ -3636,6 +3636,7 @@ static vm_fault_t filemap_map_folio_rang
 		continue;
 skip:
 		if (count) {
+			VM_WARN_ON_FOLIO(page_folio(page) != folio, folio);
 			set_pte_range(vmf, folio, page, count, addr);
 			*rss += count;
 			folio_ref_add(folio, count);
@@ -3739,7 +3740,7 @@ vm_fault_t filemap_map_pages(struct vm_f
 		vmf->pte += xas.xa_index - last_pgoff;
 		last_pgoff = xas.xa_index;
 		end = folio_next_index(folio) - 1;
-		nr_pages = min(end, end_pgoff) - xas.xa_index + 1;
+		nr_pages = min(end, end_pgoff) - xas.xa_index;
 
 		if (!folio_test_large(folio))
 			ret |= filemap_map_order0_folio(vmf,
--

  parent reply	other threads:[~2024-12-29  6:42 UTC|newest]

Thread overview: 38+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-12-11  1:54 [syzbot] [mm?] WARNING in __folio_rmap_sanity_checks (2) syzbot
2024-12-11 10:06 ` David Hildenbrand
2024-12-28  4:56 ` syzbot
2024-12-28  7:54   ` Hillf Danton
2024-12-28  8:03     ` syzbot
2024-12-28 10:36   ` Hillf Danton
2024-12-28 12:20     ` syzbot
2024-12-29  0:00   ` Hillf Danton
2024-12-29  1:14     ` syzbot
2024-12-29  6:42   ` Hillf Danton [this message]
2024-12-29  7:13     ` syzbot
2024-12-30 10:40   ` Hillf Danton
2024-12-30 11:08     ` syzbot
2024-12-30 11:17   ` Hillf Danton
2024-12-30 11:49     ` syzbot
2024-12-30 12:02   ` Hillf Danton
2024-12-30 12:20     ` syzbot
2024-12-31  8:41   ` Hillf Danton
2024-12-31  9:09     ` syzbot
2025-01-10 16:35     ` David Hildenbrand
2025-01-11  1:00       ` Hillf Danton
2025-01-11 10:03         ` David Hildenbrand
2024-12-28 12:25 ` syzbot
2025-01-10 15:48   ` David Hildenbrand
2025-01-10 16:14     ` Matthew Wilcox
2025-01-10 16:19       ` David Hildenbrand
2025-01-10 16:27         ` Matthew Wilcox
2025-01-10 16:31           ` David Hildenbrand
2025-01-10 19:55             ` Liam R. Howlett
2025-01-10 21:24               ` Suren Baghdasaryan
2025-01-11  4:29                 ` Liam R. Howlett
2025-01-10 21:03   ` Liam R. Howlett
2025-01-11  6:15     ` syzbot
2025-01-11  9:25     ` David Hildenbrand
2025-01-11  9:54       ` syzbot
2025-01-13 15:39         ` David Hildenbrand
2025-01-13 15:45           ` Liam R. Howlett
2025-01-13 15:50             ` David Hildenbrand

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=20241229064212.638-1-hdanton@sina.com \
    --to=hdanton@sina.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=syzbot+c0673e1f1f054fac28c2@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