rusticl/device: add retain/release callbacks for luxmark v4

Signed-off-by: Karol Herbst <kherbst@redhat.com>
Acked-by: Alyssa Rosenzweig <alyssa.rosenzweig@collabora.com>
Part-of: <https://gitlab.freedesktop.org/mesa/mesa/-/merge_requests/15439>
This commit is contained in:
Karol Herbst
2022-03-31 02:38:17 +02:00
committed by Marge Bot
parent 5570bdc889
commit 6fb9d490cb

View File

@@ -116,8 +116,8 @@ pub static DISPATCH: cl_icd_dispatch = cl_icd_dispatch {
clReleaseDeviceEXT: None,
clCreateEventFromGLsyncKHR: None,
clCreateSubDevices: None,
clRetainDevice: None,
clReleaseDevice: None,
clRetainDevice: Some(cl_retain_device),
clReleaseDevice: Some(cl_release_device),
clCreateImage: Some(cl_create_image),
clCreateProgramWithBuiltInKernels: None,
clCompileProgram: Some(cl_compile_program),
@@ -562,6 +562,14 @@ extern "C" fn cl_create_buffer(
match_obj!(create_buffer(context, flags, size, host_ptr,), errcode_ret)
}
extern "C" fn cl_retain_device(_device: cl_device_id) -> cl_int {
CL_SUCCESS as cl_int
}
extern "C" fn cl_release_device(_device: cl_device_id) -> cl_int {
CL_SUCCESS as cl_int
}
extern "C" fn cl_create_image_2d(
context: cl_context,
flags: cl_mem_flags,