diff options
author | Bas Nieuwenhuizen <[email protected]> | 2019-02-20 02:19:42 +0100 |
---|---|---|
committer | Bas Nieuwenhuizen <[email protected]> | 2019-02-20 02:55:41 +0100 |
commit | 7631feaa0040616585cf69b52241d2b06b82b524 (patch) | |
tree | 905cefecc236be0df18d3faae5cf173c3979fcb2 /src/amd/vulkan/radv_formats.c | |
parent | 3d7611e9a6c63a5ec03d3f9a7f90fbf286ec72a3 (diff) |
radv: Sync ETC2 whitelisted devices.
Fixes: 4bb6c49375e "radv: Allow ETC2 on RAVEN and VEGA10 instead of all GFX9."
Reviewed-by: Dave Airlie <[email protected]>
Diffstat (limited to 'src/amd/vulkan/radv_formats.c')
-rw-r--r-- | src/amd/vulkan/radv_formats.c | 12 |
1 files changed, 9 insertions, 3 deletions
diff --git a/src/amd/vulkan/radv_formats.c b/src/amd/vulkan/radv_formats.c index 499d94befeb..0a3ff9ebbd9 100644 --- a/src/amd/vulkan/radv_formats.c +++ b/src/amd/vulkan/radv_formats.c @@ -595,6 +595,14 @@ static bool radv_is_filter_minmax_format_supported(VkFormat format) } } +bool +radv_device_supports_etc(struct radv_physical_device *physical_device) +{ + return physical_device->rad_info.family == CHIP_VEGA10 || + physical_device->rad_info.family == CHIP_RAVEN || + physical_device->rad_info.family == CHIP_STONEY; +} + static void radv_physical_device_get_format_properties(struct radv_physical_device *physical_device, VkFormat format, @@ -612,9 +620,7 @@ radv_physical_device_get_format_properties(struct radv_physical_device *physical } if (desc->layout == VK_FORMAT_LAYOUT_ETC && - physical_device->rad_info.family != CHIP_VEGA10 && - physical_device->rad_info.family != CHIP_RAVEN && - physical_device->rad_info.family != CHIP_STONEY) { + !radv_device_supports_etc(physical_device)) { out_properties->linearTilingFeatures = linear; out_properties->optimalTilingFeatures = tiled; out_properties->bufferFeatures = buffer; |