Received: by 2002:ad5:474a:0:0:0:0:0 with SMTP id i10csp3717443imu; Mon, 7 Jan 2019 08:13:38 -0800 (PST) X-Google-Smtp-Source: ALg8bN4I6K9UsyLBTjG5i2/XZOcPfz9UOPRj8O3NxY0gKz/0prfuin/wrsmtr+oY8Tf1eOuP7lXq X-Received: by 2002:a17:902:442:: with SMTP id 60mr58578763ple.73.1546877618759; Mon, 07 Jan 2019 08:13:38 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1546877618; cv=none; d=google.com; s=arc-20160816; b=kvGqPm8R+xQRVqm+PuGTOHe6vKB3ZatU9rZ2MP83jjM5h8XVqXl4/k3LtAG1O+P99T yKfBHdfeAAiyKOB/v/A6eaxVB1flR290HrA64dmJAGcQs3mvOHFMhe6360JiCnRwcrU5 lpVQkAkwRk3UQFcrhNvbBWu3quS6GXDAdorUuFtJqO+551NpeaQq0JC6CK9xonmCjQkI zHyJJB3xiKHTXPMl2WfJnkZA1ru7rZ35yhhdDJEen8d/mIaI2ACOFdq0ISZ3w9c8OJSZ MExhdw7AarcerHXkS0cNQcMxAFC5Jd/S7AytuAhTi3WW1LSmILJZ0NZ7CbtMEl/2dpDm 86gg== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=TAl8N96VrVsHWtl7/nGvftBoxATUJsRhC2711tdF8Kk=; b=OWicIlVEkvww/jcuLibLGrIKDozEKvakVpaZimf/PnTmc8dFJA4YmvdeoIXEb7Jfkj EWgZazN0fj342PiktnsHWRD0MpCTlmRgJB8Vy8pcWTr1JlWZvKtYz25drZVaNOI/pH2R kifNCnFhIEFdUoBlMzPvUWU9oHG/9fzUWtrr5rN4O6FC9BgqpOyedGT1bVDLgVoBaKY4 R1fNnM21Mjw8G8N0hA71zHpTg4tAYA/InZQ626eCJhfim+rW3Ou7S9o88OJvXqKGdUma 7sYmXSXH3YTHUx2C921sHbo+Vk1vNstDwpzlVo90+A9MfV/6nB3QK4apmSFyaD1lxaPK Imtg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=HpFj5TY7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id 33si63889320plh.245.2019.01.07.08.13.22; Mon, 07 Jan 2019 08:13:38 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=HpFj5TY7; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729105AbfAGM6K (ORCPT + 99 others); Mon, 7 Jan 2019 07:58:10 -0500 Received: from mail.kernel.org ([198.145.29.99]:45672 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1729939AbfAGM6G (ORCPT ); Mon, 7 Jan 2019 07:58:06 -0500 Received: from localhost (5356596B.cm-6-7b.dynamic.ziggo.nl [83.86.89.107]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id B5635206BB; Mon, 7 Jan 2019 12:58:05 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1546865886; bh=9xjIuNcYg4GLqatvJjIuhEPh7tN2CQSK2abmNe3qv3s=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=HpFj5TY7YBK7VupP8a3tsJbLJmb124Wh11A8KjzoO0wyN/L89Yvq7VbFXsqHS2l88 AEYuimSPDKX1HO7diImX7qdBY4la789IzqdSX/c69TZCwiOu8YUwF74/XvVeu/tEfG S7L5U+h9z8TamTuW9qPaqoOEq4rEJgB8FoQ55mCg= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Maurizio Lombardi , Theodore Tso , stable@kernel.org Subject: [PATCH 4.19 109/170] ext4: missing unlock/put_page() in ext4_try_to_write_inline_data() Date: Mon, 7 Jan 2019 13:32:16 +0100 Message-Id: <20190107104505.809381854@linuxfoundation.org> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190107104452.953560660@linuxfoundation.org> References: <20190107104452.953560660@linuxfoundation.org> User-Agent: quilt/0.65 X-stable: review X-Patchwork-Hint: ignore MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org 4.19-stable review patch. If anyone has any objections, please let me know. ------------------ From: Maurizio Lombardi commit 132d00becb31e88469334e1e62751c81345280e0 upstream. In case of error, ext4_try_to_write_inline_data() should unlock and release the page it holds. Fixes: f19d5870cbf7 ("ext4: add normal write support for inline data") Cc: stable@kernel.org # 3.8 Signed-off-by: Maurizio Lombardi Signed-off-by: Theodore Ts'o Signed-off-by: Greg Kroah-Hartman --- fs/ext4/inline.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) --- a/fs/ext4/inline.c +++ b/fs/ext4/inline.c @@ -705,8 +705,11 @@ int ext4_try_to_write_inline_data(struct if (!PageUptodate(page)) { ret = ext4_read_inline_page(inode, page); - if (ret < 0) + if (ret < 0) { + unlock_page(page); + put_page(page); goto out_up_read; + } } ret = 1;