Re: [igt-dev] [PATCH i-g-t] igt/pm_backlight: Require a connected output for the backlight

Dhinakaran Pandiyan
2018-09-05T01:52:43Z

On Tue, 2018-09-04 at 22:34 +0100, Chris Wilson wrote:
> We cannot control the backlight if its attached output is not
> connected.
> Don't assert, but require.
Makes sense.
Reviewed-by: Dhinakaran Pandiyan <dhinakaran.pandiyan@intel.com>

>
> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
> ---
> tests/pm_backlight.c | 4 +++-
> 1 file changed, 3 insertions(+), 1 deletion(-)
>
> diff --git a/tests/pm_backlight.c b/tests/pm_backlight.c
> index 33614e969..e94340a2b 100644
> --- a/tests/pm_backlight.c
> +++ b/tests/pm_backlight.c
> @@ -225,7 +225,9 @@ igt_main
> break;
> }
>
> - igt_assert_f(found, "Could not map \"%s\" to output
> (%s?)\n", name, name + 6);
> + igt_require_f(found,
> + "Could not map backlight for \"%s\" to
> connected output\n",
> + name);
>
> igt_output_set_pipe(output, pipe);
> mode = igt_output_get_mode(output);