syzbot


general protection fault in bfs_get_block

Status: upstream: reported C repro on 2023/04/02 00:46
Bug presence: origin:upstream
[Documentation on labels]
Reported-by: syzbot+3b7bfa480e59af94f896@syzkaller.appspotmail.com
First crash: 518d, last: 32d
Bug presence (1)
Date Name Commit Repro Result
2023/05/06 upstream (ToT) 418d5c98319f C [report] WARNING in mark_buffer_dirty
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream general protection fault in bfs_get_block bfs 2 535d 571d 0/27 auto-obsoleted due to no activity on 2023/07/13 12:29
upstream general protection fault in bfs_get_block (2) bfs C error done 2 261d 280d 25/27 fixed on 2024/01/30 15:47
Fix bisection attempts (13)
Created Duration User Patch Repo Result
2024/07/30 20:46 1h03m bisect fix linux-6.1.y OK (0) job log log
2024/06/13 13:48 2h22m bisect fix linux-6.1.y OK (0) job log log
2024/05/14 05:20 1h24m bisect fix linux-6.1.y OK (0) job log log
2024/04/07 10:02 1h43m bisect fix linux-6.1.y OK (0) job log log
2024/03/07 22:56 1h16m bisect fix linux-6.1.y OK (0) job log log
2024/01/29 15:54 1h16m bisect fix linux-6.1.y OK (0) job log log
2023/12/27 16:27 1h02m bisect fix linux-6.1.y OK (0) job log log
2023/11/26 16:18 1h09m bisect fix linux-6.1.y OK (0) job log log
2023/10/25 16:22 2h28m bisect fix linux-6.1.y OK (0) job log log
2023/09/19 04:46 1h06m bisect fix linux-6.1.y OK (0) job log log
2023/07/05 07:12 1h24m bisect fix linux-6.1.y OK (0) job log log
2023/06/01 23:43 45m bisect fix linux-6.1.y OK (0) job log log
2023/05/02 04:09 37m bisect fix linux-6.1.y OK (0) job log log

Sample crash report:
general protection fault, probably for non-canonical address 0xdffffc0000000005: 0000 [#1] PREEMPT SMP KASAN
KASAN: null-ptr-deref in range [0x0000000000000028-0x000000000000002f]
CPU: 0 PID: 3652 Comm: syz-executor319 Not tainted 6.1.22-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/02/2023
RIP: 0010:bfs_move_block fs/bfs/file.c:42 [inline]
RIP: 0010:bfs_move_blocks fs/bfs/file.c:56 [inline]
RIP: 0010:bfs_get_block+0x7f4/0xac0 fs/bfs/file.c:125
Code: 08 4c 89 f7 e8 dd 61 86 ff 41 8b 16 48 89 ef 48 89 de b9 08 00 00 00 e8 fa 3c a5 ff 49 89 c6 48 8d 58 28 48 89 d8 48 c1 e8 03 <42> 80 3c 38 00 74 08 48 89 df e8 ad 61 86 ff 48 8b 2b 49 8d 7d 28
RSP: 0018:ffffc90003d5eaf8 EFLAGS: 00010206
RAX: 0000000000000005 RBX: 0000000000000028 RCX: ffff88807ade57c0
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffff888012844d00 R08: ffffffff81ff0664 R09: fffff94000388077
R10: 0000000000000000 R11: dffffc0000000001 R12: 000000000000002a
R13: ffff88807153e488 R14: 0000000000000000 R15: dffffc0000000000
FS:  0000555556d31300(0000) GS:ffff8880b9800000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000000 CR3: 0000000077bfc000 CR4: 00000000003506f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 __block_write_begin_int+0x544/0x1a30 fs/buffer.c:1991
 __block_write_begin fs/buffer.c:2041 [inline]
 block_write_begin+0x98/0x1f0 fs/buffer.c:2102
 bfs_write_begin+0x31/0xd0 fs/bfs/file.c:177
 generic_perform_write+0x2fc/0x5e0 mm/filemap.c:3754
 __generic_file_write_iter+0x176/0x400 mm/filemap.c:3882
 generic_file_write_iter+0xab/0x310 mm/filemap.c:3914
 __kernel_write_iter+0x2ff/0x710 fs/read_write.c:517
 __kernel_write+0x11c/0x170 fs/read_write.c:537
 __dump_emit+0x232/0x350 fs/coredump.c:804
 writenote+0x21d/0x3b0 fs/binfmt_elf.c:1488
 write_note_info fs/binfmt_elf.c:1956 [inline]
 elf_core_dump+0x30df/0x45b0 fs/binfmt_elf.c:2299
 do_coredump+0x18b7/0x2700 fs/coredump.c:755
 get_signal+0x1454/0x17d0 kernel/signal.c:2844
 arch_do_signal_or_restart+0xb0/0x1a10 arch/x86/kernel/signal.c:869
 exit_to_user_mode_loop+0x6a/0x100 kernel/entry/common.c:168
 exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:204
 irqentry_exit_to_user_mode+0x5/0x30 kernel/entry/common.c:310
 exc_page_fault+0x4e0/0x790 arch/x86/mm/fault.c:1578
 asm_exc_page_fault+0x22/0x30 arch/x86/include/asm/idtentry.h:570
RIP: 0033:0x0
Code: Unable to access opcode bytes at 0xffffffffffffffd6.
RSP: 002b:0000000020000008 EFLAGS: 00010217
RAX: 0000000000000000 RBX: 0000000000000015 RCX: 00007facd9d13f69
RDX: 0000000000000000 RSI: 0000000020000000 RDI: 0000000000000000
RBP: 00007fffd23e0118 R08: 0000000000000000 R09: 0000000000000001
R10: 0000000000000000 R11: 0000000000000246 R12: 00007fffd23e0140
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:bfs_move_block fs/bfs/file.c:42 [inline]
RIP: 0010:bfs_move_blocks fs/bfs/file.c:56 [inline]
RIP: 0010:bfs_get_block+0x7f4/0xac0 fs/bfs/file.c:125
Code: 08 4c 89 f7 e8 dd 61 86 ff 41 8b 16 48 89 ef 48 89 de b9 08 00 00 00 e8 fa 3c a5 ff 49 89 c6 48 8d 58 28 48 89 d8 48 c1 e8 03 <42> 80 3c 38 00 74 08 48 89 df e8 ad 61 86 ff 48 8b 2b 49 8d 7d 28
RSP: 0018:ffffc90003d5eaf8 EFLAGS: 00010206
RAX: 0000000000000005 RBX: 0000000000000028 RCX: ffff88807ade57c0
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffff888012844d00 R08: ffffffff81ff0664 R09: fffff94000388077
R10: 0000000000000000 R11: dffffc0000000001 R12: 000000000000002a
R13: ffff88807153e488 R14: 0000000000000000 R15: dffffc0000000000
FS:  0000555556d31300(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fffd23dffe8 CR3: 0000000077bfc000 CR4: 00000000003506e0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0:	08 4c 89 f7          	or     %cl,-0x9(%rcx,%rcx,4)
   4:	e8 dd 61 86 ff       	callq  0xff8661e6
   9:	41 8b 16             	mov    (%r14),%edx
   c:	48 89 ef             	mov    %rbp,%rdi
   f:	48 89 de             	mov    %rbx,%rsi
  12:	b9 08 00 00 00       	mov    $0x8,%ecx
  17:	e8 fa 3c a5 ff       	callq  0xffa53d16
  1c:	49 89 c6             	mov    %rax,%r14
  1f:	48 8d 58 28          	lea    0x28(%rax),%rbx
  23:	48 89 d8             	mov    %rbx,%rax
  26:	48 c1 e8 03          	shr    $0x3,%rax
* 2a:	42 80 3c 38 00       	cmpb   $0x0,(%rax,%r15,1) <-- trapping instruction
  2f:	74 08                	je     0x39
  31:	48 89 df             	mov    %rbx,%rdi
  34:	e8 ad 61 86 ff       	callq  0xff8661e6
  39:	48 8b 2b             	mov    (%rbx),%rbp
  3c:	49 8d 7d 28          	lea    0x28(%r13),%rdi

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/04/02 00:45 linux-6.1.y 3b29299e5f60 f325deb0 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-6-1-kasan general protection fault in bfs_get_block
* Struck through repros no longer work on HEAD.