Skip to contentSkip to conversation

drm/tilcdc: make tilcdc_mode_hvtotal() static

PATCH In review Xiongwei Song 2 participants 2 messages Dec 2, 2017 – Dec 4, 2017

Subsystems (3)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/tilcdc: make tilcdc_mode_hvtotal() static

The function tilcdc_mode_hvtotal is local to the source and does not need to be in global scope, so make it static.

drivers/gpu/drm/tilcdc/tilcdc_crtc.c:297:6: warning: no previous prototype for 'tilcdc_mode_hvtotal' [-Wmissing-prototypes]
uint tilcdc_mode_hvtotal(const struct drm_display_mode *mode)

---
 drivers/gpu/drm/tilcdc/tilcdc_crtc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/tilcdc/tilcdc_crtc.c +1 -1
index 6ef4d1a..c4804d9 100644
@@ -294,7 +294,7 @@ static void tilcdc_crtc_set_clk(struct drm_crtc *crtc)
 				LCDC_V2_CORE_CLK_EN);
 }
 
-uint tilcdc_mode_hvtotal(const struct drm_display_mode *mode)
+static uint tilcdc_mode_hvtotal(const struct drm_display_mode *mode)
 {
 	return (uint) div_u64(1000llu * mode->htotal * mode->vtotal,
 			      mode->clock);
Signature · 1 line
2.9.5
#1 lore raw
Quoted 7 lines · Xiongwei Song

The function tilcdc_mode_hvtotal is local to the source and does not need to be in global scope, so make it static.

drivers/gpu/drm/tilcdc/tilcdc_crtc.c:297:6: warning: no previous prototype for 'tilcdc_mode_hvtotal' [-Wmissing-prototypes]
uint tilcdc_mode_hvtotal(const struct drm_display_mode *mode)

Thanks, I'll pick this up for the next pull request.

Best regards,
Jyri

Quoted 18 lines
---
 drivers/gpu/drm/tilcdc/tilcdc_crtc.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
drivers/gpu/drm/tilcdc/tilcdc_crtc.c +1 -1
index 6ef4d1a..c4804d9 100644
@@ -294,7 +294,7 @@ static void tilcdc_crtc_set_clk(struct drm_crtc *crtc)
 				LCDC_V2_CORE_CLK_EN);
 }
 
-uint tilcdc_mode_hvtotal(const struct drm_display_mode *mode)
+static uint tilcdc_mode_hvtotal(const struct drm_display_mode *mode)
 {
 	return (uint) div_u64(1000llu * mode->htotal * mode->vtotal,
 			      mode->clock);
Signature · 2 lines
Texas Instruments Finland Oy, Porkkalankatu 22, 00180 Helsinki.
Y-tunnus/Business ID: 0615521-4. Kotipaikka/Domicile: Helsinki