Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1481046 > unrolled thread

Re: [PATCH] drm: msm: mdp4: mark symbols static where possible

Started byArchit Taneja <architt@codeaurora.org>
First post2016-09-12 10:50 +0200
Last post2016-09-12 10:50 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  Re: [PATCH] drm: msm: mdp4: mark symbols static where possible Archit Taneja <architt@codeaurora.org> - 2016-09-12 10:50 +0200

#1481046 — Re: [PATCH] drm: msm: mdp4: mark symbols static where possible

FromArchit Taneja <architt@codeaurora.org>
Date2016-09-12 10:50 +0200
SubjectRe: [PATCH] drm: msm: mdp4: mark symbols static where possible
Message-ID<sgv6a-So-5@gated-at.bofh.it>

On 09/07/2016 04:28 PM, Baoyou Xie wrote:
> We get 2 warnings when building kernel with W=1:
> drivers/gpu/drm/msm/mdp/mdp4/mdp4_lcdc_encoder.c:96:23: warning: no previous prototype for 'get_connector' [-Wmissing-prototypes]
> drivers/gpu/drm/msm/mdp/mdp4/mdp4_plane.c:84:5: warning: no previous prototype for 'mdp4_plane_set_property' [-Wmissing-prototypes]
>
> In fact, these functions are only used in the file in which they are
> declared and don't need a declaration, but can be made static.
> So this patch marks these functions with 'static'.

Reviewed-by: Archit Taneja <architt@codeaurora.org>

>
> Signed-off-by: Baoyou Xie <baoyou.xie@linaro.org>
> ---
>   drivers/gpu/drm/msm/mdp/mdp4/mdp4_lcdc_encoder.c | 2 +-
>   drivers/gpu/drm/msm/mdp/mdp4/mdp4_plane.c        | 2 +-
>   2 files changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/msm/mdp/mdp4/mdp4_lcdc_encoder.c b/drivers/gpu/drm/msm/mdp/mdp4/mdp4_lcdc_encoder.c
> index bc3d8e7..a06b064 100644
> --- a/drivers/gpu/drm/msm/mdp/mdp4/mdp4_lcdc_encoder.c
> +++ b/drivers/gpu/drm/msm/mdp/mdp4/mdp4_lcdc_encoder.c
> @@ -93,7 +93,7 @@ static const struct drm_encoder_funcs mdp4_lcdc_encoder_funcs = {
>   };
>
>   /* this should probably be a helper: */
> -struct drm_connector *get_connector(struct drm_encoder *encoder)
> +static struct drm_connector *get_connector(struct drm_encoder *encoder)
>   {
>   	struct drm_device *dev = encoder->dev;
>   	struct drm_connector *connector;
> diff --git a/drivers/gpu/drm/msm/mdp/mdp4/mdp4_plane.c b/drivers/gpu/drm/msm/mdp/mdp4/mdp4_plane.c
> index 9f96dfe..c5adef0 100644
> --- a/drivers/gpu/drm/msm/mdp/mdp4/mdp4_plane.c
> +++ b/drivers/gpu/drm/msm/mdp/mdp4/mdp4_plane.c
> @@ -81,7 +81,7 @@ static void mdp4_plane_install_properties(struct drm_plane *plane,
>   	// XXX
>   }
>
> -int mdp4_plane_set_property(struct drm_plane *plane,
> +static int mdp4_plane_set_property(struct drm_plane *plane,
>   		struct drm_property *property, uint64_t val)
>   {
>   	// XXX
>

-- 
Qualcomm Innovation Center, Inc. is a member of Code Aurora Forum,
a Linux Foundation Collaborative Project

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web