==================================================================
BUG: KASAN: slab-use-after-free in instrument_atomic_read include/linux/instrumented.h:68 [inline]
BUG: KASAN: slab-use-after-free in atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline]
BUG: KASAN: slab-use-after-free in gfs2_qd_dealloc+0x8a/0x100 fs/gfs2/quota.c:117
Read of size 4 at addr ffff888017710a78 by task udevd/5381
CPU: 1 PID: 5381 Comm: udevd Not tainted 6.6.0-rc3-syzkaller-dirty #0
Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 09/06/2023
Call Trace:
__dump_stack lib/dump_stack.c:88 [inline]
dump_stack_lvl+0x1e7/0x2d0 lib/dump_stack.c:106
print_address_description mm/kasan/report.c:364 [inline]
print_report+0x163/0x540 mm/kasan/report.c:475
kasan_report+0x175/0x1b0 mm/kasan/report.c:588
kasan_check_range+0x27e/0x290 mm/kasan/generic.c:187
instrument_atomic_read include/linux/instrumented.h:68 [inline]
atomic_read include/linux/atomic/atomic-instrumented.h:32 [inline]
gfs2_qd_dealloc+0x8a/0x100 fs/gfs2/quota.c:117
rcu_do_batch kernel/rcu/tree.c:2139 [inline]
rcu_core+0xacf/0x1790 kernel/rcu/tree.c:2403
__do_softirq+0x2ab/0x908 kernel/softirq.c:553
invoke_softirq kernel/softirq.c:427 [inline]
__irq_exit_rcu+0xf1/0x1b0 kernel/softirq.c:632
irq_exit_rcu+0x9/0x20 kernel/softirq.c:644
sysvec_apic_timer_interrupt+0x95/0xb0 arch/x86/kernel/apic/apic.c:1074
asm_sysvec_apic_timer_interrupt+0x1a/0x20 arch/x86/include/asm/idtentry.h:645
RIP: 0010:filter_irq_stacks+0x2e/0xa0 kernel/stacktrace.c:394
Code: 55 41 57 41 56 41 55 41 54 53 85 f6 74 72 49 89 fe 41 89 f4 45 31 ff 48 c7 c5 90 01 e0 8a 49 c7 c5 40 f5 d7 8a 48 89 fb eb 0c <49> ff c7 48 83 c3 08 4d 39 fc 74 4f 48 89 d8 48 c1 e8 03 48 b9 00
RSP: 0018:ffffc90004fbf9d0 EFLAGS: 00000283
RAX: ffffffff81769937 RBX: ffffc90004fbfa70 RCX: dffffc0000000000
RDX: 0000000000000000 RSI: 0000000000000009 RDI: ffffc90004fbfa60
RBP: ffffffff8ae00190 R08: ffffffff81349cfc R09: 1ffffffff1d34f1d
R10: dffffc0000000000 R11: fffffbfff1d34f1e R12: 0000000000000009
R13: ffffffff8ad7f540 R14: ffffc90004fbfa60 R15: 0000000000000002
__stack_depot_save+0x20/0x650 lib/stackdepot.c:377
kasan_save_stack+0x4f/0x60 mm/kasan/common.c:46
__kasan_record_aux_stack+0xad/0xc0 mm/kasan/generic.c:492
__call_rcu_common kernel/rcu/tree.c:2653 [inline]
call_rcu+0x167/0xa70 kernel/rcu/tree.c:2767
task_work_run+0x24a/0x300 kernel/task_work.c:180
resume_user_mode_work include/linux/resume_user_mode.h:49 [inline]
exit_to_user_mode_loop+0xde/0x100 kernel/entry/common.c:171
exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:204
__syscall_exit_to_user_mode_work kernel/entry/common.c:285 [inline]
syscall_exit_to_user_mode+0x64/0x280 kernel/entry/common.c:296
do_syscall_64+0x4d/0xc0 arch/x86/entry/common.c:86
entry_SYSCALL_64_after_hwframe+0x63/0xcd
RIP: 0033:0x7fc63c716ab9
Code: 00 00 00 44 8b 54 24 58 48 89 44 24 30 48 8d 44 24 40 48 89 44 24 38 64 8b 04 25 18 00 00 00 85 c0 75 21 b8 01 01 00 00 0f 05 <48> 3d 00 f0 ff ff 76 6f 48 8b 15 40 a3 0d 00 f7 d8 64 89 02 48 83
RSP: 002b:00007fff180f8ea0 EFLAGS: 00000246 ORIG_RAX: 0000000000000101
RAX: fffffffffffffffe RBX: 00007fff180fb000 RCX: 00007fc63c716ab9
RDX: 0000000000080000 RSI: 00007fc63cc7fdd8 RDI: 000000000000000b
RBP: 000055726b104950 R08: 000055726b100b10 R09: 00007fc63c7f1b20
R10: 0000000000000000 R11: 0000000000000246 R12: 000000000000000b
R13: 00007fc63cc7fdd8 R14: 0000000000080000 R15: 0000000000000001
Allocated by task 5812:
kasan_save_stack mm/kasan/common.c:45 [inline]
kasan_set_track+0x4f/0x70 mm/kasan/common.c:52
____kasan_kmalloc mm/kasan/common.c:374 [inline]
__kasan_kmalloc+0x98/0xb0 mm/kasan/common.c:383
kmalloc include/linux/slab.h:599 [inline]
kzalloc include/linux/slab.h:720 [inline]
init_sbd fs/gfs2/ops_fstype.c:77 [inline]
gfs2_fill_super+0x136/0x26c0 fs/gfs2/ops_fstype.c:1164
get_tree_bdev+0x416/0x5b0 fs/super.c:1577
gfs2_get_tree+0x54/0x210 fs/gfs2/ops_fstype.c:1348
vfs_get_tree+0x8c/0x280 fs/super.c:1750
do_new_mount+0x28f/0xae0 fs/namespace.c:3335
do_mount fs/namespace.c:3675 [inline]
__do_sys_mount fs/namespace.c:3884 [inline]
__se_sys_mount+0x2d9/0x3c0 fs/namespace.c:3861
do_syscall_x64 arch/x86/entry/common.c:50 [inline]
do_syscall_64+0x41/0xc0 arch/x86/entry/common.c:80
entry_SYSCALL_64_after_hwframe+0x63/0xcd
Freed by task 5396:
kasan_save_stack mm/kasan/common.c:45 [inline]
kasan_set_track+0x4f/0x70 mm/kasan/common.c:52
kasan_save_free_info+0x28/0x40 mm/kasan/generic.c:522
____kasan_slab_free+0xd6/0x120 mm/kasan/common.c:236
kasan_slab_free include/linux/kasan.h:164 [inline]
slab_free_hook mm/slub.c:1800 [inline]
slab_free_freelist_hook mm/slub.c:1826 [inline]
slab_free mm/slub.c:3809 [inline]
__kmem_cache_free+0x25f/0x3b0 mm/slub.c:3822
generic_shutdown_super+0x13a/0x2c0 fs/super.c:693
kill_block_super+0x41/0x70 fs/super.c:1646
deactivate_locked_super+0xa4/0x110 fs/super.c:481
cleanup_mnt+0x426/0x4c0 fs/namespace.c:1254
task_work_run+0x24a/0x300 kernel/task_work.c:180
resume_user_mode_work include/linux/resume_user_mode.h:49 [inline]
exit_to_user_mode_loop+0xde/0x100 kernel/entry/common.c:171
exit_to_user_mode_prepare+0xb1/0x140 kernel/entry/common.c:204
__syscall_exit_to_user_mode_work kernel/entry/common.c:285 [inline]
syscall_exit_to_user_mode+0x64/0x280 kernel/entry/common.c:296
do_syscall_64+0x4d/0xc0 arch/x86/entry/common.c:86
entry_SYSCALL_64_after_hwframe+0x63/0xcd
The buggy address belongs to the object at ffff888017710000
which belongs to the cache kmalloc-8k of size 8192
The buggy address is located 2680 bytes inside of
freed 8192-byte region [ffff888017710000, ffff888017712000)
The buggy address belongs to the physical page:
page:ffffea00005dc400 refcount:1 mapcount:0 mapping:0000000000000000 index:0x0 pfn:0x17710
head:ffffea00005dc400 order:3 entire_mapcount:0 nr_pages_mapped:0 pincount:0
anon flags: 0xfff00000000840(slab|head|node=0|zone=1|lastcpupid=0x7ff)
page_type: 0xffffffff()
raw: 00fff00000000840 ffff888012842280 ffffea0001ef9200 dead000000000005
raw: 0000000000000000 0000000000020002 00000001ffffffff 0000000000000000
page dumped because: kasan: bad access detected
page_owner tracks the page as allocated
page last allocated via order 3, migratetype Unmovable, gfp_mask 0xd20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC), pid 1, tgid 1 (swapper/0), ts 8586024694, free_ts 0
set_page_owner include/linux/page_owner.h:31 [inline]
post_alloc_hook+0x1e6/0x210 mm/page_alloc.c:1536
prep_new_page mm/page_alloc.c:1543 [inline]
get_page_from_freelist+0x31db/0x3360 mm/page_alloc.c:3170
__alloc_pages+0x255/0x670 mm/page_alloc.c:4426
alloc_page_interleave+0x22/0x1d0 mm/mempolicy.c:2131
alloc_slab_page+0x6a/0x160 mm/slub.c:1870
allocate_slab mm/slub.c:2017 [inline]
new_slab+0x84/0x2f0 mm/slub.c:2070
___slab_alloc+0xc85/0x1310 mm/slub.c:3223
__slab_alloc mm/slub.c:3322 [inline]
__slab_alloc_node mm/slub.c:3375 [inline]
slab_alloc_node mm/slub.c:3468 [inline]
__kmem_cache_alloc_node+0x1af/0x270 mm/slub.c:3517
__do_kmalloc_node mm/slab_common.c:1022 [inline]
__kmalloc+0xa8/0x230 mm/slab_common.c:1036
acpi_ut_initialize_buffer+0x1d1/0x2b0
acpi_rs_create_pci_routing_table+0x116/0xa50 drivers/acpi/acpica/rscreate.c:212
acpi_rs_get_prt_method_data+0xe8/0x140 drivers/acpi/acpica/rsutils.c:456
acpi_pci_irq_find_prt_entry+0x16e/0xde0 drivers/acpi/pci_irq.c:214
acpi_pci_irq_lookup+0xb0/0x7a0 drivers/acpi/pci_irq.c:298
acpi_pci_irq_enable+0x23a/0x9a0 drivers/acpi/pci_irq.c:413
do_pci_enable_device+0x212/0x490 drivers/pci/pci.c:1953
page_owner free stack trace missing
Memory state around the buggy address:
ffff888017710900: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
ffff888017710980: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
>ffff888017710a00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
^
ffff888017710a80: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
ffff888017710b00: fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb fb
==================================================================
----------------
Code disassembly (best guess):
0: 55 push %rbp
1: 41 57 push %r15
3: 41 56 push %r14
5: 41 55 push %r13
7: 41 54 push %r12
9: 53 push %rbx
a: 85 f6 test %esi,%esi
c: 74 72 je 0x80
e: 49 89 fe mov %rdi,%r14
11: 41 89 f4 mov %esi,%r12d
14: 45 31 ff xor %r15d,%r15d
17: 48 c7 c5 90 01 e0 8a mov $0xffffffff8ae00190,%rbp
1e: 49 c7 c5 40 f5 d7 8a mov $0xffffffff8ad7f540,%r13
25: 48 89 fb mov %rdi,%rbx
28: eb 0c jmp 0x36
* 2a: 49 ff c7 inc %r15 <-- trapping instruction
2d: 48 83 c3 08 add $0x8,%rbx
31: 4d 39 fc cmp %r15,%r12
34: 74 4f je 0x85
36: 48 89 d8 mov %rbx,%rax
39: 48 c1 e8 03 shr $0x3,%rax
3d: 48 rex.W
3e: b9 .byte 0xb9