From: Nikita Kiryanov <nikita@compulab.co.il>
To: u-boot@lists.denx.de
Subject: [U-Boot] [PATCH v2 1/2] omap_hsmmc: Check wp and cd GPIO for valid GPIO first
Date: Thu, 21 Mar 2013 11:38:40 +0200 [thread overview]
Message-ID: <514AD520.8010300@compulab.co.il> (raw)
In-Reply-To: <514ABFD4.3080809@compulab.co.il>
Hi Tom,
a few style comments:
On 03/20/2013 08:46 PM, Tom Rini wrote:
> When we cannot check write protect or card change via GPIO (and have
> been passed -1 in omap_mmc_init), only even try the gpio_is_valid is
> true.
That last part needs rephrasing: "only try if gpio_is_valid() is true".
> This prevents invalid GPIO messages from being seen on the
> console when doing MMC operations
>
> Signed-off-by: Tom Rini <trini@ti.com>
>
[...]
> + if (gpio_is_valid(cd_gpio))
> + return gpio_get_value(cd_gpio);
> + else
> + return -1;
Also, the "else" word is not necessary (in both checks).
Aside from that,
Acked-by: Nikita Kiryanov <nikita@compulab.co.il>
--
Regards,
Nikita.
prev parent reply other threads:[~2013-03-21 9:38 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-03-20 18:46 [U-Boot] [PATCH v2 1/2] omap_hsmmc: Check wp and cd GPIO for valid GPIO first Tom Rini
2013-03-20 18:46 ` [U-Boot] [PATCH v2 2/2] omap_hsmmc: Use -EINVAL not -1 for errors Tom Rini
2013-03-21 8:07 ` [U-Boot] [PATCH v2 1/2] omap_hsmmc: Check wp and cd GPIO for valid GPIO first Nikita Kiryanov
2013-03-21 9:38 ` Nikita Kiryanov [this message]
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=514AD520.8010300@compulab.co.il \
--to=nikita@compulab.co.il \
--cc=u-boot@lists.denx.de \
/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