Received: by 2002:a05:6a10:9848:0:0:0:0 with SMTP id x8csp3336402pxf; Mon, 15 Mar 2021 07:25:01 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyzVXv7ebxvKyBXznr/UUM/VeAFsoV8FT7tSmcGXMDvD0wv8s8rq9nsD+2H852hFwMoC9Ox X-Received: by 2002:a17:907:3e9e:: with SMTP id hs30mr24281585ejc.66.1615818301628; Mon, 15 Mar 2021 07:25:01 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1615818301; cv=none; d=google.com; s=arc-20160816; b=LA6H1xp6g8Bi5hJzCwu8SFlk8owXNl+yBMmEvWuVc+a9H1tb98yXOd7UdlmIfYvm0h 0zwknrg7rzSBNU3BfEpf2x5ceUAhYq4LSmRCDu+H6WMf31pMzWrSVedok3bjDSxX9WR2 Df63dWrKGPeMPRnXqoDvweV1SKKm55I5C8qnxrjT3lNZfQn1K+PnJEZAGsMOllOofx8f k+oQ2v4UjyxmWpbIlhL6ZGWjCaM+IMSN+KVESvursJU2c0PMDn+U8foV187KA6LHQOdn pBU5aPjaLbs67yZ5WSHG4FkZ+ptkBhCtQ/bFi0q3iiahwyyAzD49GjiUSz51rl3AtfI5 Wx8A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:mime-version :user-agent:references:in-reply-to:message-id:date:subject:cc:to :from:dkim-signature; bh=HqJ0arVcMfo6l2imn3PpI2UU/MpWp4GtHSDkdQZ1fMU=; b=HZR8xnCro7Kl1fPKmTBDVsu8wT4Gcju3gR8zm6ApR00RJSGmphkQKEMhnV+CJqTd+7 /MRnM/3558DapdBtX2YmoW25KnQwaWwyLR2e388J8HATEZ0LtpQYUSMQIBDQZ4QIcoto Zpg6slBPtARSBAkjvI58IS+UyHvfzyGXB/akUKtrL7QIhQvPXeiCtDCqhMi8ZaVGVHg1 EeXrCh3Ccz50jMWCnmvFWf0azRbyQ7npca8oBSAgUZ6gJ+ixxljRfOy1WmYY37EQeO8+ xcLz0aov8xnOuQdq3P+RzxC3t/hfIHgkAUwLW17ylPyjG4V3zXDzK4fTiGc/EClPAhmq P/ng== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=A0vuQsdw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id l11si11236930edb.511.2021.03.15.07.24.38; Mon, 15 Mar 2021 07:25:01 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linuxfoundation.org header.s=korg header.b=A0vuQsdw; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=linuxfoundation.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S238096AbhCOOWo (ORCPT + 99 others); Mon, 15 Mar 2021 10:22:44 -0400 Received: from mail.kernel.org ([198.145.29.99]:37500 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S232934AbhCOOAM (ORCPT ); Mon, 15 Mar 2021 10:00:12 -0400 Received: by mail.kernel.org (Postfix) with ESMTPSA id 95E2A64EEC; Mon, 15 Mar 2021 13:59:57 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=linuxfoundation.org; s=korg; t=1615816798; bh=YWVb5gUVrbifFAYA4t0MTol9HiYX7gH91R/aJyElmFM=; h=From:To:Cc:Subject:Date:In-Reply-To:References:From; b=A0vuQsdwbOXnmHVNdl0ARxK0PiIIshiDdverVOOJvZvXjjDwFNQ5zAGexdI4uY/V1 JXx10ZhCgYBg9hhE3o3MMFTeKrf4qrPMk4QHhKuL0YR/kzuVzUx/ObDP+g3UWhlTEm c1ieMpqRUO35Ty2iHPd4G95Huml/22BVNPylCzDE= From: gregkh@linuxfoundation.org To: linux-kernel@vger.kernel.org Cc: Greg Kroah-Hartman , stable@vger.kernel.org, Christophe JAILLET , Ulf Hansson , Sasha Levin Subject: [PATCH 5.11 131/306] mmc: mxs-mmc: Fix a resource leak in an error handling path in mxs_mmc_probe() Date: Mon, 15 Mar 2021 14:53:14 +0100 Message-Id: <20210315135512.079891456@linuxfoundation.org> X-Mailer: git-send-email 2.30.2 In-Reply-To: <20210315135507.611436477@linuxfoundation.org> References: <20210315135507.611436477@linuxfoundation.org> User-Agent: quilt/0.66 MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org From: Greg Kroah-Hartman From: Christophe JAILLET [ Upstream commit 0bb7e560f821c7770973a94e346654c4bdccd42c ] If 'mmc_of_parse()' fails, we must undo the previous 'dma_request_chan()' call. Signed-off-by: Christophe JAILLET Link: https://lore.kernel.org/r/20201208203527.49262-1-christophe.jaillet@wanadoo.fr Signed-off-by: Ulf Hansson Signed-off-by: Sasha Levin --- drivers/mmc/host/mxs-mmc.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/mmc/host/mxs-mmc.c b/drivers/mmc/host/mxs-mmc.c index 56bbc6cd9c84..947581de7860 100644 --- a/drivers/mmc/host/mxs-mmc.c +++ b/drivers/mmc/host/mxs-mmc.c @@ -628,7 +628,7 @@ static int mxs_mmc_probe(struct platform_device *pdev) ret = mmc_of_parse(mmc); if (ret) - goto out_clk_disable; + goto out_free_dma; mmc->ocr_avail = MMC_VDD_32_33 | MMC_VDD_33_34; -- 2.30.1