syzbot


WARNING in shmem_rmdir

Status: premoderation: reported C repro on 2025/06/20 16:08
Reported-by: syzbot+f437598bbc79210ef8bc@syzkaller.appspotmail.com
First crash: 9h03m, last: 33m

Sample crash report:
------------[ cut here ]------------
WARNING: CPU: 0 PID: 297 at fs/inode.c:340 drop_nlink+0xce/0x110 fs/inode.c:340
Modules linked in:
CPU: 0 UID: 0 PID: 297 Comm: syz-executor426 Not tainted 6.12.23-syzkaller-g6c1c18fcb8b7 #0 ba78288b1e32eb9f88d3f8d8da6b79a037cd8362
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025
RIP: 0010:drop_nlink+0xce/0x110 fs/inode.c:340
Code: 04 00 00 be 08 00 00 00 e8 7f 56 ee ff f0 48 ff 83 b8 04 00 00 5b 41 5c 41 5d 41 5e 41 5f 5d c3 cc cc cc cc cc e8 e2 68 98 ff <0f> 0b eb 81 44 89 f1 80 e1 07 80 c1 03 38 c1 0f 8c 59 ff ff ff 4c
RSP: 0018:ffffc900011ffa80 EFLAGS: 00010293
RAX: ffffffff81ed146e RBX: ffff88811df43bf0 RCX: ffff88810b2d2600
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffffc900011ffaa8 R08: 0000000000000003 R09: 0000000000000004
R10: dffffc0000000000 R11: fffff5200023ff40 R12: dffffc0000000000
R13: 1ffff11023be8787 R14: ffff88811df43c38 R15: 0000000000000000
FS:  0000000000000000(0000) GS:ffff8881f6e00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 00007fbf875e11b0 CR3: 000000010afe6000 CR4: 00000000003526b0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 shmem_rmdir+0x5f/0x90 mm/shmem.c:3734
 vfs_rmdir+0x3dd/0x560 fs/namei.c:4340
 incfs_kill_sb+0x109/0x230 fs/incfs/vfs.c:1968
 deactivate_locked_super+0xd5/0x2a0 fs/super.c:476
 deactivate_super+0xb8/0xe0 fs/super.c:509
 cleanup_mnt+0x3f1/0x480 fs/namespace.c:1374
 __cleanup_mnt+0x1d/0x40 fs/namespace.c:1381
 task_work_run+0x1e0/0x250 kernel/task_work.c:240
 exit_task_work include/linux/task_work.h:43 [inline]
 do_exit+0x9b4/0x2630 kernel/exit.c:944
 do_group_exit+0x22a/0x300 kernel/exit.c:1094
 __do_sys_exit_group kernel/exit.c:1105 [inline]
 __se_sys_exit_group kernel/exit.c:1103 [inline]
 __x64_sys_exit_group+0x43/0x50 kernel/exit.c:1103
 x64_sys_call+0x2ed2/0x2ee0 arch/x86/include/generated/asm/syscalls_64.h:232
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0x58/0xf0 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x76/0x7e
RIP: 0033:0x7fbf87564789
Code: Unable to access opcode bytes at 0x7fbf8756475f.
RSP: 002b:00007ffee01662c8 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7
RAX: ffffffffffffffda RBX: 0000000000000001 RCX: 00007fbf87564789
RDX: 000000000000003c RSI: 00000000000000e7 RDI: 0000000000000001
RBP: 00007fbf875e0350 R08: ffffffffffffffb8 R09: 0000000000000000
R10: 0000000000001000 R11: 0000000000000246 R12: 00007fbf875e0350
R13: 0000000000000000 R14: 00007fbf875e0da0 R15: 00007fbf87535760
 </TASK>
---[ end trace 0000000000000000 ]---
==================================================================
BUG: KASAN: null-ptr-deref in instrument_atomic_read_write include/linux/instrumented.h:96 [inline]
BUG: KASAN: null-ptr-deref in atomic_inc_return include/linux/atomic/atomic-instrumented.h:453 [inline]
BUG: KASAN: null-ptr-deref in ihold+0x24/0x70 fs/inode.c:452
Write of size 4 at addr 0000000000000168 by task syz-executor426/297

CPU: 1 UID: 0 PID: 297 Comm: syz-executor426 Tainted: G        W          6.12.23-syzkaller-g6c1c18fcb8b7 #0 ba78288b1e32eb9f88d3f8d8da6b79a037cd8362
Tainted: [W]=WARN
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025
Call Trace:
 <TASK>
 __dump_stack+0x21/0x30 lib/dump_stack.c:94
 dump_stack_lvl+0x10c/0x190 lib/dump_stack.c:120
 print_report+0x3d/0x70 mm/kasan/report.c:491
 kasan_report+0x163/0x1a0 mm/kasan/report.c:601
 check_region_inline mm/kasan/generic.c:-1 [inline]
 kasan_check_range+0x299/0x2a0 mm/kasan/generic.c:189
 __kasan_check_write+0x18/0x20 mm/kasan/shadow.c:37
 instrument_atomic_read_write include/linux/instrumented.h:96 [inline]
 atomic_inc_return include/linux/atomic/atomic-instrumented.h:453 [inline]
 ihold+0x24/0x70 fs/inode.c:452
 d_delete_notify include/linux/fsnotify.h:357 [inline]
 vfs_rmdir+0x26a/0x560 fs/namei.c:4353
 incfs_kill_sb+0x109/0x230 fs/incfs/vfs.c:1968
 deactivate_locked_super+0xd5/0x2a0 fs/super.c:476
 deactivate_super+0xb8/0xe0 fs/super.c:509
 cleanup_mnt+0x3f1/0x480 fs/namespace.c:1374
 __cleanup_mnt+0x1d/0x40 fs/namespace.c:1381
 task_work_run+0x1e0/0x250 kernel/task_work.c:240
 exit_task_work include/linux/task_work.h:43 [inline]
 do_exit+0x9b4/0x2630 kernel/exit.c:944
 do_group_exit+0x22a/0x300 kernel/exit.c:1094
 __do_sys_exit_group kernel/exit.c:1105 [inline]
 __se_sys_exit_group kernel/exit.c:1103 [inline]
 __x64_sys_exit_group+0x43/0x50 kernel/exit.c:1103
 x64_sys_call+0x2ed2/0x2ee0 arch/x86/include/generated/asm/syscalls_64.h:232
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0x58/0xf0 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x76/0x7e
RIP: 0033:0x7fbf87564789
Code: Unable to access opcode bytes at 0x7fbf8756475f.
RSP: 002b:00007ffee01662c8 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7
RAX: ffffffffffffffda RBX: 0000000000000001 RCX: 00007fbf87564789
RDX: 000000000000003c RSI: 00000000000000e7 RDI: 0000000000000001
RBP: 00007fbf875e0350 R08: ffffffffffffffb8 R09: 0000000000000000
R10: 0000000000001000 R11: 0000000000000246 R12: 00007fbf875e0350
R13: 0000000000000000 R14: 00007fbf875e0da0 R15: 00007fbf87535760
 </TASK>
==================================================================
BUG: kernel NULL pointer dereference, address: 0000000000000168
#PF: supervisor write access in kernel mode
#PF: error_code(0x0002) - not-present page
PGD 0 P4D 0 
Oops: Oops: 0002 [#1] PREEMPT SMP KASAN PTI
CPU: 1 UID: 0 PID: 297 Comm: syz-executor426 Tainted: G    B   W          6.12.23-syzkaller-g6c1c18fcb8b7 #0 ba78288b1e32eb9f88d3f8d8da6b79a037cd8362
Tainted: [B]=BAD_PAGE, [W]=WARN
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025
RIP: 0010:arch_atomic_add_return arch/x86/include/asm/atomic.h:85 [inline]
RIP: 0010:raw_atomic_add_return include/linux/atomic/atomic-arch-fallback.h:564 [inline]
RIP: 0010:raw_atomic_inc_return include/linux/atomic/atomic-arch-fallback.h:1020 [inline]
RIP: 0010:atomic_inc_return include/linux/atomic/atomic-instrumented.h:454 [inline]
RIP: 0010:ihold+0x2a/0x70 fs/inode.c:452
Code: f3 0f 1e fa 55 48 89 e5 41 56 53 48 89 fb e8 cd 5f 98 ff 48 8d bb 68 01 00 00 be 04 00 00 00 e8 3c 4d ee ff 41 be 01 00 00 00 <f0> 44 0f c1 b3 68 01 00 00 41 ff c6 bf 02 00 00 00 44 89 f6 e8 dd
RSP: 0018:ffffc900011ffac0 EFLAGS: 00010246
RAX: ffff88810b2d2600 RBX: 0000000000000000 RCX: ffff88810b2d2600
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffffc900011ffad0 R08: ffffffff88954947 R09: 1ffffffff112a928
R10: dffffc0000000000 R11: fffffbfff112a929 R12: ffff88811df43bfc
R13: 0000000000000000 R14: 0000000000000001 R15: 0000000000000000
FS:  0000000000000000(0000) GS:ffff8881f6f00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000168 CR3: 000000011dcf0000 CR4: 00000000003526b0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
Call Trace:
 <TASK>
 d_delete_notify include/linux/fsnotify.h:357 [inline]
 vfs_rmdir+0x26a/0x560 fs/namei.c:4353
 incfs_kill_sb+0x109/0x230 fs/incfs/vfs.c:1968
 deactivate_locked_super+0xd5/0x2a0 fs/super.c:476
 deactivate_super+0xb8/0xe0 fs/super.c:509
 cleanup_mnt+0x3f1/0x480 fs/namespace.c:1374
 __cleanup_mnt+0x1d/0x40 fs/namespace.c:1381
 task_work_run+0x1e0/0x250 kernel/task_work.c:240
 exit_task_work include/linux/task_work.h:43 [inline]
 do_exit+0x9b4/0x2630 kernel/exit.c:944
 do_group_exit+0x22a/0x300 kernel/exit.c:1094
 __do_sys_exit_group kernel/exit.c:1105 [inline]
 __se_sys_exit_group kernel/exit.c:1103 [inline]
 __x64_sys_exit_group+0x43/0x50 kernel/exit.c:1103
 x64_sys_call+0x2ed2/0x2ee0 arch/x86/include/generated/asm/syscalls_64.h:232
 do_syscall_x64 arch/x86/entry/common.c:52 [inline]
 do_syscall_64+0x58/0xf0 arch/x86/entry/common.c:83
 entry_SYSCALL_64_after_hwframe+0x76/0x7e
RIP: 0033:0x7fbf87564789
Code: Unable to access opcode bytes at 0x7fbf8756475f.
RSP: 002b:00007ffee01662c8 EFLAGS: 00000246 ORIG_RAX: 00000000000000e7
RAX: ffffffffffffffda RBX: 0000000000000001 RCX: 00007fbf87564789
RDX: 000000000000003c RSI: 00000000000000e7 RDI: 0000000000000001
RBP: 00007fbf875e0350 R08: ffffffffffffffb8 R09: 0000000000000000
R10: 0000000000001000 R11: 0000000000000246 R12: 00007fbf875e0350
R13: 0000000000000000 R14: 00007fbf875e0da0 R15: 00007fbf87535760
 </TASK>
Modules linked in:
CR2: 0000000000000168
---[ end trace 0000000000000000 ]---
RIP: 0010:arch_atomic_add_return arch/x86/include/asm/atomic.h:85 [inline]
RIP: 0010:raw_atomic_add_return include/linux/atomic/atomic-arch-fallback.h:564 [inline]
RIP: 0010:raw_atomic_inc_return include/linux/atomic/atomic-arch-fallback.h:1020 [inline]
RIP: 0010:atomic_inc_return include/linux/atomic/atomic-instrumented.h:454 [inline]
RIP: 0010:ihold+0x2a/0x70 fs/inode.c:452
Code: f3 0f 1e fa 55 48 89 e5 41 56 53 48 89 fb e8 cd 5f 98 ff 48 8d bb 68 01 00 00 be 04 00 00 00 e8 3c 4d ee ff 41 be 01 00 00 00 <f0> 44 0f c1 b3 68 01 00 00 41 ff c6 bf 02 00 00 00 44 89 f6 e8 dd
RSP: 0018:ffffc900011ffac0 EFLAGS: 00010246
RAX: ffff88810b2d2600 RBX: 0000000000000000 RCX: ffff88810b2d2600
RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000
RBP: ffffc900011ffad0 R08: ffffffff88954947 R09: 1ffffffff112a928
R10: dffffc0000000000 R11: fffffbfff112a929 R12: ffff88811df43bfc
R13: 0000000000000000 R14: 0000000000000001 R15: 0000000000000000
FS:  0000000000000000(0000) GS:ffff8881f6f00000(0000) knlGS:0000000000000000
CS:  0010 DS: 0000 ES: 0000 CR0: 0000000080050033
CR2: 0000000000000168 CR3: 000000011dcf0000 CR4: 00000000003526b0
DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000
DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400
----------------
Code disassembly (best guess):
   0:	f3 0f 1e fa          	endbr64
   4:	55                   	push   %rbp
   5:	48 89 e5             	mov    %rsp,%rbp
   8:	41 56                	push   %r14
   a:	53                   	push   %rbx
   b:	48 89 fb             	mov    %rdi,%rbx
   e:	e8 cd 5f 98 ff       	call   0xff985fe0
  13:	48 8d bb 68 01 00 00 	lea    0x168(%rbx),%rdi
  1a:	be 04 00 00 00       	mov    $0x4,%esi
  1f:	e8 3c 4d ee ff       	call   0xffee4d60
  24:	41 be 01 00 00 00    	mov    $0x1,%r14d
* 2a:	f0 44 0f c1 b3 68 01 	lock xadd %r14d,0x168(%rbx) <-- trapping instruction
  31:	00 00
  33:	41 ff c6             	inc    %r14d
  36:	bf 02 00 00 00       	mov    $0x2,%edi
  3b:	44 89 f6             	mov    %r14d,%esi
  3e:	e8                   	.byte 0xe8
  3f:	dd                   	.byte 0xdd

Crashes (8):
Time Kernel Commit Syzkaller Config Log Report Syz repro C repro VM info Assets (help?) Manager Title
2025/06/20 21:45 android16-6.12 6c1c18fcb8b7 804b3919 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci2-android-6-12-rust WARNING in shmem_rmdir
2025/06/20 20:30 android16-6.12 6c1c18fcb8b7 804b3919 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci2-android-6-12-rust WARNING in shmem_rmdir
2025/06/20 19:06 android16-6.12 6c1c18fcb8b7 804b3919 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci2-android-6-12-rust WARNING in shmem_rmdir
2025/06/20 17:37 android16-6.12 6c1c18fcb8b7 804b3919 .config strace log report syz / log C [disk image] [vmlinux] [kernel image] ci2-android-6-12-rust WARNING in shmem_rmdir
2025/06/21 00:36 android16-6.12 6c1c18fcb8b7 804b3919 .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-6-12-rust WARNING in shmem_rmdir
2025/06/20 23:17 android16-6.12 6c1c18fcb8b7 804b3919 .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-6-12-rust WARNING in shmem_rmdir
2025/06/20 20:15 android16-6.12 6c1c18fcb8b7 804b3919 .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-6-12-rust WARNING in shmem_rmdir
2025/06/20 16:07 android16-6.12 6c1c18fcb8b7 804b3919 .config console log report info [disk image] [vmlinux] [kernel image] ci2-android-6-12-rust WARNING in shmem_rmdir
* Struck through repros no longer work on HEAD.