diff options
author | Matthew Wilcox <[email protected]> | 2019-02-14 11:03:48 -0800 |
---|---|---|
committer | Dave Airlie <[email protected]> | 2019-02-15 13:08:08 +1000 |
commit | 69ef943dbc14b21987c79f8399ffea08f9a1b446 (patch) | |
tree | 2e231c985a2670be1966b1f81c92004641ba3736 /tools/perf/scripts/python/export-to-sqlite.py | |
parent | 7abbb35ba98ec52583b92898b2e37533f462d248 (diff) |
drm: Use array_size() when creating lease
Passing an object_count of sufficient size will make
object_count * 4 wrap around to be very small, then a later function
will happily iterate off the end of the object_ids array. Using
array_size() will saturate at SIZE_MAX, the kmalloc() will fail and
we'll return an -ENOMEM to the norty userspace.
Fixes: 62884cd386b8 ("drm: Add four ioctls for managing drm mode object leases [v7]")
Signed-off-by: Matthew Wilcox <[email protected]>
Acked-by: Kees Cook <[email protected]>
Acked-by: Daniel Vetter <[email protected]>
Cc: <[email protected]> # v4.15+
Signed-off-by: Dave Airlie <[email protected]>
Diffstat (limited to 'tools/perf/scripts/python/export-to-sqlite.py')
0 files changed, 0 insertions, 0 deletions