gallium/dri2: Report I915_FORMAT_MOD_Y_TILED_GEN12_MC_CCS num_planes

Return the expected number of planes in a DMA buffer that has the
I915_FORMAT_MOD_Y_TILED_GEN12_MC_CCS modifier.

Reviewed-by: Lionel Landwerlin <lionel.g.landwerlin@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/6486>
This commit is contained in:
Nanley Chery 2019-09-11 15:34:46 -07:00 committed by Marge Bot
parent 7ee5da90ed
commit a42bf9a297
1 changed files with 2 additions and 1 deletions

View File

@ -847,9 +847,10 @@ dri2_get_modifier_num_planes(uint64_t modifier, int fourcc)
return 0;
switch (modifier) {
case I915_FORMAT_MOD_Y_TILED_GEN12_MC_CCS:
case I915_FORMAT_MOD_Y_TILED_GEN12_RC_CCS:
case I915_FORMAT_MOD_Y_TILED_CCS:
return 2;
return 2 * util_format_get_num_planes(map->pipe_format);
case DRM_FORMAT_MOD_ARM_16X16_BLOCK_U_INTERLEAVED:
case DRM_FORMAT_MOD_ARM_AFBC(
AFBC_FORMAT_MOD_BLOCK_SIZE_16x16 |