[syzbot] [xfs?] [ext4?] kernel BUG in __block_write_begin_int

9 views
Skip to first unread message

syzbot

unread,
Sep 4, 2023, 3:29:54 AM9/4/23
to adilger...@dilger.ca, djw...@kernel.org, linux...@vger.kernel.org, linux-...@vger.kernel.org, linux-...@vger.kernel.org, linu...@vger.kernel.org, so...@kernel.org, syzkall...@googlegroups.com, ty...@mit.edu, yuk...@huawei.com, zhang_...@foxmail.com
Hello,

syzbot found the following issue on:

HEAD commit: 0468be89b3fa Merge tag 'iommu-updates-v6.6' of git://git.k..
git tree: upstream
console+strace: https://syzkaller.appspot.com/x/log.txt?x=11145910680000
kernel config: https://syzkaller.appspot.com/x/.config?x=3d78b3780d210e21
dashboard link: https://syzkaller.appspot.com/bug?extid=4a08ffdf3667b36650a1
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=164f7a57a80000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=143b0298680000

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/f3914b539822/disk-0468be89.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/6128b0644784/vmlinux-0468be89.xz
kernel image: https://storage.googleapis.com/syzbot-assets/349d98668c3a/bzImage-0468be89.xz
mounted in repro: https://storage.googleapis.com/syzbot-assets/75bd68910fd4/mount_0.gz

The issue was bisected to:

commit 8b0472b50bcf0f19a5119b00a53b63579c8e1e4d
Author: Zhang Shurong <zhang_...@foxmail.com>
Date: Sat Jul 22 07:53:53 2023 +0000

md: raid1: fix potential OOB in raid1_remove_disk()

bisection log: https://syzkaller.appspot.com/x/bisect.txt?x=16e52577a80000
final oops: https://syzkaller.appspot.com/x/report.txt?x=15e52577a80000
console output: https://syzkaller.appspot.com/x/log.txt?x=11e52577a80000

IMPORTANT: if you fix the issue, please add the following tag to the commit:
Reported-by: syzbot+4a08ff...@syzkaller.appspotmail.com
Fixes: 8b0472b50bcf ("md: raid1: fix potential OOB in raid1_remove_disk()")

------------[ cut here ]------------
kernel BUG at fs/buffer.c:2028!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
CPU: 0 PID: 5187 Comm: syz-executor424 Not tainted 6.5.0-syzkaller-10885-g0468be89b3fa #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
RIP: 0010:iomap_to_bh fs/buffer.c:2028 [inline]
RIP: 0010:__block_write_begin_int+0x18f7/0x1a40 fs/buffer.c:2111
Code: af 0d 85 ff 48 8b 7c 24 08 48 c7 c6 20 22 18 8b e8 6e 8b c6 ff 0f 0b e8 97 0d 85 ff eb 13 e8 90 0d 85 ff eb c7 e8 89 0d 85 ff <0f> 0b e8 82 0d 85 ff 48 8b 7c 24 08 48 c7 c6 20 22 18 8b e8 41 8b
RSP: 0018:ffffc9000418f520 EFLAGS: 00010293
RAX: ffffffff82087b37 RBX: 0000000000040000 RCX: ffff888078093b80
RDX: 0000000000000000 RSI: 0000000000040000 RDI: 00000000000d0000
RBP: ffffc9000418f6b0 R08: ffffffff82086ba2 R09: 1ffff1100f27203a
R10: dffffc0000000000 R11: ffffed100f27203b R12: 00000000000d0000
R13: 0000000000000400 R14: 0000000000000000 R15: ffff8880793901d0
FS: 00007f0623ec56c0(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000020040000 CR3: 0000000067478000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
iomap_write_begin+0xaf6/0x1f00 fs/iomap/buffered-io.c:772
iomap_write_iter fs/iomap/buffered-io.c:907 [inline]
iomap_file_buffered_write+0x587/0x1020 fs/iomap/buffered-io.c:968
blkdev_buffered_write block/fops.c:634 [inline]
blkdev_write_iter+0x41d/0x5c0 block/fops.c:688
call_write_iter include/linux/fs.h:1985 [inline]
new_sync_write fs/read_write.c:491 [inline]
vfs_write+0x782/0xaf0 fs/read_write.c:584
ksys_write+0x1a0/0x2c0 fs/read_write.c:637
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f0623f2b6c9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 71 19 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f0623ec5218 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 00007f0623fb9478 RCX: 00007f0623f2b6c9
RDX: 000000000208e24b RSI: 0000000020000100 RDI: 0000000000000003
RBP: 00007f0623fb9470 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00007f0623f7f694
R13: 00007f0623f7f1c0 R14: 0031656c69662f2e R15: 6f6f6c2f7665642f
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:iomap_to_bh fs/buffer.c:2028 [inline]
RIP: 0010:__block_write_begin_int+0x18f7/0x1a40 fs/buffer.c:2111
Code: af 0d 85 ff 48 8b 7c 24 08 48 c7 c6 20 22 18 8b e8 6e 8b c6 ff 0f 0b e8 97 0d 85 ff eb 13 e8 90 0d 85 ff eb c7 e8 89 0d 85 ff <0f> 0b e8 82 0d 85 ff 48 8b 7c 24 08 48 c7 c6 20 22 18 8b e8 41 8b
RSP: 0018:ffffc9000418f520 EFLAGS: 00010293
RAX: ffffffff82087b37 RBX: 0000000000040000 RCX: ffff888078093b80
RDX: 0000000000000000 RSI: 0000000000040000 RDI: 00000000000d0000
RBP: ffffc9000418f6b0 R08: ffffffff82086ba2 R09: 1ffff1100f27203a
R10: dffffc0000000000 R11: ffffed100f27203b R12: 00000000000d0000
R13: 0000000000000400 R14: 0000000000000000 R15: ffff8880793901d0
FS: 00007f0623ec56c0(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f0623f66850 CR3: 0000000067478000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400


---
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.
For information about bisection process see: https://goo.gl/tpsmEJ#bisection

If the bug is already fixed, 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 bug's subsystems, reply with:
#syz set subsystems: new-subsystem
(See the list of subsystem names on the web dashboard)

If the bug is a duplicate of another bug, reply with:
#syz dup: exact-subject-of-another-report

If you want to undo deduplication, reply with:
#syz undup

Yu Kuai

unread,
Sep 4, 2023, 4:11:55 AM9/4/23
to syzbot, adilger...@dilger.ca, djw...@kernel.org, linux...@vger.kernel.org, linux-...@vger.kernel.org, linux-...@vger.kernel.org, linu...@vger.kernel.org, so...@kernel.org, syzkall...@googlegroups.com, ty...@mit.edu, zhang_...@foxmail.com, yukuai (C), yang...@huawei.com
Hi,

在 2023/09/04 15:29, syzbot 写道:
> Hello,
>
> syzbot found the following issue on:
>
> HEAD commit: 0468be89b3fa Merge tag 'iommu-updates-v6.6' of git://git.k..
> git tree: upstream
> console+strace: https://syzkaller.appspot.com/x/log.txt?x=11145910680000
> kernel config: https://syzkaller.appspot.com/x/.config?x=3d78b3780d210e21
> dashboard link: https://syzkaller.appspot.com/bug?extid=4a08ffdf3667b36650a1
> 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=164f7a57a80000
> C reproducer: https://syzkaller.appspot.com/x/repro.c?x=143b0298680000
>
> Downloadable assets:
> disk image: https://storage.googleapis.com/syzbot-assets/f3914b539822/disk-0468be89.raw.xz
> vmlinux: https://storage.googleapis.com/syzbot-assets/6128b0644784/vmlinux-0468be89.xz
> kernel image: https://storage.googleapis.com/syzbot-assets/349d98668c3a/bzImage-0468be89.xz
> mounted in repro: https://storage.googleapis.com/syzbot-assets/75bd68910fd4/mount_0.gz
>
> The issue was bisected to:
>
> commit 8b0472b50bcf0f19a5119b00a53b63579c8e1e4d
> Author: Zhang Shurong <zhang_...@foxmail.com>
> Date: Sat Jul 22 07:53:53 2023 +0000
>
> md: raid1: fix potential OOB in raid1_remove_disk()
>

Really? raid1 is not even used from the c reproducer, this bisect result
is insane.

Thanks,
Kuai
> .
>

Dave Chinner

unread,
Sep 4, 2023, 4:33:46 AM9/4/23
to syzbot, adilger...@dilger.ca, djw...@kernel.org, linux...@vger.kernel.org, linux-...@vger.kernel.org, linux-...@vger.kernel.org, linu...@vger.kernel.org, so...@kernel.org, syzkall...@googlegroups.com, ty...@mit.edu, yuk...@huawei.com, zhang_...@foxmail.com, linux...@vger.kernel.org, ax...@kernel.dk, h...@lst.de
[cc linux-block, Christoph]

On Mon, Sep 04, 2023 at 12:29:52AM -0700, syzbot wrote:
> Hello,
>
> syzbot found the following issue on:
>
> HEAD commit: 0468be89b3fa Merge tag 'iommu-updates-v6.6' of git://git.k..
> git tree: upstream
> console+strace: https://syzkaller.appspot.com/x/log.txt?x=11145910680000
> kernel config: https://syzkaller.appspot.com/x/.config?x=3d78b3780d210e21
> dashboard link: https://syzkaller.appspot.com/bug?extid=4a08ffdf3667b36650a1
> 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=164f7a57a80000
> C reproducer: https://syzkaller.appspot.com/x/repro.c?x=143b0298680000
>
> Downloadable assets:
> disk image: https://storage.googleapis.com/syzbot-assets/f3914b539822/disk-0468be89.raw.xz
> vmlinux: https://storage.googleapis.com/syzbot-assets/6128b0644784/vmlinux-0468be89.xz
> kernel image: https://storage.googleapis.com/syzbot-assets/349d98668c3a/bzImage-0468be89.xz
> mounted in repro: https://storage.googleapis.com/syzbot-assets/75bd68910fd4/mount_0.gz
>
> The issue was bisected to:
>
> commit 8b0472b50bcf0f19a5119b00a53b63579c8e1e4d
> Author: Zhang Shurong <zhang_...@foxmail.com>
> Date: Sat Jul 22 07:53:53 2023 +0000
>
> md: raid1: fix potential OOB in raid1_remove_disk()

Bisect is broken. That has nothing to do with the block device
conversion to use iomap that triggered this.

The commit that made this change was 487c607df790 ("block: use iomap
for writes to block devices"), and that's why we're getting a
BUG_ON() being triggered in iomap_to_bh()....
It appears that 0010:__block_write_begin_int() has iterated beyond
the iomap that was passed in, triggering the BUG_ON() check in
iomap_to_bh().

Definitely not an XFS problem. Most likely not an ext4 problem.
It appears to be related to syzbot trying to modify the block device
under a mounted ext4 filesystem given the reproducer involves
mounting an ext4 filesystem, then the process that mounted the ext4
filesystem hits a BUG_ON trying to write to a block device.

Certainly seems like a block device problem, though, given
the new iomap write path in the block device merged in the 6.6-rc1 window.

#syz set subsystems: block

-Dave.
--
Dave Chinner
da...@fromorbit.com

Christoph Hellwig

unread,
Sep 4, 2023, 9:26:54 AM9/4/23
to Dave Chinner, syzbot, adilger...@dilger.ca, djw...@kernel.org, linux...@vger.kernel.org, linux-...@vger.kernel.org, linux-...@vger.kernel.org, linu...@vger.kernel.org, so...@kernel.org, syzkall...@googlegroups.com, ty...@mit.edu, yuk...@huawei.com, zhang_...@foxmail.com, linux...@vger.kernel.org, ax...@kernel.dk, h...@lst.de
On Mon, Sep 04, 2023 at 06:33:41PM +1000, Dave Chinner wrote:
> It appears that 0010:__block_write_begin_int() has iterated beyond
> the iomap that was passed in, triggering the BUG_ON() check in
> iomap_to_bh().

Yes, I'll look into it.

syzbot

unread,
Sep 4, 2023, 11:39:24 AM9/4/23
to nog...@google.com, syzkall...@googlegroups.com
Hello,

syzbot has tested the proposed patch but the reproducer is still triggering an issue:
kernel BUG in __block_write_begin_int

------------[ cut here ]------------
kernel BUG at fs/buffer.c:2043!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
CPU: 1 PID: 12283 Comm: syz-executor.0 Not tainted 6.5.0-rc2-syzkaller-00089-g8b0472b50bcf #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
RIP: 0010:iomap_to_bh fs/buffer.c:2043 [inline]
RIP: 0010:__block_write_begin_int+0x1906/0x1a60 fs/buffer.c:2126
Code: 90 d7 86 ff 48 8b 7c 24 08 48 c7 c6 e0 a8 17 8b e8 cf 7f c7 ff 0f 0b e8 78 d7 86 ff eb 13 e8 71 d7 86 ff eb c7 e8 6a d7 86 ff <0f> 0b e8 63 d7 86 ff 48 8b 7c 24 08 48 c7 c6 e0 a8 17 8b e8 a2 7f
RSP: 0018:ffffc900038b7520 EFLAGS: 00010293
RAX: ffffffff8204fe06 RBX: 0000000000040000 RCX: ffff888028119dc0
RDX: 0000000000000000 RSI: 0000000000040000 RDI: 00000000000f4000
RBP: ffffc900038b76b0 R08: ffffffff8204ee62 R09: 1ffff1100cd8cc57
R10: dffffc0000000000 R11: ffffed100cd8cc58 R12: 00000000000f4000
R13: 0000000000000400 R14: 0000000000000000 R15: ffff888066c662b8
FS: 00007f5f8786d6c0(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000002003e000 CR3: 000000006917e000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
iomap_write_begin+0xadb/0x1d40 fs/iomap/buffered-io.c:679
iomap_write_iter fs/iomap/buffered-io.c:816 [inline]
iomap_file_buffered_write+0x608/0xcc0 fs/iomap/buffered-io.c:873
blkdev_buffered_write block/fops.c:633 [inline]
blkdev_write_iter+0x41d/0x5c0 block/fops.c:687
call_write_iter include/linux/fs.h:1871 [inline]
new_sync_write fs/read_write.c:491 [inline]
vfs_write+0x782/0xaf0 fs/read_write.c:584
ksys_write+0x1a0/0x2c0 fs/read_write.c:637
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f5f86a7cae9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f5f8786d0c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 00007f5f86b9c050 RCX: 00007f5f86a7cae9
RDX: 000000000208e24b RSI: 0000000020000100 RDI: 0000000000000003
RBP: 00007f5f86ac847a R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 000000000000000b R14: 00007f5f86b9c050 R15: 00007ffeda63c308
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:iomap_to_bh fs/buffer.c:2043 [inline]
RIP: 0010:__block_write_begin_int+0x1906/0x1a60 fs/buffer.c:2126
Code: 90 d7 86 ff 48 8b 7c 24 08 48 c7 c6 e0 a8 17 8b e8 cf 7f c7 ff 0f 0b e8 78 d7 86 ff eb 13 e8 71 d7 86 ff eb c7 e8 6a d7 86 ff <0f> 0b e8 63 d7 86 ff 48 8b 7c 24 08 48 c7 c6 e0 a8 17 8b e8 a2 7f
RSP: 0018:ffffc900038b7520 EFLAGS: 00010293
RAX: ffffffff8204fe06 RBX: 0000000000040000 RCX: ffff888028119dc0
RDX: 0000000000000000 RSI: 0000000000040000 RDI: 00000000000f4000
RBP: ffffc900038b76b0 R08: ffffffff8204ee62 R09: 1ffff1100cd8cc57
R10: dffffc0000000000 R11: ffffed100cd8cc58 R12: 00000000000f4000
R13: 0000000000000400 R14: 0000000000000000 R15: ffff888066c662b8
FS: 00007f5f8786d6c0(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f5f86ad700d CR3: 000000006917e000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400


Tested on:

commit: 8b0472b5 md: raid1: fix potential OOB in raid1_remove_..
git tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
console output: https://syzkaller.appspot.com/x/log.txt?x=12d76f10680000
kernel config: https://syzkaller.appspot.com/x/.config?x=baba0c433c23e8d8
dashboard link: https://syzkaller.appspot.com/bug?extid=4a08ffdf3667b36650a1
compiler: Debian clang version 15.0.6, GNU ld (GNU Binutils for Debian) 2.40

Note: no patches were applied.

syzbot

unread,
Sep 4, 2023, 11:59:37 AM9/4/23
to nog...@google.com, syzkall...@googlegroups.com
Hello,

syzbot has tested the proposed patch but the reproducer is still triggering an issue:
kernel BUG in __block_write_begin_int

------------[ cut here ]------------
kernel BUG at fs/buffer.c:2043!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
CPU: 0 PID: 9466 Comm: syz-executor.0 Not tainted 6.5.0-rc2-syzkaller-00088-ga705b11b358d #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
RIP: 0010:iomap_to_bh fs/buffer.c:2043 [inline]
RIP: 0010:__block_write_begin_int+0x1906/0x1a60 fs/buffer.c:2126
Code: 90 d7 86 ff 48 8b 7c 24 08 48 c7 c6 e0 a8 17 8b e8 cf 7f c7 ff 0f 0b e8 78 d7 86 ff eb 13 e8 71 d7 86 ff eb c7 e8 6a d7 86 ff <0f> 0b e8 63 d7 86 ff 48 8b 7c 24 08 48 c7 c6 e0 a8 17 8b e8 a2 7f
RSP: 0018:ffffc900063af520 EFLAGS: 00010293
RAX: ffffffff8204fe06 RBX: 0000000000040000 RCX: ffff88807d73bb80
RDX: 0000000000000000 RSI: 0000000000040000 RDI: 00000000000b4000
RBP: ffffc900063af6b0 R08: ffffffff8204ee62 R09: 1ffff1100d1cd522
R10: dffffc0000000000 R11: ffffed100d1cd523 R12: 00000000000b4000
R13: 0000000000000400 R14: 0000000000000000 R15: ffff888068e6a910
FS: 00007f275e9126c0(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000002002e000 CR3: 00000000292a5000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
iomap_write_begin+0xadb/0x1d40 fs/iomap/buffered-io.c:679
iomap_write_iter fs/iomap/buffered-io.c:816 [inline]
iomap_file_buffered_write+0x608/0xcc0 fs/iomap/buffered-io.c:873
blkdev_buffered_write block/fops.c:633 [inline]
blkdev_write_iter+0x41d/0x5c0 block/fops.c:687
call_write_iter include/linux/fs.h:1871 [inline]
new_sync_write fs/read_write.c:491 [inline]
vfs_write+0x782/0xaf0 fs/read_write.c:584
ksys_write+0x1a0/0x2c0 fs/read_write.c:637
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f275dc7cae9
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 e1 20 00 00 90 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f275e9120c8 EFLAGS: 00000246 ORIG_RAX: 0000000000000001
RAX: ffffffffffffffda RBX: 00007f275dd9c050 RCX: 00007f275dc7cae9
RDX: 000000000208e24b RSI: 0000000020000100 RDI: 0000000000000003
RBP: 00007f275dcc847a R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 000000000000000b R14: 00007f275dd9c050 R15: 00007ffde823cc58
</TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:iomap_to_bh fs/buffer.c:2043 [inline]
RIP: 0010:__block_write_begin_int+0x1906/0x1a60 fs/buffer.c:2126
Code: 90 d7 86 ff 48 8b 7c 24 08 48 c7 c6 e0 a8 17 8b e8 cf 7f c7 ff 0f 0b e8 78 d7 86 ff eb 13 e8 71 d7 86 ff eb c7 e8 6a d7 86 ff <0f> 0b e8 63 d7 86 ff 48 8b 7c 24 08 48 c7 c6 e0 a8 17 8b e8 a2 7f
RSP: 0018:ffffc900063af520 EFLAGS: 00010293
RAX: ffffffff8204fe06 RBX: 0000000000040000 RCX: ffff88807d73bb80
RDX: 0000000000000000 RSI: 0000000000040000 RDI: 00000000000b4000
RBP: ffffc900063af6b0 R08: ffffffff8204ee62 R09: 1ffff1100d1cd522
R10: dffffc0000000000 R11: ffffed100d1cd523 R12: 00000000000b4000
R13: 0000000000000400 R14: 0000000000000000 R15: ffff888068e6a910
FS: 00007f275e9126c0(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000000002002e000 CR3: 00000000292a5000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400


Tested on:

commit: a705b11b md/raid5-cache: fix a deadlock in r5l_exit_lo..
git tree: https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
console output: https://syzkaller.appspot.com/x/log.txt?x=15785104680000

Christoph Hellwig

unread,
Sep 5, 2023, 3:45:08 AM9/5/23
to syzbot, adilger...@dilger.ca, djw...@kernel.org, linux...@vger.kernel.org, linux-...@vger.kernel.org, linux-...@vger.kernel.org, linu...@vger.kernel.org, so...@kernel.org, syzkall...@googlegroups.com, ty...@mit.edu, yuk...@huawei.com, zhang_...@foxmail.com
syz test: git://git.infradead.org/users/hch/misc.git bdev-iomap-fix

Aleksandr Nogikh

unread,
Sep 5, 2023, 5:27:03 AM9/5/23
to Christoph Hellwig, syzbot, adilger...@dilger.ca, djw...@kernel.org, linux...@vger.kernel.org, linux-...@vger.kernel.org, linux-...@vger.kernel.org, linu...@vger.kernel.org, so...@kernel.org, syzkall...@googlegroups.com, ty...@mit.edu, yuk...@huawei.com, zhang_...@foxmail.com
On Tue, Sep 5, 2023 at 9:45 AM Christoph Hellwig <h...@infradead.org> wrote:
>
> syz test: git://git.infradead.org/users/hch/misc.git bdev-iomap-fix

A minor correction:

#syz test: git://git.infradead.org/users/hch/misc.git bdev-iomap-fix

syzbot

unread,
Sep 5, 2023, 6:04:33 AM9/5/23
to adilger...@dilger.ca, djw...@kernel.org, h...@infradead.org, linux...@vger.kernel.org, linux-...@vger.kernel.org, linux-...@vger.kernel.org, linu...@vger.kernel.org, nog...@google.com, so...@kernel.org, syzkall...@googlegroups.com, ty...@mit.edu, yuk...@huawei.com, zhang_...@foxmail.com
Hello,

syzbot has tested the proposed patch but the reproducer is still triggering an issue:
WARNING in __kthread_create_on_node

------------[ cut here ]------------
different return values (11 and 6) from vsnprintf("kmmpd-%.*s", ...)
WARNING: CPU: 1 PID: 12350 at lib/kasprintf.c:31 kvasprintf+0x17b/0x190 lib/kasprintf.c:30
Modules linked in:
CPU: 1 PID: 12350 Comm: syz-executor.0 Not tainted 6.5.0-syzkaller-11705-gfd19eb3c02e0 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/26/2023
RIP: 0010:kvasprintf+0x17b/0x190 lib/kasprintf.c:30
Code: 48 8d 65 d8 5b 41 5c 41 5d 41 5e 41 5f 5d c3 e8 cb db 55 fd 48 c7 c7 a0 0a 59 8b 44 89 e6 89 da 48 8b 4c 24 18 e8 65 56 1c fd <0f> 0b eb 98 e8 2c 46 90 06 66 2e 0f 1f 84 00 00 00 00 00 66 90 f3
RSP: 0018:ffffc90003507620 EFLAGS: 00010246
RAX: 2ce359f82b370100 RBX: 0000000000000006 RCX: ffff88806a543b80
RDX: 0000000000000000 RSI: 0000000000000001 RDI: 0000000000000000
RBP: ffffc900035076f0 R08: ffffffff81541672 R09: 1ffff1101732516a
R10: dffffc0000000000 R11: ffffed101732516b R12: 000000000000000b
R13: ffffc90003507880 R14: 1ffff920006a0ec8 R15: ffff888025476fa0
FS: 00007f224ed5d6c0(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000001b2c420000 CR3: 00000000691b6000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
__kthread_create_on_node+0x1a9/0x3c0 kernel/kthread.c:444
kthread_create_on_node+0xde/0x120 kernel/kthread.c:512
ext4_multi_mount_protect+0x792/0x9f0 fs/ext4/mmp.c:392
__ext4_fill_super fs/ext4/super.c:5363 [inline]
ext4_fill_super+0x4495/0x6d10 fs/ext4/super.c:5703
get_tree_bdev+0x416/0x5b0 fs/super.c:1577
vfs_get_tree+0x8c/0x280 fs/super.c:1750
do_new_mount+0x28f/0xae0 fs/namespace.c:3335
do_mount fs/namespace.c:3675 [inline]
__do_sys_mount fs/namespace.c:3884 [inline]
__se_sys_mount+0x2d9/0x3c0 fs/namespace.c:3861
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7f224e07e1ea
Code: d8 64 89 02 48 c7 c0 ff ff ff ff eb a6 e8 de 09 00 00 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 49 89 ca b8 a5 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b0 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007f224ed5cee8 EFLAGS: 00000246 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 00007f224ed5cf80 RCX: 00007f224e07e1ea
RDX: 0000000020000040 RSI: 0000000020000500 RDI: 00007f224ed5cf40
RBP: 0000000020000040 R08: 00007f224ed5cf80 R09: 0000000000004500
R10: 0000000000004500 R11: 0000000000000246 R12: 0000000020000500
R13: 00007f224ed5cf40 R14: 00000000000004b4 R15: 0000000020000540
</TASK>


Tested on:

commit: fd19eb3c iomap: handle error conditions more gracefull..
git tree: git://git.infradead.org/users/hch/misc.git bdev-iomap-fix
console output: https://syzkaller.appspot.com/x/log.txt?x=11955af0680000
kernel config: https://syzkaller.appspot.com/x/.config?x=ff0db7a15ba54ead

Christoph Hellwig

unread,
Sep 5, 2023, 8:27:05 AM9/5/23
to syzbot, adilger...@dilger.ca, djw...@kernel.org, h...@infradead.org, linux...@vger.kernel.org, linux-...@vger.kernel.org, linux-...@vger.kernel.org, linu...@vger.kernel.org, nog...@google.com, so...@kernel.org, syzkall...@googlegroups.com, ty...@mit.edu, yuk...@huawei.com, zhang_...@foxmail.com
On Tue, Sep 05, 2023 at 03:04:32AM -0700, syzbot wrote:
> Hello,
>
> syzbot has tested the proposed patch but the reproducer is still triggering an issue:
> WARNING in __kthread_create_on_node

Well, that is


a) a different issue in ext4
b) just a warning

Reply all
Reply to author
Forward
0 new messages