[Nouveau] [PATCH 06/17] drm/nouveau/gpio: mark symbol static where possible

Baoyou Xie baoyou.xie at linaro.org
Sat Oct 22 09:41:47 UTC 2016


We get 1 warning when building kernel with W=1:
drivers/gpu/drm/nouveau/nvkm/subdev/gpio/gk104.c:41:1: warning: no previous prototype for 'gk104_gpio_intr_mask' [-Wmissing-prototypes]

In fact, this function is only used in the file in which it is
declared and don't need a declaration, but can be made static.
So this patch marks this function with 'static'.

Signed-off-by: Baoyou Xie <baoyou.xie at linaro.org>
---
 drivers/gpu/drm/nouveau/nvkm/subdev/gpio/gk104.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/nouveau/nvkm/subdev/gpio/gk104.c b/drivers/gpu/drm/nouveau/nvkm/subdev/gpio/gk104.c
index 3f45afd1..2ead515 100644
--- a/drivers/gpu/drm/nouveau/nvkm/subdev/gpio/gk104.c
+++ b/drivers/gpu/drm/nouveau/nvkm/subdev/gpio/gk104.c
@@ -37,7 +37,7 @@ gk104_gpio_intr_stat(struct nvkm_gpio *gpio, u32 *hi, u32 *lo)
 	nvkm_wr32(device, 0x00dc80, intr1);
 }
 
-void
+static void
 gk104_gpio_intr_mask(struct nvkm_gpio *gpio, u32 type, u32 mask, u32 data)
 {
 	struct nvkm_device *device = gpio->subdev.device;
-- 
2.7.4



More information about the Nouveau mailing list