From patchwork Sat Mar 11 12:51:39 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arthur Grillo X-Patchwork-Id: 13170815 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id C4BC0C6FD1C for ; Sat, 11 Mar 2023 12:52:00 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id E776510E1B1; Sat, 11 Mar 2023 12:51:59 +0000 (UTC) Received: from mx1.riseup.net (mx1.riseup.net [198.252.153.129]) by gabe.freedesktop.org (Postfix) with ESMTPS id C6D9B10E196 for ; Sat, 11 Mar 2023 12:51:56 +0000 (UTC) Received: from fews1.riseup.net (fews1-pn.riseup.net [10.0.1.83]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange X25519 server-signature RSA-PSS (2048 bits) server-digest SHA256 client-signature RSA-PSS (2048 bits) client-digest SHA256) (Client CN "mail.riseup.net", Issuer "R3" (not verified)) by mx1.riseup.net (Postfix) with ESMTPS id 4PYjVN2MCDzDqPd; Sat, 11 Mar 2023 12:51:56 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=riseup.net; s=squak; t=1678539116; bh=bEb5LZGqEggoLJOpDV69ZnUAL53OPfcvEE2guod7O5E=; h=From:To:Cc:Subject:Date:From; b=KI7cgb5uYU0E2Qt8SMLlq3EjVINV5tQSI/DoHns1EVa+38/+C1USYf5MnpQM+3rt2 ufYgWX67HCHg7b1cv5zXl+6wglXR+AYviMoxOeTX86gc3NA+JqdSRPQN59vxXqq7KX U5vmJ1LI38q/w69DKilRsoaJAm0YCMzzH2lO5MU8= X-Riseup-User-ID: EFB5BE8CF46FC6BEB438CB15B14A13FDA57363C176715DE27564920FCDC610EA Received: from [127.0.0.1] (localhost [127.0.0.1]) by fews1.riseup.net (Postfix) with ESMTPSA id 4PYjVK3t7xz5w5d; Sat, 11 Mar 2023 12:51:53 +0000 (UTC) From: Arthur Grillo To: dri-devel@lists.freedesktop.org Subject: [PATCH v3 0/2] drm/format-helper: Add Kunit tests for drm_fb_xrgb8888_to_mono() Date: Sat, 11 Mar 2023 09:51:39 -0300 Message-Id: <20230311125141.564801-1-arthurgrillo@riseup.net> MIME-Version: 1.0 X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: davidgow@google.com, tales.aparecida@gmail.com, javierm@redhat.com, mairacanal@riseup.net, tzimmermann@suse.de, jose.exposito89@gmail.com, andrealmeid@riseup.net, Arthur Grillo Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" This patchset aims to insert a unit test for the conversion from XRGB8888 to monochromatic. Previously this was a single patch, but as the changes grew from v1 to v2, I thought it would be better to split it in two. Thanks for reviewing! Best regards, ~Arthur Grillo --- v1->v2: https://lore.kernel.org/all/20230302200131.754154-1-arthurgrillo@riseup.net/ - Remove extra helper an use the existing one that Javier patched [1]. - Make the expected results more intuitive by using the BIT macro. - Change the "destination_pitch" test case colors. v2->v3: https://lore.kernel.org/all/20230310200901.216971-1-arthurgrillo@riseup.net/ - Use binary constants instead of the BIT macros, to suppress a warning pointed out by the kernel bot and still maintain the intuitive intention. --- [1]: https://lore.kernel.org/all/20230307215039.346863-1-javierm@redhat.com/ --- Arthur Grillo (2): drm/format-helper: Add Kunit tests for drm_fb_xrgb8888_to_mono() drm/format-helper: Make "destination_pitch" test case usable for the monochrome case .../gpu/drm/tests/drm_format_helper_test.c | 134 +++++++++++++----- 1 file changed, 98 insertions(+), 36 deletions(-)