From patchwork Sun Jun 9 20:14:15 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Simon Baatz X-Patchwork-Id: 2695081 Return-Path: X-Original-To: patchwork-linux-mmc@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork2.kernel.org (Postfix) with ESMTP id 6C398DF2A1 for ; Sun, 9 Jun 2013 20:15:14 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1751226Ab3FIUPN (ORCPT ); Sun, 9 Jun 2013 16:15:13 -0400 Received: from mo-p00-ob.rzone.de ([81.169.146.161]:31776 "EHLO mo-p00-ob.rzone.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751243Ab3FIUPN (ORCPT ); Sun, 9 Jun 2013 16:15:13 -0400 X-RZG-AUTH: :L20Qdkipd/NtQfa28f3iP6nsj1VEm6lxnnjU56eNUnjyVKhsqx3PYdmEEmLU8T5OUVI= X-RZG-CLASS-ID: mo00 Received: from gandalf.schnuecks.de (p57A57344.dip0.t-ipconnect.de [87.165.115.68]) by smtp.strato.de (jored mo31) (RZmta 31.27 DYNA|AUTH) with (DHE-RSA-AES256-SHA encrypted) ESMTPA id e034ccp59IfsGX ; Sun, 9 Jun 2013 22:15:11 +0200 (CEST) Received: by gandalf.schnuecks.de (Postfix, from userid 500) id 4AE67400E3; Sun, 9 Jun 2013 22:15:11 +0200 (CEST) From: Simon Baatz To: linux-arm-kernel@lists.infradead.org, linux-mmc@vger.kernel.org, devicetree-discuss@lists.ozlabs.org Cc: Chris Ball , Jason Cooper , Andrew Lunn , Guennadi Liakhovetski , Thomas Petazzoni , Ulf Hansson Subject: [RESEND PATCH V3 5/8] mmc: sdhci-pxav3: handle mmc_of_parse() errors during probe Date: Sun, 9 Jun 2013 22:14:15 +0200 Message-Id: <1370808858-32241-6-git-send-email-gmbnomis@gmail.com> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1370808858-32241-1-git-send-email-gmbnomis@gmail.com> References: <1370808858-32241-1-git-send-email-gmbnomis@gmail.com> Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org Signed-off-by: Simon Baatz --- drivers/mmc/host/sdhci-pxav3.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/drivers/mmc/host/sdhci-pxav3.c b/drivers/mmc/host/sdhci-pxav3.c index 1ae358e..67ea388 100644 --- a/drivers/mmc/host/sdhci-pxav3.c +++ b/drivers/mmc/host/sdhci-pxav3.c @@ -252,7 +252,9 @@ static int sdhci_pxav3_probe(struct platform_device *pdev) match = of_match_device(of_match_ptr(sdhci_pxav3_of_match), &pdev->dev); if (match) { - mmc_of_parse(host->mmc); + ret = mmc_of_parse(host->mmc); + if (ret) + goto err_of_parse; sdhci_get_of_property(pdev); pdata = pxav3_get_mmc_pdata(dev); } else if (pdata) { @@ -313,10 +315,11 @@ static int sdhci_pxav3_probe(struct platform_device *pdev) return 0; +err_of_parse: +err_cd_req: err_add_host: clk_disable_unprepare(clk); clk_put(clk); -err_cd_req: err_clk_get: sdhci_pltfm_free(pdev); kfree(pxa);