================================================================== BUG: KASAN: use-after-free in user_mode arch/x86/include/asm/ptrace.h:131 [inline] BUG: KASAN: use-after-free in trace_page_fault_entries arch/x86/mm/fault.c:1541 [inline] BUG: KASAN: use-after-free in do_page_fault+0x66/0x330 arch/x86/mm/fault.c:1553 Read of size 8 at addr ffff8881e6f7ff00 by task syz-executor.1/1653 CPU: 0 PID: 1653 Comm: syz-executor.1 Not tainted 5.4.268-syzkaller-00012-g51cf29fc2bfc #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/27/2024 Call Trace: The buggy address belongs to the page: page:ffffea00079bdfc0 refcount:0 mapcount:0 mapping:0000000000000000 index:0x0 flags: 0x8000000000000000() raw: 8000000000000000 0000000000000000 ffffea00079bdfc8 0000000000000000 raw: 0000000000000000 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as freed page last allocated via order 3, migratetype Unmovable, gfp_mask 0x1d20c0(__GFP_IO|__GFP_FS|__GFP_NOWARN|__GFP_NORETRY|__GFP_COMP|__GFP_NOMEMALLOC|__GFP_HARDWALL) set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook mm/page_alloc.c:2165 [inline] prep_new_page+0x18f/0x370 mm/page_alloc.c:2171 get_page_from_freelist+0x2d13/0x2d90 mm/page_alloc.c:3794 __alloc_pages_nodemask+0x393/0x840 mm/page_alloc.c:4891 alloc_slab_page+0x39/0x3c0 mm/slub.c:343 allocate_slab mm/slub.c:1683 [inline] new_slab+0x97/0x440 mm/slub.c:1749 new_slab_objects mm/slub.c:2505 [inline] ___slab_alloc+0x2fe/0x490 mm/slub.c:2667 __slab_alloc+0x62/0xa0 mm/slub.c:2707 slab_alloc_node mm/slub.c:2792 [inline] slab_alloc mm/slub.c:2837 [inline] kmem_cache_alloc+0x109/0x250 mm/slub.c:2842 getname_flags+0xb8/0x4e0 fs/namei.c:141 getname fs/namei.c:212 [inline] do_symlinkat+0xa1/0x400 fs/namei.c:4244 do_syscall_64+0xca/0x1c0 arch/x86/entry/common.c:290 entry_SYSCALL_64_after_hwframe+0x5c/0xc1 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1176 [inline] __free_pages_ok+0x847/0x950 mm/page_alloc.c:1438 free_the_page mm/page_alloc.c:4953 [inline] __free_pages+0x91/0x140 mm/page_alloc.c:4959 __free_slab+0x221/0x2e0 mm/slub.c:1774 free_slab mm/slub.c:1789 [inline] discard_slab mm/slub.c:1795 [inline] unfreeze_partials+0x14e/0x180 mm/slub.c:2288 put_cpu_partial+0x44/0x180 mm/slub.c:2324 __slab_free+0x297/0x360 mm/slub.c:2971 qlist_free_all+0x43/0xb0 mm/kasan/quarantine.c:167 quarantine_reduce+0x1d9/0x210 mm/kasan/quarantine.c:260 __kasan_kmalloc+0x41/0x210 mm/kasan/common.c:507 slab_post_alloc_hook mm/slab.h:584 [inline] slab_alloc_node mm/slub.c:2829 [inline] slab_alloc mm/slub.c:2837 [inline] __kmalloc_track_caller+0x100/0x2b0 mm/slub.c:4449 kvasprintf+0xd6/0x180 lib/kasprintf.c:25 kobject_set_name_vargs+0x5d/0x110 lib/kobject.c:297 kobject_add_varg lib/kobject.c:392 [inline] kobject_init_and_add+0xda/0x190 lib/kobject.c:481 netdev_queue_add_kobject net/core/net-sysfs.c:1567 [inline] netdev_queue_update_kobjects+0x16b/0x3a0 net/core/net-sysfs.c:1595 register_queue_kobjects net/core/net-sysfs.c:1637 [inline] netdev_register_kobject+0x263/0x310 net/core/net-sysfs.c:1858 register_netdevice+0xbc5/0x12a0 net/core/dev.c:9190 Memory state around the buggy address: ffff8881e6f7fe00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff8881e6f7fe80: 00 00 00 00 00 00 00 00 ff ff ff ff ff ff ff ff >ffff8881e6f7ff00: ff ff ff ff ff ff ff ff ff ff ff ff f1 f1 f1 f1 ^ ffff8881e6f7ff80: 00 f2 f2 f2 04 f3 f3 f3 ff ff ff ff ff ff ff ff ffff8881e6f80000: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ================================================================== PANIC: double fault, error_code: 0x0 CPU: 0 PID: 1653 Comm: syz-executor.1 Tainted: G B 5.4.268-syzkaller-00012-g51cf29fc2bfc #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 03/27/2024 RIP: 0010:check_memory_region+0x3/0x280 mm/kasan/generic.c:190 Code: 5c 41 5d 41 5e 41 5f 5d c3 48 c7 c7 43 7c 59 85 eb 0a 48 c7 c7 7b 7c 59 85 4c 89 fe e8 c5 4e bb 02 31 db eb d7 90 90 55 41 57 <41> 56 53 b0 01 48 85 f6 0f 84 8e 01 00 00 48 89 fd 48 c1 ed 2f 81 RSP: 0018:ffff8881e65d5000 EFLAGS: 00010046 RAX: 0000000000000000 RBX: ffff8881e65d5058 RCX: ffffffff81303811 RDX: 0000000000000000 RSI: 0000000000000008 RDI: ffffffff864b68e8 RBP: 0000000000000000 R08: ffffffff813036e8 R09: 0000000000000000 R10: 0000000000000000 R11: 0000000000000000 R12: ffff8881e65d50e0 R13: dffffc0000000000 R14: ffffe8ffffc13b98 R15: 0000000000000000 FS: 0000555556ceb480(0000) GS:ffff8881f6e00000(0000) knlGS:0000000000000000 CS: 0010 DS: 0000 ES: 0000 CR0: 0000000080050033 CR2: ffff8881e65d4ff8 CR3: 00000001f5c2a000 CR4: 00000000003406b0 DR0: 0000000000000000 DR1: 0000000000000000 DR2: 0000000000000000 DR3: 0000000000000000 DR6: 00000000fffe0ff0 DR7: 0000000000000600 Call Trace: <#DF> ---------------- Code disassembly (best guess): 0: 5c pop %rsp 1: 41 5d pop %r13 3: 41 5e pop %r14 5: 41 5f pop %r15 7: 5d pop %rbp 8: c3 ret 9: 48 c7 c7 43 7c 59 85 mov $0xffffffff85597c43,%rdi 10: eb 0a jmp 0x1c 12: 48 c7 c7 7b 7c 59 85 mov $0xffffffff85597c7b,%rdi 19: 4c 89 fe mov %r15,%rsi 1c: e8 c5 4e bb 02 call 0x2bb4ee6 21: 31 db xor %ebx,%ebx 23: eb d7 jmp 0xfffffffc 25: 90 nop 26: 90 nop 27: 55 push %rbp 28: 41 57 push %r15 * 2a: 41 56 push %r14 <-- trapping instruction 2c: 53 push %rbx 2d: b0 01 mov $0x1,%al 2f: 48 85 f6 test %rsi,%rsi 32: 0f 84 8e 01 00 00 je 0x1c6 38: 48 89 fd mov %rdi,%rbp 3b: 48 c1 ed 2f shr $0x2f,%rbp 3f: 81 .byte 0x81