drm/nouveau/gr/gf100-: change gf108_gr_fwif from global to static
Subsystems (3)
PATCH 1/1 drm/nouveau/gr/gf100-: change gf108_gr_fwif from global to static
Smatch reports this issue gf108.c:147:1: warning: symbol 'gf108_gr_fwif'
was not declared. Should it be static?
gf108_gr_fwif is only used in gf108.c. Single file variables should not be global so change gf108_gr_fwif's storage-class specifier to static.
--- drivers/gpu/drm/nouveau/nvkm/engine/gr/gf108.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/nouveau/nvkm/engine/gr/gf108.c +1 -1
@@ -143,7 +143,7 @@ gf108_gr = { } }; -const struct gf100_gr_fwif +static const struct gf100_gr_fwif gf108_gr_fwif[] = { {-1 , gf100_gr_load, &gf108_gr }, {-1 , gf100_gr_nofw, &gf108_gr },
Signature · 1 line
2.27.0
Will push to the appropriate branch in a moment
Quoted 27 lines · Tom Rix
Smatch reports this issue gf108.c:147:1: warning: symbol '
gf108_gr_fwif' was not declared. Should it be static?
gf108_gr_fwifis only used in gf108.c. Single file variables should not be global so change gf108_gr_fwif's storage-class specifier to static.Signed-off-by Tom Rix <[email protected]>---
drivers/gpu/drm/nouveau/nvkm/engine/gr/gf108.c | 2 +-1 file changed, 1 insertion(+), 1 deletion(-)drivers/gpu/drm/nouveau/nvkm/engine/gr/gf108.c +0
-0@@ -143,7 +143,7 @@ gf108_gr = { } };drivers/gpu/drm/nouveau/nvkm/engine/gr/gf108.c +1
-1-const struct gf100_gr_fwif +static const struct gf100_gr_fwifgf108_gr_fwif[] = {
{ -1,gf100_gr_load,&gf108_gr}, { -1,gf100_gr_nofw,&gf108_gr},
Signature · 3 lines
Cheers, Lyude Paul (she/her) Software Engineer at Red Hat