lkml.org 
[lkml]   [2014]   [Sep]   [10]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
SubjectRE: [PATCH 1/4 v3] GPIO: gpio-dwapb: Enable platform driver binding to MFD driver
Date
> 
> Hi Alvin,
>
> I did a quick test and this looks like it works for me (with device tree).
> I had a couple of small fixes below.
It is very appreciated to help testing.


> Alan
>
> >
> > - port->bgc.gc.ngpio = ngpio;
> > - port->bgc.gc.of_node = port_np;
> > +#ifdef CONFIG_OF_GPIO
> > + port->bgc.gc.of_node = pp->node;
> > +#endif
>
> Please use 'if (IS_ENABLED(CONFIG_OF_GPIO)) as a conditional as you do
> elsewhere.
OK.

>
> > static int dwapb_gpio_probe(struct platform_device *pdev) {
> > + int i;
> > struct resource *res;
> > struct dwapb_gpio *gpio;
> > - struct device_node *np;
> > int err;
> > - unsigned int offs = 0;
> > + struct device *dev = &pdev->dev;
> > + struct dwapb_platform_data *pdata = dev_get_platdata(dev);
> > + bool is_pdata_alloc = !pdata;
>
> Please combine the int's in one line (int err, i;) and put them as the last one on
> this list. It looks the same to the compiler of course, but more uniform for
> human eyes :)
OK.



\
 
 \ /
  Last update: 2014-09-11 03:01    [W:0.167 / U:0.068 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site