radv: Relax linear requirement to VCN1 and prior

With the previous commit ("ac/surface: Filter swizzle modes for VCN"),
only video-compatible swizzle modes will be picked, so we can enable
tiling for VCN2+.

Reviewed-by: David Rosca <david.rosca@amd.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/40948>
This commit is contained in:
Benjamin Cheng 2026-04-14 09:46:12 -04:00 committed by Marge Bot
parent fcaab2b921
commit 9182da14a7

View file

@ -44,12 +44,9 @@ radv_choose_tiling(struct radv_device *device, const VkImageCreateInfo *pCreateI
return RADEON_SURF_MODE_LINEAR_ALIGNED;
}
if (pdev->info.vcn_ip_version < VCN_1_0_0 &&
pCreateInfo->usage & (VK_IMAGE_USAGE_VIDEO_DECODE_DPB_BIT_KHR | VK_IMAGE_USAGE_VIDEO_ENCODE_DPB_BIT_KHR))
return RADEON_SURF_MODE_LINEAR_ALIGNED;
if (pdev->info.vcn_ip_version < VCN_5_0_0 &&
pCreateInfo->usage & (VK_IMAGE_USAGE_VIDEO_DECODE_DST_BIT_KHR | VK_IMAGE_USAGE_VIDEO_ENCODE_SRC_BIT_KHR))
if (pdev->info.vcn_ip_version < VCN_2_0_0 &&
pCreateInfo->usage & (VK_IMAGE_USAGE_VIDEO_DECODE_DPB_BIT_KHR | VK_IMAGE_USAGE_VIDEO_ENCODE_DPB_BIT_KHR |
VK_IMAGE_USAGE_VIDEO_DECODE_DST_BIT_KHR | VK_IMAGE_USAGE_VIDEO_ENCODE_SRC_BIT_KHR))
return RADEON_SURF_MODE_LINEAR_ALIGNED;
if (pCreateInfo->usage & VK_IMAGE_USAGE_VIDEO_ENCODE_QUANTIZATION_DELTA_MAP_BIT_KHR)