[igt-dev] [PATCH i-g-t 1/3] tests/kms_plane_scaling: negative tests can return -EINVAL or -ERANGE

Kamil Konieczny kamil.konieczny at linux.intel.com
Tue Apr 25 09:00:25 UTC 2023


On 2023-04-24 at 15:33:58 -0300, Maíra Canal wrote:
> Similar to the subtest invalid-parameters, when the display commit fails
> due to invalid parameters, the commit can return -EINVAL ou -ERANGE, not
> only -EINVAL.
> 
> Fixes: 2372a4beb ("tests/kms_plane_scaling: Add negative test to check num of scalers")
> Signed-off-by: Maíra Canal <mcanal at igalia.com>

Reviewed-by: Kamil Konieczny <kamil.konieczny at linux.intel.com>

> ---
>  tests/kms_plane_scaling.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/tests/kms_plane_scaling.c b/tests/kms_plane_scaling.c
> index 5008cd93..302fffcd 100644
> --- a/tests/kms_plane_scaling.c
> +++ b/tests/kms_plane_scaling.c
> @@ -838,7 +838,7 @@ test_invalid_num_scalers(data_t *d, enum pipe pipe, igt_output_t *output)
>  	 * */
>  	ret = igt_display_try_commit_atomic(display, DRM_MODE_ATOMIC_ALLOW_MODESET, NULL);
>  	igt_skip_on_f(ret == 0, "Cannot test handling of too many scaling ops, the device supports a large amount.\n");
> -	igt_assert_eq(ret, -EINVAL);
> +	igt_assert(ret == -EINVAL || ret == -ERANGE);
>  
>  	/* cleanup */
>  	igt_plane_set_fb(plane[0], NULL);
> -- 
> 2.40.0
> 


More information about the igt-dev mailing list