[Intel-gfx] [PATCH] drm/i915/selftests: Prevent selecting 0 for our random width/align

Matthew Auld matthew.auld at intel.com
Thu Aug 6 15:27:40 UTC 2020


On 06/08/2020 15:57, Chris Wilson wrote:
> When igt_random_offset() is a given a range of [0, PAGE_SIZE], it is
> allowed to return 0. However, attempting to use a size of 0 for the
> igt_lmem_write_cpu() byte poking, leads to call igt_random_offset() with
> a range of [offset, offset + 0] and ask it to find a length of 4 within
> it. This triggers the bug on that the requested length should fit within
> the range!
> 
> Signed-off-by: Chris Wilson <chris at chris-wilson.co.uk>
> Cc: Matthew Auld <matthew.auld at intel.com>

Reviewed-by: Matthew Auld <matthew.auld at intel.com>


More information about the Intel-gfx mailing list