From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-alma10-1.taild15c8.ts.net [100.103.45.18]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 90BED23392B for ; Sun, 19 Jul 2026 07:17:48 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=100.103.45.18 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784445470; cv=none; b=rjbcWZX2ildhzyGVwoMwPxApMQxHNqvt569AlJezz3Z345CdO7YNOh5C6I8gLAGBkHBhwP23CZeKewWMpVHLpiLiCr4zySQFIaUENtQYfu+FwEhZwk0RT7iZQ47tLPZcOWAaJykQ5+X0AuQnKpcMSo7MbiJBSEl2S/cnEBPbBO4= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1784445470; c=relaxed/simple; bh=0aTDHkuDDZFCYdFiBRV8oY1wAU7jhMT27Qreoaq5UWQ=; h=Message-ID:Date:MIME-Version:Cc:Subject:To:References:From: In-Reply-To:Content-Type; b=eSD7aWVBwxYodFETzBXtUYrhlXU+Q4duvI0X6zk+4HCXmG4Ov9AqtRBaUK8/uuOlcP/uAHl8OXSpNffoj2UU0IW23FiL0I6Ehl1dSykBSXx9uBa+/7krKgktFZXlFRNs8DlkKgW1wWJZ8rLu3TX3y1sYxFhHjjZadk334qB1IYU= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=P7KfFtFE; arc=none smtp.client-ip=100.103.45.18 Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="P7KfFtFE" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 9B9AC1F00A3A; Sun, 19 Jul 2026 07:17:47 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=kernel.org; s=k20260515; t=1784445468; bh=ov08yvGtWw3dxwliGz6MHO4uj0XtDIs8Kop7RqOjyE0=; h=Date:Cc:Subject:To:References:From:In-Reply-To; b=P7KfFtFEi1mBVAs5V7fYN5lMRn1Csg1W4ByemGDsGQ3b8p4uEvKIrXuH2+ZI0BJQ1 zlxspdjz0X8m2tGf/n8o7ve1IYfleKpNiPMNmqX5s71CjpwN0WjT5DJ2vY4qa+6ngu 5NSCdywkB5ltGZDzJSEGLD6WEFEekINO3+v5/QBsOIezag/Y44IJMWWTAE0w1XkR32 0tG9maf1mqKvzc+H7XV5tpnGqFFIO+wvokQc/vyUkzPd908vn22K7oWE3Veu+3+cWm k+XlwALBn5ySAGfG3w+9r62YWsRNfgrWt4eHdQT///8l4tj5fp3tMSL3u2WCtWYRlN 1G2oXbHg9LoRg== Message-ID: <8f354c53-18d9-4cf2-8ca6-e7476210c171@kernel.org> Date: Sun, 19 Jul 2026 15:17:45 +0800 Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Cc: chao@kernel.org, linux-f2fs-devel@lists.sourceforge.net, linux-kernel@vger.kernel.org Subject: Re: [PATCH] f2fs: fix dentry folio leak in find_in_level To: Guanghui Yang <3497809730@qq.com>, Jaegeuk Kim References: Content-Language: en-US From: Chao Yu In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 7bit On 7/13/26 14:36, Guanghui Yang wrote: > find_in_level() gets a dentry folio with f2fs_find_data_folio() before > calling find_in_block(). If find_in_block() returns an error, the > function stores the error in res_folio and breaks out of the loop without > dropping the dentry folio. > > This leaks the folio reference on the find_in_block() error path. Drop > the dentry folio before returning the error to the caller. > Need fixes and Cc stable lines. > Signed-off-by: Guanghui Yang <3497809730@qq.com> Reviewed-by: Chao Yu Thanks,