Received: by 2002:a25:8b12:0:0:0:0:0 with SMTP id i18csp5214834ybl; Tue, 27 Aug 2019 00:55:42 -0700 (PDT) X-Google-Smtp-Source: APXvYqy/XkTYs6dUT5XQq0OCuN+7U87Oinvmpt4kdPwPPJ+fQTnK67qWGXYhzqMMdOvPeTUPMLAO X-Received: by 2002:a63:5f01:: with SMTP id t1mr18345993pgb.200.1566892542756; Tue, 27 Aug 2019 00:55:42 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1566892542; cv=none; d=google.com; s=arc-20160816; b=dvIN9uLUn5FpJcOXlpZIds9Gc6TyJ+uP0BZF/Euut0GemjDyx6LwiXxdBHsL5qj0HV q6QSUSl8rYh2YX+d6RzFoeapw0EZxG2ie1033BzmMENJ8sM4H+yrVJAnZnDklqEj+DmJ vSnWBTEZkumMvOM8u60QEs609L7CqNJGzbtG523ayiwGnFCzzsk8ee4VbxUxKBK+zbTw adRM7WZMfPacPV3WkL6y14S20KAaZn9kZ4pz8x7qqdXQkOrwUa8vB6wfzLT1oSyxZV0S +FMBLZgTM/eLOYUWfqtPefQoIT/azFTp62eXKlG4vgETOr9Iw+1cem8IEbtBZUZMLA1k elBA== 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=mV7CHonPxogPcyeUftXkm+Lw0wH74Tktm5Tn2Qcq/ho=; b=zT9m2V7imKwXGVgO71uTYJFY2Jv79axs/d9P5LMYkaaZIH1bYdCkFE6N54uQlXKT2z 7a1kzqFnwKQH0NqWoYU6Lj/dBg/gZJeRYkEziRkDD1pc/ZnBh9dqGYvAlIWZfTqBA4lD Hf3HVdtKEgxw83hJjoV2YamDyY1R0pdsYLM253EbeNx0rvviQpO/Sf53BuRhGxIZxzGm 7DvWshbn+cw/EX3VZzje+l1307oI9zEjYVF3PuIFHx8yMHjZoexg6H0O+nn4IjeX69++ zFEF675mFOW5HDtXe6a5EM85b/8wko5pa4lOqSNLUB+AiXLPWa3HcxGfy+oZfZdkOyE8 peBg== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=uoDTvzny; 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 cp2si12345561plb.437.2019.08.27.00.55.27; Tue, 27 Aug 2019 00:55:42 -0700 (PDT) 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=uoDTvzny; 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 S1729933AbfH0Hxy (ORCPT + 99 others); Tue, 27 Aug 2019 03:53:54 -0400 Received: from mail.kernel.org ([198.145.29.99]:45486 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725825AbfH0Hxx (ORCPT ); Tue, 27 Aug 2019 03:53:53 -0400 Received: from localhost (83-86-89-107.cable.dynamic.v4.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 3F7B120828; Tue, 27 Aug 2019 07:53:52 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1566892432; bh=tFqCp16aNSWR277rTmCPSwFTD5kGdcp9QL3VQurlJrk=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=uoDTvznyaNyT7UfY6054FcjQKwlzJkBRApVODWPgJLKfrOJ44Nd6d/TRwlFziG3+/ n2xet9yubwleEM/WTlIjVxO+4uhV834wS1ww8GfshLZop/CPDWWaqVnWD6O4w2XTpO Ciac4i2wPJvWoD8sN2pm7Oniw+QRGv34DAe+zdK4= From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, ZhangXiaoxu , Mike Snitzer Subject: [PATCH 4.14 51/62] dm space map metadata: fix missing store of apply_bops() return value Date: Tue, 27 Aug 2019 09:50:56 +0200 Message-Id: <20190827072703.472679604@linuxfoundation.org> X-Mailer: git-send-email 2.23.0 In-Reply-To: <20190827072659.803647352@linuxfoundation.org> References: <20190827072659.803647352@linuxfoundation.org> User-Agent: quilt/0.66 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 From: ZhangXiaoxu commit ae148243d3f0816b37477106c05a2ec7d5f32614 upstream. In commit 6096d91af0b6 ("dm space map metadata: fix occasional leak of a metadata block on resize"), we refactor the commit logic to a new function 'apply_bops'. But when that logic was replaced in out() the return value was not stored. This may lead out() returning a wrong value to the caller. Fixes: 6096d91af0b6 ("dm space map metadata: fix occasional leak of a metadata block on resize") Cc: stable@vger.kernel.org Signed-off-by: ZhangXiaoxu Signed-off-by: Mike Snitzer Signed-off-by: Greg Kroah-Hartman --- drivers/md/persistent-data/dm-space-map-metadata.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) --- a/drivers/md/persistent-data/dm-space-map-metadata.c +++ b/drivers/md/persistent-data/dm-space-map-metadata.c @@ -248,7 +248,7 @@ static int out(struct sm_metadata *smm) } if (smm->recursion_count == 1) - apply_bops(smm); + r = apply_bops(smm); smm->recursion_count--;