[v5.15] BUG: unable to handle kernel paging request in write_inode_now

0 views
Skip to first unread message

syzbot

unread,
Apr 26, 2023, 10:54:59 AM4/26/23
to syzkaller...@googlegroups.com
Hello,

syzbot found the following issue on:

HEAD commit: f48aeeaaa64c Linux 5.15.109
git tree: linux-5.15.y
console output: https://syzkaller.appspot.com/x/log.txt?x=129c8064280000
kernel config: https://syzkaller.appspot.com/x/.config?x=dd54db86b106e341
dashboard link: https://syzkaller.appspot.com/bug?extid=93da6e97a594c63ac165
compiler: Debian clang version 15.0.7, GNU ld (GNU Binutils for Debian) 2.35.2

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

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/5ca5c1cc3cce/disk-f48aeeaa.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/362919aba204/vmlinux-f48aeeaa.xz
kernel image: https://storage.googleapis.com/syzbot-assets/73de4b9cdbe0/bzImage-f48aeeaa.xz

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

loop1: detected capacity change from 0 to 4096
ntfs3: loop1: Different NTFS' sector size (1024) and media sector size (512)
BUG: unable to handle page fault for address: fffff5210191ff2b
#PF: supervisor write access in kernel mode
#PF: error_code(0x0002) - not-present page
PGD 23ffee067 P4D 23ffee067 PUD 0
Oops: 0002 [#1] PREEMPT SMP KASAN
CPU: 0 PID: 26452 Comm: syz-executor.1 Not tainted 5.15.109-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/14/2023
RIP: 0010:write_inode_now+0x27c/0x2f0 fs/fs-writeback.c:2775
Code: 0a 00 00 31 d2 e8 64 8f 77 ff 2e 2e 2e 31 c0 4c 89 ff 48 8d 74 24 40 e8 82 00 00 00 48 c7 44 24 20 0e 36 e0 45 48 8b 4c 24 18 <41> c7 04 0e 00 00 00 00 41 c7 44 0e 10 00 00 00 00 65 48 8b 0c 25
RSP: 0018:ffffc9000c8ff940 EFLAGS: 00010246
RAX: 0000000000000000 RBX: 0000000000000001 RCX: 1ffff9200191ff2c
RDX: 0000000000000000 RSI: 0000000000000004 RDI: 0000000000000001
RBP: ffffc9000c8ffa48 R08: dffffc0000000000 R09: ffffed1009d3dc58
R10: 0000000000000000 R11: dffffc0000000001 R12: ffff88804e9ee230
R13: ffff88804e9ee230 R14: dffffc00ffffffff R15: ffff88804e9ee230
FS: 00007fc5ee9ef700(0000) GS:ffff8880b9a00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: fffff5210191ff2b CR3: 0000000053030000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
iput_final fs/inode.c:1650 [inline]
iput+0x5ce/0x8b0 fs/inode.c:1689
ntfs_fill_super+0x3c3f/0x4450 fs/ntfs3/super.c:1185
get_tree_bdev+0x3fe/0x620 fs/super.c:1303
vfs_get_tree+0x88/0x270 fs/super.c:1508
do_new_mount+0x28b/0xad0 fs/namespace.c:2994
do_mount fs/namespace.c:3337 [inline]
__do_sys_mount fs/namespace.c:3545 [inline]
__se_sys_mount+0x2d5/0x3c0 fs/namespace.c:3522
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7fc5f047e69a
Code: 48 c7 c2 b8 ff ff ff f7 d8 64 89 02 b8 ff ff ff ff eb d2 e8 b8 04 00 00 0f 1f 84 00 00 00 00 00 49 89 ca b8 a5 00 00 00 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:00007fc5ee9eef88 EFLAGS: 00000202 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 000000000001f6c7 RCX: 00007fc5f047e69a
RDX: 000000002001f700 RSI: 000000002001f740 RDI: 00007fc5ee9eefe0
RBP: 00007fc5ee9ef020 R08: 00007fc5ee9ef020 R09: 0000000000004516
R10: 0000000000004516 R11: 0000000000000202 R12: 000000002001f700
R13: 000000002001f740 R14: 00007fc5ee9eefe0 R15: 000000002001f780
</TASK>
Modules linked in:
CR2: fffff5210191ff2b
---[ end trace 1bdbd7ce201a2f0d ]---
RIP: 0010:write_inode_now+0x27c/0x2f0 fs/fs-writeback.c:2775
Code: 0a 00 00 31 d2 e8 64 8f 77 ff 2e 2e 2e 31 c0 4c 89 ff 48 8d 74 24 40 e8 82 00 00 00 48 c7 44 24 20 0e 36 e0 45 48 8b 4c 24 18 <41> c7 04 0e 00 00 00 00 41 c7 44 0e 10 00 00 00 00 65 48 8b 0c 25
RSP: 0018:ffffc9000c8ff940 EFLAGS: 00010246
RAX: 0000000000000000 RBX: 0000000000000001 RCX: 1ffff9200191ff2c
RDX: 0000000000000000 RSI: 0000000000000004 RDI: 0000000000000001
RBP: ffffc9000c8ffa48 R08: dffffc0000000000 R09: ffffed1009d3dc58
R10: 0000000000000000 R11: dffffc0000000001 R12: ffff88804e9ee230
R13: ffff88804e9ee230 R14: dffffc00ffffffff R15: ffff88804e9ee230
FS: 00007fc5ee9ef700(0000) GS:ffff8880b9a00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: fffff5210191ff2b CR3: 0000000053030000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
0: 0a 00 or (%rax),%al
2: 00 31 add %dh,(%rcx)
4: d2 e8 shr %cl,%al
6: 64 8f fs (bad)
8: 77 ff ja 0x9
a: 2e 2e 2e 31 c0 cs cs cs xor %eax,%eax
f: 4c 89 ff mov %r15,%rdi
12: 48 8d 74 24 40 lea 0x40(%rsp),%rsi
17: e8 82 00 00 00 callq 0x9e
1c: 48 c7 44 24 20 0e 36 movq $0x45e0360e,0x20(%rsp)
23: e0 45
25: 48 8b 4c 24 18 mov 0x18(%rsp),%rcx
* 2a: 41 c7 04 0e 00 00 00 movl $0x0,(%r14,%rcx,1) <-- trapping instruction
31: 00
32: 41 c7 44 0e 10 00 00 movl $0x0,0x10(%r14,%rcx,1)
39: 00 00
3b: 65 gs
3c: 48 rex.W
3d: 8b .byte 0x8b
3e: 0c 25 or $0x25,%al


---
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,
May 23, 2023, 6:05:45 PM5/23/23
to syzkaller...@googlegroups.com
syzbot has found a reproducer for the following issue on:

HEAD commit: 9d6bde853685 Linux 5.15.112
git tree: linux-5.15.y
console output: https://syzkaller.appspot.com/x/log.txt?x=118fcbf9280000
kernel config: https://syzkaller.appspot.com/x/.config?x=a61e8195d8bdf36e
dashboard link: https://syzkaller.appspot.com/bug?extid=93da6e97a594c63ac165
compiler: Debian clang version 15.0.7, GNU ld (GNU Binutils for Debian) 2.35.2
syz repro: https://syzkaller.appspot.com/x/repro.syz?x=10ab80c1280000
C reproducer: https://syzkaller.appspot.com/x/repro.c?x=17048772280000

Downloadable assets:
disk image: https://storage.googleapis.com/syzbot-assets/b65d6c2ec328/disk-9d6bde85.raw.xz
vmlinux: https://storage.googleapis.com/syzbot-assets/cf811ebac37b/vmlinux-9d6bde85.xz
kernel image: https://storage.googleapis.com/syzbot-assets/b2f32fdecf97/bzImage-9d6bde85.xz
mounted in repro #1: https://storage.googleapis.com/syzbot-assets/8cc51bb669d3/mount_0.gz
mounted in repro #2: https://storage.googleapis.com/syzbot-assets/5307732f738f/mount_4.gz

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

loop0: detected capacity change from 0 to 4096
ntfs3: loop0: Different NTFS' sector size (2048) and media sector size (512)
BUG: unable to handle page fault for address: fffff521008e1f2b
#PF: supervisor write access in kernel mode
#PF: error_code(0x0002) - not-present page
PGD 23ffee067 P4D 23ffee067 PUD 0
Oops: 0002 [#1] PREEMPT SMP KASAN
CPU: 0 PID: 5792 Comm: syz-executor790 Not tainted 5.15.112-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 04/28/2023
RIP: 0010:write_inode_now+0x27c/0x2f0 fs/fs-writeback.c:2778
Code: 0a 00 00 31 d2 e8 54 81 77 ff 2e 2e 2e 31 c0 4c 89 ff 48 8d 74 24 40 e8 82 00 00 00 48 c7 44 24 20 0e 36 e0 45 48 8b 4c 24 18 <41> c7 04 0e 00 00 00 00 41 c7 44 0e 10 00 00 00 00 65 48 8b 0c 25
RSP: 0018:ffffc9000470f940 EFLAGS: 00010246
RAX: 0000000000000000 RBX: 0000000000000001 RCX: 1ffff920008e1f2c
RDX: 0000000000000000 RSI: 0000000000000004 RDI: 0000000000000001
RBP: ffffc9000470fa48 R08: dffffc0000000000 R09: ffffed100e1264f8
R10: 0000000000000000 R11: dffffc0000000001 R12: ffff888070932730
R13: ffff888070932730 R14: dffffc00ffffffff R15: ffff888070932730
FS: 00007f80c6776700(0000) GS:ffff8880b9a00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: fffff521008e1f2b CR3: 000000001f719000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
<TASK>
iput_final fs/inode.c:1650 [inline]
iput+0x5ce/0x8b0 fs/inode.c:1689
ntfs_fill_super+0x3c3f/0x4450 fs/ntfs3/super.c:1185
get_tree_bdev+0x3fe/0x620 fs/super.c:1303
vfs_get_tree+0x88/0x270 fs/super.c:1508
do_new_mount+0x28b/0xad0 fs/namespace.c:2994
do_mount fs/namespace.c:3337 [inline]
__do_sys_mount fs/namespace.c:3545 [inline]
__se_sys_mount+0x2d5/0x3c0 fs/namespace.c:3522
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x3d/0xb0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x61/0xcb
RIP: 0033:0x7f80c67cc1fa
Code: 48 c7 c2 b8 ff ff ff f7 d8 64 89 02 b8 ff ff ff ff eb d2 e8 d8 00 00 00 0f 1f 84 00 00 00 00 00 49 89 ca b8 a5 00 00 00 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:00007f80c6776128 EFLAGS: 00000286 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 00007f80c67766b8 RCX: 00007f80c67cc1fa
RDX: 000000002001f340 RSI: 000000002001f380 RDI: 00007f80c6776180
RBP: 0000000000000004 R08: 00007f80c67761c0 R09: 000000000001f323
R10: 0000000000000000 R11: 0000000000000286 R12: 000000002001f340
R13: 000000002001f380 R14: 000000000001f329 R15: 000000002001f3c0
</TASK>
Modules linked in:
CR2: fffff521008e1f2b
---[ end trace fb6ec743ca6f078c ]---
RIP: 0010:write_inode_now+0x27c/0x2f0 fs/fs-writeback.c:2778
Code: 0a 00 00 31 d2 e8 54 81 77 ff 2e 2e 2e 31 c0 4c 89 ff 48 8d 74 24 40 e8 82 00 00 00 48 c7 44 24 20 0e 36 e0 45 48 8b 4c 24 18 <41> c7 04 0e 00 00 00 00 41 c7 44 0e 10 00 00 00 00 65 48 8b 0c 25
RSP: 0018:ffffc9000470f940 EFLAGS: 00010246
RAX: 0000000000000000 RBX: 0000000000000001 RCX: 1ffff920008e1f2c
RDX: 0000000000000000 RSI: 0000000000000004 RDI: 0000000000000001
RBP: ffffc9000470fa48 R08: dffffc0000000000 R09: ffffed100e1264f8
R10: 0000000000000000 R11: dffffc0000000001 R12: ffff888070932730
R13: ffff888070932730 R14: dffffc00ffffffff R15: ffff888070932730
FS: 00007f80c6776700(0000) GS:ffff8880b9a00000(0000) knlGS:0000000000000000
CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: fffff521008e1f2b CR3: 000000001f719000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
0: 0a 00 or (%rax),%al
2: 00 31 add %dh,(%rcx)
4: d2 e8 shr %cl,%al
6: 54 push %rsp
7: 81 77 ff 2e 2e 2e 31 xorl $0x312e2e2e,-0x1(%rdi)
e: c0 4c 89 ff 48 rorb $0x48,-0x1(%rcx,%rcx,4)
13: 8d 74 24 40 lea 0x40(%rsp),%esi
17: e8 82 00 00 00 callq 0x9e
1c: 48 c7 44 24 20 0e 36 movq $0x45e0360e,0x20(%rsp)
23: e0 45
25: 48 8b 4c 24 18 mov 0x18(%rsp),%rcx
* 2a: 41 c7 04 0e 00 00 00 movl $0x0,(%r14,%rcx,1) <-- trapping instruction
31: 00
32: 41 c7 44 0e 10 00 00 movl $0x0,0x10(%r14,%rcx,1)
39: 00 00
3b: 65 gs
3c: 48 rex.W
3d: 8b .byte 0x8b
3e: 0c 25 or $0x25,%al


---
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