mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
From: Thomas Zimmermann <tzimmermann@suse.de>
To: Javier Martinez Canillas <javierm@redhat.com>,
	linux-kernel@vger.kernel.org
Cc: kernel test robot <lkp@intel.com>,
	David Airlie <airlied@gmail.com>,
	Maarten Lankhorst <maarten.lankhorst@linux.intel.com>,
	Marcus Folkesson <marcus.folkesson@gmail.com>,
	Maxime Ripard <mripard@kernel.org>,
	Simona Vetter <simona@ffwll.ch>,
	dri-devel@lists.freedesktop.org
Subject: Re: [PATCH] drm/sitronix/st7571-i2c: Make st7571_panel_data to be static variables
Date: Fri, 18 Jul 2025 14:00:15 +0200	[thread overview]
Message-ID: <fbb77c0f-2bc1-45b4-9475-d2b17c9bcf8b@suse.de> (raw)
In-Reply-To: <20250718072541.686759-1-javierm@redhat.com>

Hi Javier

Am 18.07.25 um 09:25 schrieb Javier Martinez Canillas:
> The kernel test robot reported that sparse gives the following warnings:
>
> make C=2 M=drivers/gpu/drm/sitronix/
>    CC [M]  st7571-i2c.o
>    CHECK   st7571-i2c.c
> st7571-i2c.c:1027:26: warning: symbol 'st7567_config' was not declared. Should it be static?
> st7571-i2c.c:1039:26: warning: symbol 'st7571_config' was not declared. Should it be static?
>    MODPOST Module.symvers
>    LD [M]  st7571-i2c.ko
>
> Reported-by: kernel test robot <lkp@intel.com>
> Closes: https://lore.kernel.org/oe-kbuild-all/202507180503.nfyD9uRv-lkp@intel.com
> Signed-off-by: Javier Martinez Canillas <javierm@redhat.com>
> ---
>
>   drivers/gpu/drm/sitronix/st7571-i2c.c | 4 ++--
>   1 file changed, 2 insertions(+), 2 deletions(-)
>
> diff --git a/drivers/gpu/drm/sitronix/st7571-i2c.c b/drivers/gpu/drm/sitronix/st7571-i2c.c
> index 453eb7e045e5..7fe5b69e6f2f 100644
> --- a/drivers/gpu/drm/sitronix/st7571-i2c.c
> +++ b/drivers/gpu/drm/sitronix/st7571-i2c.c
> @@ -1024,7 +1024,7 @@ static void st7571_remove(struct i2c_client *client)
>   	drm_dev_unplug(&st7571->dev);
>   }
>   
> -struct st7571_panel_data st7567_config = {
> +static struct st7571_panel_data st7567_config = {

Make it 'static const' please. Here and below.

Best regards
Thomas

>   	.init = st7567_lcd_init,
>   	.parse_dt = st7567_parse_dt,
>   	.constraints = {
> @@ -1036,7 +1036,7 @@ struct st7571_panel_data st7567_config = {
>   	},
>   };
>   
> -struct st7571_panel_data st7571_config = {
> +static struct st7571_panel_data st7571_config = {
>   	.init = st7571_lcd_init,
>   	.parse_dt = st7571_parse_dt,
>   	.constraints = {

-- 
--
Thomas Zimmermann
Graphics Driver Developer
SUSE Software Solutions Germany GmbH
Frankenstrasse 146, 90461 Nuernberg, Germany
GF: Ivo Totev, Andrew Myers, Andrew McDonald, Boudien Moerman
HRB 36809 (AG Nuernberg)


      reply	other threads:[~2025-07-18 12:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2025-07-18  7:25 Javier Martinez Canillas
2025-07-18 12:00 ` Thomas Zimmermann [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=fbb77c0f-2bc1-45b4-9475-d2b17c9bcf8b@suse.de \
    --to=tzimmermann@suse.de \
    --cc=airlied@gmail.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=javierm@redhat.com \
    --cc=linux-kernel@vger.kernel.org \
    --cc=lkp@intel.com \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=marcus.folkesson@gmail.com \
    --cc=mripard@kernel.org \
    --cc=simona@ffwll.ch \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®