EXT4-fs error (device loop0): ext4_get_group_desc:277: comm syz-executor.0: block_group >= groups_count - block_group = 4294963226, groups_count = 1 ================================================================== BUG: KASAN: null-ptr-deref in instrument_atomic_read_write include/linux/instrumented.h:101 [inline] BUG: KASAN: null-ptr-deref in atomic_try_cmpxchg_acquire include/asm-generic/atomic-instrumented.h:705 [inline] BUG: KASAN: null-ptr-deref in queued_spin_lock include/asm-generic/qspinlock.h:82 [inline] BUG: KASAN: null-ptr-deref in do_raw_spin_lock include/linux/spinlock.h:183 [inline] BUG: KASAN: null-ptr-deref in __raw_spin_lock include/linux/spinlock_api_smp.h:143 [inline] BUG: KASAN: null-ptr-deref in _raw_spin_lock+0x81/0xe0 kernel/locking/spinlock.c:151 Write of size 4 at addr 0000000000000000 by task syz-executor.0/4108 CPU: 1 PID: 4108 Comm: syz-executor.0 Not tainted 5.10.240-syzkaller-1008073-gad9a98ef27a4 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025 Call Trace: __dump_stack+0x21/0x24 lib/dump_stack.c:77 dump_stack_lvl+0x169/0x1d8 lib/dump_stack.c:118 __kasan_report mm/kasan/report.c:439 [inline] kasan_report+0xd8/0x130 mm/kasan/report.c:452 check_region_inline mm/kasan/generic.c:-1 [inline] kasan_check_range+0x280/0x290 mm/kasan/generic.c:189 __kasan_check_write+0x14/0x20 mm/kasan/shadow.c:37 instrument_atomic_read_write include/linux/instrumented.h:101 [inline] atomic_try_cmpxchg_acquire include/asm-generic/atomic-instrumented.h:705 [inline] queued_spin_lock include/asm-generic/qspinlock.h:82 [inline] do_raw_spin_lock include/linux/spinlock.h:183 [inline] __raw_spin_lock include/linux/spinlock_api_smp.h:143 [inline] _raw_spin_lock+0x81/0xe0 kernel/locking/spinlock.c:151 spin_lock include/linux/spinlock.h:354 [inline] ext4_mb_release_context fs/ext4/mballoc.c:5001 [inline] ext4_mb_new_blocks+0x1568/0x42f0 fs/ext4/mballoc.c:5284 ext4_ext_map_blocks+0x135d/0x5d40 fs/ext4/extents.c:4335 ext4_map_blocks+0x978/0x1bc0 fs/ext4/inode.c:674 _ext4_get_block+0x1bb/0x4b0 fs/ext4/inode.c:817 ext4_get_block+0x39/0x50 fs/ext4/inode.c:834 __block_write_begin_int+0x4f3/0x1570 fs/buffer.c:2042 __block_write_begin+0x30/0x40 fs/buffer.c:2092 ext4_convert_inline_data_to_extent fs/ext4/ext4_jbd2.h:-1 [inline] ext4_try_to_write_inline_data+0x774/0x1140 fs/ext4/inline.c:751 ext4_write_begin+0x219/0x1550 fs/ext4/inode.c:1192 ext4_da_write_begin+0x455/0xe80 fs/ext4/inode.c:3033 generic_perform_write+0x2be/0x510 mm/filemap.c:3509 ext4_buffered_write_iter+0x4b8/0x640 fs/ext4/file.c:271 ext4_file_write_iter+0x536/0x1980 fs/ext4/file.c:-1 __kernel_write+0x55a/0x910 fs/read_write.c:550 dump_emit+0x240/0x360 fs/coredump.c:855 elf_core_dump+0x240d/0x2bc0 fs/binfmt_elf.c:2245 do_coredump+0x1ac9/0x27f0 fs/coredump.c:817 get_signal+0xf23/0x12e0 kernel/signal.c:2779 arch_do_signal_or_restart+0xbf/0x10f0 arch/x86/kernel/signal.c:805 handle_signal_work kernel/entry/common.c:145 [inline] exit_to_user_mode_loop+0xa2/0xe0 kernel/entry/common.c:169 exit_to_user_mode_prepare kernel/entry/common.c:199 [inline] irqentry_exit_to_user_mode+0x4e/0x80 kernel/entry/common.c:287 irqentry_exit+0x12/0x60 kernel/entry/common.c:375 exc_page_fault+0x67/0xc0 arch/x86/mm/fault.c:1487 asm_exc_page_fault+0x1e/0x30 arch/x86/include/asm/idtentry.h:571 RIP: 0033:0x0 Code: Unable to access opcode bytes at RIP 0xffffffffffffffd6. RSP: 002b:0000000020000473 EFLAGS: 00010217 RAX: 0000000000000000 RBX: 0000000000000058 RCX: 00007fbb0e4f3959 RDX: 00007fbb0e075fb0 RSI: 0000000000000058 RDI: 00007fbb0e075fb0 RBP: 00007fbb0e54fc88 R08: 0000000000000000 R09: 0000000000000058 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 000000000000000b R14: 00007fbb0e612f80 R15: 00007fffc607b4b8 ================================================================== BUG: kernel NULL pointer dereference, address: 0000000000000000 #PF: supervisor write access in kernel mode #PF: error_code(0x0002) - not-present page PGD 11e030067 P4D 11e030067 PUD 11bfb1067 PMD 0 Oops: 0002 [#1] PREEMPT SMP KASAN CPU: 1 PID: 4108 Comm: syz-executor.0 Tainted: G B 5.10.240-syzkaller-1008073-gad9a98ef27a4 #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/07/2025 RIP: 0010:arch_atomic_try_cmpxchg arch/x86/include/asm/atomic.h:202 [inline] RIP: 0010:atomic_try_cmpxchg_acquire include/asm-generic/atomic-instrumented.h:707 [inline] RIP: 0010:queued_spin_lock include/asm-generic/qspinlock.h:82 [inline] RIP: 0010:do_raw_spin_lock include/linux/spinlock.h:183 [inline] RIP: 0010:__raw_spin_lock include/linux/spinlock_api_smp.h:143 [inline] RIP: 0010:_raw_spin_lock+0x97/0xe0 kernel/locking/spinlock.c:151 Code: 44 24 20 00 00 00 00 48 89 df be 04 00 00 00 e8 af 52 27 fd 4c 89 f7 be 04 00 00 00 e8 a2 52 27 fd 8b 44 24 20 b9 01 00 00 00 0f b1 0b 75 2d 48 c7 04 24 0e 36 e0 45 4b c7 04 27 00 00 00 00 RSP: 0018:ffffc9000456de80 EFLAGS: 00010297 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000001 RDX: 0000000000000001 RSI: 0000000000000004 RDI: ffffc9000456dea0 RBP: ffffc9000456df10 R08: 0000000000000004 R09: 0000000000000003 R10: fffff520008adbd4 R11: 1ffff920008adbd4 R12: dffffc0000000000 R13: 1ffff110243e86dd R14: ffffc9000456dea0 R15: 1ffff920008adbd0 FS: 00007fbb0e0766c0(0000) GS:ffff8881f7100000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000000 CR3: 000000011f266000 CR4: 00000000003506a0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 Call Trace: spin_lock include/linux/spinlock.h:354 [inline] ext4_mb_release_context fs/ext4/mballoc.c:5001 [inline] ext4_mb_new_blocks+0x1568/0x42f0 fs/ext4/mballoc.c:5284 ext4_ext_map_blocks+0x135d/0x5d40 fs/ext4/extents.c:4335 ext4_map_blocks+0x978/0x1bc0 fs/ext4/inode.c:674 _ext4_get_block+0x1bb/0x4b0 fs/ext4/inode.c:817 ext4_get_block+0x39/0x50 fs/ext4/inode.c:834 __block_write_begin_int+0x4f3/0x1570 fs/buffer.c:2042 __block_write_begin+0x30/0x40 fs/buffer.c:2092 ext4_convert_inline_data_to_extent fs/ext4/ext4_jbd2.h:-1 [inline] ext4_try_to_write_inline_data+0x774/0x1140 fs/ext4/inline.c:751 ext4_write_begin+0x219/0x1550 fs/ext4/inode.c:1192 ext4_da_write_begin+0x455/0xe80 fs/ext4/inode.c:3033 generic_perform_write+0x2be/0x510 mm/filemap.c:3509 ext4_buffered_write_iter+0x4b8/0x640 fs/ext4/file.c:271 ext4_file_write_iter+0x536/0x1980 fs/ext4/file.c:-1 __kernel_write+0x55a/0x910 fs/read_write.c:550 dump_emit+0x240/0x360 fs/coredump.c:855 elf_core_dump+0x240d/0x2bc0 fs/binfmt_elf.c:2245 do_coredump+0x1ac9/0x27f0 fs/coredump.c:817 get_signal+0xf23/0x12e0 kernel/signal.c:2779 arch_do_signal_or_restart+0xbf/0x10f0 arch/x86/kernel/signal.c:805 handle_signal_work kernel/entry/common.c:145 [inline] exit_to_user_mode_loop+0xa2/0xe0 kernel/entry/common.c:169 exit_to_user_mode_prepare kernel/entry/common.c:199 [inline] irqentry_exit_to_user_mode+0x4e/0x80 kernel/entry/common.c:287 irqentry_exit+0x12/0x60 kernel/entry/common.c:375 exc_page_fault+0x67/0xc0 arch/x86/mm/fault.c:1487 asm_exc_page_fault+0x1e/0x30 arch/x86/include/asm/idtentry.h:571 RIP: 0033:0x0 Code: Unable to access opcode bytes at RIP 0xffffffffffffffd6. RSP: 002b:0000000020000473 EFLAGS: 00010217 RAX: 0000000000000000 RBX: 0000000000000058 RCX: 00007fbb0e4f3959 RDX: 00007fbb0e075fb0 RSI: 0000000000000058 RDI: 00007fbb0e075fb0 RBP: 00007fbb0e54fc88 R08: 0000000000000000 R09: 0000000000000058 R10: 0000000000000000 R11: 0000000000000246 R12: 0000000000000000 R13: 000000000000000b R14: 00007fbb0e612f80 R15: 00007fffc607b4b8 Modules linked in: CR2: 0000000000000000 ---[ end trace 861b05fcce7ba339 ]--- RIP: 0010:arch_atomic_try_cmpxchg arch/x86/include/asm/atomic.h:202 [inline] RIP: 0010:atomic_try_cmpxchg_acquire include/asm-generic/atomic-instrumented.h:707 [inline] RIP: 0010:queued_spin_lock include/asm-generic/qspinlock.h:82 [inline] RIP: 0010:do_raw_spin_lock include/linux/spinlock.h:183 [inline] RIP: 0010:__raw_spin_lock include/linux/spinlock_api_smp.h:143 [inline] RIP: 0010:_raw_spin_lock+0x97/0xe0 kernel/locking/spinlock.c:151 Code: 44 24 20 00 00 00 00 48 89 df be 04 00 00 00 e8 af 52 27 fd 4c 89 f7 be 04 00 00 00 e8 a2 52 27 fd 8b 44 24 20 b9 01 00 00 00 0f b1 0b 75 2d 48 c7 04 24 0e 36 e0 45 4b c7 04 27 00 00 00 00 RSP: 0018:ffffc9000456de80 EFLAGS: 00010297 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 0000000000000001 RDX: 0000000000000001 RSI: 0000000000000004 RDI: ffffc9000456dea0 RBP: ffffc9000456df10 R08: 0000000000000004 R09: 0000000000000003 R10: fffff520008adbd4 R11: 1ffff920008adbd4 R12: dffffc0000000000 R13: 1ffff110243e86dd R14: ffffc9000456dea0 R15: 1ffff920008adbd0 FS: 00007fbb0e0766c0(0000) GS:ffff8881f7100000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: 0000000000000000 CR3: 000000011f266000 CR4: 00000000003506a0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000400 ---------------- Code disassembly (best guess): 0: 44 24 20 rex.R and $0x20,%al 3: 00 00 add %al,(%rax) 5: 00 00 add %al,(%rax) 7: 48 89 df mov %rbx,%rdi a: be 04 00 00 00 mov $0x4,%esi f: e8 af 52 27 fd call 0xfd2752c3 14: 4c 89 f7 mov %r14,%rdi 17: be 04 00 00 00 mov $0x4,%esi 1c: e8 a2 52 27 fd call 0xfd2752c3 21: 8b 44 24 20 mov 0x20(%rsp),%eax 25: b9 01 00 00 00 mov $0x1,%ecx * 2a: f0 0f b1 0b lock cmpxchg %ecx,(%rbx) <-- trapping instruction 2e: 75 2d jne 0x5d 30: 48 c7 04 24 0e 36 e0 movq $0x45e0360e,(%rsp) 37: 45 38: 4b c7 04 27 00 00 00 movq $0x0,(%r15,%r12,1) 3f: 00