[PATCH 8/8] amdgpu: use sync file for shared semaphores (v2.1)

Chris Wilson chris at chris-wilson.co.uk
Tue Apr 11 12:42:17 UTC 2017


On Tue, Apr 11, 2017 at 01:22:20PM +1000, Dave Airlie wrote:
> +static int amdgpu_sem_lookup_and_sync(struct amdgpu_cs_parser *p,
> +				      uint32_t handle)
> +{
> +	int r;
> +	struct dma_fence *old_fence;
> +
> +	r = drm_syncobj_swap_fences(p->filp, handle, NULL, &old_fence);
> +	if (r)
> +		return r;

I'm a bit puzzled over this interface as this means that all
in-semaphores are not reusable. That seems a bit odd as it means
userspace can't use the results from one engine on two+ parallel
engines. Searching kronos for VkSemaphore
https://www.khronos.org/registry/vulkan/specs/1.0/man/html/VkSemaphore.html
isn't enlightening...
-Chris

-- 
Chris Wilson, Intel Open Source Technology Centre


More information about the dri-devel mailing list