i965/perf: verify kernel support before registering OA metrics
authorMark Janes <mark.a.janes@intel.com>
Wed, 31 Jul 2019 23:16:50 +0000 (16:16 -0700)
committerMark Janes <mark.a.janes@intel.com>
Thu, 1 Aug 2019 23:39:41 +0000 (16:39 -0700)
commit1186f6ea6947e779b99b87e48b8e5ac6d25b87bf
treefaa278c9fca678d6ab3a18c6306ef408ddb9163a
parent7852fe54159cb6602a4408b8107b52999890dc79
i965/perf: verify kernel support before registering OA metrics

When gen_device_info updates the topology in it's initializer, the
kernel queries will fail silently.  Iris and anv have minimum
kernel requirements that support the queries.  i965 must verify kernel
support before reporting OA metrics.

Reviewed-by: Kenneth Graunke <kenneth@whitecape.org>
Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
src/mesa/drivers/dri/i965/brw_performance_query.c