diff options
author | Gwenole Beauchesne <gwenole.beauchesne@intel.com> | 2012-04-06 17:24:36 +0200 |
---|---|---|
committer | Gwenole Beauchesne <gwenole.beauchesne@intel.com> | 2012-09-26 14:26:49 +0200 |
commit | 73ccb0c88d53298befa6a896d2bb39a041169b36 (patch) | |
tree | a6168b5406a30b4388ab1c7a84f0dbd3a2da6dec /src/intel_driver.c | |
parent | 8098e75a2a7d1dab08819e851a0eeb884f8e7f69 (diff) | |
download | libva-intel-driver-73ccb0c88d53298befa6a896d2bb39a041169b36.tar.gz libva-intel-driver-73ccb0c88d53298befa6a896d2bb39a041169b36.tar.bz2 libva-intel-driver-73ccb0c88d53298befa6a896d2bb39a041169b36.zip |
dri: cope with drm_state changes.
Signed-off-by: Gwenole Beauchesne <gwenole.beauchesne@intel.com>
Diffstat (limited to 'src/intel_driver.c')
-rw-r--r-- | src/intel_driver.c | 16 |
1 files changed, 9 insertions, 7 deletions
diff --git a/src/intel_driver.c b/src/intel_driver.c index 4e6df81..b34d9a1 100644 --- a/src/intel_driver.c +++ b/src/intel_driver.c @@ -29,7 +29,7 @@ #include <assert.h> -#include <va/va_dricommon.h> +#include <va/va_drmcommon.h> #include "intel_batchbuffer.h" #include "intel_memman.h" @@ -50,15 +50,17 @@ Bool intel_driver_init(VADriverContextP ctx) { struct intel_driver_data *intel = intel_driver_data(ctx); - struct dri_state *dri_state = (struct dri_state *)ctx->dri_state; + struct drm_state * const drm_state = (struct drm_state *)ctx->drm_state; int has_exec2, has_bsd, has_blt; - assert(dri_state); - assert(dri_state->driConnectedFlag == VA_DRI2 || - dri_state->driConnectedFlag == VA_DRI1); + assert(drm_state); + assert(drm_state->auth_type == VA_DRM_AUTH_DRI1 || + drm_state->auth_type == VA_DRM_AUTH_DRI2 || + drm_state->auth_type == VA_DRM_AUTH_CUSTOM); - intel->fd = dri_state->fd; - intel->dri2Enabled = (dri_state->driConnectedFlag == VA_DRI2); + intel->fd = drm_state->fd; + intel->dri2Enabled = (drm_state->auth_type == VA_DRM_AUTH_DRI2 || + drm_state->auth_type == VA_DRM_AUTH_CUSTOM); if (!intel->dri2Enabled) { return False; |