From: s.hauer@pengutronix.de (Sascha Hauer)
To: linux-arm-kernel@lists.infradead.org
Subject: [PATCH] ARM: mx28evk: Simplify GPIO requests for mx28evk_fec_reset
Date: Thu, 10 Nov 2011 09:47:06 +0100 [thread overview]
Message-ID: <20111110084706.GV16886@pengutronix.de> (raw)
In-Reply-To: <65EE16ACC360FA4D99C96DC085B3F7722CB848@039-SN1MPN1-002.039d.mgd.msft.net>
On Thu, Nov 10, 2011 at 08:11:10AM +0000, Dong Aisheng-B29396 wrote:
> >
> > I think it makes more sense to create an array per board and not per
> > board function. In the mx28evk file we use gpios for the fec, we have a
> > gpio_request_one for the flexcan switch and a gpio_request_array for the
> > lcd pins. All these could be added to a single mx28evk_gpios array.
> > Then it would be easy to see which gpios a board uses and it would be
> > trivial to add additional gpios. The same applies for other boards aswell
> > of course.
> >
> One question is that if one gpio, assume in one function like fec, request fail
> will cause the whole gpio array request fail.
They don't fail. If they do it means we have a duplicate entry in the
table or otherwise screwed up the kernel. I think a single pr_err("bad
things may happen, continue and hope for the best") is enough here.
Sascha
--
Pengutronix e.K. | |
Industrial Linux Solutions | http://www.pengutronix.de/ |
Peiner Str. 6-8, 31137 Hildesheim, Germany | Phone: +49-5121-206917-0 |
Amtsgericht Hildesheim, HRA 2686 | Fax: +49-5121-206917-5555 |
prev parent reply other threads:[~2011-11-10 8:47 UTC|newest]
Thread overview: 5+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-11-09 19:09 [PATCH] ARM: mx28evk: Simplify GPIO requests for mx28evk_fec_reset Fabio Estevam
2011-11-09 19:13 ` Uwe Kleine-König
2011-11-10 7:53 ` Sascha Hauer
2011-11-10 8:11 ` Dong Aisheng-B29396
2011-11-10 8:47 ` Sascha Hauer [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=20111110084706.GV16886@pengutronix.de \
--to=s.hauer@pengutronix.de \
--cc=linux-arm-kernel@lists.infradead.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;
as well as URLs for NNTP newsgroup(s).