i965: Handle non-zero texture buffer offsets in buffer object range calculation.
authorFrancisco Jerez <currojerez@riseup.net>
Fri, 16 Mar 2018 21:35:10 +0000 (14:35 -0700)
committerFrancisco Jerez <currojerez@riseup.net>
Wed, 23 May 2018 23:21:28 +0000 (16:21 -0700)
commite989acb03ba802737f762627dd16ac1d0b9f0d13
tree62246b2a52809648edf8e35798842a26cdfed82d
parent156d2c6e621d836c4d45c636b87669e1de3d4464
i965: Handle non-zero texture buffer offsets in buffer object range calculation.

Otherwise the specified surface state will allow the GPU to access
memory up to BufferOffset bytes past the end of the buffer.  Found by
inspection.

v2: Protect against out-of-range BufferOffset (Nanley).
Cc: mesa-stable@lists.freedesktop.org
Reviewed-by: Nanley Chery <nanley.g.chery@intel.com>
src/mesa/drivers/dri/i965/brw_wm_surface_state.c