[v5.15] WARNING in _btrfs_ioctl_set_received_subvol

0 views
Skip to first unread message

syzbot

unread,
Apr 5, 2023, 5:32:54 AM4/5/23
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: c957cbb87315 Linux 5.15.105
git tree: linux-5.15.y
console output: https://syzkaller.appspot.com/x/log.txt?x=160fe631c80000
kernel config: https://syzkaller.appspot.com/x/.config?x=852dc3de44ba1f3f
dashboard link: https://syzkaller.appspot.com/bug?extid=1b73f1c3d9fcd83690c0
compiler: Debian clang version 15.0.7, GNU ld (GNU Binutils for Debian) 2.35.2
userspace arch: arm64

Unfortunately, I don't have any reproducer for this issue yet.

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/91d0cf1fc5fb/disk-c957cbb8.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/346dc1169521/vmlinux-c957cbb8.xz
kernel image: https://storage.googleapis.com/syzbot-assets/f7005bdc0e20/Image-c957cbb8.gz.xz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+1b73f1...@syzkaller.appspotmail.com

el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142
do_el0_svc+0x58/0x14c arch/arm64/kernel/syscall.c:181
el0_svc+0x7c/0x1f0 arch/arm64/kernel/entry-common.c:596
el0t_64_sync_handler+0x84/0xe4 arch/arm64/kernel/entry-common.c:614
el0t_64_sync+0x1a0/0x1a4 arch/arm64/kernel/entry.S:584
------------[ cut here ]------------
WARNING: CPU: 0 PID: 16341 at fs/btrfs/ioctl.c:4501 _btrfs_ioctl_set_received_subvol+0xa40/0xe24 fs/btrfs/ioctl.c:4501
Modules linked in:
CPU: 0 PID: 16341 Comm: syz-executor.4 Not tainted 5.15.105-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/02/2023
pstate: 60400005 (nZCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
pc : _btrfs_ioctl_set_received_subvol+0xa40/0xe24 fs/btrfs/ioctl.c:4501
lr : _btrfs_ioctl_set_received_subvol+0xa40/0xe24 fs/btrfs/ioctl.c:4501
sp : ffff8000222b7ae0
x29: ffff8000222b7b30 x28: dfff800000000000 x27: 00000000fffffff4
x26: ffff0000d1ba813f x25: ffff0000d1ba815f x24: ffff000125157790
x23: 1fffe00024a2aefd x22: ffff0001251577e8 x21: 00000000fffffff4
x20: ffff00013c790b50 x19: ffff0001388ff400 x18: 0000000000000001
x17: ff808000083336c4 x16: ffff80001193f6fc x15: ffff8000083336c4
x14: 00000000ffffffff x13: ffffffffffffffff x12: 0000000000040000
x11: 000000000000e38f x10: ffff8000229ca000 x9 : efa3112b4b386300
x8 : efa3112b4b386300 x7 : 0000000000000001 x6 : 0000000000000001
x5 : ffff8000222b7258 x4 : ffff80001499f940 x3 : ffff800008549b3c
x2 : 0000000000000001 x1 : 0000000100000000 x0 : 0000000000000026
Call trace:
_btrfs_ioctl_set_received_subvol+0xa40/0xe24 fs/btrfs/ioctl.c:4501
btrfs_ioctl_set_received_subvol_32+0x300/0xa6c fs/btrfs/ioctl.c:4564
btrfs_ioctl+0x86c/0xa5c fs/btrfs/ioctl.c:4987
vfs_ioctl fs/ioctl.c:51 [inline]
__do_sys_ioctl fs/ioctl.c:874 [inline]
__se_sys_ioctl fs/ioctl.c:860 [inline]
__arm64_sys_ioctl+0x14c/0x1c8 fs/ioctl.c:860
__invoke_syscall arch/arm64/kernel/syscall.c:38 [inline]
invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:52
el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142
do_el0_svc+0x58/0x14c arch/arm64/kernel/syscall.c:181
el0_svc+0x7c/0x1f0 arch/arm64/kernel/entry-common.c:596
el0t_64_sync_handler+0x84/0xe4 arch/arm64/kernel/entry-common.c:614
el0t_64_sync+0x1a0/0x1a4 arch/arm64/kernel/entry.S:584
irq event stamp: 89716
hardirqs last enabled at (89715): [<ffff800008329304>] __up_console_sem+0xb4/0x100 kernel/printk/printk.c:257
hardirqs last disabled at (89716): [<ffff80001193ad90>] el1_dbg+0x24/0x80 arch/arm64/kernel/entry-common.c:387
softirqs last enabled at (89692): [<ffff800008020ccc>] softirq_handle_end kernel/softirq.c:401 [inline]
softirqs last enabled at (89692): [<ffff800008020ccc>] __do_softirq+0xb5c/0xe20 kernel/softirq.c:587
softirqs last disabled at (89635): [<ffff8000081b4ee0>] do_softirq_own_stack include/asm-generic/softirq_stack.h:10 [inline]
softirqs last disabled at (89635): [<ffff8000081b4ee0>] invoke_softirq kernel/softirq.c:439 [inline]
softirqs last disabled at (89635): [<ffff8000081b4ee0>] __irq_exit_rcu+0x28c/0x534 kernel/softirq.c:636
---[ end trace c492996c2bba4461 ]---
BTRFS: error (device loop4) in _btrfs_ioctl_set_received_subvol:4501: errno=-12 Out of memory
BTRFS info (device loop4): forced readonly


---
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 syzk...@googlegroups.com.

syzbot will keep track of this issue. See:
https://goo.gl/tpsmEJ#status for how to communicate with syzbot.

syzbot

unread,
Jul 22, 2023, 7:26:49 PM7/22/23
to syzkaller...@googlegroups.com
syzbot has found a reproducer for the following issue on:

HEAD commit: d54cfc420586 Linux 5.15.120
git tree: linux-5.15.y
console output: https://syzkaller.appspot.com/x/log.txt?x=11334bd1a80000
kernel config: https://syzkaller.appspot.com/x/.config?x=1cbb66d8f24dbb30
dashboard link: https://syzkaller.appspot.com/bug?extid=1b73f1c3d9fcd83690c0
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40
userspace arch: arm64
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=15334bd1a80000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=11b67e4ea80000

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/a7edb50fe106/disk-d54cfc42.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/6d9892e76c6e/vmlinux-d54cfc42.xz
kernel image: https://storage.googleapis.com/syzbot-assets/0fd11af6d33e/Image-d54cfc42.gz.xz
mounted in repro: https://storage.googleapis.com/syzbot-assets/8c97c4847b05/mount_0.gz

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+1b73f1...@syzkaller.appspotmail.com

el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142
do_el0_svc+0x58/0x14c arch/arm64/kernel/syscall.c:181
el0_svc+0x7c/0x1f0 arch/arm64/kernel/entry-common.c:596
el0t_64_sync_handler+0x84/0xe4 arch/arm64/kernel/entry-common.c:614
el0t_64_sync+0x1a0/0x1a4 arch/arm64/kernel/entry.S:584
------------[ cut here ]------------
WARNING: CPU: 0 PID: 3969 at fs/btrfs/ioctl.c:4508 _btrfs_ioctl_set_received_subvol+0xa40/0xe24 fs/btrfs/ioctl.c:4508
Modules linked in:
CPU: 0 PID: 3969 Comm: syz-executor423 Not tainted 5.15.120-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/03/2023
pstate: 60400005 (nZCv daif +PAN -UAO -TCO -DIT -SSBS BTYPE=--)
pc : _btrfs_ioctl_set_received_subvol+0xa40/0xe24 fs/btrfs/ioctl.c:4508
lr : _btrfs_ioctl_set_received_subvol+0xa40/0xe24 fs/btrfs/ioctl.c:4508
sp : ffff80001c717bc0
x29: ffff80001c717c10 x28: dfff800000000000 x27: 00000000fffffff4
x26: ffff0000d371613f x25: ffff0000d371615f x24: ffff0000dc3330b0
x23: 1fffe0001b866621 x22: ffff0000dc333108 x21: 00000000fffffff4
x20: ffff0000cb25cb50 x19: ffff0000d9ee4780 x18: 0000000000000001
x17: ff80800008335ea8 x16: 0000000000000000 x15: ffff800008335ea8
x14: 00000000ffffffff x13: ffffffffffffffff x12: 0000000000000000
x11: ff8080000832d950 x10: 0000000000000000 x9 : 8db15f07d0ef5900
x8 : 8db15f07d0ef5900 x7 : 0000000000000001 x6 : 0000000000000001
x5 : ffff80001c717338 x4 : ffff8000149cfca0 x3 : ffff800008335ff4
x2 : 0000000000000001 x1 : 0000000100000000 x0 : 0000000000000026
Call trace:
_btrfs_ioctl_set_received_subvol+0xa40/0xe24 fs/btrfs/ioctl.c:4508
btrfs_ioctl_set_received_subvol+0x88/0x200 fs/btrfs/ioctl.c:4605
btrfs_ioctl+0x394/0xa5c fs/btrfs/ioctl.c:4991
vfs_ioctl fs/ioctl.c:51 [inline]
__do_sys_ioctl fs/ioctl.c:874 [inline]
__se_sys_ioctl fs/ioctl.c:860 [inline]
__arm64_sys_ioctl+0x14c/0x1c8 fs/ioctl.c:860
__invoke_syscall arch/arm64/kernel/syscall.c:38 [inline]
invoke_syscall+0x98/0x2b8 arch/arm64/kernel/syscall.c:52
el0_svc_common+0x138/0x258 arch/arm64/kernel/syscall.c:142
do_el0_svc+0x58/0x14c arch/arm64/kernel/syscall.c:181
el0_svc+0x7c/0x1f0 arch/arm64/kernel/entry-common.c:596
el0t_64_sync_handler+0x84/0xe4 arch/arm64/kernel/entry-common.c:614
el0t_64_sync+0x1a0/0x1a4 arch/arm64/kernel/entry.S:584
irq event stamp: 75498
hardirqs last enabled at (75497): [<ffff80000832bae8>] __up_console_sem+0xb4/0x100 kernel/printk/printk.c:257
hardirqs last disabled at (75498): [<ffff800011957088>] el1_dbg+0x24/0x80 arch/arm64/kernel/entry-common.c:387
softirqs last enabled at (75474): [<ffff800008020ccc>] softirq_handle_end kernel/softirq.c:401 [inline]
softirqs last enabled at (75474): [<ffff800008020ccc>] __do_softirq+0xb5c/0xe20 kernel/softirq.c:587
softirqs last disabled at (75443): [<ffff8000081b573c>] do_softirq_own_stack include/asm-generic/softirq_stack.h:10 [inline]
softirqs last disabled at (75443): [<ffff8000081b573c>] invoke_softirq kernel/softirq.c:439 [inline]
softirqs last disabled at (75443): [<ffff8000081b573c>] __irq_exit_rcu+0x28c/0x534 kernel/softirq.c:636
---[ end trace 038f87c691217221 ]---
BTRFS: error (device loop0) in _btrfs_ioctl_set_received_subvol:4508: errno=-12 Out of memory
BTRFS info (device loop0): forced readonly


---
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.
Reply all
Reply to author
Forward
0 new messages