reservation: wait only with non-zero timeout specified (v3)
PATCH 1/2 reservation: wait only with non-zero timeout specified (v3)
When the timeout value passed to reservation_object_wait_timeout_rcu is zero, no wait should be done if the fences are not signaled.
Return '1' for idle and '0' for busy if the specified timeout is '0' to keep consistent with the case of non-zero timeout.
v2: call fence_put if not signaled in the case of timeout==0
v3: switch to reservation_object_test_signaled_rcu
--- drivers/dma-buf/reservation.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/dma-buf/reservation.c +3 -0
@@ -327,6 +327,9 @@ long reservation_object_wait_timeout_rcu(struct reservation_object *obj,unsigned seq, shared_count, i =0 ;long ret = timeout; +if (!timeout) +return reservation_object_test_signaled_rcu (obj, wait_all); + retry: fence =NULL ; shared_count =0 ;
Signature · 6 lines
1.9.1 _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel
PATCH 2/2 dma-buf/fence: don't wait when specified timeout is zero
When specified timeout is zero for fence_wait_timeout, just check if the fence is signaled or not without wait.
--- drivers/dma-buf/fence.c | 3 +++ 1 file changed, 3 insertions(+)
drivers/dma-buf/fence.c +3 -0
@@ -159,6 +159,9 @@ fence_wait_timeout(struct fence *fence, bool intr, signed long timeout)if (WARN_ON (timeout <0 ))return -EINVAL ; +if (timeout ==0 ) +return fence_is_signaled (fence); +trace_fence_wait_start (fence); ret = fence->ops->wait (fence, intr, timeout);trace_fence_wait_end (fence);
Signature · 6 lines
1.9.1 _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel
Re: [PATCH 2/2] dma-buf/fence: don't wait when specified timeout is zero
Op 21-01-15 om 11:35 schreef Jammy Zhou:
Quoted 5 lines
When specified timeout is zero for
fence_wait_timeout, just check if the fence is signaled or not without wait.Signed-off-by Jammy Zhou <[email protected]>
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
Re: [PATCH 2/2] dma-buf/fence: don't wait when specified timeout is zero
In reply to Jammy ZhouAm 21.01.2015 um 11:35 schrieb Jammy Zhou:
Quoted 4 lines
When specified timeout is zero for
fence_wait_timeout, just check if the fence is signaled or not without wait.Signed-off-by Jammy Zhou <[email protected]>
Quoted 9 lines
--- drivers/dma-buf/fence.c | 3 +++ 1 file changed, 3 insertions(+)drivers/dma-buf/fence.c +0
-0
drivers/dma-buf/fence.c fence_wait_timeout(struct fence *fence, bool intr, signed long timeout) · line 167
Quoted 9 lines
drivers/dma-buf/fence.c +3
-0@@ -159,6 +159,9 @@ fence_wait_timeout(struct fence *fence, bool intr, signed long timeout)if (WARN_ON (timeout <0 ))return -EINVAL ; +if (timeout ==0 ) +return fence_is_signaled (fence); +trace_fence_wait_start (fence); ret = fence->ops->wait (fence, intr, timeout);trace_fence_wait_end (fence);
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
Op 21-01-15 om 11:35 schreef Jammy Zhou:
Quoted 6 lines
When the timeout value passed to
reservation_object_wait_timeout_rcuis zero, no wait should be done if the fences are not signaled.Return '1' for idle and '0' for busy if the specified timeout is '0' to keep consistent with the case of non-zero timeout.
Quoted 8 lines
v2: call
fence_putif not signaled in the case of timeout==0v3: switch to
reservation_object_test_signaled_rcuSigned-off-by Jammy Zhou <[email protected]>Reviewed-by Christian König <[email protected]>Reviewed-by Alex Deucher <[email protected]>
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
Quoted 9 lines · Maarten Lankhorst
Op 21-01-15 om 11:35 schreef Jammy Zhou:
Quoted 8 lines
When the timeout value passed to
reservation_object_wait_timeout_rcuis zero, no wait should be done if the fences are not signaled.Return '1' for idle and '0' for busy if the specified timeout is '0' to keep consistent with the case of non-zero timeout.
v2: call
fence_putif not signaled in the case of timeout==0
Quoted 7 lines
Quoted 6 lines
v3: switch to
reservation_object_test_signaled_rcuSigned-off-by Jammy Zhou <[email protected]>Reviewed-by Christian König <[email protected]>Reviewed-by Alex Deucher <[email protected]>Reviewed-by Maarten Lankhorst <[email protected]>
Dave, Maarten,
Do you want to pick these up, or would you rather I pulled them through my tree?
Thanks,
Alex
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
Hey,
Quoted 17 lines · Alex Deucher
Quoted 15 lines · Maarten Lankhorst
Op 21-01-15 om 11:35 schreef Jammy Zhou:
Quoted 14 lines
When the timeout value passed to
reservation_object_wait_timeout_rcuy, is zero, no wait should be done if the fences are not signaled.Return '1' for idle and '0' for busy if the specified timeout is '0' to keep consistent with the case of non-zero timeout.
v2: call
fence_putif not signaled in the case of timeout==0v3: switch to
reservation_object_test_signaled_rcuSigned-off-by Jammy Zhou <[email protected]>Reviewed-by Christian König <[email protected]>Reviewed-by Alex Deucher <[email protected]>
Quoted 5 lines
Quoted 1 line
Reviewed-by Maarten Lankhorst <[email protected]>Dave, Maarten,
Do you want to pick these up, or would you rather I pulled them through my tree?
This goes through Sumit Semwal's tree. He's the dma-buf maintainer and I already made him aware of the patches.
~Maarten
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
Quoted 20 lines · Maarten Lankhorst
Hey,
Quoted 17 lines · Alex Deucher
Quoted 15 lines · Maarten Lankhorst
Op 21-01-15 om 11:35 schreef Jammy Zhou:
Quoted 14 lines
When the timeout value passed to
reservation_object_wait_timeout_rcuy, is zero, no wait should be done if the fences are not signaled.Return '1' for idle and '0' for busy if the specified timeout is '0' to keep consistent with the case of non-zero timeout.
v2: call
fence_putif not signaled in the case of timeout==0v3: switch to
reservation_object_test_signaled_rcuSigned-off-by Jammy Zhou <[email protected]>Reviewed-by Christian König <[email protected]>Reviewed-by Alex Deucher <[email protected]>
Quoted 6 lines
Quoted 5 lines
Quoted 1 line
Reviewed-by Maarten Lankhorst <[email protected]>Dave, Maarten,
Do you want to pick these up, or would you rather I pulled them through my tree?
This goes through Sumit Semwal's tree. He's the dma-buf maintainer and I already made him aware of the patches.
Thanks!
Alex
_______________________________________________
dri-devel mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/dri-devel
Sumit Semwal
maintainerHi Jammy, All,
Quoted 22 lines · Alex Deucher
Quoted 20 lines · Maarten Lankhorst
Hey,
Quoted 17 lines · Alex Deucher
Quoted 15 lines · Maarten Lankhorst
Op 21-01-15 om 11:35 schreef Jammy Zhou:
Quoted 14 lines
When the timeout value passed to
reservation_object_wait_timeout_rcuy, is zero, no wait should be done if the fences are not signaled.Return '1' for idle and '0' for busy if the specified timeout is '0' to keep consistent with the case of non-zero timeout.
v2: call
fence_putif not signaled in the case of timeout==0v3: switch to
reservation_object_test_signaled_rcuSigned-off-by Jammy Zhou <[email protected]>Reviewed-by Christian König <[email protected]>Reviewed-by Alex Deucher <[email protected]>
Quoted 7 lines
Quoted 6 lines
Quoted 5 lines
Quoted 1 line
Reviewed-by Maarten Lankhorst <[email protected]>Dave, Maarten,
Do you want to pick these up, or would you rather I pulled them through my tree?
This goes through Sumit Semwal's tree. He's the dma-buf maintainer and I already made him aware of the patches.
Both these patches are now pulled and pushed out to my for-next branch.
Quoted 4 lines
Thanks!
Alex
Signature · 6 lines
Thanks and Best regards, Sumit. _______________________________________________ dri-devel mailing list [email protected] http://lists.freedesktop.org/mailman/listinfo/dri-devel