syzbot


BUG: unable to handle kernel paging request in kernfs_remove_by_name_ns

Status: upstream: reported on 2025/08/04 08:38
Subsystems: kernfs
[Documentation on labels]
Reported-by: syzbot+4faa3fd832279bd35a81@syzkaller.appspotmail.com
First crash: 75d, last: 10h07m
Discussions (1)
Title Replies (including bot) Last reply
[syzbot] [kernfs?] BUG: unable to handle kernel paging request in kernfs_remove_by_name_ns 0 (1) 2025/08/04 08:38
Similar bugs (1)
Kernel Title Rank 🛈 Repro Cause bisect Fix bisect Count Last Reported Patched Status
linux-6.6 KASAN: global-out-of-bounds Read in kernfs_remove_by_name_ns 17 2 30d 53d 0/2 upstream: reported on 2025/07/27 16:29

Sample crash report:
BUG: unable to handle page fault for address: ffffffff8b4ef1c8
#PF: supervisor write access in kernel mode
#PF: error_code(0x0003) - permissions violation
PGD e385067 P4D e385067 PUD e386063 PMD b4001a1 
Oops: Oops: 0003 [#1] SMP KASAN NOPTI
CPU: 1 UID: 0 PID: 16603 Comm: syz.8.2359 Not tainted syzkaller #0 PREEMPT(full) 
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025
RIP: 0010:arch_atomic64_try_cmpxchg arch/x86/include/asm/atomic64_64.h:101 [inline]
RIP: 0010:raw_atomic64_try_cmpxchg_acquire include/linux/atomic/atomic-arch-fallback.h:4296 [inline]
RIP: 0010:raw_atomic_long_try_cmpxchg_acquire include/linux/atomic/atomic-long.h:1482 [inline]
RIP: 0010:atomic_long_try_cmpxchg_acquire include/linux/atomic/atomic-instrumented.h:4458 [inline]
RIP: 0010:rwsem_write_trylock kernel/locking/rwsem.c:268 [inline]
RIP: 0010:__down_write_common kernel/locking/rwsem.c:1316 [inline]
RIP: 0010:__down_write kernel/locking/rwsem.c:1326 [inline]
RIP: 0010:down_write+0xcb/0x200 kernel/locking/rwsem.c:1591
Code: 48 89 df 48 c7 44 24 28 00 00 00 00 e8 3e c3 8c f6 be 08 00 00 00 48 8d 7c 24 28 e8 2f c3 8c f6 ba 01 00 00 00 48 8b 44 24 28 <f0> 48 0f b1 13 0f 94 c0 5a 84 c0 0f 84 ed 00 00 00 48 c7 c0 34 d5
RSP: 0018:ffffc900042bf938 EFLAGS: 00010246
RAX: 0000000000000000 RBX: ffffffff8b4ef1c8 RCX: ffffffff8b943d31
RDX: 0000000000000001 RSI: 0000000000000008 RDI: ffffc900042bf960
RBP: 1ffff92000857f28 R08: 0000000000000001 R09: fffff52000857f2c
R10: ffffc900042bf967 R11: 0000000000000001 R12: dffffc0000000000
R13: 0000000000000000 R14: 0000000000000002 R15: ffff88802a57a120
FS:  00007fcbfc5796c0(0000) GS:ffff8881247b7000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffff8b4ef1c8 CR3: 000000003538e000 CR4: 0000000000350ef0
Call Trace:
 <TASK>
 kernfs_remove_by_name_ns+0x3d/0x110 fs/kernfs/dir.c:1712
 sysfs_remove_file include/linux/sysfs.h:777 [inline]
 driver_remove_file drivers/base/driver.c:201 [inline]
 driver_remove_file+0x4a/0x60 drivers/base/driver.c:197
 remove_bind_files drivers/base/bus.c:605 [inline]
 bus_remove_driver+0x224/0x2c0 drivers/base/bus.c:743
 driver_unregister+0x76/0xb0 drivers/base/driver.c:277
 comedi_device_detach_locked+0x12f/0xa50 drivers/comedi/drivers.c:207
 do_devconfig_ioctl+0x555/0x710 drivers/comedi/comedi_fops.c:848
 comedi_unlocked_ioctl+0x165d/0x2f00 drivers/comedi/comedi_fops.c:2178
 vfs_ioctl fs/ioctl.c:51 [inline]
 __do_sys_ioctl fs/ioctl.c:598 [inline]
 __se_sys_ioctl fs/ioctl.c:584 [inline]
 __x64_sys_ioctl+0x18e/0x210 fs/ioctl.c:584
 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline]
 do_syscall_64+0xcd/0x4c0 arch/x86/entry/syscall_64.c:94
 entry_SYSCALL_64_after_hwframe+0x77/0x7f
RIP: 0033:0x7fcbfb78ebe9
Code: ff ff c3 66 2e 0f 1f 84 00 00 00 00 00 0f 1f 40 00 48 89 f8 48 89 f7 48 89 d6 48 89 ca 4d 89 c2 4d 89 c8 4c 8b 4c 24 08 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 a8 ff ff ff f7 d8 64 89 01 48
RSP: 002b:00007fcbfc579038 EFLAGS: 00000246 ORIG_RAX: 0000000000000010
RAX: ffffffffffffffda RBX: 00007fcbfb9c6270 RCX: 00007fcbfb78ebe9
RDX: 0000000000000000 RSI: 0000000040946400 RDI: 0000000000000007
RBP: 00007fcbfb811e19 R08: 0000000000000000 R09: 0000000000000000
R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000
R13: 00007fcbfb9c6308 R14: 00007fcbfb9c6270 R15: 00007ffd025b3e08
 </TASK>
Modules linked in:
CR2: ffffffff8b4ef1c8
---[ end trace 0000000000000000 ]---
RIP: 0010:arch_atomic64_try_cmpxchg arch/x86/include/asm/atomic64_64.h:101 [inline]
RIP: 0010:raw_atomic64_try_cmpxchg_acquire include/linux/atomic/atomic-arch-fallback.h:4296 [inline]
RIP: 0010:raw_atomic_long_try_cmpxchg_acquire include/linux/atomic/atomic-long.h:1482 [inline]
RIP: 0010:atomic_long_try_cmpxchg_acquire include/linux/atomic/atomic-instrumented.h:4458 [inline]
RIP: 0010:rwsem_write_trylock kernel/locking/rwsem.c:268 [inline]
RIP: 0010:__down_write_common kernel/locking/rwsem.c:1316 [inline]
RIP: 0010:__down_write kernel/locking/rwsem.c:1326 [inline]
RIP: 0010:down_write+0xcb/0x200 kernel/locking/rwsem.c:1591
Code: 48 89 df 48 c7 44 24 28 00 00 00 00 e8 3e c3 8c f6 be 08 00 00 00 48 8d 7c 24 28 e8 2f c3 8c f6 ba 01 00 00 00 48 8b 44 24 28 <f0> 48 0f b1 13 0f 94 c0 5a 84 c0 0f 84 ed 00 00 00 48 c7 c0 34 d5
RSP: 0018:ffffc900042bf938 EFLAGS: 00010246
RAX: 0000000000000000 RBX: ffffffff8b4ef1c8 RCX: ffffffff8b943d31
RDX: 0000000000000001 RSI: 0000000000000008 RDI: ffffc900042bf960
RBP: 1ffff92000857f28 R08: 0000000000000001 R09: fffff52000857f2c
R10: ffffc900042bf967 R11: 0000000000000001 R12: dffffc0000000000
R13: 0000000000000000 R14: 0000000000000002 R15: ffff88802a57a120
FS:  00007fcbfc5796c0(0000) GS:ffff8881247b7000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: ffffffff8b4ef1c8 CR3: 000000003538e000 CR4: 0000000000350ef0
----------------
Code disassembly (best guess):
   0:	48 89 df             	mov    %rbx,%rdi
   3:	48 c7 44 24 28 00 00 	movq   $0x0,0x28(%rsp)
   a:	00 00
   c:	e8 3e c3 8c f6       	call   0xf68cc34f
  11:	be 08 00 00 00       	mov    $0x8,%esi
  16:	48 8d 7c 24 28       	lea    0x28(%rsp),%rdi
  1b:	e8 2f c3 8c f6       	call   0xf68cc34f
  20:	ba 01 00 00 00       	mov    $0x1,%edx
  25:	48 8b 44 24 28       	mov    0x28(%rsp),%rax
* 2a:	f0 48 0f b1 13       	lock cmpxchg %rdx,(%rbx) <-- trapping instruction
  2f:	0f 94 c0             	sete   %al
  32:	5a                   	pop    %rdx
  33:	84 c0                	test   %al,%al
  35:	0f 84 ed 00 00 00    	je     0x128
  3b:	48                   	rex.W
  3c:	c7                   	.byte 0xc7
  3d:	c0                   	.byte 0xc0
  3e:	34 d5                	xor    $0xd5,%al

Crashes (21):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/09/08 03:38 upstream 6ab41fca2e80 d291dd2d .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-badwrites-root BUG: unable to handle kernel paging request in kernfs_remove_by_name_ns
2025/08/25 02:22 upstream 69fd6b99b8f8 bf27483f .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream BUG: unable to handle kernel paging request in kernfs_remove_by_name_ns
2025/08/17 03:06 upstream 90d970cade8e 1804e95e .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream BUG: unable to handle kernel paging request in kernfs_remove_by_name_ns
2025/07/26 05:34 upstream 5f33ebd2018c fb8f743d .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream BUG: unable to handle kernel paging request in kernfs_remove_by_name_ns
2025/08/20 06:07 upstream b19a97d57c15 79512909 .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream-386 BUG: unable to handle kernel paging request in kernfs_remove_by_name_ns
2025/07/05 10:31 linux-next 26ffb3d6f02c 4f67c4ae .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-rust-kasan-gce BUG: unable to handle kernel paging request in kernfs_remove_by_name_ns
2025/09/18 14:31 upstream 8b789f2b7602 e2beed91 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-selinux-root general protection fault in kernfs_remove_by_name_ns
2025/09/11 05:44 upstream 7aac71907bde fdeaa69b .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-selinux-root general protection fault in kernfs_remove_by_name_ns
2025/09/10 08:51 upstream 9dd1835ecda5 fdeaa69b .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-selinux-root general protection fault in kernfs_remove_by_name_ns
2025/08/29 20:10 upstream fb679c832b64 3e1beec6 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-selinux-root general protection fault in kernfs_remove_by_name_ns
2025/07/24 10:04 upstream 01a412d06bc5 0c1d6ded .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-smack-root general protection fault in kernfs_remove_by_name_ns
2025/07/17 08:38 upstream e2291551827f 44f8051e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-kasan-gce-selinux-root general protection fault in kernfs_remove_by_name_ns
2025/09/01 17:31 upstream b320789d6883 807a3b61 .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream general protection fault in kernfs_remove_by_name_ns
2025/08/29 21:36 upstream fb679c832b64 807a3b61 .config console log report info [disk image (non-bootable)] [vmlinux] [kernel image] ci-qemu-upstream general protection fault in kernfs_remove_by_name_ns
2025/09/14 21:14 linux-next 590b221ed425 e2beed91 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-rust-kasan-gce general protection fault in kernfs_remove_by_name_ns
2025/09/14 05:49 linux-next 590b221ed425 e2beed91 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-rust-kasan-gce general protection fault in kernfs_remove_by_name_ns
2025/08/17 03:30 linux-next 931e46dcbc7e 1804e95e .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root KASAN: null-ptr-deref Write in kernfs_remove_by_name_ns
2025/08/13 21:04 linux-next 2674d1eadaa2 22ec1469 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-rust-kasan-gce general protection fault in kernfs_remove_by_name_ns
2025/08/10 06:44 linux-next b1549501188c 32a0e5ed .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in kernfs_remove_by_name_ns
2025/08/05 09:14 linux-next afec768a6a8f abdcb213 .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-rust-kasan-gce general protection fault in kernfs_remove_by_name_ns
2025/08/04 08:37 linux-next 5c5a10f0be96 7368264b .config console log report info [disk image] [vmlinux] [kernel image] ci-upstream-linux-next-kasan-gce-root general protection fault in kernfs_remove_by_name_ns
* Struck through repros no longer work on HEAD.