diff options
author | 2019-11-18 16:51:22 +0100 | |
---|---|---|
committer | 2019-12-16 12:13:17 +0100 | |
commit | 8582e244e5fe72d2e9ace186fa8f3ed3bb4122e1 (patch) | |
tree | d4320f21786b04080144a502d8c7826f5062cc25 /tools/perf/scripts/python/exported-sql-viewer.py | |
parent | drm/rockchip: dsi: add px30 support (diff) | |
download | linux-dev-8582e244e5fe72d2e9ace186fa8f3ed3bb4122e1.tar.xz linux-dev-8582e244e5fe72d2e9ace186fa8f3ed3bb4122e1.zip |
drm/modes: parse_cmdline: Fix possible reference past end of string
Before this commit, if the last option of a video=... option is for
example "rotate" without a "=<value>" after it then delim will point to
the terminating 0 of the string, and value which is sets to <delim + 1>
will point one position past the end of the string.
This commit fixes this by enforcing that the contents of delim equals '='
as it should be for options which take a value, this check is done in a
new drm_mode_parse_cmdline_int helper function which factors out the
common integer parsing code for all the options which take an int.
Acked-by: Maxime Ripard <mripard@kernel.org>
Signed-off-by: Hans de Goede <hdegoede@redhat.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20191118155134.30468-1-hdegoede@redhat.com
Diffstat (limited to 'tools/perf/scripts/python/exported-sql-viewer.py')
0 files changed, 0 insertions, 0 deletions