syzbot


general protection fault in timerqueue_del (2)

Status: fixed on 2024/01/31 13:17
Subsystems: kernel
[Documentation on labels]
Reported-by: syzbot+500a5eabc2495aaeb60e@syzkaller.appspotmail.com
Fix commit: 6f861765464f fs: Block writes to mounted block devices
First crash: 270d, last: 128d
Cause bisection: introduced by (bisect log) :
commit 2acf15b94d5b8ea8392c4b6753a6ffac3135cd78
Author: Yu Kuai <yukuai3@huawei.com>
Date: Fri Jul 2 04:07:43 2021 +0000

  reiserfs: add check for root_inode in reiserfs_fill_super

Crash: possible deadlock in fs_reclaim_acquire (log)
Repro: C syz .config
  
Fix bisection: fixed by (bisect log) :
commit 6f861765464f43a71462d52026fbddfc858239a5
Author: Jan Kara <jack@suse.cz>
Date: Wed Nov 1 17:43:10 2023 +0000

  fs: Block writes to mounted block devices

  
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [reiserfs?] general protection fault in timerqueue_del (2) 1 (3) 2024/01/29 09:39
Similar bugs (2)
Kernel Title Repro Cause bisect Fix bisect Count Last Reported Patched Status
upstream general protection fault in timerqueue_del kernel 1 368d 364d 0/26 auto-obsoleted due to no activity on 2023/07/23 15:07
upstream BUG: unable to handle kernel paging request in timerqueue_del kernel 1 969d 963d 0/26 auto-closed as invalid on 2021/12/29 14:44
Last patch testing requests (7)
Created Duration User Patch Repo Result
2024/01/14 22:40 20m retest repro upstream OK log
2024/01/09 17:59 19m retest repro upstream OK log
2023/11/05 17:09 14m retest repro upstream report log
2023/10/31 16:09 16m retest repro upstream report log
2023/10/17 02:35 1h00m yuran.pereira@hotmail.com https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git master report log
2023/08/27 13:34 31m retest repro upstream report log
2023/08/27 13:34 25m retest repro upstream report log
Fix bisection attempts (4)
Created Duration User Patch Repo Result
2024/01/27 20:57 10h19m bisect fix upstream job log (1)
2023/12/20 17:47 2h45m bisect fix upstream job log (0) log
2023/11/19 14:28 2h34m bisect fix upstream job log (0) log
2023/10/03 07:37 3h51m bisect fix upstream job log (0) log

Sample crash report:
general protection fault, probably for non-canonical address 0xfff10c173258a422: 0000 [#1] PREEMPT SMP KASAN
KASAN: maybe wild-memory-access in range [0xff8880b992c52110-0xff8880b992c52117]
CPU: 1 PID: 5021 Comm: syz-executor329 Not tainted 6.5.0-rc4-syzkaller-00009-g4b954598a47b #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2023
RIP: 0010:__rb_change_child include/linux/rbtree_augmented.h:173 [inline]
RIP: 0010:__rb_rotate_set_parents lib/rbtree.c:81 [inline]
RIP: 0010:____rb_erase_color lib/rbtree.c:256 [inline]
RIP: 0010:rb_erase+0x530/0x1360 lib/rbtree.c:445
Code: 48 83 f8 03 48 89 03 48 89 5d 00 0f 86 b9 00 00 00 48 ba 00 00 00 00 00 fc ff df 48 83 e0 fc 48 8d 78 10 48 89 fe 48 c1 ee 03 <80> 3c 16 00 0f 85 bb 0c 00 00 48 3b 68 10 0f 84 26 03 00 00 48 8d
RSP: 0018:ffffc900001e0d90 EFLAGS: 00010016
RAX: ff8880b992c52100 RBX: ffffc90003a4f818 RCX: ffff8880b992b950
RDX: dffffc0000000000 RSI: 1ff110173258a422 RDI: ff8880b992c52110
RBP: ffff8880b992c520 R08: 0000000000000006 R09: ffff8880b992c521
R10: ffff8880b992c1b0 R11: ffffc900001e0ff8 R12: dffffc0000000000
R13: ffff8880b992c521 R14: ffff8880b992c521 R15: ffff8880b992c528
FS:  00005555562f9380(0000) GS:ffff8880b9900000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fa5ff797000 CR3: 0000000029d93000 CR4: 0000000000350ee0
Call Trace:
 <IRQ>
 rb_erase_cached include/linux/rbtree.h:126 [inline]
 timerqueue_del+0x83/0x140 lib/timerqueue.c:57
 __remove_hrtimer+0x99/0x290 kernel/time/hrtimer.c:1119
 __run_hrtimer kernel/time/hrtimer.c:1668 [inline]
 __hrtimer_run_queues+0x55b/0xc10 kernel/time/hrtimer.c:1752
 hrtimer_interrupt+0x31b/0x800 kernel/time/hrtimer.c:1814
 local_apic_timer_interrupt arch/x86/kernel/apic/apic.c:1098 [inline]
 __sysvec_apic_timer_interrupt+0x14a/0x430 arch/x86/kernel/apic/apic.c:1115
 sysvec_apic_timer_interrupt+0x8e/0xc0 arch/x86/kernel/apic/apic.c:1109
 </IRQ>
 <TASK>
 asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:645
RIP: 0010:memmove+0x5f/0x1b0 arch/x86/lib/memmove_64.S:76
Code: 38 fe 74 47 48 83 ea 20 48 83 ea 20 4c 8b 1e 4c 8b 56 08 4c 8b 4e 10 4c 8b 46 18 48 8d 76 20 4c 89 1f 4c 89 57 08 4c 89 4f 10 <4c> 89 47 18 48 8d 7f 20 73 d4 48 83 c2 20 e9 b4 00 00 00 66 66 2e
RSP: 0018:ffffc9000390ef88 EFLAGS: 00000286
RAX: ffff888073e61fb4 RBX: 0000000000000002 RCX: ffff888073e61030
RDX: fffffffffd4d2600 RSI: ffff88807698f964 RDI: ffff88807698f954
RBP: 0000000000000020 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000000 R12: 0000000000000001
R13: 0000000000000000 R14: ffff888073e61fa4 R15: 0000000000000010
 leaf_paste_entries+0x43c/0x920 fs/reiserfs/lbalance.c:1377
 balance_leaf_finish_node_paste_dirent fs/reiserfs/do_balan.c:1295 [inline]
 balance_leaf_finish_node_paste fs/reiserfs/do_balan.c:1321 [inline]
 balance_leaf_finish_node fs/reiserfs/do_balan.c:1364 [inline]
 balance_leaf+0x9476/0xcd90 fs/reiserfs/do_balan.c:1452
 do_balance+0x337/0x840 fs/reiserfs/do_balan.c:1888
 reiserfs_paste_into_item+0x62a/0x7c0 fs/reiserfs/stree.c:2157
 reiserfs_add_entry+0x936/0xd60 fs/reiserfs/namei.c:565
 reiserfs_mkdir+0x68a/0x9a0 fs/reiserfs/namei.c:860
 xattr_mkdir fs/reiserfs/xattr.c:77 [inline]
 create_privroot fs/reiserfs/xattr.c:890 [inline]
 reiserfs_xattr_init+0x57f/0xbb0 fs/reiserfs/xattr.c:1006
 reiserfs_fill_super+0x2139/0x3150 fs/reiserfs/super.c:2175
 mount_bdev+0x30d/0x3d0 fs/super.c:1391
 legacy_get_tree+0x109/0x220 fs/fs_context.c:611
 vfs_get_tree+0x88/0x350 fs/super.c:1519
 do_new_mount fs/namespace.c:3335 [inline]
 path_mount+0x1492/0x1ed0 fs/namespace.c:3662
 do_mount fs/namespace.c:3675 [inline]
 __do_sys_mount fs/namespace.c:3884 [inline]
 __se_sys_mount fs/namespace.c:3861 [inline]
 __x64_sys_mount+0x293/0x310 fs/namespace.c:3861
 do_syscall_x64 arch/x86/entry/common.c:50 [inline]
 do_syscall_64+0x38/0xb0 arch/x86/entry/common.c:80
 entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7fa6077d7d7a
Code: d8 64 89 02 48 c7 c0 ff ff ff ff eb a6 e8 5e 04 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 b8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007ffd88d77a68 EFLAGS: 00000286 ORIG_RAX: 00000000000000a5
RAX: ffffffffffffffda RBX: 00007ffd88d77a80 RCX: 00007fa6077d7d7a
RDX: 0000000020001100 RSI: 0000000020000040 RDI: 00007ffd88d77a80
RBP: 0000000000000004 R08: 00007ffd88d77ac0 R09: 00000000000010f4
R10: 0000000000000080 R11: 0000000000000286 R12: 0000000000000080
R13: 00007ffd88d77ac0 R14: 0000000000000003 R15: 0000000000400000
 </TASK>
Modules linked in:
---[ end trace 0000000000SeaBIOS (version 1.8.2-google)
----------------
Code disassembly (best guess):
   0:	48 83 f8 03          	cmp    $0x3,%rax
   4:	48 89 03             	mov    %rax,(%rbx)
   7:	48 89 5d 00          	mov    %rbx,0x0(%rbp)
   b:	0f 86 b9 00 00 00    	jbe    0xca
  11:	48 ba 00 00 00 00 00 	movabs $0xdffffc0000000000,%rdx
  18:	fc ff df
  1b:	48 83 e0 fc          	and    $0xfffffffffffffffc,%rax
  1f:	48 8d 78 10          	lea    0x10(%rax),%rdi
  23:	48 89 fe             	mov    %rdi,%rsi
  26:	48 c1 ee 03          	shr    $0x3,%rsi
* 2a:	80 3c 16 00          	cmpb   $0x0,(%rsi,%rdx,1) <-- trapping instruction
  2e:	0f 85 bb 0c 00 00    	jne    0xcef
  34:	48 3b 68 10          	cmp    0x10(%rax),%rbp
  38:	0f 84 26 03 00 00    	je     0x364
  3e:	48                   	rex.W
  3f:	8d                   	.byte 0x8d

Crashes (3):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2023/08/03 01:26 upstream 4b954598a47b 39a91c18 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-kasan-gce-root general protection fault in timerqueue_del
2023/07/31 15:06 upstream 5d0c230f1de8 2a0d0f29 .config console log report syz C [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-kasan-gce-root general protection fault in timerqueue_del
2023/10/17 14:59 upstream 213f891525c2 342b9c55 .config console log report syz [disk image] [vmlinux] [kernel image] [mounted in repro] ci-upstream-kasan-gce-root general protection fault in timerqueue_del
* Struck through repros no longer work on HEAD.