i965: Use allow_higher_compat_version option during screen initialization
authorIan Romanick <ian.d.romanick@intel.com>
Fri, 30 Oct 2020 19:28:22 +0000 (12:28 -0700)
committerIan Romanick <ian.d.romanick@intel.com>
Thu, 28 Jan 2021 03:10:01 +0000 (19:10 -0800)
commitf11a827941c5cc0bf986863975a77e4d892f00e1
tree5e4150697650ec3925133d8f1572f898af9bd7f8
parentdbf6c17a1bd86607d90899d9c2ae92fc23518935
i965: Use allow_higher_compat_version option during screen initialization

Currently, `allow_higher_compat_version` is only used during context
creation.  Doing that means an application that doesn't request a
specific version can be given a version higher than 3.0.

However, an application still cannot request a higher version via
glXCreateContextAttribsARB.  The GLX and DRI layers will only see that
version 3.0 is supported, so context creation will fail before the drive
is called.  For this to work, max_gl_compat_version must be set to a
higher version.

This enables running many piglit tests on i965 with
allow_higher_compat_version.

v2: Fix a typo in a comment.  Noticed by Tim.  Fix a typo in the commit
message.  Noticed by the spell checker. :)

v3: Don't parse driconf again.  Suggested by Tim.

Reviewed-by: Timothy Arceri <tarceri@itsqueeze.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/7387>
src/mesa/drivers/dri/i965/brw_context.c
src/mesa/drivers/dri/i965/intel_screen.c