diff mbox series

[1/2] media: atomisp: make dbgopt static

Message ID 186826ed0f3d3ff42171fdabb30897f03575141a.1706865681.git.hverkuil-cisco@xs4all.nl (mailing list archive)
State New, archived
Headers show
Series media: atomisp: two sparse/smatch fixes | expand

Commit Message

Hans Verkuil Feb. 2, 2024, 9:21 a.m. UTC
This fixes a sparse warning:

drivers/staging/media/atomisp/pci/atomisp_drvfs.c:40:14: warning: symbol 'dbgopt' was not declared. Should it be static?

Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
---
 drivers/staging/media/atomisp/pci/atomisp_drvfs.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Comments

Hans Verkuil Feb. 2, 2024, 10:04 a.m. UTC | #1
On 02/02/2024 10:21, Hans Verkuil wrote:
> This fixes a sparse warning:
> 
> drivers/staging/media/atomisp/pci/atomisp_drvfs.c:40:14: warning: symbol 'dbgopt' was not declared. Should it be static?
> 
> Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>

Fixes: b03301870d9b ("media: atomisp: Replace atomisp_drvfs attr with using driver.dev_groups attr")

> ---
>  drivers/staging/media/atomisp/pci/atomisp_drvfs.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/staging/media/atomisp/pci/atomisp_drvfs.c b/drivers/staging/media/atomisp/pci/atomisp_drvfs.c
> index 293171da1266..ba7dd569a55a 100644
> --- a/drivers/staging/media/atomisp/pci/atomisp_drvfs.c
> +++ b/drivers/staging/media/atomisp/pci/atomisp_drvfs.c
> @@ -37,7 +37,7 @@
>   *        bit 1: running binary
>   *        bit 2: memory statistic
>   */
> -unsigned int dbgopt = OPTION_BIN_LIST;
> +static unsigned int dbgopt = OPTION_BIN_LIST;
>  
>  static inline int iunit_dump_dbgopt(struct atomisp_device *isp,
>  				    unsigned int opt)
Nicolas Dufresne Feb. 9, 2024, 3:55 p.m. UTC | #2
Le vendredi 02 février 2024 à 11:04 +0100, Hans Verkuil a écrit :
> On 02/02/2024 10:21, Hans Verkuil wrote:
> > This fixes a sparse warning:
> > 
> > drivers/staging/media/atomisp/pci/atomisp_drvfs.c:40:14: warning: symbol 'dbgopt' was not declared. Should it be static?
> > 
> > Signed-off-by: Hans Verkuil <hverkuil-cisco@xs4all.nl>
> 
> Fixes: b03301870d9b ("media: atomisp: Replace atomisp_drvfs attr with using driver.dev_groups attr")

Reviewed-by: Nicolas Dufresne <nicolas.dufresne@collabora.com>

> 
> > ---
> >  drivers/staging/media/atomisp/pci/atomisp_drvfs.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> > 
> > diff --git a/drivers/staging/media/atomisp/pci/atomisp_drvfs.c b/drivers/staging/media/atomisp/pci/atomisp_drvfs.c
> > index 293171da1266..ba7dd569a55a 100644
> > --- a/drivers/staging/media/atomisp/pci/atomisp_drvfs.c
> > +++ b/drivers/staging/media/atomisp/pci/atomisp_drvfs.c
> > @@ -37,7 +37,7 @@
> >   *        bit 1: running binary
> >   *        bit 2: memory statistic
> >   */
> > -unsigned int dbgopt = OPTION_BIN_LIST;
> > +static unsigned int dbgopt = OPTION_BIN_LIST;
> >  
> >  static inline int iunit_dump_dbgopt(struct atomisp_device *isp,
> >  				    unsigned int opt)
> 
>
diff mbox series

Patch

diff --git a/drivers/staging/media/atomisp/pci/atomisp_drvfs.c b/drivers/staging/media/atomisp/pci/atomisp_drvfs.c
index 293171da1266..ba7dd569a55a 100644
--- a/drivers/staging/media/atomisp/pci/atomisp_drvfs.c
+++ b/drivers/staging/media/atomisp/pci/atomisp_drvfs.c
@@ -37,7 +37,7 @@ 
  *        bit 1: running binary
  *        bit 2: memory statistic
  */
-unsigned int dbgopt = OPTION_BIN_LIST;
+static unsigned int dbgopt = OPTION_BIN_LIST;
 
 static inline int iunit_dump_dbgopt(struct atomisp_device *isp,
 				    unsigned int opt)