On Mon, Mar 11, 2019 at 10:40 AM Bartosz Golaszewski
<bgolaszew...@baylibre.com> wrote:
> czw., 7 mar 2019 o 11:39 Arnd Bergmann <a...@arndb.de> napisaƂ(a):
> > clang warns about a tentative array definition in the gpio-omap driver:
> >
> > drivers/gpio/gpio-omap.c:1282:34: error: tentative array definition assumed 
> > to have one element [-Werror]
> > static const struct of_device_id omap_gpio_match[];
> >
> > It's best to just reorder the entire file to avoid forward declarations,
> > which lets us use the regular declaration. To do this, the unnecessary
> > CONFIG_OF check must also be removed.
> >

> > +static const struct dev_pm_ops gpio_pm_ops = {
> > +       SET_RUNTIME_PM_OPS(omap_gpio_runtime_suspend, 
> > omap_gpio_runtime_resume,
> > +                                                                       
> > NULL)
> > +};
> > +
> >  static struct platform_driver omap_gpio_driver = {
> >         .probe          = omap_gpio_probe,
> >         .remove         = omap_gpio_remove,
> >         .driver         = {
> >                 .name   = "omap_gpio",
> >                 .pm     = &gpio_pm_ops,
> > -               .of_match_table = of_match_ptr(omap_gpio_match),
> > +               .of_match_table = omap_gpio_match,
>
> This doesn't seem like a logical part of this commit. Can you send a
> separate patch?
>
> Other than that, looks good to me.

This change has to be kept together the with removal of the #ifdef,
otherwise I'd introduce a new warning about an unused variable.

I could try to split out the reordering of the file though.

      Arnd

Reply via email to