Return-Path: Received: from NAM10-DM6-obe.outbound.protection.outlook.com (mail-dm6nam10on2064.outbound.protection.outlook.com [40.107.93.64]) by gabe.freedesktop.org (Postfix) with ESMTPS id 313DC6E11C for ; Tue, 9 Nov 2021 15:53:54 +0000 (UTC) References: <20211104162742.174363-1-contact@emersion.fr> From: Rodrigo Siqueira Jordao Message-ID: Date: Tue, 9 Nov 2021 10:53:49 -0500 In-Reply-To: <20211104162742.174363-1-contact@emersion.fr> Content-Type: text/plain; charset=utf-8; format=flowed Content-Language: en-US Content-Transfer-Encoding: 7bit MIME-Version: 1.0 Subject: Re: [igt-dev] [PATCH] tests/kms_plane_alpha_blend: skip coverage tests on missing enum List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: igt-dev-bounces@lists.freedesktop.org Sender: "igt-dev" To: Simon Ser , igt-dev@lists.freedesktop.org Cc: Mark Yacoub List-ID: On 2021-11-04 12:27 p.m., Simon Ser wrote: > Some KMS drivers support the KMS "pixel blend mode" plane property, > but don't support the "Coverage" mode. This enum entry is missing > to indicate lack of support as seen in this drm_info exerpt: > > "pixel blend mode": enum {None, Pre-multiplied} = Pre-multiplied > > Skip the coverage tests in this case. > > Signed-off-by: Simon Ser > Cc: Rodrigo Siqueira > Cc: Harry Wentland > Cc: Nicholas Kazlauskas > --- > tests/kms_plane_alpha_blend.c | 4 ++-- > 1 file changed, 2 insertions(+), 2 deletions(-) > > diff --git a/tests/kms_plane_alpha_blend.c b/tests/kms_plane_alpha_blend.c > index 9e4ee22b43af..d061262da196 100644 > --- a/tests/kms_plane_alpha_blend.c > +++ b/tests/kms_plane_alpha_blend.c > @@ -419,7 +419,7 @@ static void coverage_7efc(data_t *data, enum pipe pipe, igt_plane_t *plane) > igt_crc_t ref_crc = {}, crc = {}; > int i; > > - igt_plane_set_prop_enum(plane, IGT_PLANE_PIXEL_BLEND_MODE, "Coverage"); > + igt_require(igt_plane_try_prop_enum(plane, IGT_PLANE_PIXEL_BLEND_MODE, "Coverage")); > igt_display_commit2(display, COMMIT_ATOMIC); > igt_pipe_crc_start(data->pipe_crc); > > @@ -451,7 +451,7 @@ static void coverage_premult_constant(data_t *data, enum pipe pipe, igt_plane_t > if (plane->type != DRM_PLANE_TYPE_PRIMARY) > igt_plane_set_fb(igt_pipe_get_plane_type(&display->pipes[pipe], DRM_PLANE_TYPE_PRIMARY), &data->gray_fb); > > - igt_plane_set_prop_enum(plane, IGT_PLANE_PIXEL_BLEND_MODE, "Coverage"); > + igt_require(igt_plane_try_prop_enum(plane, IGT_PLANE_PIXEL_BLEND_MODE, "Coverage")); > igt_plane_set_fb(plane, &data->argb_fb_cov_7e); > igt_display_commit2(display, COMMIT_ATOMIC); > igt_pipe_crc_start(data->pipe_crc); > Reviewed-by: Rodrigo Siqueira Thanks