[PATCH] gpio: stmpe: Add DT support for stmpe gpio

Lee Jones lee.jones at linaro.org
Fri Nov 23 23:14:13 EST 2012


> >> -     stmpe_gpio->chip.base = pdata ? pdata->gpio_base : -1;
> >
> > Why have you deleted this?
> >
> >> +
> >> +     if (pdata) {
> >> +             stmpe_gpio->norequest_mask = pdata->norequest_mask;
> >> +             stmpe_gpio->chip.base = pdata->gpio_base;
> >
> > Then added this?
> >
> >> +     } else {
> >> +             stmpe_gpio->chip.base = -1;
> >
> > And this?
> 
> To group all non-DT assignments in a single if block, instead of two.

That assignment has nothing to do with DT.

> > Just leave the top line in and it saves you lots of complecations.
> 
> Sorry, Couldn't get this one.

I'm saying, just leave it where it is.

> >> +             if (np)
> >> +                     of_property_read_u32(np, "st,norequest-mask",
> >> +                                     &pdata->norequest_mask);
> >
> > Can you explain to me what this does?
> 
> You mean pdata->norequest_mask?  It marks few gpios as unusable.
> Because these pads might be used by other blocks of stmpe.

I'm not sure if that should be set with DT or not.

Second opinion anyone?

-- 
Lee Jones
Linaro ST-Ericsson Landing Team Lead
Linaro.org │ Open source software for ARM SoCs
Follow Linaro: Facebook | Twitter | Blog


More information about the devicetree-discuss mailing list