RE: [RFC PATCH 08/12] gpio/tegra: Add device tree support

From: Stephen Warren
Date: Mon Aug 15 2011 - 11:48:00 EST


Belisko Marek wrote at Saturday, August 13, 2011 3:49 AM:
> On Sat, Aug 13, 2011 at 12:54 AM, Stephen Warren <swarren@xxxxxxxxxx> wrote:
> > Signed-off-by: Stephen Warren <swarren@xxxxxxxxxx>
> > ---
> > Âdrivers/gpio/gpio-tegra.c | Â 31 +++++++++++++++++++++++++++++++
> > Â1 files changed, 31 insertions(+), 0 deletions(-)
> >
> > diff --git a/drivers/gpio/gpio-tegra.c b/drivers/gpio/gpio-tegra.c
...
> > +static void __init tegra_gpio_probe_dt(struct platform_device *pdev)
> > +{
> > + Â Â Â const __be32 *gpios;
> > + Â Â Â u32 gpioslen;
> > + Â Â Â int i;
> > +
> > + Â Â Â gpios = of_get_property(pdev->dev.of_node, "nvidia,gpios", &gpioslen);
> > + Â Â Â if (gpios == NULL)
> > + Â Â Â Â Â Â Â return;
> > +
> > + Â Â Â gpioslen /= sizeof(*gpios);
> > + Â Â Â for (i = 0; i < gpioslen; i++, gpios++) {
> > + Â Â Â Â Â Â Â u32 gpio = be32_to_cpup(gpios);
> > + Â Â Â Â Â Â Â dev_err(&pdev->dev, "Enabling GPIO %d\n", gpio);
>
> Is really necessary to print all enabled gpio's to console? Also seen
> same in pinmux probe.

Oops, that's certainly not necessary. That was debugging code, and I meant
to convert to dev_dbg before posting.

--
nvpublic

èº{.nÇ+‰·Ÿ®‰­†+%ŠËlzwm…ébëæìr¸›zX§»®w¥Š{ayºÊÚë,j­¢f£¢·hš‹àz¹®w¥¢¸ ¢·¦j:+v‰¨ŠwèjØm¶Ÿÿ¾«‘êçzZ+ƒùšŽŠÝj"ú!¶iO•æ¬z·švØ^¶m§ÿðà nÆàþY&—