From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-il1-f197.google.com (mail-il1-f197.google.com [209.85.166.197]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id A281F2FE57B for ; Thu, 20 Nov 2025 18:21:03 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.166.197 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763662865; cv=none; b=Ruyf+OHSdOZNdzz9N/wMJVqBMKEo8NmFz4fMTlBmyZWT6PHdht6u79dslrO66FO512whSWEa3wiCj/O57N7bXAT+T0XTSH8jeTwh7I3cfZ1wzvhB0++qHD053aV0xlm7tUwEcSdIVGx58+H+4sM1TbTPjdAPIdK4OzTs+n6Spck= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1763662865; c=relaxed/simple; bh=LANrc5ueirYX/I4FG6SuUtNdZcL9gvlgFx5BLa7ET3c=; h=MIME-Version:Date:In-Reply-To:Message-ID:Subject:From:To: Content-Type; b=WDAKDZLBQSVnE9sGRjTndfvs6oJaFJDXehyH6s9GGKe5Pyn0LoRHEI2Cx1y6BDaze8x45B3iOxX6TS2eCNZMBPrBpG5pkGMNYCW9r7ElcjN/720YuMjM2kxIqnzKR6+ihUKjjtSxew5GZdVnCf8VgOvQKSaXU9Ttri0BXr4gXmU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=syzkaller.appspotmail.com; spf=pass smtp.mailfrom=M3KW2WVRGUFZ5GODRSRYTGD7.apphosting.bounces.google.com; arc=none smtp.client-ip=209.85.166.197 Authentication-Results: smtp.subspace.kernel.org; dmarc=fail (p=none dis=none) header.from=syzkaller.appspotmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=M3KW2WVRGUFZ5GODRSRYTGD7.apphosting.bounces.google.com Received: by mail-il1-f197.google.com with SMTP id e9e14a558f8ab-4348db9e727so12024895ab.2 for ; Thu, 20 Nov 2025 10:21:03 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1763662863; x=1764267663; h=to:from:subject:message-id:in-reply-to:date:mime-version :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=w3r73aTQZJuIxtxQ8xKDbX47eIX/0O1G74WiPToiR84=; b=nXZhRLyoDO804EKdg3a9wIQh4Pyv81QV0/qZyKykCRq60inp7w56y/U1IzG6ahiRGF IpPay6l4RKqx3uABql1iYmGSnXSvWc/YAKvvYFhVK/C9wdwQvrEDlY1NwycUAA1Vzf6C bWRML/oH2K3dmMK9BhMgyes5sPeirz4JbEyZpnbkLIp2AqY3NU/Geovl46GiGiuud9dl VTsWA1Wq6hHkim7uQsr4Z9Ovyw//Rna6DH/QOH73sKITn9vMJy+tJmvkf4rBrhaq6Fe/ zVQY5+VJdUIGEvWwreFlPxf3LKc6z9H+sGfxCwP+kOe+GrQLnXEZoprQ8YdOj+6P7maB UCjw== X-Forwarded-Encrypted: i=1; AJvYcCVpJpbbjFdh1MQZu/d0lYgbuvh+j2itWHUzil+F8Q7OWsHTbmQlLd133jJZ/zINaInf+HQy6WWXA78xAos=@vger.kernel.org X-Gm-Message-State: AOJu0YxoYlQouqEpF0Fp/K/YeJTn9VXS/Y6SLZobxvAwZrwpqgqNF/HW EuoKQ1RNDwsKkeUXUFzSUgSrpoDFbTRt/vVpfwONpqFl08k1JLKz6CmpwllaERAHBHsIpBDt2rw 2w/9UdfMnU7zFERheg25MrgWr3tnZx2X+vobvcwj5O00LLeQJdLzQHgmi0ho= X-Google-Smtp-Source: AGHT+IEmIGC39vf3Kv8XFhlAlZrrce+eqqo8mJ0dWNVArErIqyC7Hhm5aMxMByM19c+jgWWN3OY9ffgVIRnFfhVqQaNtfWiduHTw Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 X-Received: by 2002:a05:6e02:12c9:b0:433:7673:1d with SMTP id e9e14a558f8ab-435a9080003mr45764615ab.31.1763662862818; Thu, 20 Nov 2025 10:21:02 -0800 (PST) Date: Thu, 20 Nov 2025 10:21:02 -0800 In-Reply-To: X-Google-Appengine-App-Id: s~syzkaller X-Google-Appengine-App-Id-Alias: syzkaller Message-ID: <691f5c0e.a70a0220.2ea503.0033.GAE@google.com> Subject: Re: [syzbot] [ext4?] KASAN: use-after-free Read in ext4_find_extent (4) From: syzbot To: eraykrdg1@gmail.com, linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com Content-Type: text/plain; charset="UTF-8" Hello, syzbot has tested the proposed patch but the reproducer is still triggering an issue: KASAN: use-after-free Read in ext4_find_extent ================================================================== BUG: KASAN: use-after-free in ext4_ext_binsearch fs/ext4/extents.c:841 [inline] BUG: KASAN: use-after-free in ext4_find_extent+0xae6/0xcc0 fs/ext4/extents.c:956 Read of size 4 at addr ffff888072543018 by task kworker/u8:3/49 CPU: 1 UID: 0 PID: 49 Comm: kworker/u8:3 Not tainted syzkaller #0 PREEMPT(full) Hardware name: Google Google Compute Engine/Google Compute Engine, BIOS Google 10/25/2025 Workqueue: ext4-rsv-conversion ext4_end_io_rsv_work Call Trace: dump_stack_lvl+0x189/0x250 lib/dump_stack.c:120 print_address_description mm/kasan/report.c:378 [inline] print_report+0xca/0x240 mm/kasan/report.c:482 kasan_report+0x118/0x150 mm/kasan/report.c:595 ext4_ext_binsearch fs/ext4/extents.c:841 [inline] ext4_find_extent+0xae6/0xcc0 fs/ext4/extents.c:956 ext4_ext_map_blocks+0x288/0x6ac0 fs/ext4/extents.c:4208 ext4_map_create_blocks fs/ext4/inode.c:609 [inline] ext4_map_blocks+0x860/0x1740 fs/ext4/inode.c:811 ext4_convert_unwritten_extents+0x2ae/0x5d0 fs/ext4/extents.c:4976 ext4_convert_unwritten_io_end_vec+0xff/0x170 fs/ext4/extents.c:5016 ext4_end_io_end+0xc7/0x410 fs/ext4/page-io.c:199 ext4_do_flush_completed_IO fs/ext4/page-io.c:290 [inline] ext4_end_io_rsv_work+0x262/0x330 fs/ext4/page-io.c:305 process_one_work kernel/workqueue.c:3263 [inline] process_scheduled_works+0xae1/0x17b0 kernel/workqueue.c:3346 worker_thread+0x8a0/0xda0 kernel/workqueue.c:3427 kthread+0x711/0x8a0 kernel/kthread.c:463 ret_from_fork+0x4bc/0x870 arch/x86/kernel/process.c:158 ret_from_fork_asm+0x1a/0x30 arch/x86/entry/entry_64.S:245 The buggy address belongs to the physical page: page: refcount:0 mapcount:0 mapping:0000000000000000 index:0x7f7902757 pfn:0x72543 flags: 0xfff00000000000(node=0|zone=1|lastcpupid=0x7ff) raw: 00fff00000000000 dead000000000100 dead000000000122 0000000000000000 raw: 00000007f7902757 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_ZERO|__GFP_COMP), pid 6138, tgid 6138 (syz-executor), ts 130428789605, free_ts 136080635031 set_page_owner include/linux/page_owner.h:32 [inline] post_alloc_hook+0x234/0x290 mm/page_alloc.c:1845 prep_new_page mm/page_alloc.c:1853 [inline] get_page_from_freelist+0x2356/0x2430 mm/page_alloc.c:3879 __alloc_frozen_pages_noprof+0x181/0x370 mm/page_alloc.c:5178 alloc_pages_mpol+0x232/0x4a0 mm/mempolicy.c:2416 folio_alloc_mpol_noprof mm/mempolicy.c:2435 [inline] vma_alloc_folio_noprof+0xe4/0x200 mm/mempolicy.c:2470 folio_prealloc+0x30/0x180 mm/memory.c:-1 alloc_anon_folio mm/memory.c:5126 [inline] do_anonymous_page mm/memory.c:5183 [inline] do_pte_missing mm/memory.c:4360 [inline] handle_pte_fault mm/memory.c:6195 [inline] __handle_mm_fault+0x2a8b/0x5400 mm/memory.c:6336 handle_mm_fault+0x2d5/0x7f0 mm/memory.c:6505 do_user_addr_fault+0xa7c/0x1380 arch/x86/mm/fault.c:1336 handle_page_fault arch/x86/mm/fault.c:1476 [inline] exc_page_fault+0x82/0x100 arch/x86/mm/fault.c:1532 asm_exc_page_fault+0x26/0x30 arch/x86/include/asm/idtentry.h:618 page last free pid 6138 tgid 6138 stack trace: reset_page_owner include/linux/page_owner.h:25 [inline] free_pages_prepare mm/page_alloc.c:1394 [inline] free_unref_folios+0xe5d/0x15f0 mm/page_alloc.c:2958 folios_put_refs+0x584/0x670 mm/swap.c:1002 free_pages_and_swap_cache+0x277/0x520 mm/swap_state.c:355 __tlb_batch_free_encoded_pages mm/mmu_gather.c:136 [inline] tlb_batch_pages_flush mm/mmu_gather.c:149 [inline] tlb_flush_mmu_free mm/mmu_gather.c:397 [inline] tlb_flush_mmu+0x3a0/0x680 mm/mmu_gather.c:404 tlb_finish_mmu+0xc3/0x1d0 mm/mmu_gather.c:497 vms_clear_ptes+0x42c/0x540 mm/vma.c:1235 vms_complete_munmap_vmas+0x206/0x8a0 mm/vma.c:1277 do_vmi_align_munmap+0x364/0x440 mm/vma.c:1536 do_vmi_munmap+0x253/0x2e0 mm/vma.c:1584 __vm_munmap+0x207/0x380 mm/vma.c:3156 __do_sys_munmap mm/mmap.c:1080 [inline] __se_sys_munmap mm/mmap.c:1077 [inline] __x64_sys_munmap+0x60/0x70 mm/mmap.c:1077 do_syscall_x64 arch/x86/entry/syscall_64.c:63 [inline] do_syscall_64+0xfa/0xfa0 arch/x86/entry/syscall_64.c:94 entry_SYSCALL_64_after_hwframe+0x77/0x7f Memory state around the buggy address: ffff888072542f00: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff888072542f80: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff >ffff888072543000: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ^ ffff888072543080: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ffff888072543100: ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ff ================================================================== Tested on: commit: 8e621c9a Merge tag 'net-6.18-rc7' of git://git.kernel... git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=10bc2a12580000 kernel config: https://syzkaller.appspot.com/x/.config?x=6e611fe59206f39f dashboard link: https://syzkaller.appspot.com/bug?extid=ee60e584b5c6bb229126 compiler: Debian clang version 20.1.8 (++20250708063551+0c9f909b7976-1~exp1~20250708183702.136), Debian LLD 20.1.8 patch: https://syzkaller.appspot.com/x/patch.diff?x=11f6f692580000