[igt-dev] [PATCH i-g-t 2/2] lib/igt_kms: bandwidth failure should return ENOSPC

Modem, Bhanuprakash bhanuprakash.modem at intel.com
Wed May 3 05:55:26 UTC 2023


Hi Thasleem,

lib/igt_kms: bandwidth failure should return ENOSPC
---------------------------------------------^
We are returning bool not ENOSPC, please fix the title.

On Tue-02-05-2023 04:32 pm, Mohammed Thasleem wrote:
> Return failure for ENOSPC on fit to bandwidth failure in MST config.

Please elaborate about this patch.

> 
> Signed-off-by: Mohammed Thasleem <mohammed.thasleem at intel.com>
> ---
>   lib/igt_kms.c | 2 ++
>   1 file changed, 2 insertions(+)
> 
> diff --git a/lib/igt_kms.c b/lib/igt_kms.c
> index c12823d31..790fbca2e 100644
> --- a/lib/igt_kms.c
> +++ b/lib/igt_kms.c
> @@ -4534,6 +4534,8 @@ bool __override_all_active_output_modes_to_fit_bw(igt_display_t *display,
>   
>   		if (!ret)
>   			return true;
> +		else if (ret == -ENOSPC)
-----------------------------^
It must be "!=", right?

Everytime we get the no space error, we need to retry with another mode 
till we get the valid one. For other errors, just return false.

- Bhanu

> +			return false;
>   	}
>   
>   	return false;


More information about the igt-dev mailing list