syzbot


general protection fault in prepare_for_delete_or_cut

Status: upstream: reported C repro on 2022/12/30 06:10
Subsystems: reiserfs fat
[Documentation on labels]
Reported-by: syzbot+ed64b374d2cdc63e247e@syzkaller.appspotmail.com
First crash: 455d, last: 408d
Similar bugs (3)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream general protection fault in prepare_for_delete_or_cut reiserfs C error done 71 63d 447d 0/26 upstream: reported C repro on 2023/01/06 16:52
linux-4.19 general protection fault in prepare_for_delete_or_cut fat reiserfs C error 3 423d 452d 0/1 upstream: reported C repro on 2023/01/01 21:41
linux-6.1 BUG: unable to handle kernel paging request in prepare_for_delete_or_cut origin:upstream C 2 4d03h 27d 0/3 upstream: reported C repro on 2024/03/02 01:50
Fix bisection attempts (1)
Created Duration User Patch Repo Result
2023/02/15 04:48 27m bisect fix linux-4.14.y job log (0) log

Sample crash report:
REISERFS error (device loop0): vs-13050 reiserfs_update_sd_size: i/o failure occurred trying to update [2 2 0x0 SD] stat data
REISERFS warning: reiserfs-5093 is_leaf: item entry count seems wrong *3.5*[2 1 0(1) DIR], item_len 35, item_location 4029, free_space(entry_count) 2
REISERFS error (device loop0): vs-5150 search_by_key: invalid format found in block 532. Fsck?
kasan: CONFIG_KASAN_INLINE enabled
kasan: GPF could be caused by NULL-ptr deref or user memory access
general protection fault: 0000 [#1] PREEMPT SMP KASAN
Modules linked in:
CPU: 0 PID: 7966 Comm: syz-executor384 Not tainted 4.14.302-syzkaller #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/26/2022
task: ffff8880b37a20c0 task.stack: ffff8880b36c0000
RIP: 0010:reiserfs_node_data fs/reiserfs/reiserfs.h:2186 [inline]
RIP: 0010:item_head fs/reiserfs/reiserfs.h:2202 [inline]
RIP: 0010:tp_item_head fs/reiserfs/reiserfs.h:2228 [inline]
RIP: 0010:prepare_for_delete_or_cut+0x115/0x18c0 fs/reiserfs/stree.c:1060
RSP: 0018:ffff8880b36c7500 EFLAGS: 00010206
RAX: dffffc0000000000 RBX: ffff8880b36c76c0 RCX: ffff8880b36c7b20
RDX: 0000000000000005 RSI: ffff88808df46788 RDI: 0000000000000028
RBP: 0000000000000000 R08: ffff8880b36c76d0 R09: ffff8880b36c76c0
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000000
R13: 0000000000000002 R14: 1ffff110166d8f6c R15: ffff8880b36c76d0
FS:  0000555556841300(0000) GS:ffff8880ba400000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fd5c86be740 CR3: 00000000b613a000 CR4: 00000000003406f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 reiserfs_cut_from_item+0x1ca/0x1570 fs/reiserfs/stree.c:1692
 reiserfs_do_truncate+0x53f/0xf50 fs/reiserfs/stree.c:1983
 reiserfs_truncate_file+0x17e/0xdb0 fs/reiserfs/inode.c:2319
 reiserfs_file_release+0x758/0xaf0 fs/reiserfs/file.c:115
 __fput+0x25f/0x7a0 fs/file_table.c:210
 task_work_run+0x11f/0x190 kernel/task_work.c:113
 tracehook_notify_resume include/linux/tracehook.h:191 [inline]
 exit_to_usermode_loop+0x1ad/0x200 arch/x86/entry/common.c:164
 prepare_exit_to_usermode arch/x86/entry/common.c:199 [inline]
 syscall_return_slowpath arch/x86/entry/common.c:270 [inline]
 do_syscall_64+0x4a3/0x640 arch/x86/entry/common.c:297
 entry_SYSCALL_64_after_hwframe+0x5e/0xd3
RIP: 0033:0x7f8858b46313
RSP: 002b:00007ffcf69f7198 EFLAGS: 00000246 ORIG_RAX: 0000000000000003
RAX: 0000000000000000 RBX: 0000000000000005 RCX: 00007f8858b46313
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000004
RBP: 00007ffcf69f71a8 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 00007ffcf69f71b0
R13: 0000000000000000 R14: 0000000000000000 R15: 0000000000000000
Code: 00 fc ff df 48 c1 ea 03 80 3c 02 00 0f 85 1a 17 00 00 48 b8 00 00 00 00 00 fc ff df 48 8b 6d 00 48 8d 7d 28 48 89 fa 48 c1 ea 03 <80> 3c 02 00 0f 85 ed 16 00 00 4c 8b 6d 28 49 63 c4 48 8d 44 40 
RIP: reiserfs_node_data fs/reiserfs/reiserfs.h:2186 [inline] RSP: ffff8880b36c7500
RIP: item_head fs/reiserfs/reiserfs.h:2202 [inline] RSP: ffff8880b36c7500
RIP: tp_item_head fs/reiserfs/reiserfs.h:2228 [inline] RSP: ffff8880b36c7500
RIP: prepare_for_delete_or_cut+0x115/0x18c0 fs/reiserfs/stree.c:1060 RSP: ffff8880b36c7500
---[ end trace 0db54383152ced1b ]---
----------------
Code disassembly (best guess), 4 bytes skipped:
   0:	48 c1 ea 03          	shr    $0x3,%rdx
   4:	80 3c 02 00          	cmpb   $0x0,(%rdx,%rax,1)
   8:	0f 85 1a 17 00 00    	jne    0x1728
   e:	48 b8 00 00 00 00 00 	movabs $0xdffffc0000000000,%rax
  15:	fc ff df
  18:	48 8b 6d 00          	mov    0x0(%rbp),%rbp
  1c:	48 8d 7d 28          	lea    0x28(%rbp),%rdi
  20:	48 89 fa             	mov    %rdi,%rdx
  23:	48 c1 ea 03          	shr    $0x3,%rdx
* 27:	80 3c 02 00          	cmpb   $0x0,(%rdx,%rax,1) <-- trapping instruction
  2b:	0f 85 ed 16 00 00    	jne    0x171e
  31:	4c 8b 6d 28          	mov    0x28(%rbp),%r13
  35:	49 63 c4             	movslq %r12d,%rax
  38:	48                   	rex.W
  39:	8d                   	.byte 0x8d
  3a:	44                   	rex.R
  3b:	40                   	rex

Crashes (2):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/01/16 03:53 linux-4.14.y c4215ee4771b a63719e7 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-4-14 general protection fault in prepare_for_delete_or_cut
2022/12/30 06:10 linux-4.14.y c4215ee4771b 44712fbc .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-linux-4-14 general protection fault in prepare_for_delete_or_cut
* Struck through repros no longer work on HEAD.