* [syzbot] [bcachefs?] UBSAN: shift-out-of-bounds in __btree_node_pinned
@ 2024-10-02 10:54 syzbot
2024-10-04 19:54 ` [syzbot] " syzbot
` (3 more replies)
0 siblings, 4 replies; 5+ messages in thread
From: syzbot @ 2024-10-02 10:54 UTC (permalink / raw)
To: kent.overstreet, linux-bcachefs, linux-kernel, syzkaller-bugs
Hello,
syzbot found the following issue on:
HEAD commit: ad46e8f95e93 Merge tag 'pm-6.12-rc1-2' of git://git.kernel..
git tree: upstream
console output: https://syzkaller.appspot.com/x/log.txt?x=13b3d507980000
kernel config: https://syzkaller.appspot.com/x/.config?x=62086b2fd100a029
dashboard link: https://syzkaller.appspot.com/bug?extid=9f41e4b255897d99d4e9
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=11b69e80580000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=1567c6a9980000
Downloadable assets:
disk image (non-bootable): https://storage.googleapis.com/syzbot-assets/7feb34a89c2a/non_bootable_disk-ad46e8f9.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/72b7539cbeb1/vmlinux-ad46e8f9.xz
kernel image: https://storage.googleapis.com/syzbot-assets/73c9b9cebaf4/bzImage-ad46e8f9.xz
mounted in repro: https://storage.googleapis.com/syzbot-assets/54e2032c8f9d/mount_0.gz
IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+9f41e4b255897d99d4e9@syzkaller.appspotmail.com
------------[ cut here ]------------
UBSAN: shift-out-of-bounds in fs/bcachefs/btree_cache.c:198:18
shift exponent 227 is too large for 64-bit type 'unsigned long long'
CPU: 0 UID: 0 PID: 5109 Comm: read_btree_node Not tainted 6.11.0-syzkaller-11728-gad46e8f95e93 #0
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014
Call Trace:
<TASK>
__dump_stack lib/dump_stack.c:94 [inline]
dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120
ubsan_epilogue lib/ubsan.c:231 [inline]
__ubsan_handle_shift_out_of_bounds+0x3c8/0x420 lib/ubsan.c:468
__btree_node_pinned+0x80b/0x850 fs/bcachefs/btree_cache.c:198
__bch2_btree_node_hash_insert+0xcfd/0x13e0 fs/bcachefs/btree_cache.c:270
bch2_btree_node_hash_insert fs/bcachefs/btree_cache.c:287 [inline]
bch2_btree_node_fill+0x94e/0x1200 fs/bcachefs/btree_cache.c:932
bch2_btree_node_get_noiter+0x9d5/0xf70 fs/bcachefs/btree_cache.c:1238
found_btree_node_is_readable fs/bcachefs/btree_node_scan.c:85 [inline]
try_read_btree_node fs/bcachefs/btree_node_scan.c:190 [inline]
read_btree_nodes_worker+0x122c/0x20b0 fs/bcachefs/btree_node_scan.c:239
kthread+0x2f0/0x390 kernel/kthread.c:389
ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
</TASK>
---[ end trace ]---
Kernel panic - not syncing: UBSAN: panic_on_warn set ...
CPU: 0 UID: 0 PID: 5109 Comm: read_btree_node Not tainted 6.11.0-syzkaller-11728-gad46e8f95e93 #0
Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014
Call Trace:
<TASK>
__dump_stack lib/dump_stack.c:94 [inline]
dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120
panic+0x349/0x880 kernel/panic.c:354
check_panic_on_warn+0x86/0xb0 kernel/panic.c:243
ubsan_epilogue lib/ubsan.c:236 [inline]
__ubsan_handle_shift_out_of_bounds+0x3e7/0x420 lib/ubsan.c:468
__btree_node_pinned+0x80b/0x850 fs/bcachefs/btree_cache.c:198
__bch2_btree_node_hash_insert+0xcfd/0x13e0 fs/bcachefs/btree_cache.c:270
bch2_btree_node_hash_insert fs/bcachefs/btree_cache.c:287 [inline]
bch2_btree_node_fill+0x94e/0x1200 fs/bcachefs/btree_cache.c:932
bch2_btree_node_get_noiter+0x9d5/0xf70 fs/bcachefs/btree_cache.c:1238
found_btree_node_is_readable fs/bcachefs/btree_node_scan.c:85 [inline]
try_read_btree_node fs/bcachefs/btree_node_scan.c:190 [inline]
read_btree_nodes_worker+0x122c/0x20b0 fs/bcachefs/btree_node_scan.c:239
kthread+0x2f0/0x390 kernel/kthread.c:389
ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
</TASK>
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 syzkaller@googlegroups.com.
syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.
If the report is already addressed, let syzbot know by replying with:
#syz fix: exact-commit-title
If you want syzbot to run the reproducer, reply with:
#syz test: git://repo/address.git branch-or-commit-hash
If you attach or paste a git patch, syzbot will apply it before testing.
If you want to overwrite report's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)
If the report is a duplicate of another one, reply with:
#syz dup: exact-subject-of-another-report
If you want to undo deduplication, reply with:
#syz undup
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [syzbot] UBSAN: shift-out-of-bounds in __btree_node_pinned
2024-10-02 10:54 [syzbot] [bcachefs?] UBSAN: shift-out-of-bounds in __btree_node_pinned syzbot
@ 2024-10-04 19:54 ` syzbot
2024-10-04 21:48 ` syzbot
` (2 subsequent siblings)
3 siblings, 0 replies; 5+ messages in thread
From: syzbot @ 2024-10-04 19:54 UTC (permalink / raw)
To: linux-kernel
For archival purposes, forwarding an incoming command email to
linux-kernel@vger.kernel.org.
***
Subject: UBSAN: shift-out-of-bounds in __btree_node_pinned
Author: niharchaithanya@gmail.com
#syz test
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [syzbot] UBSAN: shift-out-of-bounds in __btree_node_pinned
2024-10-02 10:54 [syzbot] [bcachefs?] UBSAN: shift-out-of-bounds in __btree_node_pinned syzbot
2024-10-04 19:54 ` [syzbot] " syzbot
@ 2024-10-04 21:48 ` syzbot
2025-01-01 16:25 ` [syzbot] [bcachefs?] " syzbot
2025-09-28 0:11 ` Forwarded: " syzbot
3 siblings, 0 replies; 5+ messages in thread
From: syzbot @ 2024-10-04 21:48 UTC (permalink / raw)
To: linux-kernel
For archival purposes, forwarding an incoming command email to
linux-kernel@vger.kernel.org.
***
Subject: UBSAN: shift-out-of-bounds in __btree_node_pinned
Author: niharchaithanya@gmail.com
#syz test
^ permalink raw reply [flat|nested] 5+ messages in thread
* Re: [syzbot] [bcachefs?] UBSAN: shift-out-of-bounds in __btree_node_pinned
2024-10-02 10:54 [syzbot] [bcachefs?] UBSAN: shift-out-of-bounds in __btree_node_pinned syzbot
2024-10-04 19:54 ` [syzbot] " syzbot
2024-10-04 21:48 ` syzbot
@ 2025-01-01 16:25 ` syzbot
2025-09-28 0:11 ` Forwarded: " syzbot
3 siblings, 0 replies; 5+ messages in thread
From: syzbot @ 2025-01-01 16:25 UTC (permalink / raw)
To: kent.overstreet, linux-bcachefs, linux-kernel, niharchaithanya,
syzkaller-bugs
syzbot has bisected this issue to:
commit 7a51608d0125469664e2daf8e060d6d783924c98
Author: Kent Overstreet <kent.overstreet@linux.dev>
Date: Thu Sep 5 00:49:37 2024 +0000
bcachefs: Rework btree node pinning
bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=115c06c4580000
start commit: ccb98ccef0e5 Merge tag 'platform-drivers-x86-v6.13-4' of g..
git tree: upstream
final oops: https://syzkaller.appspot.com/x/report.txt?x=135c06c4580000
console output: https://syzkaller.appspot.com/x/log.txt?x=155c06c4580000
kernel config: https://syzkaller.appspot.com/x/.config?x=ba7cde9482d6bb6
dashboard link: https://syzkaller.appspot.com/bug?extid=9f41e4b255897d99d4e9
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=118c28b0580000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=11d45af8580000
Reported-by: syzbot+9f41e4b255897d99d4e9@syzkaller.appspotmail.com
Fixes: 7a51608d0125 ("bcachefs: Rework btree node pinning")
For information about bisection process see: https://goo.gl/tpsmEJ#bisection
^ permalink raw reply [flat|nested] 5+ messages in thread
* Forwarded: Re: [syzbot] [bcachefs?] UBSAN: shift-out-of-bounds in __btree_node_pinned
2024-10-02 10:54 [syzbot] [bcachefs?] UBSAN: shift-out-of-bounds in __btree_node_pinned syzbot
` (2 preceding siblings ...)
2025-01-01 16:25 ` [syzbot] [bcachefs?] " syzbot
@ 2025-09-28 0:11 ` syzbot
3 siblings, 0 replies; 5+ messages in thread
From: syzbot @ 2025-09-28 0:11 UTC (permalink / raw)
To: linux-kernel, syzkaller-bugs
For archival purposes, forwarding an incoming command email to
linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com.
***
Subject: Re: [syzbot] [bcachefs?] UBSAN: shift-out-of-bounds in __btree_node_pinned
Author: xandfury@gmail.com
syzbot <syzbot+9f41e4b255897d99d4e9@syzkaller.appspotmail.com> writes:
> Hello,
>
> syzbot found the following issue on:
>
> HEAD commit: ad46e8f95e93 Merge tag ’pm-6.12-rc1-2’ of git://git.kernel..
> git tree: upstream
> console output: <https://syzkaller.appspot.com/x/log.txt?x=13b3d507980000>
> kernel config: <https://syzkaller.appspot.com/x/.config?x=62086b2fd100a029>
> dashboard link: <https://syzkaller.appspot.com/bug?extid=9f41e4b255897d99d4e9>
> compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
> syz repro: <https://syzkaller.appspot.com/x/repro.syz?x=11b69e80580000>
> C reproducer: <https://syzkaller.appspot.com/x/repro.c?x=1567c6a9980000>
>
> Downloadable assets:
> disk image (non-bootable): <https://storage.googleapis.com/syzbot-assets/7feb34a89c2a/non_bootable_disk-ad46e8f9.raw.xz>
> vmlinux: <https://storage.googleapis.com/syzbot-assets/72b7539cbeb1/vmlinux-ad46e8f9.xz>
> kernel image: <https://storage.googleapis.com/syzbot-assets/73c9b9cebaf4/bzImage-ad46e8f9.xz>
> mounted in repro: <https://storage.googleapis.com/syzbot-assets/54e2032c8f9d/mount_0.gz>
>
> IMPORTANT: if you fix the issue, please add the following tag to the commit:
> Reported-by: syzbot+9f41e4b255897d99d4e9@syzkaller.appspotmail.com
>
> ————[ cut here ]————
> UBSAN: shift-out-of-bounds in fs/bcachefs/btree_cache.c:198:18
> shift exponent 227 is too large for 64-bit type ’unsigned long long’
> CPU: 0 UID: 0 PID: 5109 Comm: read_btree_node Not tainted 6.11.0-syzkaller-11728-gad46e8f95e93 #0
> Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014
> Call Trace:
> <TASK>
> __dump_stack lib/dump_stack.c:94 [inline]
> dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120
> ubsan_epilogue lib/ubsan.c:231 [inline]
> __ubsan_handle_shift_out_of_bounds+0x3c8/0x420 lib/ubsan.c:468
> __btree_node_pinned+0x80b/0x850 fs/bcachefs/btree_cache.c:198
> __bch2_btree_node_hash_insert+0xcfd/0x13e0 fs/bcachefs/btree_cache.c:270
> bch2_btree_node_hash_insert fs/bcachefs/btree_cache.c:287 [inline]
> bch2_btree_node_fill+0x94e/0x1200 fs/bcachefs/btree_cache.c:932
> bch2_btree_node_get_noiter+0x9d5/0xf70 fs/bcachefs/btree_cache.c:1238
> found_btree_node_is_readable fs/bcachefs/btree_node_scan.c:85 [inline]
> try_read_btree_node fs/bcachefs/btree_node_scan.c:190 [inline]
> read_btree_nodes_worker+0x122c/0x20b0 fs/bcachefs/btree_node_scan.c:239
> kthread+0x2f0/0x390 kernel/kthread.c:389
> ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
> ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
> </TASK>
> —[ end trace ]—
> Kernel panic - not syncing: UBSAN: panic_on_warn set …
> CPU: 0 UID: 0 PID: 5109 Comm: read_btree_node Not tainted 6.11.0-syzkaller-11728-gad46e8f95e93 #0
> Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 1.16.3-debian-1.16.3-2~bpo12+1 04/01/2014
> Call Trace:
> <TASK>
> __dump_stack lib/dump_stack.c:94 [inline]
> dump_stack_lvl+0x241/0x360 lib/dump_stack.c:120
> panic+0x349/0x880 kernel/panic.c:354
> check_panic_on_warn+0x86/0xb0 kernel/panic.c:243
> ubsan_epilogue lib/ubsan.c:236 [inline]
> __ubsan_handle_shift_out_of_bounds+0x3e7/0x420 lib/ubsan.c:468
> __btree_node_pinned+0x80b/0x850 fs/bcachefs/btree_cache.c:198
> __bch2_btree_node_hash_insert+0xcfd/0x13e0 fs/bcachefs/btree_cache.c:270
> bch2_btree_node_hash_insert fs/bcachefs/btree_cache.c:287 [inline]
> bch2_btree_node_fill+0x94e/0x1200 fs/bcachefs/btree_cache.c:932
> bch2_btree_node_get_noiter+0x9d5/0xf70 fs/bcachefs/btree_cache.c:1238
> found_btree_node_is_readable fs/bcachefs/btree_node_scan.c:85 [inline]
> try_read_btree_node fs/bcachefs/btree_node_scan.c:190 [inline]
> read_btree_nodes_worker+0x122c/0x20b0 fs/bcachefs/btree_node_scan.c:239
> kthread+0x2f0/0x390 kernel/kthread.c:389
> ret_from_fork+0x4b/0x80 arch/x86/kernel/process.c:147
> ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:244
> </TASK>
> 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 syzkaller@googlegroups.com.
>
> syzbot will keep track of this issue. See:
> <https://goo.gl/tpsmEJ#status> for how to communicate with syzbot.
>
> If the report is already addressed, let syzbot know by replying with:
> #syz fix: exact-commit-title
>
> If you want syzbot to run the reproducer, reply with:
> #syz test: git://repo/address.git branch-or-commit-hash
> If you attach or paste a git patch, syzbot will apply it before testing.
>
> If you want to overwrite report’s subsystems, reply with:
> #syz set subsystems: new-subsystem
> (See the list of subsystem names on the web dashboard)
>
> If the report is a duplicate of another one, reply with:
> #syz dup: exact-subject-of-another-report
>
> If you want to undo deduplication, reply with:
> #syz undup
#syz test: git://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master
^ permalink raw reply [flat|nested] 5+ messages in thread
end of thread, other threads:[~2025-09-28 0:11 UTC | newest]
Thread overview: 5+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-10-02 10:54 [syzbot] [bcachefs?] UBSAN: shift-out-of-bounds in __btree_node_pinned syzbot
2024-10-04 19:54 ` [syzbot] " syzbot
2024-10-04 21:48 ` syzbot
2025-01-01 16:25 ` [syzbot] [bcachefs?] " syzbot
2025-09-28 0:11 ` Forwarded: " syzbot
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox