From patchwork Thu Jan 4 13:58:43 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Michael Nazzareno Trimarchi X-Patchwork-Id: 10144759 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id EB0E6601A1 for ; Thu, 4 Jan 2018 13:58:50 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id DFEBA2861D for ; Thu, 4 Jan 2018 13:58:50 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id D453528639; Thu, 4 Jan 2018 13:58:50 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.8 required=2.0 tests=BAYES_00,DKIM_SIGNED, RCVD_IN_DNSWL_HI,T_DKIM_INVALID autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 306BD2861D for ; Thu, 4 Jan 2018 13:58:49 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1753030AbeADN6s (ORCPT ); Thu, 4 Jan 2018 08:58:48 -0500 Received: from mail-wm0-f68.google.com ([74.125.82.68]:35882 "EHLO mail-wm0-f68.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1753013AbeADN6r (ORCPT ); Thu, 4 Jan 2018 08:58:47 -0500 Received: by mail-wm0-f68.google.com with SMTP id b76so3630080wmg.1 for ; Thu, 04 Jan 2018 05:58:47 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id; bh=x5Da/uShBCVR9OVloQMxGIEZzbJSKTeFkQRiki+yIUw=; b=GuHja4E6/f+Ugs+9zDDj3zn+pk7B5mqIP0QMleJ7GvepQn61yM6STEinzXRdmsBOBx fX5mkS+07Q5ZPgKHC4LZe4odTnZyNmcbET2jYWtDOMZPIOL74xJoqnRx0MiGZ+F+atVU G+r2uC+YlK6T7TUkUfK2HRkdPoj5mtV5in4HaWhvXZU4y1W72Wt8P5xd9zRvLKMydHyh kT9OC7Tr86RxcT47rIeWfg/IAHJ0huSAx+O4rnkwR5/NJQkHb7fEs/7lz9xNXjgW6t6G mTbv1Cw31BKQkb+Uh33NW6bcH+AnC1+hxpv/QQtgI7sqliEGxm6+Kf10tegrve2f/t9V t64A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id; bh=x5Da/uShBCVR9OVloQMxGIEZzbJSKTeFkQRiki+yIUw=; b=rvtt6Wgoqv/qNhGBtCidbLvo3q/wtoO1C58RLVApnkTodAgAUz7G9d3ejZSqTkQfzt VAHg3otGysxpQ+ibq0zfc+E3BiDLQuBSbFKnxnPyGtGJpYlGQvYQd4q9Zqc4DLAu2uaB CiVGCgwOlStfl01ATTkV4i3NR17aqejrxdJXyM3L6ARC4VKakiwroXkR0Zu6o5lrriZd lMMInZ5u3PtQa+xnW1qKZ6yug8vV8vYufSDBfAmkmUaNNfe01VHWKpjIcxwlK+l4HEFN GM8QGwvGcdkUlLH1OUhbYfkvo++/qcMrEbQzHAbkD0qOJQJ1NgBYshgWGW5M2xp6phXR WC2g== X-Gm-Message-State: AKGB3mKI1gpaiUyjKhh58cCfwScOtGvEfEPat0qHWD6OSKRq0xk5H7Bm kCthAr5+WaCjpu6PB1gnKNbO0w== X-Google-Smtp-Source: ACJfBouH1oVM7ufe/RtuXO2jz8WzziNRbZflm+uWMWxwo3gNa0hFux9gsdnYsEFj4/J8mDcrh9LFPQ== X-Received: by 10.28.232.208 with SMTP id f77mr3923974wmi.155.1515074326599; Thu, 04 Jan 2018 05:58:46 -0800 (PST) Received: from localhost.localdomain ([5.170.79.2]) by smtp.gmail.com with ESMTPSA id z5sm2950205wre.94.2018.01.04.05.58.45 (version=TLS1_2 cipher=ECDHE-RSA-AES128-SHA bits=128/128); Thu, 04 Jan 2018 05:58:45 -0800 (PST) From: Michael Trimarchi To: Ulf Hansson Cc: Michael Trimarchi , linux-mmc@vger.kernel.org, Adrian Hunter Subject: [PATCH 1/2] mmc: sdhci-esdhc-imx: Manage sdhci_runtime_suspend_host error code Date: Thu, 4 Jan 2018 14:58:43 +0100 Message-Id: <1515074324-12933-1-git-send-email-michael@amarulasolutions.com> X-Mailer: git-send-email 2.7.4 Sender: linux-mmc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-mmc@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP We need to return in case of error even if the actual implementation of sdhci_runtime_suspend_host always return 0. We don't want to power down the clocks and the assuption is that the sdhci_runtime_suspend_host always let the system consistent in case of failure Signed-off-by: Michael Trimarchi --- drivers/mmc/host/sdhci-esdhc-imx.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/mmc/host/sdhci-esdhc-imx.c b/drivers/mmc/host/sdhci-esdhc-imx.c index 85140c9..d08c21e 100644 --- a/drivers/mmc/host/sdhci-esdhc-imx.c +++ b/drivers/mmc/host/sdhci-esdhc-imx.c @@ -1389,6 +1389,8 @@ static int sdhci_esdhc_runtime_suspend(struct device *dev) int ret; ret = sdhci_runtime_suspend_host(host); + if (ret) + return ret; if (host->tuning_mode != SDHCI_TUNING_MODE_3) mmc_retune_needed(host->mmc);