linux-staging.lists.linux.dev archive mirror
 help / color / mirror / Atom feed
* [PATCH v4] staging: sm750fb: make fixId array static const char * const
@ 2025-07-18 21:08 Ignacio Peña
  2025-07-18 21:17 ` Dan Carpenter
  2025-07-19  6:40 ` Greg Kroah-Hartman
  0 siblings, 2 replies; 3+ messages in thread
From: Ignacio Peña @ 2025-07-18 21:08 UTC (permalink / raw)
  To: Greg Kroah-Hartman; +Cc: linux-staging, linux-kernel, Dan Carpenter

Fix checkpatch warning for the fixId array only:
"WARNING: static const char * array should probably be
 static const char * const"

The g_fbmode array cannot be made const as it is modified at runtime
in lynxfb_setup() and lynx_alloc().

Signed-off-by: Ignacio Peña <ignacio.pena87@gmail.com>
---
v4: Sorry for the confusion. Previous versions had wrong line numbers
    or included changes to g_fbmode. This version ONLY changes fixId
    at the correct line number (734) against current mainline.

v3: Apologies for the confusion. v2 accidentally included changes to 
    g_fbmode which breaks the build. This version ONLY changes fixId
    which is never modified.

 drivers/staging/sm750fb/sm750.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/staging/sm750fb/sm750.c b/drivers/staging/sm750fb/sm750.c
index 1d929aca3..82e01f114 100644
--- a/drivers/staging/sm750fb/sm750.c
+++ b/drivers/staging/sm750fb/sm750.c
@@ -734,7 +734,7 @@ static int lynxfb_set_fbinfo(struct fb_info *info, int index)
 		"kernel HELPERS prepared vesa_modes",
 	};
 
-	static const char *fixId[2] = {
+	static const char * const fixId[2] = {
 		"sm750_fb1", "sm750_fb2",
 	};
 
-- 
2.39.5

^ permalink raw reply related	[flat|nested] 3+ messages in thread

* Re: [PATCH v4] staging: sm750fb: make fixId array static const char * const
  2025-07-18 21:08 [PATCH v4] staging: sm750fb: make fixId array static const char * const Ignacio Peña
@ 2025-07-18 21:17 ` Dan Carpenter
  2025-07-19  6:40 ` Greg Kroah-Hartman
  1 sibling, 0 replies; 3+ messages in thread
From: Dan Carpenter @ 2025-07-18 21:17 UTC (permalink / raw)
  To: Ignacio Peña; +Cc: Greg Kroah-Hartman, linux-staging, linux-kernel

On Fri, Jul 18, 2025 at 05:08:46PM -0400, Ignacio Peña wrote:
> Fix checkpatch warning for the fixId array only:
> "WARNING: static const char * array should probably be
>  static const char * const"
> 
> The g_fbmode array cannot be made const as it is modified at runtime
> in lynxfb_setup() and lynx_alloc().
> 
> Signed-off-by: Ignacio Peña <ignacio.pena87@gmail.com>
> ---
> v4: Sorry for the confusion. Previous versions had wrong line numbers
>     or included changes to g_fbmode. This version ONLY changes fixId
>     at the correct line number (734) against current mainline.

Please stop sending new versions of the patch...  At least wait a day
between sending new versions.  This one was fine already.

No one cares about the line numbers.  You had put that note about line
numbers under the --- cut off line so it's informational only and won't
be included in the final git log.  Also line numbers are constantly
changing so we just ignore it when people tell us they are changing
line 123.  It's not going to be line 123 on our end so it's not helpful.

regards,
dan carpenter


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH v4] staging: sm750fb: make fixId array static const char * const
  2025-07-18 21:08 [PATCH v4] staging: sm750fb: make fixId array static const char * const Ignacio Peña
  2025-07-18 21:17 ` Dan Carpenter
@ 2025-07-19  6:40 ` Greg Kroah-Hartman
  1 sibling, 0 replies; 3+ messages in thread
From: Greg Kroah-Hartman @ 2025-07-19  6:40 UTC (permalink / raw)
  To: Ignacio Peña; +Cc: linux-staging, linux-kernel, Dan Carpenter

On Fri, Jul 18, 2025 at 05:08:46PM -0400, Ignacio Peña wrote:
> Fix checkpatch warning for the fixId array only:
> "WARNING: static const char * array should probably be
>  static const char * const"
> 
> The g_fbmode array cannot be made const as it is modified at runtime
> in lynxfb_setup() and lynx_alloc().

Why is this part of the changelog at all?  It has no relevance to the
change you are making here.

And as Dan said, please slow down and relax.  There is no rush here at
all.  Take a few days off, think about what you want to do before
resending.

thanks,

greg k-h

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-07-19  6:41 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2025-07-18 21:08 [PATCH v4] staging: sm750fb: make fixId array static const char * const Ignacio Peña
2025-07-18 21:17 ` Dan Carpenter
2025-07-19  6:40 ` Greg Kroah-Hartman

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).