diff options
author | Ben Hutchings <ben@decadent.org.uk> | 2019-11-11 08:13:24 -0800 |
---|---|---|
committer | Jon Bloomfield <jon.bloomfield@intel.com> | 2019-11-11 08:13:49 -0800 |
commit | ea0b163b13ffc52818c079adb00d55e227a6da6f (patch) | |
tree | 4a97f4f6d41aa4ff48665efca84562b3affa19a8 /drivers/of | |
parent | 7e34f4e4aad3fd34c02b294a3cf2321adf5b4438 (diff) |
drm/i915/cmdparser: Fix jump whitelist clearing
When a jump_whitelist bitmap is reused, it needs to be cleared.
Currently this is done with memset() and the size calculation assumes
bitmaps are made of 32-bit words, not longs. So on 64-bit
architectures, only the first half of the bitmap is cleared.
If some whitelist bits are carried over between successive batches
submitted on the same context, this will presumably allow embedding
the rogue instructions that we're trying to reject.
Use bitmap_zero() instead, which gets the calculation right.
Fixes: f8c08d8faee5 ("drm/i915/cmdparser: Add support for backward jumps")
Signed-off-by: Ben Hutchings <ben@decadent.org.uk>
Signed-off-by: Jon Bloomfield <jon.bloomfield@intel.com>
Diffstat (limited to 'drivers/of')
0 files changed, 0 insertions, 0 deletions