i965: Only enable ARB_query_buffer_object for newer kernels on Haswell.
authorKenneth Graunke <kenneth@whitecape.org>
Thu, 5 May 2016 08:57:30 +0000 (01:57 -0700)
committerKenneth Graunke <kenneth@whitecape.org>
Mon, 9 May 2016 21:59:58 +0000 (14:59 -0700)
commit4c71c8a74ad29bd84ca16803672ad1e9e30e2fff
tree22aac660e6e354925429ec328f027405d24d9a9c
parent2d41eb313fa354560e92e60336e5b0cdd40137f2
i965: Only enable ARB_query_buffer_object for newer kernels on Haswell.

On Haswell, we need version 6 of the kernel command parser in order to
write the math registers.  Our implementation of ARB_query_buffer_object
heavily relies on MI_MATH, so we should only advertise it when MI_MATH
is available.  We also need MI_LOAD_REGISTER_REG, which requires version
7 of the command parser.

To make these checks easier, introduce a screen->has_mi_math_and_lrr
flag that will be set when both commands are supported.

Signed-off-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Jordan Justen <jordan.l.justen@intel.com>
src/mesa/drivers/dri/i965/intel_extensions.c
src/mesa/drivers/dri/i965/intel_screen.c
src/mesa/drivers/dri/i965/intel_screen.h