From: Wolfram Sang <w.sang@pengutronix.de>
To: "Lothar Waßmann" <LW@KARO-electronics.de>
Cc: Shawn Guo <shawn.guo@linaro.org>,
linux-mmc@vger.kernel.org, linux-kernel@vger.kernel.org,
Sascha Hauer <kernel@pengutronix.de>, Chris Ball <cjb@laptop.org>,
linux-arm-kernel@lists.infradead.org
Subject: Re: [MXS MMC 4/5] Check the return codes of clk_enable() and mxs_reset_block()
Date: Tue, 6 Dec 2011 20:12:03 +0100 [thread overview]
Message-ID: <20111206191203.GE7835@pengutronix.de> (raw)
In-Reply-To: <b4779523002ceef3e95887bbcf7ed570cdd93a95.1323177907.git.LW@KARO-electronics.de>
[-- Attachment #1.1: Type: text/plain, Size: 1031 bytes --]
On Tue, Dec 06, 2011 at 02:41:29PM +0100, Lothar Waßmann wrote:
> Add an int return value to mxs_mmc_reset(), so that the return code of
> mxs_reset_block() can be promoted to the caller.
> Also check the return code of clk_enable() in the probe function.
>
> Signed-off-by: Lothar Waßmann <LW@KARO-electronics.de>
> - clk_enable(host->clk);
> + ret = clk_enable(host->clk);
> + if (ret) {
> + dev_err(mmc_dev(host->mmc),
> + "%s: failed to enable clock: %d\n", __func__, ret);
> + goto out_clk_put;
> + }
>
> - mxs_mmc_reset(host);
> + ret = mxs_mmc_reset(host);
> + if (ret) {
> + dev_err(mmc_dev(host->mmc),
> + "%s: failed to reset controller: %d\n", __func__, ret);
> + goto out_clk_put;
> + }
Why __func__ here? dev_err and the msg itself should be indication enough?
Otherwise
Acked-by: Wolfram Sang <w.sang@pengutronix.de>
--
Pengutronix e.K. | Wolfram Sang |
Industrial Linux Solutions | http://www.pengutronix.de/ |
[-- Attachment #1.2: Digital signature --]
[-- Type: application/pgp-signature, Size: 198 bytes --]
[-- Attachment #2: Type: text/plain, Size: 176 bytes --]
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
next prev parent reply other threads:[~2011-12-06 19:12 UTC|newest]
Thread overview: 18+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-12-06 13:41 [MXS MMC 0/5] Some cleanups and fixes for the MXS MMC subsystem Lothar Waßmann
2011-12-06 13:41 ` [MXS MMC 1/5] Fix grammatical error in comment Lothar Waßmann
2011-12-06 19:05 ` Wolfram Sang
2011-12-07 11:00 ` Shawn Guo
2011-12-06 13:41 ` [MXS MMC 2/5] Some cleanups for the MMC driver Lothar Waßmann
2011-12-07 12:01 ` Shawn Guo
2011-12-07 11:57 ` Lothar Waßmann
2011-12-07 12:16 ` Shawn Guo
2011-12-07 12:50 ` Uwe Kleine-König
2011-12-06 13:41 ` [MXS MMC 3/5] Add support for SSP/MMC ports 2 & 3 Lothar Waßmann
2011-12-06 19:10 ` Wolfram Sang
2011-12-07 12:30 ` Shawn Guo
2011-12-06 13:41 ` [MXS MMC 4/5] Check the return codes of clk_enable() and mxs_reset_block() Lothar Waßmann
2011-12-06 19:12 ` Wolfram Sang [this message]
2011-12-07 12:33 ` Shawn Guo
2011-12-06 13:41 ` [MXS MMC 5/5] Add an appropriate MODULE_ALIAS Lothar Waßmann
2011-12-06 19:12 ` Wolfram Sang
2011-12-07 12:34 ` Shawn Guo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=20111206191203.GE7835@pengutronix.de \
--to=w.sang@pengutronix.de \
--cc=LW@KARO-electronics.de \
--cc=cjb@laptop.org \
--cc=kernel@pengutronix.de \
--cc=linux-arm-kernel@lists.infradead.org \
--cc=linux-kernel@vger.kernel.org \
--cc=linux-mmc@vger.kernel.org \
--cc=shawn.guo@linaro.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox