================================================================== BUG: KASAN: use-after-free in crc_itu_t+0xd2/0xe0 lib/crc-itu-t.c:60 Read of size 1 at addr ffff8880a645b000 by task syz-executor.2/5049 CPU: 0 PID: 5049 Comm: syz-executor.2 Not tainted 6.4.0-rc2-next-20230515-syzkaller #0 Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 05/25/2023 Call Trace: __dump_stack lib/dump_stack.c:88 [inline] dump_stack_lvl+0xd9/0x150 lib/dump_stack.c:106 print_address_description.constprop.0+0x2c/0x3c0 mm/kasan/report.c:351 print_report mm/kasan/report.c:462 [inline] kasan_report+0x11c/0x130 mm/kasan/report.c:571 crc_itu_t+0xd2/0xe0 lib/crc-itu-t.c:60 udf_finalize_lvid+0xe0/0x1d0 fs/udf/super.c:1988 udf_close_lvid.isra.0+0x406/0x550 fs/udf/super.c:2056 udf_put_super+0x1bb/0x230 fs/udf/super.c:2326 generic_shutdown_super+0x158/0x480 fs/super.c:500 kill_block_super+0xa1/0x100 fs/super.c:1407 deactivate_locked_super+0x98/0x160 fs/super.c:331 deactivate_super+0xb1/0xd0 fs/super.c:362 cleanup_mnt+0x2ae/0x3d0 fs/namespace.c:1177 task_work_run+0x16f/0x270 kernel/task_work.c:179 resume_user_mode_work include/linux/resume_user_mode.h:49 [inline] exit_to_user_mode_loop kernel/entry/common.c:171 [inline] exit_to_user_mode_prepare+0x210/0x240 kernel/entry/common.c:204 __syscall_exit_to_user_mode_work kernel/entry/common.c:286 [inline] syscall_exit_to_user_mode+0x1d/0x50 kernel/entry/common.c:297 do_syscall_64+0x46/0xb0 arch/x86/entry/common.c:86 entry_SYSCALL_64_after_hwframe+0x63/0xcd RIP: 0033:0x7f7e3a68d5d7 Code: ff ff ff f7 d8 64 89 01 48 83 c8 ff c3 66 0f 1f 44 00 00 31 f6 e9 09 00 00 00 66 0f 1f 84 00 00 00 00 00 b8 a6 00 00 00 0f 05 <48> 3d 01 f0 ff ff 73 01 c3 48 c7 c1 b8 ff ff ff f7 d8 64 89 01 48 RSP: 002b:00007ffc49d625f8 EFLAGS: 00000246 ORIG_RAX: 00000000000000a6 RAX: 0000000000000000 RBX: 0000000000000000 RCX: 00007f7e3a68d5d7 RDX: 00007ffc49d626cb RSI: 000000000000000a RDI: 00007ffc49d626c0 RBP: 00007ffc49d626c0 R08: 00000000ffffffff R09: 00007ffc49d62490 R10: 0000555555fa58ab R11: 0000000000000246 R12: 00007f7e3a6e6cdc R13: 00007ffc49d63780 R14: 0000555555fa5810 R15: 00007ffc49d637c0 The buggy address belongs to the physical page: page:ffffea00029916c0 refcount:0 mapcount:0 mapping:0000000000000000 index:0x1 pfn:0xa645b flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) page_type: 0xffffffff() raw: 00fff00000000000 ffffea0001258cc8 ffffea0000e84d88 0000000000000000 raw: 0000000000000001 0000000000000000 00000000ffffffff 0000000000000000 page dumped because: kasan: bad access detected page_owner tracks the page as freed page last allocated via order 0, migratetype Movable, gfp_mask 0x140dca(GFP_HIGHUSER_MOVABLE|__GFP_COMP|__GFP_ZERO), pid 17483, tgid 17477 (syz-executor.5), ts 990151068943, free_ts 990180459010 set_page_owner include/linux/page_owner.h:31 [inline] post_alloc_hook+0x2db/0x350 mm/page_alloc.c:1731 prep_new_page mm/page_alloc.c:1738 [inline] get_page_from_freelist+0xf67/0x2a80 mm/page_alloc.c:3539 __alloc_pages+0x1cb/0x4a0 mm/page_alloc.c:4805 __folio_alloc+0x16/0x40 mm/page_alloc.c:4837 vma_alloc_folio+0x155/0x850 mm/mempolicy.c:2240 do_anonymous_page mm/memory.c:4088 [inline] do_pte_missing mm/memory.c:3648 [inline] handle_pte_fault mm/memory.c:4950 [inline] __handle_mm_fault+0x2263/0x4170 mm/memory.c:5092 handle_mm_fault+0x2af/0x9f0 mm/memory.c:5246 do_user_addr_fault+0x2ca/0x1210 arch/x86/mm/fault.c:1349 handle_page_fault arch/x86/mm/fault.c:1534 [inline] exc_page_fault+0x98/0x170 arch/x86/mm/fault.c:1590 asm_exc_page_fault+0x26/0x30 arch/x86/include/asm/idtentry.h:570 page last free stack trace: reset_page_owner include/linux/page_owner.h:24 [inline] free_pages_prepare mm/page_alloc.c:1302 [inline] free_unref_page_prepare+0x4dd/0xb90 mm/page_alloc.c:2600 free_unref_page_list+0xe3/0xa70 mm/page_alloc.c:2741 release_pages+0xcd8/0x1380 mm/swap.c:1042 folios_put include/linux/mm.h:1499 [inline] folio_batch_move_lru+0x2b7/0x400 mm/swap.c:224 lru_add_drain_cpu+0x56f/0x850 mm/swap.c:652 lru_add_drain+0x10c/0x440 mm/swap.c:752 free_pages_and_swap_cache+0x1c/0xa0 mm/swap_state.c:314 tlb_batch_pages_flush+0xa8/0x1a0 mm/mmu_gather.c:97 tlb_flush_mmu_free mm/mmu_gather.c:292 [inline] tlb_flush_mmu mm/mmu_gather.c:299 [inline] tlb_finish_mmu+0x14b/0x7e0 mm/mmu_gather.c:391 exit_mmap+0x2b2/0x930 mm/mmap.c:3146 __mmput+0x128/0x4c0 kernel/fork.c:1347 mmput+0x60/0x70 kernel/fork.c:1369 exit_mm kernel/exit.c:564 [inline] do_exit+0x9d7/0x29f0 kernel/exit.c:858 do_group_exit+0xd4/0x2a0 kernel/exit.c:1021 get_signal+0x2315/0x25b0 kernel/signal.c:2874 arch_do_signal_or_restart+0x79/0x5c0 arch/x86/kernel/signal.c:306 Memory state around the buggy address: ffff8880a645af00: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ffff8880a645af80: 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 >ffff8880a645b000: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff8880a645b080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff8880a645b100: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ==================================================================