mirror of https://lore.kernel.org/lkml/
 help / color / mirror / Atom feed
* [PATCH] dma-fence: Fix safe access wrapper to call timeline name method
@ 2025-10-21 16:09 Akash Goel
  2025-10-21 18:36 ` Tvrtko Ursulin
  0 siblings, 1 reply; 3+ messages in thread
From: Akash Goel @ 2025-10-21 16:09 UTC (permalink / raw)
  To: sumit.semwal, gustavo, christian.koenig
  Cc: linux-media, dri-devel, linaro-mm-sig, linux-kernel, nd,
	Akash Goel, stable

This commit fixes the wrapper function dma_fence_timeline_name(), that
was added for safe access, to actually call the timeline name method of
dma_fence_ops.

Cc: <stable@vger.kernel.org> # v6.17+
Signed-off-by: Akash Goel <akash.goel@arm.com>
---
 drivers/dma-buf/dma-fence.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/dma-buf/dma-fence.c b/drivers/dma-buf/dma-fence.c
index 3f78c56b58dc..39e6f93dc310 100644
--- a/drivers/dma-buf/dma-fence.c
+++ b/drivers/dma-buf/dma-fence.c
@@ -1141,7 +1141,7 @@ const char __rcu *dma_fence_timeline_name(struct dma_fence *fence)
 			 "RCU protection is required for safe access to returned string");
 
 	if (!test_bit(DMA_FENCE_FLAG_SIGNALED_BIT, &fence->flags))
-		return fence->ops->get_driver_name(fence);
+		return fence->ops->get_timeline_name(fence);
 	else
 		return "signaled-timeline";
 }
-- 
2.25.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] dma-fence: Fix safe access wrapper to call timeline name method
  2025-10-21 16:09 [PATCH] dma-fence: Fix safe access wrapper to call timeline name method Akash Goel
@ 2025-10-21 18:36 ` Tvrtko Ursulin
  2025-10-27 10:27   ` Christian König
  0 siblings, 1 reply; 3+ messages in thread
From: Tvrtko Ursulin @ 2025-10-21 18:36 UTC (permalink / raw)
  To: Akash Goel, sumit.semwal, gustavo, christian.koenig
  Cc: linux-media, dri-devel, linaro-mm-sig, linux-kernel, nd, stable


On 21/10/2025 17:09, Akash Goel wrote:
> This commit fixes the wrapper function dma_fence_timeline_name(), that
> was added for safe access, to actually call the timeline name method of
> dma_fence_ops.
> 
> Cc: <stable@vger.kernel.org> # v6.17+
> Signed-off-by: Akash Goel <akash.goel@arm.com>

Fixes: 506aa8b02a8d ("dma-fence: Add safe access helpers and document 
the rules")

Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>

Apologies for the copy and paste snafu.

Regards,

Tvrtko

> ---
>   drivers/dma-buf/dma-fence.c | 2 +-
>   1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/dma-buf/dma-fence.c b/drivers/dma-buf/dma-fence.c
> index 3f78c56b58dc..39e6f93dc310 100644
> --- a/drivers/dma-buf/dma-fence.c
> +++ b/drivers/dma-buf/dma-fence.c
> @@ -1141,7 +1141,7 @@ const char __rcu *dma_fence_timeline_name(struct dma_fence *fence)
>   			 "RCU protection is required for safe access to returned string");
>   
>   	if (!test_bit(DMA_FENCE_FLAG_SIGNALED_BIT, &fence->flags))
> -		return fence->ops->get_driver_name(fence);
> +		return fence->ops->get_timeline_name(fence);
>   	else
>   		return "signaled-timeline";
>   }


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PATCH] dma-fence: Fix safe access wrapper to call timeline name method
  2025-10-21 18:36 ` Tvrtko Ursulin
@ 2025-10-27 10:27   ` Christian König
  0 siblings, 0 replies; 3+ messages in thread
From: Christian König @ 2025-10-27 10:27 UTC (permalink / raw)
  To: Tvrtko Ursulin, Akash Goel, sumit.semwal, gustavo
  Cc: linux-media, dri-devel, linaro-mm-sig, linux-kernel, nd, stable

On 10/21/25 20:36, Tvrtko Ursulin wrote:
> 
> On 21/10/2025 17:09, Akash Goel wrote:
>> This commit fixes the wrapper function dma_fence_timeline_name(), that
>> was added for safe access, to actually call the timeline name method of
>> dma_fence_ops.
>>
>> Cc: <stable@vger.kernel.org> # v6.17+
>> Signed-off-by: Akash Goel <akash.goel@arm.com>
> 
> Fixes: 506aa8b02a8d ("dma-fence: Add safe access helpers and document the rules")
> 
> Reviewed-by: Tvrtko Ursulin <tvrtko.ursulin@igalia.com>

Good catch, Reviewed-by: Christian König <christian.koenig@amd.com> as well.

Please ping me if you need somebody to push this to drm-misc-fixes.

Thanks,
Christian.

> 
> Apologies for the copy and paste snafu.
> 
> Regards,
> 
> Tvrtko
> 
>> ---
>>   drivers/dma-buf/dma-fence.c | 2 +-
>>   1 file changed, 1 insertion(+), 1 deletion(-)
>>
>> diff --git a/drivers/dma-buf/dma-fence.c b/drivers/dma-buf/dma-fence.c
>> index 3f78c56b58dc..39e6f93dc310 100644
>> --- a/drivers/dma-buf/dma-fence.c
>> +++ b/drivers/dma-buf/dma-fence.c
>> @@ -1141,7 +1141,7 @@ const char __rcu *dma_fence_timeline_name(struct dma_fence *fence)
>>                "RCU protection is required for safe access to returned string");
>>         if (!test_bit(DMA_FENCE_FLAG_SIGNALED_BIT, &fence->flags))
>> -        return fence->ops->get_driver_name(fence);
>> +        return fence->ops->get_timeline_name(fence);
>>       else
>>           return "signaled-timeline";
>>   }
> 


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-10-27 10:27 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2025-10-21 16:09 [PATCH] dma-fence: Fix safe access wrapper to call timeline name method Akash Goel
2025-10-21 18:36 ` Tvrtko Ursulin
2025-10-27 10:27   ` Christian König

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox

all inboxes | Powered by JetHome®