[Intel-gfx] [PATCH i-g-t v2 11/33] tests/kms_fbc_crc: Add support for dynamic number of planes

Mika Kahola mika.kahola at intel.com
Wed Jan 25 12:22:55 UTC 2017


On Tue, 2017-01-24 at 18:33 -0500, Robert Foss wrote:
> Add changes reflecting the new support for dynamic number of planes
> per pipe.
> 
> Signed-off-by: Robert Foss <robert.foss at collabora.com>
> ---
>  tests/kms_fbc_crc.c | 9 +++++----
>  1 file changed, 5 insertions(+), 4 deletions(-)
> 
> diff --git a/tests/kms_fbc_crc.c b/tests/kms_fbc_crc.c
> index a696e124..d2c76fb1 100644
> --- a/tests/kms_fbc_crc.c
> +++ b/tests/kms_fbc_crc.c
> @@ -372,7 +372,7 @@ static bool prepare_test(data_t *data, enum
> test_mode test_mode)
>  	igt_output_t *output = data->output;
>  	igt_pipe_crc_t *pipe_crc;
>  
> -	data->primary = igt_output_get_plane(data->output,
> IGT_PLANE_PRIMARY);
> +	data->primary = igt_output_get_plane_type(data->output,
> DRM_PLANE_TYPE_PRIMARY);
>  
>  	create_fbs(data, true, data->fb);
>  
> @@ -457,10 +457,11 @@ static void finish_crtc(data_t *data, enum
> test_mode mode)
>  static void reset_display(data_t *data)
>  {
>  	igt_display_t *display = &data->display;
> -	enum pipe pipe;
> +	enum pipe pipe_type;
Earlier patch defined this as pipe_id. For consistency, should we
rename this as pipe_id too? I'll leave this up to you. Either way, this
is 

Reviewed-by: Mika Kahola <mika.kahola at intel.com>
>  
> -	for_each_pipe(display, pipe) {
> -		igt_plane_t *plane = &display-
> >pipes[pipe].planes[IGT_PLANE_PRIMARY];
> +	for_each_pipe(display, pipe_type) {
> +        igt_pipe_t *pipe = &display->pipes[pipe_type];
> +		igt_plane_t *plane = igt_pipe_get_plane_type(pipe,
> DRM_PLANE_TYPE_PRIMARY);
>  
>  		if (plane->fb)
>  			igt_plane_set_fb(plane, NULL);
-- 
Mika Kahola - Intel OTC



More information about the Intel-gfx mailing list