Skip to content

Commit

Permalink
drm/modes: Make the whitelist more const
Browse files Browse the repository at this point in the history
The commit 3764137 ("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 array itself
was not. Let's fix that.

Fixes: 3764137 ("drm/modes: Introduce a whitelist for the named modes")
Suggested-by: Jani Nikula <jani.nikula@linux.intel.com>
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: Maxime Ripard <mripard@kernel.org>
Link: https://patchwork.freedesktop.org/patch/msgid/20190906074614.30608-1-mripard@kernel.org
  • Loading branch information
Maxime Ripard committed Sep 6, 2019
1 parent 424c38a commit a3200de
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion drivers/gpu/drm/drm_modes.c
Original file line number Diff line number Diff line change
Expand Up @@ -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",
};
Expand Down

0 comments on commit a3200de

Please sign in to comment.