From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (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 A7AC22EB15; Fri, 24 Nov 2023 19:21:23 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (1024-bit key) header.d=linuxfoundation.org header.i=@linuxfoundation.org header.b="2ANwL/ss" Received: by smtp.kernel.org (Postfix) with ESMTPSA id 32BC6C433C8; Fri, 24 Nov 2023 19:21:23 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1700853683; bh=EyG4p3PvCq4aPaOWgg+I2e915yEFkdkIMw6Gae6LTpU=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=2ANwL/ssXiwO0Zpb4KPsnlwRyta/Tm/MKGe4+oqqotC1Jmiv67MnxU83koe+T5xcd tLtMLeiQhGFPtR1pKnJFifeW77DGk5ghsFzk6AEK023ZLlv+XmpsY2UGG8wGTsdgQN yj3JKu7qK9RGo/YWDJpB3CGJZxs0odrVlP/Ruu8A= From: Greg Kroah-Hartman To: stable@vger.kernel.org Cc: Greg Kroah-Hartman , patches@lists.linux.dev, Kemeng Shi , Theodore Tso , stable@kernel.org Subject: [PATCH 5.15 286/297] ext4: add missed brelse in update_backups Date: Fri, 24 Nov 2023 17:55:28 +0000 Message-ID: <20231124172010.137066171@linuxfoundation.org> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231124172000.087816911@linuxfoundation.org> References: <20231124172000.087816911@linuxfoundation.org> User-Agent: quilt/0.67 X-stable: review X-Patchwork-Hint: ignore Precedence: bulk X-Mailing-List: stable@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit 5.15-stable review patch. If anyone has any objections, please let me know. ------------------ From: Kemeng Shi commit 9adac8b01f4be28acd5838aade42b8daa4f0b642 upstream. add missed brelse in update_backups Signed-off-by: Kemeng Shi Reviewed-by: Theodore Ts'o Link: https://lore.kernel.org/r/20230826174712.4059355-3-shikemeng@huaweicloud.com Signed-off-by: Theodore Ts'o Cc: stable@kernel.org Signed-off-by: Greg Kroah-Hartman --- fs/ext4/resize.c | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) --- a/fs/ext4/resize.c +++ b/fs/ext4/resize.c @@ -1160,8 +1160,10 @@ static void update_backups(struct super_ ext4_group_first_block_no(sb, group)); BUFFER_TRACE(bh, "get_write_access"); if ((err = ext4_journal_get_write_access(handle, sb, bh, - EXT4_JTR_NONE))) + EXT4_JTR_NONE))) { + brelse(bh); break; + } lock_buffer(bh); memcpy(bh->b_data, data, size); if (rest)