From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 2188FC197A0 for ; Mon, 20 Nov 2023 08:05:33 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232134AbjKTIFc (ORCPT ); Mon, 20 Nov 2023 03:05:32 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:41564 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232098AbjKTIF3 (ORCPT ); Mon, 20 Nov 2023 03:05:29 -0500 Received: from mail-pl1-f207.google.com (mail-pl1-f207.google.com [209.85.214.207]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 6E7A5CA for ; Mon, 20 Nov 2023 00:05:23 -0800 (PST) Received: by mail-pl1-f207.google.com with SMTP id d9443c01a7336-1cc0e3a2b6eso48734865ad.3 for ; Mon, 20 Nov 2023 00:05:23 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1700467523; x=1701072323; h=to:from:subject:message-id:date:mime-version:x-gm-message-state :from:to:cc:subject:date:message-id:reply-to; bh=BFFgTieMhzmpzC7zBMFZD5JT3T1t57L3DBASoDQrHkU=; b=TB3hUFMUxsraAXPu3/w1kJ/ZGRBmAnSR+CF/dPa/FRxpWXnCCLDRhq0DvFt4gbtq4t zJc8zYU1wTTCzPSOyoKjUlKPkW69HNYVtGcqPDPy10L/RkjsdLSRO6FFR99wjFMmV8XH qU5zJouNaXbyTQHpTSVYktsaQOOt+tTAOaef2104T4jDfPecZ36YTJiARHzPfxSN3OXL tmrlGD74HOrsxpMwYYcq7XKLkl8FkBlAzJhZI/SU7Zvd8UNm+5aHrNWdVRhFAFcQDqLt L7cNqn6TThCK19ECp7C9FbFdgSZnxe+DlQU7vK7TzJxk/vmrdPuBD2QTwf2PIIjoe6Du Yvzw== X-Gm-Message-State: AOJu0YwQRG4smCHlcWbn8odHsENNrXbXb1tuF3AWHJ24ZpGdhKe13k7T frjf+U2v9QN42zcZc7z15PqTnj510gHituaztBueadnDR28w X-Google-Smtp-Source: AGHT+IGirTJ0JjBDHQiqHuy3NgK5Ew2xOfMaek3wJqfnN0aPD81r0i9kd/HnPDFnWeXVKVOQrpon4LK8ARMLLDfHbKx/d30hi7Mf MIME-Version: 1.0 X-Received: by 2002:a17:903:11c3:b0:1cf:6467:b2ed with SMTP id q3-20020a17090311c300b001cf6467b2edmr231475plh.12.1700467522985; Mon, 20 Nov 2023 00:05:22 -0800 (PST) Date: Mon, 20 Nov 2023 00:05:22 -0800 X-Google-Appengine-App-Id: s~syzkaller X-Google-Appengine-App-Id-Alias: syzkaller Message-ID: <000000000000a8e4a3060a90f205@google.com> Subject: [syzbot] [btrfs?] memory leak in __btrfs_add_free_space From: syzbot To: clm@fb.com, dsterba@suse.com, josef@toxicpanda.com, linux-btrfs@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-kernel@vger.kernel.org, syzkaller-bugs@googlegroups.com Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hello, syzbot found the following issue on: HEAD commit: c42d9eeef8e5 Merge tag 'hardening-v6.7-rc2' of git://git.k.. git tree: upstream console output: https://syzkaller.appspot.com/x/log.txt?x=10d5cc04e80000 kernel config: https://syzkaller.appspot.com/x/.config?x=e71d284dd6560ca8 dashboard link: https://syzkaller.appspot.com/bug?extid=349f1f9eb382f477ce50 compiler: gcc (Debian 12.2.0-14) 12.2.0, GNU ld (GNU Binutils for Debian) 2.40 syz repro: https://syzkaller.appspot.com/x/repro.syz?x=112a3b0f680000 Downloadable assets: disk image: https://storage.googleapis.com/syzbot-assets/026cc0fc446f/disk-c42d9eee.raw.xz vmlinux: https://storage.googleapis.com/syzbot-assets/c4b4d6d092c1/vmlinux-c42d9eee.xz kernel image: https://storage.googleapis.com/syzbot-assets/1865f885e9d6/bzImage-c42d9eee.xz mounted in repro: https://storage.googleapis.com/syzbot-assets/513e1afbe9d7/mount_0.gz IMPORTANT: if you fix the issue, please add the following tag to the commit: Reported-by: syzbot+349f1f9eb382f477ce50@syzkaller.appspotmail.com BUG: memory leak unreferenced object 0xffff888123c87618 (size 104): comm "syz-executor.6", pid 10287, jiffies 4294957667 (age 18.250s) hex dump (first 32 bytes): 01 00 00 00 00 00 00 00 00 00 00 00 00 00 00 00 ................ 00 00 00 00 00 00 00 00 01 00 00 00 00 00 00 00 ................ backtrace: [] kmemleak_alloc_recursive include/linux/kmemleak.h:42 [inline] [] slab_post_alloc_hook mm/slab.h:766 [inline] [] slab_alloc_node mm/slub.c:3478 [inline] [] slab_alloc mm/slub.c:3486 [inline] [] __kmem_cache_alloc_lru mm/slub.c:3493 [inline] [] kmem_cache_alloc+0x298/0x430 mm/slub.c:3502 [] kmem_cache_zalloc include/linux/slab.h:711 [inline] [] __btrfs_add_free_space+0x69/0x780 fs/btrfs/free-space-cache.c:2636 [] do_trimming+0x19a/0x2d0 fs/btrfs/free-space-cache.c:3687 [] trim_no_bitmap+0x3a4/0x650 fs/btrfs/free-space-cache.c:3797 [] btrfs_trim_block_group+0xbc/0x1a0 fs/btrfs/free-space-cache.c:4037 [] btrfs_trim_fs+0x1c2/0x6b0 fs/btrfs/extent-tree.c:6297 [] btrfs_ioctl_fitrim+0x1d3/0x270 fs/btrfs/ioctl.c:535 [] btrfs_ioctl+0x2200/0x33e0 fs/btrfs/ioctl.c:4573 [] vfs_ioctl fs/ioctl.c:51 [inline] [] __do_sys_ioctl fs/ioctl.c:871 [inline] [] __se_sys_ioctl fs/ioctl.c:857 [inline] [] __x64_sys_ioctl+0xf2/0x140 fs/ioctl.c:857 [] do_syscall_x64 arch/x86/entry/common.c:51 [inline] [] do_syscall_64+0x3f/0x110 arch/x86/entry/common.c:82 [] entry_SYSCALL_64_after_hwframe+0x63/0x6b --- This report is generated by a bot. It may contain errors. See https://goo.gl/tpsmEJ for more information about syzbot. syzbot engineers can be reached at syzkaller@googlegroups.com. syzbot will keep track of this issue. See: https://goo.gl/tpsmEJ#status for how to communicate with syzbot. If the report is already addressed, let syzbot know by replying with: #syz fix: exact-commit-title If you want syzbot to run the reproducer, reply with: #syz test: git://repo/address.git branch-or-commit-hash If you attach or paste a git patch, syzbot will apply it before testing. If you want to overwrite report's subsystems, reply with: #syz set subsystems: new-subsystem (See the list of subsystem names on the web dashboard) If the report is a duplicate of another one, reply with: #syz dup: exact-subject-of-another-report If you want to undo deduplication, reply with: #syz undup