mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: David Hildenbrand <david@redhat.com>
To: syzbot <syzbot+3d7dc5eaba6b932f8535@syzkaller.appspotmail.com>,
	linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org,
	syzkaller-bugs@googlegroups.com
Subject: Re: [syzbot] [fs?] kernel BUG in kpagecount_read
Date: Fri, 10 Jan 2025 16:09:11 +0100	[thread overview]
Message-ID: <500b62d9-8e09-4838-9817-1e2e2216dcdd@redhat.com> (raw)
In-Reply-To: <67812fbd.050a0220.d0267.0030.GAE@google.com>

On 10.01.25 15:33, syzbot wrote:
> Hello,
> 
> syzbot found the following issue on:
> 
> HEAD commit:    c061cf420ded Merge tag 'trace-v6.13-rc3' of git://git.kern..
> git tree:       upstream
> console output: https://syzkaller.appspot.com/x/log.txt?x=11ee22df980000
> kernel config:  https://syzkaller.appspot.com/x/.config?x=c22efbd20f8da769
> dashboard link: https://syzkaller.appspot.com/bug?extid=3d7dc5eaba6b932f8535
> compiler:       gcc (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40
> 
> Unfortunately, I don't have any reproducer for this issue yet.
> 
> Downloadable assets:
> disk image: https://storage.googleapis.com/syzbot-assets/565ec42c1d1a/disk-c061cf42.raw.xz
> vmlinux: https://storage.googleapis.com/syzbot-assets/142d1c3a6f99/vmlinux-c061cf42.xz
> kernel image: https://storage.googleapis.com/syzbot-assets/b21efab0a38b/bzImage-c061cf42.xz
> 
> IMPORTANT: if you fix the issue, please add the following tag to the commit:
> Reported-by: syzbot+3d7dc5eaba6b932f8535@syzkaller.appspotmail.com
> 
>   __napi_poll.constprop.0+0xb7/0x550 net/core/dev.c:6883
>   napi_poll net/core/dev.c:6952 [inline]
>   net_rx_action+0xa94/0x1010 net/core/dev.c:7074
>   handle_softirqs+0x213/0x8f0 kernel/softirq.c:561
>   __do_softirq kernel/softirq.c:595 [inline]
>   invoke_softirq kernel/softirq.c:435 [inline]
>   __irq_exit_rcu+0x109/0x170 kernel/softirq.c:662
>   irq_exit_rcu+0x9/0x30 kernel/softirq.c:678
>   common_interrupt+0xbf/0xe0 arch/x86/kernel/irq.c:278
>   asm_common_interrupt+0x26/0x40 arch/x86/include/asm/idtentry.h:693
> ------------[ cut here ]------------
> kernel BUG at ./include/linux/mm.h:1221!
> Oops: invalid opcode: 0000 [#1] PREEMPT SMP KASAN PTI
> CPU: 1 UID: 0 PID: 11868 Comm: syz.3.1633 Tainted: G     U             6.13.0-rc3-syzkaller-00062-gc061cf420ded #0
> Tainted: [U]=USER
> Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 11/25/2024
> RIP: 0010:folio_entire_mapcount include/linux/mm.h:1221 [inline]
> RIP: 0010:folio_precise_page_mapcount fs/proc/internal.h:172 [inline]
> RIP: 0010:kpagecount_read+0x477/0x570 fs/proc/page.c:71
> Code: 31 ff 49 29 c4 48 8b 44 24 08 4c 01 20 e8 41 77 61 ff eb 92 e8 ca 74 61 ff 48 8b 3c 24 48 c7 c6 20 eb 61 8b e8 6a 34 a8 ff 90 <0f> 0b 4c 89 ff e8 ef de c3 ff e9 5a ff ff ff e8 a5 74 61 ff 48 8b

Kind of known (at least to me :) ).

We race with splitting the large folio and end up in
	VM_BUG_ON_FOLIO(!folio_test_large(folio), folio);

We could take a speculative reference on the folio to prevent the 
concurrent split ... but I am not really sure it is worth it.

-- 
Cheers,

David / dhildenb


  reply	other threads:[~2025-01-10 15:09 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-01-10 14:33 syzbot
2025-01-10 15:09 ` David Hildenbrand [this message]
2025-01-10 15:18   ` 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=500b62d9-8e09-4838-9817-1e2e2216dcdd@redhat.com \
    --to=david@redhat.com \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=syzbot+3d7dc5eaba6b932f8535@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®