Received: by 2002:a05:6512:3d0e:0:0:0:0 with SMTP id d14csp9558lfv; Tue, 12 Apr 2022 15:08:12 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyL2mKF3zCMGbVSoCrCS3uYftfXAsPiMP5DSTE1KaZ9BRFr/B9HYmvVtk402/1I60A+wHT1 X-Received: by 2002:a05:6a00:983:b0:505:d929:b135 with SMTP id u3-20020a056a00098300b00505d929b135mr8557034pfg.25.1649801292512; Tue, 12 Apr 2022 15:08:12 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1649801292; cv=none; d=google.com; s=arc-20160816; b=e2OdZdZHF83yC084BuugfXbwmeeF1IqxGuQw3bfwGXc0P8H8gMFvkqX8HbXxoHQBzJ qGVanfrWgQ2UILGWNrgsG3/yZtGpFkIPLI392HHEewbfMJSq1lcBIWOXur0LJLBCv6g6 OO/5gLlOhfFegaDErhc26AT8wEg5FAv3v/3l4yvuK58JbzmUCIrj2FsgRD2zO4XFhEg3 d6d0nHkyQitqMM0tovB0LxRBo2DTJYPPtiHFdU4VDwLhzGxfkMua5k6rphivvwt0sArj iWXmwSKLurfFhOh4pAlARMMjqGjD+Iz2/5WqdsE3BxbAgBiXVOa6bY//Rb1f3P/9T2oJ PWsw== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:cc:to:subject:message-id:date:mime-version :in-reply-to:references:user-agent:from:dkim-signature; bh=/ZyCaP2T/2VrJe6ALq1EyhIHOZkvGaqGD4xWXLAeHqk=; b=fv3hpPREIDpITRb5U7J1tgUuc39cT25M5g+rc6+Le/CgW/ttSmFK/4IxRljWK8T94u NKYbJGPLqvyyeqRCrh5AAxhY761rGZYpUm7PhVnVokqnKoDYUOqYfI9+ZfnTCuXtCveB V/pFawF5JIYSLs9HLnbN/5G346GVsmxoQxj7k/gOjSSQ19pytV/b+gUzW2e3NHAiDfA/ XDx56Njm+s9YhO/omz/+2K6ho/A0QHJGEznhnxBt3egj8roIaV6KXXZBVtNeuo/6IPLq z3bNdXpObkK7dCcqsDuAJD1eNwQpqmi9Jf1qg89iMe7Ej09W1DoTqNJQzYTP1Fq9/frX itHA== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@baylibre-com.20210112.gappssmtp.com header.s=20210112 header.b=o87hejcB; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from lindbergh.monkeyblade.net (lindbergh.monkeyblade.net. [23.128.96.19]) by mx.google.com with ESMTPS id h18-20020a056a001a5200b004fa3a8e0066si12951589pfv.285.2022.04.12.15.08.00 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 12 Apr 2022 15:08:12 -0700 (PDT) Received-SPF: softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) client-ip=23.128.96.19; Authentication-Results: mx.google.com; dkim=pass header.i=@baylibre-com.20210112.gappssmtp.com header.s=20210112 header.b=o87hejcB; spf=softfail (google.com: domain of transitioning linux-kernel-owner@vger.kernel.org does not designate 23.128.96.19 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: from vger.kernel.org (vger.kernel.org [23.128.96.18]) by lindbergh.monkeyblade.net (Postfix) with ESMTP id D7E0716AA6E; Tue, 12 Apr 2022 13:58:55 -0700 (PDT) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S235905AbiDLLU0 (ORCPT + 99 others); Tue, 12 Apr 2022 07:20:26 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:58844 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1353429AbiDLLSl (ORCPT ); Tue, 12 Apr 2022 07:18:41 -0400 Received: from mail-oi1-x231.google.com (mail-oi1-x231.google.com [IPv6:2607:f8b0:4864:20::231]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id AA36C98F4F for ; Tue, 12 Apr 2022 03:03:57 -0700 (PDT) Received: by mail-oi1-x231.google.com with SMTP id 12so18473978oix.12 for ; Tue, 12 Apr 2022 03:03:57 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20210112.gappssmtp.com; s=20210112; h=from:user-agent:references:in-reply-to:mime-version:date:message-id :subject:to:cc; bh=/ZyCaP2T/2VrJe6ALq1EyhIHOZkvGaqGD4xWXLAeHqk=; b=o87hejcBHI3HtMx/kT2Zok9kZB5byZSfOS/ff8a6ScbRybRTQS+g+TBJsVtUUdl06p Ew1vCmSYTQ/GtDq/X6StyyvV7iAfgl9+dSU00ezQaWRVSWgXVkv5EVLj7xCsYmR0M+V5 mRDgC3b1d/yVk7mZ+r4/7RFReTdSRY+Y8z8ll5M9aiZmMytTwEMWkpFgJq1a4kLZlwWb u5lcjUJ0o0tU/8Yuiowj/xyUSeuvbsK4hzgLcl8/doDyxx6lwZXy6y+3GkxclqOcD3Sx HRlwwBM0TXozoMMJeMIeLMM8DjDqlpKuTI3RgEX+mzX+ehWuwQT8pPMdneSq+Pt11IeQ cOaA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=x-gm-message-state:from:user-agent:references:in-reply-to :mime-version:date:message-id:subject:to:cc; bh=/ZyCaP2T/2VrJe6ALq1EyhIHOZkvGaqGD4xWXLAeHqk=; b=e7w5pqBv7spwNYYXQ+BT9tJlxFo58YfGLWcofDL7Hf9htuN6D7wOKhvCkvGkv2dSrj PdU5N0Kaecuj1+2lMa3aV7ZTBpcFJF3h01vobTg+OS9KZSD511q2nlpSLahhY8GN2rho p4HG6XYnp6GiF7VrmsTYNd+kIhUmOLr3GOct5OIv8HXL8PvqVRC1Rfwne6xwKCm2FH83 wobejz1nz9WItjZEEecX/gqISXLaRJX7n1fXeMstv20dgdfZi9k631AFpEeQX8jhB+vO 58DXTh6HxUpa5UBUHftEYe0DzaTvMgKxV2XMekfqPkpa3Cg4h8TSYtwBHC4zQKrXGITl lpIw== X-Gm-Message-State: AOAM532KG7E6odyrYO0toDH5pFdXLKDcNKpxyye8lxBq2bZ2kg3ppN6i z3hfV5hy7IMJrCm66fi3PHyxoh2GIi+thq0p+o3jTw== X-Received: by 2002:a05:6808:159d:b0:2da:3946:ab3d with SMTP id t29-20020a056808159d00b002da3946ab3dmr1332889oiw.248.1649757836383; Tue, 12 Apr 2022 03:03:56 -0700 (PDT) Received: from 753933720722 named unknown by gmailapi.google.com with HTTPREST; Tue, 12 Apr 2022 03:03:55 -0700 From: Guillaume Ranquet User-Agent: meli 0.7.2 References: <20220327223927.20848-1-granquet@baylibre.com> <20220327223927.20848-19-granquet@baylibre.com> <2d0dd2f60e2b1e58ed4008212260e980edbd7cdc.camel@mediatek.com> In-Reply-To: <2d0dd2f60e2b1e58ed4008212260e980edbd7cdc.camel@mediatek.com> MIME-Version: 1.0 Date: Tue, 12 Apr 2022 03:03:55 -0700 Message-ID: Subject: Re: [PATCH v9 18/22] drm/mediatek: Add mt8195 Embedded DisplayPort driver To: Rex-BC Chen , vkoul@kernel.org, airlied@linux.ie, angelogioacchino.delregno@collabora.com, chunfeng.yun@mediatek.com, chunkuang.hu@kernel.org, ck.hu@mediatek.com, daniel@ffwll.ch, deller@gmx.de, jitao.shi@mediatek.com, kishon@ti.com, krzk+dt@kernel.org, maarten.lankhorst@linux.intel.com, matthias.bgg@gmail.com, mripard@kernel.org, p.zabel@pengutronix.de, robh+dt@kernel.org, tzimmermann@suse.de Cc: devicetree@vger.kernel.org, dri-devel@lists.freedesktop.org, linux-arm-kernel@lists.infradead.org, linux-fbdev@vger.kernel.org, linux-kernel@vger.kernel.org, linux-mediatek@lists.infradead.org, linux-phy@lists.infradead.org, markyacoub@google.com, Markus Schneider-Pargmann , kernel test robot Content-Type: text/plain; charset="UTF-8" X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00,DKIM_SIGNED, DKIM_VALID,HEADER_FROM_DIFFERENT_DOMAINS,MAILING_LIST_MULTI,RDNS_NONE, SPF_HELO_NONE,T_SCC_BODY_TEXT_LINE autolearn=no autolearn_force=no version=3.4.6 X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on lindbergh.monkeyblade.net Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Tue, 29 Mar 2022 07:41, Rex-BC Chen wrote: >Hello Guillaume, > >Thanks for your patch. >I add some comments below: > >On Mon, 2022-03-28 at 00:39 +0200, Guillaume Ranquet wrote: >> From: Markus Schneider-Pargmann >> >> This patch adds a DisplayPort driver for the Mediatek mt8195 SoC. >> >> It supports the mt8195, the embedded DisplayPort units. It offers >> DisplayPort 1.4 with up to 4 lanes. >> >> The driver shares its iomap range with the mtk-dp-phy driver using >> the regmap/syscon facility. >> >> This driver is based on an initial version by >> Jason-JH.Lin . >> >> Signed-off-by: Markus Schneider-Pargmann >> Signed-off-by: Guillaume Ranquet >> Reported-by: kernel test robot >> --- >> drivers/gpu/drm/mediatek/Kconfig | 8 + >> drivers/gpu/drm/mediatek/Makefile | 2 + >> drivers/gpu/drm/mediatek/mtk_dp.c | 2221 >> ++++++++++++++++++++++++ >> drivers/gpu/drm/mediatek/mtk_dp_reg.h | 568 ++++++ >> drivers/gpu/drm/mediatek/mtk_drm_drv.c | 1 + >> drivers/gpu/drm/mediatek/mtk_drm_drv.h | 1 + >> 6 files changed, 2801 insertions(+) >> create mode 100644 drivers/gpu/drm/mediatek/mtk_dp.c >> create mode 100644 drivers/gpu/drm/mediatek/mtk_dp_reg.h >> >> diff --git a/drivers/gpu/drm/mediatek/Kconfig >> b/drivers/gpu/drm/mediatek/Kconfig >> index 2976d21e9a34..03ffa9b896c3 100644 >> --- a/drivers/gpu/drm/mediatek/Kconfig >> +++ b/drivers/gpu/drm/mediatek/Kconfig >> @@ -28,3 +28,11 @@ config DRM_MEDIATEK_HDMI >> select PHY_MTK_HDMI >> help >> DRM/KMS HDMI driver for Mediatek SoCs >> + >> +config MTK_DPTX_SUPPORT >> + tristate "DRM DPTX Support for Mediatek SoCs" >> + depends on DRM_MEDIATEK >> + select PHY_MTK_DP >> + select DRM_DP_HELPER >> + help >> + DRM/KMS Display Port driver for Mediatek SoCs. >> diff --git a/drivers/gpu/drm/mediatek/Makefile >> b/drivers/gpu/drm/mediatek/Makefile >> index 29098d7c8307..d86a6406055e 100644 >> --- a/drivers/gpu/drm/mediatek/Makefile >> +++ b/drivers/gpu/drm/mediatek/Makefile >> @@ -21,3 +21,5 @@ mediatek-drm-hdmi-objs := mtk_cec.o \ >> mtk_hdmi_ddc.o >> >> obj-$(CONFIG_DRM_MEDIATEK_HDMI) += mediatek-drm-hdmi.o >> + >> +obj-$(CONFIG_MTK_DPTX_SUPPORT) += mtk_dp.o >> diff --git a/drivers/gpu/drm/mediatek/mtk_dp.c >> b/drivers/gpu/drm/mediatek/mtk_dp.c >> new file mode 100644 >> index 000000000000..7cd8459cf719 >> --- /dev/null >> +++ b/drivers/gpu/drm/mediatek/mtk_dp.c >> @@ -0,0 +1,2221 @@ >> +// SPDX-License-Identifier: GPL-2.0 >> +/* >> + * Copyright (c) 2019 MediaTek Inc. >> + * Copyright (c) 2021 BayLibre >> + */ >> + >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include >> +#include