On 12/11/25 16:04, Tvrtko Ursulin wrote:
...
>> @@ -90,6 +73,11 @@ static int test_signaling(void *arg)
>>           goto err_free;
>>       }
>>   +    if (rcu_dereference_protected(f->ops, true)) {
>> +        pr_err("Fence ops not cleared on signal\n");
>> +        goto err_free;
>> +    }
> 
> Bump to after the signaled check just below? Otherwise the signaled state 
> hasn't been ascertained yet.

Done. I've put it to the end of the test.

>> +
>>       if (!dma_fence_is_signaled(f)) {
>>           pr_err("Fence not reporting signaled\n");
>>           goto err_free;
>> @@ -540,19 +528,7 @@ int dma_fence(void)
>>           SUBTEST(test_stub),
>>           SUBTEST(race_signal_callback),
>>       };
>> -    int ret;
>>         pr_info("sizeof(dma_fence)=%zu\n", sizeof(struct dma_fence));
>> -
>> -    slab_fences = KMEM_CACHE(mock_fence,
>> -                 SLAB_TYPESAFE_BY_RCU |
> 
> Hm.. race_signal_callback looks like it could be depending on 
> SLAB_TYPESAFE_BY_RCU. To you not?

Hui? As far as I can see it doesn't.

The race_signal_callback test just depends on the general RCU functionality of 
fences.

Regards,
Christian.

> 
> Regards,
> 
> Tvrtko
> 
>> -                 SLAB_HWCACHE_ALIGN);
>> -    if (!slab_fences)
>> -        return -ENOMEM;
>> -
>> -    ret = subtests(tests, NULL);
>> -
>> -    kmem_cache_destroy(slab_fences);
>> -
>> -    return ret;
>> +    return subtests(tests, NULL);
>>   }
> 

Reply via email to