All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] drm/modes: Make the whitelist more const
@ 2019-09-06  7:46 Maxime Ripard
  2019-09-06  7:56 ` Jani Nikula
  0 siblings, 1 reply; 3+ messages in thread
From: Maxime Ripard @ 2019-09-06  7:46 UTC (permalink / raw)
  To: Daniel Vetter, David Airlie, Maarten Lankhorst, Sean Paul,
	Maxime Ripard
  Cc: dri-devel

The commit 3764137906a5 ("drm/modes: Introduce a whitelist for the named
modes") introduced a whitelist in the named modes lookup code in order to
be a bit more robust.

However, even though the char pointers were made const, the data they were
pointing were not. Let's fix that.

Fixes: 3764137906a5 ("drm/modes: Introduce a whitelist for the named modes")
Suggested-by: Jani Nikula <jani.nikula@linux.intel.com>
Signed-off-by: Maxime Ripard <mripard@kernel.org>
---
 drivers/gpu/drm/drm_modes.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/gpu/drm/drm_modes.c b/drivers/gpu/drm/drm_modes.c
index 858c67281518..88232698d7a0 100644
--- a/drivers/gpu/drm/drm_modes.c
+++ b/drivers/gpu/drm/drm_modes.c
@@ -1677,7 +1677,7 @@ static int drm_mode_parse_cmdline_options(char *str, size_t len,
 	return 0;
 }
 
-static const char *drm_named_modes_whitelist[] = {
+static const char * const drm_named_modes_whitelist[] = {
 	"NTSC",
 	"PAL",
 };
-- 
2.21.0

_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

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

end of thread, other threads:[~2019-09-06 16:13 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2019-09-06  7:46 [PATCH] drm/modes: Make the whitelist more const Maxime Ripard
2019-09-06  7:56 ` Jani Nikula
2019-09-06 16:13   ` Maxime Ripard

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.