anv: avoid warning about unused function

This function is only used if GFX_VER == 7

Fixes a clang warning about unused static inlined functions.

Reviewed-by: Marcin Ślusarz <marcin.slusarz@intel.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/14790>
This commit is contained in:
Thomas H.P. Andersen 2022-01-08 20:36:48 +01:00 committed by Marge Bot
parent f14cae43ac
commit 8e4b3cf832

View file

@ -673,6 +673,7 @@ transition_depth_buffer(struct anv_cmd_buffer *cmd_buffer,
}
}
#if GFX_VER == 7
static inline bool
vk_image_layout_stencil_write_optimal(VkImageLayout layout)
{
@ -680,6 +681,7 @@ vk_image_layout_stencil_write_optimal(VkImageLayout layout)
layout == VK_IMAGE_LAYOUT_DEPTH_READ_ONLY_STENCIL_ATTACHMENT_OPTIMAL ||
layout == VK_IMAGE_LAYOUT_STENCIL_ATTACHMENT_OPTIMAL_KHR;
}
#endif
/* Transitions a HiZ-enabled depth buffer from one layout to another. Unless
* the initial layout is undefined, the HiZ buffer and depth buffer will