[PATCH i-g-t 3/3] tests/kms_async_flip: skip subtest on AMD if invalid condition

Melissa Wen mwen at igalia.com
Wed Jun 11 21:51:22 UTC 2025



On 11/06/2025 07:16, Kamil Konieczny wrote:
> Hi Melissa,
> On 2025-06-01 at 16:14:46 -0300, Melissa Wen wrote:
>> Async page flips can fail for any driver-specific reasons, i.e. when the
>> driver can't commit to async page flip request due to hw limitations,
>> the commit is rejected with -EINVAL since there is one or more
>> conditions that make the request invalid. These limitations vary between
>> vendors and hw versions. In case of AMD devices, async page flip cannot
>> be perfomed if fb memory type changes (VRAM vs GTT), but framebuffer
>> allocation type cannot be controlled by any userspace configuration.
>>
>> Allow EINVAL failures on AMD device and skip the test. Async flips can
>> be still validated by the performance comparison assert if no EINVAL.
>>
>> Signed-off-by: Melissa Wen <mwen at igalia.com>
> Reviewed-by: Kamil Konieczny <kamil.konieczny at linux.intel.com>
>
> Are you ok with merging this one patch first?
> This should also be tested again, as i915.Full were not run.
Yes, sounds good.

Thanks,

Melissa

>
> Regards,
> Kamil
>
>> ---
>>   tests/kms_async_flips.c | 7 ++++++-
>>   1 file changed, 6 insertions(+), 1 deletion(-)
>>
>> diff --git a/tests/kms_async_flips.c b/tests/kms_async_flips.c
>> index 97128cfad..065ac9c49 100644
>> --- a/tests/kms_async_flips.c
>> +++ b/tests/kms_async_flips.c
>> @@ -410,7 +410,12 @@ static void test_async_flip(data_t *data)
>>   
>>   		ret = perform_flip(data, frame, flags);
>>   
>> -		if (frame == 1 && data->allow_fail)
>> +		/* AMD cannot perform async page flip if fb mem type changes,
>> +		 * and this condition cannot be controlled by any userspace
>> +		 * configuration. Therefore allow EINVAL failure and skip the
>> +		 * test for AMD devices.
>> +		 */
>> +		if ((frame == 1 && data->allow_fail) || is_amdgpu_device(data->drm_fd))
>>   			igt_skip_on(ret == -EINVAL);
>>   		else
>>   			igt_assert_eq(ret, 0);
>> -- 
>> 2.47.2
>>



More information about the igt-dev mailing list