From patchwork Tue Oct 20 17:42:48 2020 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Fabien Parent X-Patchwork-Id: 11847555 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-9.9 required=3.0 tests=BAYES_00,DKIMWL_WL_HIGH, DKIM_SIGNED,DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,INCLUDES_PATCH, MAILING_LIST_MULTI,SIGNED_OFF_BY,SPF_HELO_NONE,SPF_PASS, UNWANTED_LANGUAGE_BODY,URIBL_BLOCKED,USER_AGENT_GIT autolearn=ham autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id 5AE3FC41604 for ; Tue, 20 Oct 2020 17:44:54 +0000 (UTC) Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id D309B21D6C for ; Tue, 20 Oct 2020 17:44:53 +0000 (UTC) Authentication-Results: mail.kernel.org; dkim=pass (2048-bit key) header.d=lists.infradead.org header.i=@lists.infradead.org header.b="z0mscF8c"; dkim=fail reason="signature verification failed" (2048-bit key) header.d=baylibre-com.20150623.gappssmtp.com header.i=@baylibre-com.20150623.gappssmtp.com header.b="m61n/shu" DMARC-Filter: OpenDMARC Filter v1.3.2 mail.kernel.org D309B21D6C Authentication-Results: mail.kernel.org; dmarc=none (p=none dis=none) header.from=baylibre.com Authentication-Results: mail.kernel.org; spf=none smtp.mailfrom=linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=lists.infradead.org; s=merlin.20170209; h=Sender:Content-Transfer-Encoding: Content-Type:Cc:List-Subscribe:List-Help:List-Post:List-Archive: List-Unsubscribe:List-Id:MIME-Version:References:In-Reply-To:Message-Id:Date: Subject:To:From:Reply-To:Content-ID:Content-Description:Resent-Date: Resent-From:Resent-Sender:Resent-To:Resent-Cc:Resent-Message-ID:List-Owner; bh=0TQRgsP5fdrqbdBaW84sAmQDTbDTv9dBJ59zM4bEdL8=; b=z0mscF8cxIESE63FSVGH97zur C68oUNs0FxwlzE0G9rhp/W20L0VLabIJ49slGOvq/lEVZoYvJ7uDXhdxctP0eOdZNk5Kauat8S9Ci etavRDwO2ZxJxDPY3XYIRAXebizmvKZrzYsZ0FQOkZf6x0JKYirkicE2Ms1xVxvIIwfNX2Hq1oN5/ EbNZy3lZ0xUdM+bBgqTkcOAS8C7dLySsVRe3f7bYmC/Ih1OLUT7rBbWzxWmoyppY9axzinEFml43q 5wHEnQKR+1Zk/SQQNF9t4ZGyJOKHIWAQkLsdxyhmQEnCJF+e+Xd5dBI25GyP4G8SIJDFZv6GgF/kD dLxEZUABQ==; Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvfR-0006ZN-8t; Tue, 20 Oct 2020 17:43:25 +0000 Received: from mail-wm1-x343.google.com ([2a00:1450:4864:20::343]) by merlin.infradead.org with esmtps (Exim 4.92.3 #3 (Red Hat Linux)) id 1kUvf4-0006RO-Uo for linux-arm-kernel@lists.infradead.org; Tue, 20 Oct 2020 17:43:05 +0000 Received: by mail-wm1-x343.google.com with SMTP id f21so2704207wml.3 for ; Tue, 20 Oct 2020 10:43:02 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20150623.gappssmtp.com; s=20150623; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=AJDT7M7U/DertPjHbQd+Y+qplapGoAL1OhIVqnBxURE=; b=m61n/shu260RiFLmYCOqn3vOgiflYZZAgoGSbOU1Gj7R0KO30b1TFe9gEsoSLUR3/V mIvnJJ8cvHNP4vT1ykTljPUZqS5hWNfBRbtkw/BkDXR6U8sAx+e77RFs1huAF1INPkWU OszFMX+4wJr1VMdaQWYHYrrtkUMV2tnU1a+6CO+AJVTCol0l9IwUrpRyUoK7T10ioyqW 7X3L8c6oCQZfEy/Crye6MxZ4Fw17AlwxG72CdHiqGOmJvjnaWW2IpexTquL98PVkgVv1 5SQ3GZzKZ04XwkZISIO3bkpHJqqojqoAwN4Hf4xxpn7g3+9njPeirmkpG75HHzpHZPys f9AA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=AJDT7M7U/DertPjHbQd+Y+qplapGoAL1OhIVqnBxURE=; b=lyayhWPiilgYy8JcZTRugP2IuR9U1+y3oDJSr3eguJOgBbxVxc2JhxGo9EaMhALOqY DwDcQn459NR1hwwn95eadAh2pDZ1sHVaXm4aAAiOdjqzGUwSVyq1+jEugRGsOpwryQ54 W5kCnZUUQjxCMAy4CAqzoDz7QItxNnelWjwNuHb5T8FVshUxJ0uW8y5e9mLmc5Pq1zP9 ZBmr1SkprREoEgAK4AgZznwJ60bFl6m2RuDJg6XeuA0rbgBJjdni2gzxxruplwAZ76lL 3j+0RZO4QMUu4ivfJk611EXqqBYkUqDLF2ZJ1W/zw9PwuCJ7eoLP8n05ESX6bnM23Bq4 rJEw== X-Gm-Message-State: AOAM5300r5OwT2KDbZHUFT67p3FplQBYYAxbC78sdJv87EQJRwDB0rQX UqUjJlxXS18fPplsVfBajTM+6g== X-Google-Smtp-Source: ABdhPJyiJ1X/RENQ6UMwjnjaZvMP64TrGUC2bLTjtsjWwKG9+Q1UUxrR5oo9Xj19HjmItbczgvkGyw== X-Received: by 2002:a05:600c:21d3:: with SMTP id x19mr4078470wmj.170.1603215782078; Tue, 20 Oct 2020 10:43:02 -0700 (PDT) Received: from localhost.localdomain (199.170.185.81.rev.sfr.net. [81.185.170.199]) by smtp.gmail.com with ESMTPSA id v123sm3297756wme.7.2020.10.20.10.43.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 20 Oct 2020 10:43:01 -0700 (PDT) From: Fabien Parent To: linux-mediatek@lists.infradead.org, linux-arm-kernel@lists.infradead.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org Subject: [PATCH 3/8] drm/mediatek: add disp-color MT8167 support Date: Tue, 20 Oct 2020 19:42:48 +0200 Message-Id: <20201020174253.3757771-4-fparent@baylibre.com> X-Mailer: git-send-email 2.28.0 In-Reply-To: <20201020174253.3757771-1-fparent@baylibre.com> References: <20201020174253.3757771-1-fparent@baylibre.com> MIME-Version: 1.0 X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20201020_134303_015194_A7477E26 X-CRM114-Status: GOOD ( 13.09 ) X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: chunkuang.hu@kernel.org, daniel@ffwll.ch, airlied@linux.ie, Fabien Parent , robh+dt@kernel.org, p.zabel@pengutronix.de, matthias.bgg@gmail.com Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+linux-arm-kernel=archiver.kernel.org@lists.infradead.org Add support for disp-color on MT8167 SoC. Signed-off-by: Fabien Parent Reviewed-by: Chun-Kuang Hu --- drivers/gpu/drm/mediatek/mtk_disp_color.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/drivers/gpu/drm/mediatek/mtk_disp_color.c b/drivers/gpu/drm/mediatek/mtk_disp_color.c index 3ae9c810845b..a1227cefbf31 100644 --- a/drivers/gpu/drm/mediatek/mtk_disp_color.c +++ b/drivers/gpu/drm/mediatek/mtk_disp_color.c @@ -16,6 +16,7 @@ #define DISP_COLOR_CFG_MAIN 0x0400 #define DISP_COLOR_START_MT2701 0x0f00 +#define DISP_COLOR_START_MT8167 0x0400 #define DISP_COLOR_START_MT8173 0x0c00 #define DISP_COLOR_START(comp) ((comp)->data->color_offset) #define DISP_COLOR_WIDTH(comp) (DISP_COLOR_START(comp) + 0x50) @@ -148,6 +149,10 @@ static const struct mtk_disp_color_data mt2701_color_driver_data = { .color_offset = DISP_COLOR_START_MT2701, }; +static const struct mtk_disp_color_data mt8167_color_driver_data = { + .color_offset = DISP_COLOR_START_MT8167, +}; + static const struct mtk_disp_color_data mt8173_color_driver_data = { .color_offset = DISP_COLOR_START_MT8173, }; @@ -155,6 +160,8 @@ static const struct mtk_disp_color_data mt8173_color_driver_data = { static const struct of_device_id mtk_disp_color_driver_dt_match[] = { { .compatible = "mediatek,mt2701-disp-color", .data = &mt2701_color_driver_data}, + { .compatible = "mediatek,mt8167-disp-color", + .data = &mt8167_color_driver_data}, { .compatible = "mediatek,mt8173-disp-color", .data = &mt8173_color_driver_data}, {},