================================================================== BUG: KASAN: null-ptr-deref in instrument_atomic_read_write include/linux/instrumented.h:96 [inline] BUG: KASAN: null-ptr-deref in atomic_long_add_return_acquire include/linux/atomic/atomic-instrumented.h:3297 [inline] BUG: KASAN: null-ptr-deref in rwsem_read_trylock+0x7e/0x660 kernel/locking/rwsem.c:259 Write of size 8 at addr 0000000000000098 by task syz.2.17/488 CPU: 1 UID: 0 PID: 488 Comm: syz.2.17 Not tainted syzkaller #0 b2db0503551b593f49eb600304d5a9aa5d5345d2 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025 Call Trace: __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_long_add_return_acquire include/linux/atomic/atomic-instrumented.h:3297 [inline] rwsem_read_trylock+0x7e/0x660 kernel/locking/rwsem.c:259 __down_read_common kernel/locking/rwsem.c:1316 [inline] __down_read_killable kernel/locking/rwsem.c:1340 [inline] down_read_killable+0x79/0xf0 kernel/locking/rwsem.c:1630 mmap_read_lock_killable include/linux/mmap_lock.h:193 [inline] do_pagemap_scan fs/proc/task_mmu.c:2867 [inline] do_pagemap_cmd+0x598/0xc20 fs/proc/task_mmu.c:2920 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:907 [inline] __se_sys_ioctl+0x132/0x1b0 fs/ioctl.c:893 __x64_sys_ioctl+0x7f/0xa0 fs/ioctl.c:893 x64_sys_call+0x1878/0x2ee0 arch/x86/include/generated/asm/syscalls_64.h:17 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:0x7f5742f8eb69 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:00007f5743ea5038 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 00007f57431b5fa0 RCX: 00007f5742f8eb69 RDX: 0000200000000100 RSI: 00000000c0606610 RDI: 0000000000000004 RBP: 00007f5743011df1 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000000 R14: 00007f57431b5fa0 R15: 00007ffe948d05e8 ================================================================== BUG: kernel NULL pointer dereference, address: 0000000000000098 #PF: supervisor write access in kernel mode #PF: error_code(0x0002) - not-present page PGD 80000001137d7067 P4D 80000001137d7067 PUD 0 Oops: Oops: 0002 [#1] PREEMPT SMP KASAN PTI CPU: 1 UID: 0 PID: 488 Comm: syz.2.17 Tainted: G B syzkaller #0 b2db0503551b593f49eb600304d5a9aa5d5345d2 Tainted: [B]=BAD_PAGE Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 07/12/2025 RIP: 0010:arch_atomic64_add_return arch/x86/include/asm/atomic64_64.h:79 [inline] RIP: 0010:raw_atomic64_add_return_acquire include/linux/atomic/atomic-arch-fallback.h:2723 [inline] RIP: 0010:raw_atomic_long_add_return_acquire include/linux/atomic/atomic-long.h:163 [inline] RIP: 0010:atomic_long_add_return_acquire include/linux/atomic/atomic-instrumented.h:3298 [inline] RIP: 0010:rwsem_read_trylock+0x89/0x660 kernel/locking/rwsem.c:259 Code: b8 f1 f1 f1 f1 04 f3 f3 f3 49 89 04 1c c7 44 24 40 00 00 00 00 be 08 00 00 00 e8 42 be 76 00 41 bd 00 01 00 00 4c 89 7c 24 18 4d 0f c1 2f 49 81 c5 00 01 00 00 4d 89 f7 49 c1 ef 03 41 80 3c RSP: 0018:ffffc900011afb20 EFLAGS: 00010246 RAX: ffff88811babb900 RBX: dffffc0000000000 RCX: ffff88811babb900 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000 RBP: ffffc900011afbd0 R08: ffffffff8896a947 R09: 1ffffffff112d528 R10: dffffc0000000000 R11: fffffbfff112d529 R12: 1ffff92000235f68 R13: 0000000000000100 R14: ffffc900011afc00 R15: 0000000000000098 FS: 00007f5743ea56c0(0000) GS:ffff8881f6f00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000098 CR3: 000000012c618000 CR4: 00000000003526b0 Call Trace: __down_read_common kernel/locking/rwsem.c:1316 [inline] __down_read_killable kernel/locking/rwsem.c:1340 [inline] down_read_killable+0x79/0xf0 kernel/locking/rwsem.c:1630 mmap_read_lock_killable include/linux/mmap_lock.h:193 [inline] do_pagemap_scan fs/proc/task_mmu.c:2867 [inline] do_pagemap_cmd+0x598/0xc20 fs/proc/task_mmu.c:2920 vfs_ioctl fs/ioctl.c:51 [inline] __do_sys_ioctl fs/ioctl.c:907 [inline] __se_sys_ioctl+0x132/0x1b0 fs/ioctl.c:893 __x64_sys_ioctl+0x7f/0xa0 fs/ioctl.c:893 x64_sys_call+0x1878/0x2ee0 arch/x86/include/generated/asm/syscalls_64.h:17 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:0x7f5742f8eb69 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:00007f5743ea5038 EFLAGS: 00000246 ORIG_RAX: 0000000000000010 RAX: ffffffffffffffda RBX: 00007f57431b5fa0 RCX: 00007f5742f8eb69 RDX: 0000200000000100 RSI: 00000000c0606610 RDI: 0000000000000004 RBP: 00007f5743011df1 R08: 0000000000000000 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 0000000000000000 R14: 00007f57431b5fa0 R15: 00007ffe948d05e8 Modules linked in: CR2: 0000000000000098 ---[ end trace 0000000000000000 ]--- RIP: 0010:arch_atomic64_add_return arch/x86/include/asm/atomic64_64.h:79 [inline] RIP: 0010:raw_atomic64_add_return_acquire include/linux/atomic/atomic-arch-fallback.h:2723 [inline] RIP: 0010:raw_atomic_long_add_return_acquire include/linux/atomic/atomic-long.h:163 [inline] RIP: 0010:atomic_long_add_return_acquire include/linux/atomic/atomic-instrumented.h:3298 [inline] RIP: 0010:rwsem_read_trylock+0x89/0x660 kernel/locking/rwsem.c:259 Code: b8 f1 f1 f1 f1 04 f3 f3 f3 49 89 04 1c c7 44 24 40 00 00 00 00 be 08 00 00 00 e8 42 be 76 00 41 bd 00 01 00 00 4c 89 7c 24 18 4d 0f c1 2f 49 81 c5 00 01 00 00 4d 89 f7 49 c1 ef 03 41 80 3c RSP: 0018:ffffc900011afb20 EFLAGS: 00010246 RAX: ffff88811babb900 RBX: dffffc0000000000 RCX: ffff88811babb900 RDX: 0000000000000000 RSI: 0000000000000000 RDI: 0000000000000000 RBP: ffffc900011afbd0 R08: ffffffff8896a947 R09: 1ffffffff112d528 R10: dffffc0000000000 R11: fffffbfff112d529 R12: 1ffff92000235f68 R13: 0000000000000100 R14: ffffc900011afc00 R15: 0000000000000098 FS: 00007f5743ea56c0(0000) GS:ffff8881f6f00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000098 CR3: 000000012c618000 CR4: 00000000003526b0 ---------------- Code disassembly (best guess): 0: b8 f1 f1 f1 f1 mov $0xf1f1f1f1,%eax 5: 04 f3 add $0xf3,%al 7: f3 f3 49 89 04 1c repz xrelease mov %rax,(%r12,%rbx,1) d: c7 44 24 40 00 00 00 movl $0x0,0x40(%rsp) 14: 00 15: be 08 00 00 00 mov $0x8,%esi 1a: e8 42 be 76 00 call 0x76be61 1f: 41 bd 00 01 00 00 mov $0x100,%r13d 25: 4c 89 7c 24 18 mov %r15,0x18(%rsp) * 2a: f0 4d 0f c1 2f lock xadd %r13,(%r15) <-- trapping instruction 2f: 49 81 c5 00 01 00 00 add $0x100,%r13 36: 4d 89 f7 mov %r14,%r15 39: 49 c1 ef 03 shr $0x3,%r15 3d: 41 rex.B 3e: 80 .byte 0x80 3f: 3c .byte 0x3c