Re: [PATCH] staging: emxx_udc: Fix incorrectly defined global

2021-02-08 Thread Geert Uytterhoeven
Hi Kumar, CC Nishad, Magnus, linux-renesas-soc, On Sun, Feb 7, 2021 at 8:40 AM Kumar Kartikeya Dwivedi wrote: > On Sun, Feb 07, 2021 at 12:04:41PM IST, Stephen Rothwell wrote: > > Given that drivers/staging/emxx_udc/emxx_udc.h is only included by > > drivers/staging/emxx_udc/emxx_udc.c,

Re: [PATCH] staging: emxx_udc: Fix incorrectly defined global

2021-02-07 Thread Greg KH
On Sun, Feb 07, 2021 at 01:08:27PM +0530, Kumar Kartikeya Dwivedi wrote: > On Sun, Feb 07, 2021 at 12:04:41PM IST, Stephen Rothwell wrote: > > > > Given that drivers/staging/emxx_udc/emxx_udc.h is only included by > > drivers/staging/emxx_udc/emxx_udc.c, shouldn't these variables just be > >

Re: [PATCH] staging: emxx_udc: Fix incorrectly defined global

2021-02-07 Thread Greg KH
On Sun, Feb 07, 2021 at 05:30:31AM +0530, Kumar Kartikeya Dwivedi wrote: > The global gpio_desc pointer and int were defined in the header, > instead put the definitions in the translation unit and add an extern > declaration for consumers of the header (currently only one, which is > perhaps why

Re: [PATCH] staging: emxx_udc: Fix incorrectly defined global

2021-02-06 Thread Kumar Kartikeya Dwivedi
On Sun, Feb 07, 2021 at 12:04:41PM IST, Stephen Rothwell wrote: > > Given that drivers/staging/emxx_udc/emxx_udc.h is only included by > drivers/staging/emxx_udc/emxx_udc.c, shouldn't these variables just be > declared static in emxx_udc.c and removed from emxx_udc.h? > Either would be correct.

Re: [PATCH] staging: emxx_udc: Fix incorrectly defined global

2021-02-06 Thread Stephen Rothwell
Hi Kumar, On Sun, 7 Feb 2021 05:30:31 +0530 Kumar Kartikeya Dwivedi wrote: > > The global gpio_desc pointer and int were defined in the header, > instead put the definitions in the translation unit and add an extern > declaration for consumers of the header (currently only one, which is >

[PATCH] staging: emxx_udc: Fix incorrectly defined global

2021-02-06 Thread Kumar Kartikeya Dwivedi
The global gpio_desc pointer and int were defined in the header, instead put the definitions in the translation unit and add an extern declaration for consumers of the header (currently only one, which is perhaps why the linker didn't complain about symbol collisions). This fixes sparse related