Re: [PATCH i-g-t v3 4/6] tests/kms_properties: keep primary plane enabled for each CRTC

Alex Hung <[email protected]>
Newsgroups org.freedesktop.lists.igt-dev
Message-ID <[email protected]>

On 8/11/26 08:23, Melissa Wen wrote:
> For AMD, a primary plane must be active to keep CRTC active. So stop
> reusing primary plane fb for overlays, give the latter its own fb.
> 
> Signed-off-by: Melissa Wen <[email protected]>
> 
> ---
> 
> v2:
> - detach different changes from a single commit (Chaitanya)

Were patches 4 & 5 a single patch? I think they belong to a single patch.

Ignore me if this was discussed before.

> ---
>   tests/kms_properties.c | 12 +++++++++++-
>   1 file changed, 11 insertions(+), 1 deletion(-)
> 
> diff --git a/tests/kms_properties.c b/tests/kms_properties.c
> index 292a04a2a..87614346a 100644
> --- a/tests/kms_properties.c
> +++ b/tests/kms_properties.c
> @@ -237,7 +237,7 @@ static void run_colorop_property_tests(igt_display_t *display,
>   				       igt_crtc_t *crtc, igt_output_t *output,
>   				       bool atomic)
>   {
> -	struct igt_fb fb;
> +	struct igt_fb fb, afb;
>   	igt_plane_t *plane;
>   	igt_colorop_t *colorop;
>   	int i;
> @@ -255,6 +255,16 @@ static void run_colorop_property_tests(igt_display_t *display,
>   			 igt_crtc_name(crtc), plane->index,
>   			 kmstest_plane_type_name(plane->type), output->name);
>   
> +		/* AMD requires primary plane enabled to keep CRTC enabled */
> +		if (plane->type != DRM_PLANE_TYPE_PRIMARY) {
> +			drmModeModeInfo *mode = igt_output_get_mode(output);
> +
> +			igt_create_pattern_fb(display->drm_fd, mode->hdisplay, mode->vdisplay,
> +					      DRM_FORMAT_XRGB8888, DRM_FORMAT_MOD_LINEAR, &afb);
> +
> +			igt_plane_set_fb(plane, &afb);
> +		}
> +
>   		/* iterate over all color pipelines on plane */
>   		for (i = 0; i < plane->num_color_pipelines; ++i) {
>   			/* iterate over all colorops in pipeline*/
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.