From patchwork Tue Oct 15 10:30:19 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Hsin-Te Yuan X-Patchwork-Id: 13836115 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 bombadil.infradead.org (bombadil.infradead.org [198.137.202.133]) (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 533FFCFC287 for ; Tue, 15 Oct 2024 10:32:08 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=bombadil.20210309; h=Sender:List-Subscribe:List-Help :List-Post:List-Archive:List-Unsubscribe:List-Id:Cc:To:Message-Id: Content-Transfer-Encoding:Content-Type:MIME-Version:Subject:Date:From: Reply-To:Content-ID:Content-Description:Resent-Date:Resent-From:Resent-Sender :Resent-To:Resent-Cc:Resent-Message-ID:In-Reply-To:References:List-Owner; bh=V2rr896UjJZIJvHhd5U5Pr+M2ve1yVZw4BPOf1jkh5k=; b=w0v0wvyT8aWoc9GxLMcZjvDd0D 3LT41soKPuCZjKteaaboX0NTgwkFg4Si9bXXhdETbJHExWw/+ykD+A7gL4DRNPWfrfrHIe+Gpcqln bgpMg6kXIH2OxP1JFq9OK3+DQQTF2k0XMpTb6Q6Y1hNl13QR8iDvnAp055ovTd5kzajmwAztOmgyL +m6Ku8dayTbWJ6nH0Spuy2qdHWkKBl/l/xebMB/JOolY6DKKeYl7BQpVaK4VoruoH3kJp4ju40OrU El52qtozCUzsAhSmT19bVcgaFxUdVzz5RIob8bL5cOhNT8g9QEDhNURe/nCcZE5KiqtiCC5wyHziD /spHOjgQ==; Received: from localhost ([::1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.98 #2 (Red Hat Linux)) id 1t0eqJ-00000007qmB-3ZkI; Tue, 15 Oct 2024 10:31:56 +0000 Received: from mail-pf1-x436.google.com ([2607:f8b0:4864:20::436]) by bombadil.infradead.org with esmtps (Exim 4.98 #2 (Red Hat Linux)) id 1t0eor-00000007qNE-1KJj for linux-arm-kernel@lists.infradead.org; Tue, 15 Oct 2024 10:30:27 +0000 Received: by mail-pf1-x436.google.com with SMTP id d2e1a72fcca58-71e5b2814f6so1899603b3a.2 for ; Tue, 15 Oct 2024 03:30:24 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=chromium.org; s=google; t=1728988224; x=1729593024; darn=lists.infradead.org; h=cc:to:message-id:content-transfer-encoding:mime-version:subject :date:from:from:to:cc:subject:date:message-id:reply-to; bh=V2rr896UjJZIJvHhd5U5Pr+M2ve1yVZw4BPOf1jkh5k=; b=ZFua6kT3RZVij3fmgr+gfKqLvC8e9zsAs5NysdWdX3zcII720fxHtYt3TYSCLe/9Kh RtjDk1+2VZKe3x3NCJdTDz70Bj0T784yq7tnEjIjrt6r5/EcQmI71RUqdmU7oUOfq8cR UnZVDPhGxieQeAgFZU0UBh5odpUP/c8qPXHQU= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1728988224; x=1729593024; h=cc:to:message-id:content-transfer-encoding:mime-version:subject :date:from:x-gm-message-state:from:to:cc:subject:date:message-id :reply-to; bh=V2rr896UjJZIJvHhd5U5Pr+M2ve1yVZw4BPOf1jkh5k=; b=or+uinPRcBExJ1lyGxj64PwhtubY+4z0AJ7jTq9/n/OXO4snmoGsuCJRuL9+I33E0P udMOBBgrCnVdqyBqg+GSXV3mYgSwl+5dzwcyus8hek/3P3r/hbayxiFO1rWXcj2igeo+ 8KCCmHu92e2plQVJFD8yssiF/GFOoJCifjwLroB58F/2DzsT6wKGauHguUNIoBCf5ntR bOZCVDQq7yABBUGF6e97NWH9mOOO4zF+omYSw9gA5mBBFaeDbW+Qm1y8CvZ3XRjmqg/Q +4ztAZvDg9hR0n80nde4M4/MGFUAtDjeciaxvjRIYwRNOvH6tqWaFYLZyel9q6u0ZhoA A3dg== X-Forwarded-Encrypted: i=1; AJvYcCV4jrufQrpk5Jegx5GdcFtd9AzMg5p7bDRGbD0bqJOS/daRy6yPuxRSZt9x3YF/pbdsy/04JqHxI9cvTUwAAiEk@lists.infradead.org X-Gm-Message-State: AOJu0Yww1T9/RdDpCdhOhuljkgWy0smXXNHRkCd+0EUTJ9VrGDhNIltn C2jJsNLhAGoE7ZfqY5ngrytvTo6ifmhNI+3yXU3zV/ndd/vm7+mxSt6PcSBa/A== X-Google-Smtp-Source: AGHT+IFkLsd54kJuLGI+OOJF3TglxLq80CdGHR32sS02YQTnE9EsV0U9q3MfLsv+EAG7yVeyofCtWw== X-Received: by 2002:a05:6a00:4b12:b0:71e:6c65:e7c4 with SMTP id d2e1a72fcca58-71e6c65e883mr5595571b3a.26.1728988223751; Tue, 15 Oct 2024 03:30:23 -0700 (PDT) Received: from yuanhsinte.c.googlers.com (176.220.194.35.bc.googleusercontent.com. [35.194.220.176]) by smtp.gmail.com with ESMTPSA id d2e1a72fcca58-71e77370dfdsm946011b3a.42.2024.10.15.03.30.21 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 15 Oct 2024 03:30:23 -0700 (PDT) From: Hsin-Te Yuan Date: Tue, 15 Oct 2024 10:30:19 +0000 Subject: [PATCH] drm/mediatek: Fix color format MACROs in OVL MIME-Version: 1.0 Message-Id: <20241015-color-v1-1-35b01fa0a826@chromium.org> X-B4-Tracking: v=1; b=H4sIADpEDmcC/6tWKk4tykwtVrJSqFYqSi3LLM7MzwNyDHUUlJIzE vPSU3UzU4B8JSMDIxNDA0NT3eT8nPwi3VQjA9NUc9MkM5PERCWg2oKi1LTMCrA50bG1tQBJIzI UVwAAAA== X-Change-ID: 20241015-color-e205e75b64aa To: Chun-Kuang Hu , Philipp Zabel , David Airlie , Simona Vetter , Matthias Brugger , AngeloGioacchino Del Regno Cc: dri-devel@lists.freedesktop.org, linux-mediatek@lists.infradead.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org, dianders@chromium.org, Hsin-Te Yuan X-Mailer: b4 0.15-dev-7be4f X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20241015_033025_374699_46DF5AE3 X-CRM114-Status: GOOD ( 12.55 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.34 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org In commit 9f428b95ac89 ("drm/mediatek: Add new color format MACROs in OVL"), some new color formats are defined in the MACROs to make the switch statement more concise. However, there are typos in these formats MACROs, which cause the return value to be incorrect. Fix the typos to ensure the return value remains unchanged. Fix: 9f428b95ac89 ("drm/mediatek: Add new color format MACROs in OVL") Signed-off-by: Hsin-Te Yuan Reviewed-by: Douglas Anderson --- drivers/gpu/drm/mediatek/mtk_disp_ovl.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) --- base-commit: 75b607fab38d149f232f01eae5e6392b394dd659 change-id: 20241015-color-e205e75b64aa Best regards, diff --git a/drivers/gpu/drm/mediatek/mtk_disp_ovl.c b/drivers/gpu/drm/mediatek/mtk_disp_ovl.c index 89b439dcf3a6af9f5799487fdc0f128a9b5cbe4a..1632ac5c23d87e1cdc41013a9cf7864728dcb63b 100644 --- a/drivers/gpu/drm/mediatek/mtk_disp_ovl.c +++ b/drivers/gpu/drm/mediatek/mtk_disp_ovl.c @@ -65,8 +65,8 @@ #define OVL_CON_CLRFMT_RGB (1 << 12) #define OVL_CON_CLRFMT_ARGB8888 (2 << 12) #define OVL_CON_CLRFMT_RGBA8888 (3 << 12) -#define OVL_CON_CLRFMT_ABGR8888 (OVL_CON_CLRFMT_RGBA8888 | OVL_CON_BYTE_SWAP) -#define OVL_CON_CLRFMT_BGRA8888 (OVL_CON_CLRFMT_ARGB8888 | OVL_CON_BYTE_SWAP) +#define OVL_CON_CLRFMT_ABGR8888 (OVL_CON_CLRFMT_ARGB8888 | OVL_CON_BYTE_SWAP) +#define OVL_CON_CLRFMT_BGRA8888 (OVL_CON_CLRFMT_RGBA8888 | OVL_CON_BYTE_SWAP) #define OVL_CON_CLRFMT_UYVY (4 << 12) #define OVL_CON_CLRFMT_YUYV (5 << 12) #define OVL_CON_MTX_YUV_TO_RGB (6 << 16)