summaryrefslogtreecommitdiff
path: root/src/intel_driver.c
diff options
context:
space:
mode:
authorXiang, Haihao <haihao.xiang@intel.com>2014-04-19 00:12:35 +0800
committerXiang, Haihao <haihao.xiang@intel.com>2014-05-26 11:58:47 +0800
commite7318fe6166fbacc53413bbf175d4fc97a1c9807 (patch)
tree041d4f3f6c0cc82ef2683b271adcea2e653c655e /src/intel_driver.c
parenta1b90545a6b428a91e080ffb9dd29835212e5304 (diff)
downloadlibva-intel-driver-e7318fe6166fbacc53413bbf175d4fc97a1c9807.tar.gz
libva-intel-driver-e7318fe6166fbacc53413bbf175d4fc97a1c9807.tar.bz2
libva-intel-driver-e7318fe6166fbacc53413bbf175d4fc97a1c9807.zip
Add a new intel_device_info structure
To store statically known device information Signed-off-by: Xiang, Haihao <haihao.xiang@intel.com> (cherry picked from commit eb014a09fde988ba3ed2d2be6e8d6f0c650d281e)
Diffstat (limited to 'src/intel_driver.c')
-rw-r--r--src/intel_driver.c7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/intel_driver.c b/src/intel_driver.c
index 8650dba..e3e082d 100644
--- a/src/intel_driver.c
+++ b/src/intel_driver.c
@@ -67,6 +67,8 @@ static void intel_driver_get_revid(struct intel_driver_data *intel, int *value)
return;
}
+extern const struct intel_device_info *i965_get_device_info(int devid);
+
bool
intel_driver_init(VADriverContextP ctx)
{
@@ -91,6 +93,11 @@ intel_driver_init(VADriverContextP ctx)
pthread_mutex_init(&intel->ctxmutex, NULL);
intel_driver_get_param(intel, I915_PARAM_CHIPSET_ID, &intel->device_id);
+ intel->device_info = i965_get_device_info(intel->device_id);
+
+ if (!intel->device_info)
+ return false;
+
if (intel_driver_get_param(intel, I915_PARAM_HAS_EXECBUF2, &has_exec2))
intel->has_exec2 = has_exec2;
if (intel_driver_get_param(intel, I915_PARAM_HAS_BSD, &has_bsd))