revert old interfaces

Signed-off-by: shegangbin <shegangbin1@huawei.com>
Change-Id: Ic9af498fac6f5da5d441c4732749ad5c59b07844
This commit is contained in:
shegangbin 2023-10-10 09:55:35 +00:00
parent 1a2ae83d00
commit 54c33aeb0e
3 changed files with 0 additions and 79 deletions

View File

@ -380,12 +380,6 @@ static VKAPI_ATTR void VKAPI_CALL StubCmdOpticalFlowExecuteNV(VkCommandBuffer co
static VKAPI_ATTR VkResult VKAPI_CALL StubGetFramebufferTilePropertiesQCOM(VkDevice device, VkFramebuffer framebuffer, uint32_t* pPropertiesCount, VkTilePropertiesQCOM* pProperties) { return VK_SUCCESS; }
static VKAPI_ATTR VkResult VKAPI_CALL StubGetDynamicRenderingTilePropertiesQCOM(VkDevice device, const VkRenderingInfo* pRenderingInfo, VkTilePropertiesQCOM* pProperties) { return VK_SUCCESS; }
#ifdef VK_USE_PLATFORM_OHOS
static VKAPI_ATTR VkResult VKAPI_CALL StubSetNativeFenceFdOpenHarmony(VkDevice device, int32_t nativeFenceFd, VkSemaphore semaphore, VkFence fence) { return VK_SUCCESS; }
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
static VKAPI_ATTR VkResult VKAPI_CALL StubGetNativeFenceFdOpenHarmony(VkQueue queue, uint32_t waitSemaphoreCount, const VkSemaphore* pWaitSemaphores, VkImage image, int32_t* pNativeFenceFd) { return VK_SUCCESS; }
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
static VKAPI_ATTR VkResult VKAPI_CALL StubGetSwapchainGrallocUsageOHOS(VkDevice device, VkFormat format, VkImageUsageFlags imageUsage, uint64_t* grallocUsage) { return VK_SUCCESS; }
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
@ -1259,14 +1253,6 @@ static inline void layer_init_device_dispatch_table(VkDevice device, VkLayerDisp
if (table->GetFramebufferTilePropertiesQCOM == nullptr) { table->GetFramebufferTilePropertiesQCOM = (PFN_vkGetFramebufferTilePropertiesQCOM)StubGetFramebufferTilePropertiesQCOM; }
table->GetDynamicRenderingTilePropertiesQCOM = (PFN_vkGetDynamicRenderingTilePropertiesQCOM) gpa(device, "vkGetDynamicRenderingTilePropertiesQCOM");
if (table->GetDynamicRenderingTilePropertiesQCOM == nullptr) { table->GetDynamicRenderingTilePropertiesQCOM = (PFN_vkGetDynamicRenderingTilePropertiesQCOM)StubGetDynamicRenderingTilePropertiesQCOM; }
#ifdef VK_USE_PLATFORM_OHOS
table->SetNativeFenceFdOpenHarmony = (PFN_vkSetNativeFenceFdOpenHarmony) gpa(device, "vkSetNativeFenceFdOpenHarmony");
if (table->SetNativeFenceFdOpenHarmony == nullptr) { table->SetNativeFenceFdOpenHarmony = (PFN_vkSetNativeFenceFdOpenHarmony)StubSetNativeFenceFdOpenHarmony; }
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
table->GetNativeFenceFdOpenHarmony = (PFN_vkGetNativeFenceFdOpenHarmony) gpa(device, "vkGetNativeFenceFdOpenHarmony");
if (table->GetNativeFenceFdOpenHarmony == nullptr) { table->GetNativeFenceFdOpenHarmony = (PFN_vkGetNativeFenceFdOpenHarmony)StubGetNativeFenceFdOpenHarmony; }
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
table->GetSwapchainGrallocUsageOHOS = (PFN_vkGetSwapchainGrallocUsageOHOS) gpa(device, "vkGetSwapchainGrallocUsageOHOS");
if (table->GetSwapchainGrallocUsageOHOS == nullptr) { table->GetSwapchainGrallocUsageOHOS = (PFN_vkGetSwapchainGrallocUsageOHOS)StubGetSwapchainGrallocUsageOHOS; }

View File

@ -1025,12 +1025,6 @@ typedef struct VkLayerDispatchTable_ {
PFN_vkGetDynamicRenderingTilePropertiesQCOM GetDynamicRenderingTilePropertiesQCOM;
// ---- VK_OHOS_native_buffer extension commands
#ifdef VK_USE_PLATFORM_OHOS
PFN_vkSetNativeFenceFdOpenHarmony SetNativeFenceFdOpenHarmony;
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
PFN_vkGetNativeFenceFdOpenHarmony GetNativeFenceFdOpenHarmony;
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
PFN_vkGetSwapchainGrallocUsageOHOS GetSwapchainGrallocUsageOHOS;
#endif // VK_USE_PLATFORM_OHOS

View File

@ -1085,12 +1085,6 @@ VKAPI_ATTR void VKAPI_CALL loader_init_device_extension_dispatch_table(struct lo
table->GetDynamicRenderingTilePropertiesQCOM = (PFN_vkGetDynamicRenderingTilePropertiesQCOM)gdpa(dev, "vkGetDynamicRenderingTilePropertiesQCOM");
// ---- VK_OHOS_native_buffer extension commands
#ifdef VK_USE_PLATFORM_OHOS
table->SetNativeFenceFdOpenHarmony = (PFN_vkSetNativeFenceFdOpenHarmony)gdpa(dev, "vkSetNativeFenceFdOpenHarmony");
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
table->GetNativeFenceFdOpenHarmony = (PFN_vkGetNativeFenceFdOpenHarmony)gdpa(dev, "vkGetNativeFenceFdOpenHarmony");
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
table->GetSwapchainGrallocUsageOHOS = (PFN_vkGetSwapchainGrallocUsageOHOS)gdpa(dev, "vkGetSwapchainGrallocUsageOHOS");
#endif // VK_USE_PLATFORM_OHOS
@ -2140,12 +2134,6 @@ VKAPI_ATTR void* VKAPI_CALL loader_lookup_device_dispatch_table(const VkLayerDis
if (!strcmp(name, "GetDynamicRenderingTilePropertiesQCOM")) return (void *)table->GetDynamicRenderingTilePropertiesQCOM;
// ---- VK_OHOS_native_buffer extension commands
#ifdef VK_USE_PLATFORM_OHOS
if (!strcmp(name, "SetNativeFenceFdOpenHarmony")) return (void *)table->SetNativeFenceFdOpenHarmony;
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
if (!strcmp(name, "GetNativeFenceFdOpenHarmony")) return (void *)table->GetNativeFenceFdOpenHarmony;
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
if (!strcmp(name, "GetSwapchainGrallocUsageOHOS")) return (void *)table->GetSwapchainGrallocUsageOHOS;
#endif // VK_USE_PLATFORM_OHOS
@ -7449,41 +7437,6 @@ VKAPI_ATTR VkResult VKAPI_CALL GetDynamicRenderingTilePropertiesQCOM(
// ---- VK_OHOS_native_buffer extension trampoline/terminators
#ifdef VK_USE_PLATFORM_OHOS
VKAPI_ATTR VkResult VKAPI_CALL SetNativeFenceFdOpenHarmony(
VkDevice device,
int32_t nativeFenceFd,
VkSemaphore semaphore,
VkFence fence) {
const VkLayerDispatchTable *disp = loader_get_dispatch(device);
if (NULL == disp) {
loader_log(NULL, VULKAN_LOADER_ERROR_BIT | VULKAN_LOADER_VALIDATION_BIT, 0,
"vkSetNativeFenceFdOpenHarmony: Invalid device "
"[VUID-vkSetNativeFenceFdOpenHarmony-device-parameter]");
abort(); /* Intentionally fail so user can correct issue. */
}
return disp->SetNativeFenceFdOpenHarmony(device, nativeFenceFd, semaphore, fence);
}
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
VKAPI_ATTR VkResult VKAPI_CALL GetNativeFenceFdOpenHarmony(
VkQueue queue,
uint32_t waitSemaphoreCount,
const VkSemaphore* pWaitSemaphores,
VkImage image,
int32_t* pNativeFenceFd) {
const VkLayerDispatchTable *disp = loader_get_dispatch(queue);
if (NULL == disp) {
loader_log(NULL, VULKAN_LOADER_ERROR_BIT | VULKAN_LOADER_VALIDATION_BIT, 0,
"vkGetNativeFenceFdOpenHarmony: Invalid queue "
"[VUID-vkGetNativeFenceFdOpenHarmony-queue-parameter]");
abort(); /* Intentionally fail so user can correct issue. */
}
return disp->GetNativeFenceFdOpenHarmony(queue, waitSemaphoreCount, pWaitSemaphores, image, pNativeFenceFd);
}
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
VKAPI_ATTR VkResult VKAPI_CALL GetSwapchainGrallocUsageOHOS(
VkDevice device,
@ -9563,18 +9516,6 @@ bool extension_instance_gpa(struct loader_instance *ptr_instance, const char *na
}
// ---- VK_OHOS_native_buffer extension commands
#ifdef VK_USE_PLATFORM_OHOS
if (!strcmp("vkSetNativeFenceFdOpenHarmony", name)) {
*addr = (void *)SetNativeFenceFdOpenHarmony;
return true;
}
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
if (!strcmp("vkGetNativeFenceFdOpenHarmony", name)) {
*addr = (void *)GetNativeFenceFdOpenHarmony;
return true;
}
#endif // VK_USE_PLATFORM_OHOS
#ifdef VK_USE_PLATFORM_OHOS
if (!strcmp("vkGetSwapchainGrallocUsageOHOS", name)) {
*addr = (void *)GetSwapchainGrallocUsageOHOS;