intel: allow packed prime buffers to be treated normally

v2:
   - fix earlier rebase error breaking bisect
     (loaderPriv -> loaderPrivate)

Signed-off-by: Topi Pohjolainen <topi.pohjolainen@intel.com>
Reviewed-by: Chad Versace <chad.versace@linux.intel.com>
Reviewed-by: Ian Romanick <ian.d.romanick@intel.com>
This commit is contained in:
Topi Pohjolainen 2013-04-25 14:33:09 +03:00
parent 34c55b5925
commit e8568a0803

View file

@ -651,7 +651,11 @@ intel_create_image_from_fds(__DRIscreen *screen,
if (f == NULL)
return NULL;
image = intel_allocate_image(__DRI_IMAGE_FORMAT_NONE, loaderPrivate);
if (f->nplanes == 1)
image = intel_allocate_image(f->planes[0].dri_format, loaderPrivate);
else
image = intel_allocate_image(__DRI_IMAGE_FORMAT_NONE, loaderPrivate);
if (image == NULL)
return NULL;