syzbot


general protection fault in proc_sys_compare

Status: upstream: reported syz repro on 2025/03/07 02:45
Subsystems: bcachefs
[Documentation on labels]
Reported-by: syzbot+4364ec1693041cad20de@syzkaller.appspotmail.com
First crash: 8d23h, last: 8d23h
Cause bisection: introduced by (bisect log) :
commit 579cd64b9df8a60284ec3422be919c362de40e41
Author: Hector Martin <marcan@marcan.st>
Date: Sat Feb 8 00:54:35 2025 +0000

  ASoC: tas2770: Fix volume scale

Crash: invalid opcode in bch2_btree_path_peek_slot (log)
Repro: syz .config
  
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [bcachefs?] general protection fault in proc_sys_compare 6 (7) 2025/03/08 21:58

Sample crash report:
Oops: general protection fault, probably for non-canonical address 0xdffffc0000000000: 0000 [#1] PREEMPT SMP KASAN PTI
KASAN: null-ptr-deref in range [0x0000000000000000-0x0000000000000007]
CPU: 0 UID: 0 PID: 5490 Comm: dhcpcd Not tainted 6.14.0-rc4-syzkaller-00295-gb91872c56940 #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 02/12/2025
RIP: 0010:sysctl_is_seen fs/proc/proc_sysctl.c:907 [inline]
RIP: 0010:proc_sys_compare+0x1ba/0x260 fs/proc/proc_sysctl.c:932
Code: 09 89 c5 31 ff 89 c6 e8 04 b2 5e ff 85 ed 74 56 80 3d d2 ae c2 0d 01 75 6f e8 b2 ad 5e ff e9 74 ff ff ff 48 89 e8 48 c1 e8 03 <42> 80 3c 28 00 74 08 48 89 ef e8 d7 61 c3 ff 48 8b 5d 00 48 85 db
RSP: 0018:ffffc90003547718 EFLAGS: 00010246
RAX: 0000000000000000 RBX: ffffffff8c3b6218 RCX: 0000000000000001
RDX: dffffc0000000000 RSI: 0000000000000004 RDI: ffffc900035476a0
RBP: 0000000000000000 R08: 0000000000000003 R09: fffff520006a8ed4
R10: dffffc0000000000 R11: fffff520006a8ed4 R12: 0000000000000004
R13: dffffc0000000000 R14: ffff88806c232c30 R15: ffff88806c040020
FS:  00007f2e2350e740(0000) GS:ffff8880b8600000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000056042d48d000 CR3: 000000001e6d2000 CR4: 00000000003526f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 d_same_name fs/dcache.c:2137 [inline]
 __d_lookup+0x533/0x7b0 fs/dcache.c:2361
 lookup_fast+0x79/0x590 fs/namei.c:1751
 walk_component fs/namei.c:2110 [inline]
 link_path_walk+0x672/0xea0 fs/namei.c:2479
 path_openat+0x266/0x3590 fs/namei.c:3985
 do_filp_open+0x27f/0x4e0 fs/namei.c:4016
 do_sys_openat2+0x13e/0x1d0 fs/open.c:1428
 do_sys_open fs/open.c:1443 [inline]
 __do_sys_openat fs/open.c:1459 [inline]
 __se_sys_openat fs/open.c:1454 [inline]
 __x64_sys_openat+0x247/0x2a0 fs/open.c:1454
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0xf3/0x230 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7f2e235d89a4
Code: 24 20 48 8d 44 24 30 48 89 44 24 28 64 8b 04 25 18 00 00 00 85 c0 75 2c 44 89 e2 48 89 ee bf 9c ff ff ff b8 01 01 00 00 0f 05 <48> 3d 00 f0 ff ff 76 60 48 8b 15 55 a4 0d 00 f7 d8 64 89 02 48 83
RSP: 002b:00007ffcef5bc920 EFLAGS: 00000246 ORIG_RAX: 0000000000000101
RAX: ffffffffffffffda RBX: 00000000000100a0 RCX: 00007f2e235d89a4
RDX: 0000000000000000 RSI: 00007ffcef5ccbb8 RDI: 00000000ffffff9c
RBP: 00007ffcef5ccbb8 R08: 0000000000000000 R09: 00007ffcef5ccb28
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007ffcef5bca38 R14: 00007ffcef5bca38 R15: 0000000000000000
 </TASK>
Modules linked in:
---[ end trace 0000000000000000 ]---
RIP: 0010:sysctl_is_seen fs/proc/proc_sysctl.c:907 [inline]
RIP: 0010:proc_sys_compare+0x1ba/0x260 fs/proc/proc_sysctl.c:932
Code: 09 89 c5 31 ff 89 c6 e8 04 b2 5e ff 85 ed 74 56 80 3d d2 ae c2 0d 01 75 6f e8 b2 ad 5e ff e9 74 ff ff ff 48 89 e8 48 c1 e8 03 <42> 80 3c 28 00 74 08 48 89 ef e8 d7 61 c3 ff 48 8b 5d 00 48 85 db
RSP: 0018:ffffc90003547718 EFLAGS: 00010246
RAX: 0000000000000000 RBX: ffffffff8c3b6218 RCX: 0000000000000001
RDX: dffffc0000000000 RSI: 0000000000000004 RDI: ffffc900035476a0
RBP: 0000000000000000 R08: 0000000000000003 R09: fffff520006a8ed4
R10: dffffc0000000000 R11: fffff520006a8ed4 R12: 0000000000000004
R13: dffffc0000000000 R14: ffff88806c232c30 R15: ffff88806c040020
FS:  00007f2e2350e740(0000) GS:ffff8880b8600000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 000056042d48d000 CR3: 000000001e6d2000 CR4: 00000000003526f0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess), 1 bytes skipped:
   0:	89 c5                	mov    %eax,%ebp
   2:	31 ff                	xor    %edi,%edi
   4:	89 c6                	mov    %eax,%esi
   6:	e8 04 b2 5e ff       	call   0xff5eb20f
   b:	85 ed                	test   %ebp,%ebp
   d:	74 56                	je     0x65
   f:	80 3d d2 ae c2 0d 01 	cmpb   $0x1,0xdc2aed2(%rip)        # 0xdc2aee8
  16:	75 6f                	jne    0x87
  18:	e8 b2 ad 5e ff       	call   0xff5eadcf
  1d:	e9 74 ff ff ff       	jmp    0xffffff96
  22:	48 89 e8             	mov    %rbp,%rax
  25:	48 c1 e8 03          	shr    $0x3,%rax
* 29:	42 80 3c 28 00       	cmpb   $0x0,(%rax,%r13,1) <-- trapping instruction
  2e:	74 08                	je     0x38
  30:	48 89 ef             	mov    %rbp,%rdi
  33:	e8 d7 61 c3 ff       	call   0xffc3620f
  38:	48 8b 5d 00          	mov    0x0(%rbp),%rbx
  3c:	48 85 db             	test   %rbx,%rbx

Crashes (1):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/03/03 02:33 upstream b91872c56940 c3901742 .config console log report syz / log [disk image] [vmlinux] [kernel image] [mounted in repro] ci2-upstream-fs general protection fault in proc_sys_compare
* Struck through repros no longer work on HEAD.