kernel BUG in mpage_prepare_extent_to_map

19 views
Skip to first unread message

syzbot

unread,
Nov 2, 2021, 10:08:21 AM11/2/21
to syzkaller-a...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: 4944ec82ebb9 Merge 5.10.76 into android12-5.10-lts
git tree: android12-5.10-lts
console output: https://syzkaller.appspot.com/x/log.txt?x=11739e0eb00000
kernel config: https://syzkaller.appspot.com/x/.config?x=a9fabc39a1bc8139
dashboard link: https://syzkaller.appspot.com/bug?extid=0ed9f769264276638893
compiler: Debian clang version 11.0.1-2, GNU ld (GNU Binutils for Debian) 2.35.2

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

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

------------[ cut here ]------------
kernel BUG at fs/ext4/inode.c:2647!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
CPU: 0 PID: 494 Comm: kworker/u4:6 Tainted: G W 5.10.76-syzkaller-01178-g4944ec82ebb9 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
Workqueue: writeback wb_workfn (flush-8:0)
RIP: 0010:mpage_prepare_extent_to_map+0xbe9/0xc00 fs/ext4/inode.c:2647
Code: e8 dc c8 c3 ff e9 80 f6 ff ff 44 89 e9 80 e1 07 38 c1 0f 8c a6 fe ff ff 4c 89 ef e8 c1 c8 c3 ff e9 99 fe ff ff e8 b7 f6 89 ff <0f> 0b e8 b0 f6 89 ff 0f 0b e8 d9 31 b8 02 66 0f 1f 84 00 00 00 00
RSP: 0000:ffffc9000dee6d80 EFLAGS: 00010293
RAX: ffffffff81e30179 RBX: 0000000000000000 RCX: ffff88810da74f00
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffffc9000dee6f50 R08: ffffffff81e2fdf1 R09: fffff94000b96de9
R10: fffff94000b96de9 R11: 0000000000000000 R12: ffffea0005cb6f40
R13: ffffc9000dee6e40 R14: 0000000000000001 R15: dffffc0000000000
FS: 0000000000000000(0000) GS:ffff8881f7000000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007ffe522074c0 CR3: 000000010bbe1000 CR4: 00000000003506b0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
ext4_writepages+0xcbb/0x3950 fs/ext4/inode.c:2776
do_writepages+0x13a/0x280 mm/page-writeback.c:2358
__writeback_single_inode+0xb8/0x6f0 fs/fs-writeback.c:1467
writeback_sb_inodes+0x9a4/0x1910 fs/fs-writeback.c:1729
__writeback_inodes_wb fs/fs-writeback.c:1798 [inline]
wb_writeback+0x4ec/0xc40 fs/fs-writeback.c:1904
wb_check_start_all fs/fs-writeback.c:2028 [inline]
wb_do_writeback+0x739/0xbc0 fs/fs-writeback.c:2054
wb_workfn+0x178/0x9d0 fs/fs-writeback.c:2088
process_one_work+0x6b4/0xfb0 kernel/workqueue.c:2289
worker_thread+0xb15/0x1600 kernel/workqueue.c:2435
kthread+0x371/0x390 kernel/kthread.c:313
ret_from_fork+0x1f/0x30 arch/x86/entry/entry_64.S:296
Modules linked in:
---[ end trace cfb8dd64d0921f95 ]---
RIP: 0010:mpage_prepare_extent_to_map+0xbe9/0xc00 fs/ext4/inode.c:2647
Code: e8 dc c8 c3 ff e9 80 f6 ff ff 44 89 e9 80 e1 07 38 c1 0f 8c a6 fe ff ff 4c 89 ef e8 c1 c8 c3 ff e9 99 fe ff ff e8 b7 f6 89 ff <0f> 0b e8 b0 f6 89 ff 0f 0b e8 d9 31 b8 02 66 0f 1f 84 00 00 00 00
RSP: 0000:ffffc9000dee6d80 EFLAGS: 00010293
RAX: ffffffff81e30179 RBX: 0000000000000000 RCX: ffff88810da74f00
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffffc9000dee6f50 R08: ffffffff81e2fdf1 R09: fffff94000b96de9
R10: fffff94000b96de9 R11: 0000000000000000 R12: ffffea0005cb6f40
R13: ffffc9000dee6e40 R14: 0000000000000001 R15: dffffc0000000000
FS: 0000000000000000(0000) GS:ffff8881f7100000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007f2c7629e000 CR3: 0000000159fa4000 CR4: 00000000003506a0
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.

syzbot

unread,
Jan 22, 2022, 5:57:17 PM1/22/22
to syzkaller-a...@googlegroups.com
syzbot has found a reproducer for the following issue on:

HEAD commit: 0347b1658399 Merge 5.10.93 into android12-5.10-lts
git tree: android12-5.10-lts
console output: https://syzkaller.appspot.com/x/log.txt?x=1318b13fb00000
kernel config: https://syzkaller.appspot.com/x/.config?x=e0f3947457f8d2a4
dashboard link: https://syzkaller.appspot.com/bug?extid=0ed9f769264276638893
compiler: Debian clang version 11.0.1-2, GNU ld (GNU Binutils for Debian) 2.35.2
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=14db3c48700000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=11e0993db00000

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

------------[ cut here ]------------
kernel BUG at fs/ext4/inode.c:2647!
invalid opcode: 0000 [#1] PREEMPT SMP KASAN
CPU: 0 PID: 459 Comm: syz-executor359 Tainted: G W 5.10.93-syzkaller-01028-g0347b1658399 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 01/01/2011
RIP: 0010:mpage_prepare_extent_to_map+0xbe9/0xc00 fs/ext4/inode.c:2647
Code: e8 fc bd c3 ff e9 80 f6 ff ff 44 89 e9 80 e1 07 38 c1 0f 8c a6 fe ff ff 4c 89 ef e8 e1 bd c3 ff e9 99 fe ff ff e8 87 c9 89 ff <0f> 0b e8 80 c9 89 ff 0f 0b e8 79 1e b8 02 66 0f 1f 84 00 00 00 00
RSP: 0018:ffffc90000e2e9c0 EFLAGS: 00010293
RAX: ffffffff81e321f9 RBX: 0000000000000000 RCX: ffff88810c12cf00
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffffc90000e2eb90 R08: ffffffff81e31e71 R09: fffff940008d68b1
R10: fffff940008d68b1 R11: 0000000000000000 R12: ffffea00046b4580
R13: ffffc90000e2ea80 R14: 000000000000011e R15: dffffc0000000000
FS: 00007fcfd0717700(0000) GS:ffff8881f7000000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fcfd07d5520 CR3: 000000010a142000 CR4: 00000000003506b0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
ext4_writepages+0xcbb/0x3950 fs/ext4/inode.c:2776
do_writepages+0x13a/0x280 mm/page-writeback.c:2358
__filemap_fdatawrite_range+0x356/0x420 mm/filemap.c:427
filemap_write_and_wait_range+0x64/0xe0 mm/filemap.c:660
__iomap_dio_rw+0x621/0x10c0 fs/iomap/direct-io.c:495
iomap_dio_rw+0x35/0x80 fs/iomap/direct-io.c:611
ext4_dio_write_iter fs/ext4/file.c:571 [inline]
ext4_file_write_iter+0xfc5/0x1b70 fs/ext4/file.c:681
do_iter_readv_writev+0x548/0x740 include/linux/fs.h:1941
do_iter_write+0x182/0x660 fs/read_write.c:866
vfs_iter_write+0x7c/0xa0 fs/read_write.c:907
iter_file_splice_write+0x7fb/0xf70 fs/splice.c:686
do_splice_from fs/splice.c:764 [inline]
direct_splice_actor+0xfe/0x130 fs/splice.c:933
splice_direct_to_actor+0x4f4/0xbc0 fs/splice.c:888
do_splice_direct+0x28b/0x3e0 fs/splice.c:976
do_sendfile+0x914/0x1390 fs/read_write.c:1257
__do_sys_sendfile64 fs/read_write.c:1318 [inline]
__se_sys_sendfile64 fs/read_write.c:1304 [inline]
__x64_sys_sendfile64+0x1c4/0x220 fs/read_write.c:1304
do_syscall_64+0x31/0x70 arch/x86/entry/common.c:46
entry_SYSCALL_64_after_hwframe+0x44/0xa9
RIP: 0033:0x7fcfd0793809
Code: 28 00 00 00 75 05 48 83 c4 28 c3 e8 31 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 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fcfd0717308 EFLAGS: 00000246 ORIG_RAX: 0000000000000028
RAX: ffffffffffffffda RBX: 00007fcfd081c298 RCX: 00007fcfd0793809
RDX: 0000000000000000 RSI: 0000000000000004 RDI: 0000000000000003
RBP: 00007fcfd081c290 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000080000005 R11: 0000000000000246 R12: 00007fcfd081c29c
R13: 00007fcfd07e2a90 R14: 65732f636f72702f R15: 0000000000022000
Modules linked in:
---[ end trace 32f51ef0a2327213 ]---
RIP: 0010:mpage_prepare_extent_to_map+0xbe9/0xc00 fs/ext4/inode.c:2647
Code: e8 fc bd c3 ff e9 80 f6 ff ff 44 89 e9 80 e1 07 38 c1 0f 8c a6 fe ff ff 4c 89 ef e8 e1 bd c3 ff e9 99 fe ff ff e8 87 c9 89 ff <0f> 0b e8 80 c9 89 ff 0f 0b e8 79 1e b8 02 66 0f 1f 84 00 00 00 00
RSP: 0018:ffffc90000e2e9c0 EFLAGS: 00010293
RAX: ffffffff81e321f9 RBX: 0000000000000000 RCX: ffff88810c12cf00
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffffc90000e2eb90 R08: ffffffff81e31e71 R09: fffff940008d68b1
R10: fffff940008d68b1 R11: 0000000000000000 R12: ffffea00046b4580
R13: ffffc90000e2ea80 R14: 000000000000011e R15: dffffc0000000000
FS: 00007fcfd0717700(0000) GS:ffff8881f7000000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fcfd07d5520 CR3: 000000010a142000 CR4: 00000000003506b0
Reply all
Reply to author
Forward
0 new messages