Received: by 2002:a05:6a10:f3d0:0:0:0:0 with SMTP id a16csp158032pxv; Thu, 24 Jun 2021 05:13:35 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyh1F2Uco0vUTqYZLO3xGo7zlD5H8i/zXuERbbYLxoMXW+KSwW6QVU+YQ/AQr/SerXjp/AG X-Received: by 2002:aa7:d60a:: with SMTP id c10mr6583971edr.369.1624536814965; Thu, 24 Jun 2021 05:13:34 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1624536814; cv=none; d=google.com; s=arc-20160816; b=lSbu+IDM+ryKEtzA/1nJT9R3zjeOM12h4kgRtFYMOP3usQfzJ6o7tq6n+HkorPll2z ae0fEKD4CyCGjoiVE7hCZXjfz/ukit7Prg+tG6JcsQaFgM/O0VEFE2fBg1UdX6m82yWg yQgKf8dJzzALdgOXEVzBPyQLC4kj+QgV3886t6t32jES3SvVjnNARO5jSfk8qCnCxKBI F6SKfqS/KFGWh6ydorRNUP+HINGXlltmYugs8/4V795cEzByLt+fYUshiy33CdgzaKNr GczU9ozPxKGOIjde6MibCLeqSUOxtfnZIaLC1Ocvf72lmUmalaYncHnHCUKxX2OlLeim Gu4w== 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:from:in-reply-to :references:mime-version:dkim-signature; bh=Hl72FS2y9n4jB9a1L7Hg43gY2B5zO77yYR8Igj/hYDI=; b=eXnKBF0oBgI0bxezy73U6COi1LGN6gBdF0b1W4UV7PVky3r5Sl5CKmC8IyVccm4F3v ZaGFIao4LY9AoS0ND/X6AVmCZqIxity9/w4GVLmkoD1/psYiKLHDVhKGhe9BklrBDMNi oeHTcWgjd99Cvpm+KDis1wxKSW33eoK4iDk+DP/hyCYuS+bp8Cqo1uhd1XZR1uo1zz6R gPJzSAU69NDN12g0ulgdKd15yVhXKfrwDL/TBEq7ysOF84Al1YHviHivEwVSLhCMa9pI rNHkOCdc5PlP1TRiporxBpaj2RNvV4awWmNS5mF3hZvxH7n+uL6BqqXVeaUnBilLz8q6 WB2Q== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=Nf6mocvX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id ig2si2447657ejc.605.2021.06.24.05.13.12; Thu, 24 Jun 2021 05:13:34 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@amarulasolutions.com header.s=google header.b=Nf6mocvX; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S230454AbhFXMNs (ORCPT + 99 others); Thu, 24 Jun 2021 08:13:48 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:40886 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230330AbhFXMNr (ORCPT ); Thu, 24 Jun 2021 08:13:47 -0400 Received: from mail-ed1-x536.google.com (mail-ed1-x536.google.com [IPv6:2a00:1450:4864:20::536]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id B9C6AC061574 for ; Thu, 24 Jun 2021 05:11:27 -0700 (PDT) Received: by mail-ed1-x536.google.com with SMTP id q14so8193545eds.5 for ; Thu, 24 Jun 2021 05:11:27 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; h=mime-version:references:in-reply-to:from:date:message-id:subject:to :cc; bh=Hl72FS2y9n4jB9a1L7Hg43gY2B5zO77yYR8Igj/hYDI=; b=Nf6mocvXO8NeZN8KVnMZdEwN0VGtlu+nF63Hc3crZMEB2Pa88argC2qEH737O17A8t Mdt8H36DcAhBkk3FQNKViV8IKxUqV0Uj3qixjwf2n9qZmfcXTn7QQe/u3gVFOFrcQry8 0ckG508FS/iQx+qUUVHHJn4RFaUABamSFqZWc= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:mime-version:references:in-reply-to:from:date :message-id:subject:to:cc; bh=Hl72FS2y9n4jB9a1L7Hg43gY2B5zO77yYR8Igj/hYDI=; b=f74FKEvFNoXzNkNNuruliTPF3KbPkjKok5nv+uIrxtE/1FM/v3c+83agV0SAjxrGdP AUAYXvybOmDGcCeCOzrc/VHR5Y2k+iUQ/CJ6XD2bqbatuLubzmZ4ddU8MKoFEtura1jh z9OTPAOx2YQOwRJUnY58EejAQUmidtXOpQBWnBQmCFNnJzyWQtlkyDXwdoaP9WVIohQE tPP9UhPIYaxguRDcTt3z178j6NCp7W7GxCWqsbtBq3fVt317LuG/t/Ya9J5OW4IBZukM DS8RfuiGAncXws6iKmA83vgGitVgXGk/Fa75Qy3j4FQQ2NSUdWm+QCey0oG5MAepic0N d/hw== X-Gm-Message-State: AOAM532KNnXhgeJmdgcFu9EHiSCAqpQVx3zSZ6hUNgKzKXEOpqfdkks0 ig4bLPvyhQJk3sV6SNCveQkeuvAetBECxlfDCPdHMw== X-Received: by 2002:aa7:cf03:: with SMTP id a3mr6764586edy.27.1624536686322; Thu, 24 Jun 2021 05:11:26 -0700 (PDT) MIME-Version: 1.0 References: <20210621072424.111733-1-jagan@amarulasolutions.com> <20210621072424.111733-3-jagan@amarulasolutions.com> In-Reply-To: From: Jagan Teki Date: Thu, 24 Jun 2021 17:41:14 +0530 Message-ID: Subject: Re: [RFC PATCH 2/9] drm: bridge: Add Samsung SEC MIPI DSIM bridge driver To: Laurent Pinchart Cc: Peng Fan , Shawn Guo , Sascha Hauer , Tomasz Figa , Fancy Fang , devicetree , Francis Laniel , Matteo Lisi , Neil Armstrong , Robert Foss , linux-kernel , dri-devel , Andrzej Hajda , NXP Linux Team , Milco Pratesi , Anthony Brandon , linux-phy@lists.infradead.org, linux-amarula , linux-arm-kernel Content-Type: text/plain; charset="UTF-8" Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Hi Laurent, On Thu, Jun 24, 2021 at 3:53 AM Laurent Pinchart wrote: > > Hi Jagan, > > Thank you for the patch. > > On Mon, Jun 21, 2021 at 12:54:17PM +0530, Jagan Teki wrote: > > Samsung SEC MIPI DSIM Bridge controller is MIPI DSI bridge > > available in NXP's i.MX8M Mini and Nano Processors. > > > > Add bridge driver for it. > > > > Cc: Andrzej Hajda > > Cc: Neil Armstrong > > Cc: Robert Foss > > Cc: Laurent Pinchart > > Signed-off-by: Jagan Teki > > --- > > drivers/gpu/drm/bridge/Kconfig | 15 + > > drivers/gpu/drm/bridge/Makefile | 1 + > > drivers/gpu/drm/bridge/sec-dsim.c | 1535 +++++++++++++++++++++++++++++ > > 3 files changed, 1551 insertions(+) > > create mode 100644 drivers/gpu/drm/bridge/sec-dsim.c > > > > diff --git a/drivers/gpu/drm/bridge/Kconfig b/drivers/gpu/drm/bridge/Kconfig > > index 19109c0b5481..a183eb165a35 100644 > > --- a/drivers/gpu/drm/bridge/Kconfig > > +++ b/drivers/gpu/drm/bridge/Kconfig > > @@ -189,6 +189,21 @@ config DRM_PARADE_PS8640 > > The PS8640 is a high-performance and low-power > > MIPI DSI to eDP converter > > > > +config DRM_SEC_MIPI_DSIM > > + tristate "Samsung SEC MIPI DSIM Bridge controller" > > + depends on DRM > > + depends on COMMON_CLK > > + depends on OF && HAS_IOMEM > > + select DRM_KMS_HELPER > > + select DRM_MIPI_DSI > > + select DRM_PANEL_BRIDGE > > + select GENERIC_PHY_MIPI_DPHY > > + select MFD_SYSCON > > + select REGMAP_MMIO > > + help > > + This enables the Samsung SEC MIPI DSIM Bridge controller as > > + for example found on NXP's i.MX8M Mini and Nano Processors. > > + > > config DRM_SIL_SII8620 > > tristate "Silicon Image SII8620 HDMI/MHL bridge" > > depends on OF > > diff --git a/drivers/gpu/drm/bridge/Makefile b/drivers/gpu/drm/bridge/Makefile > > index 88e4edf81087..ff802a4ffe65 100644 > > --- a/drivers/gpu/drm/bridge/Makefile > > +++ b/drivers/gpu/drm/bridge/Makefile > > @@ -12,6 +12,7 @@ obj-$(CONFIG_DRM_MEGACHIPS_STDPXXXX_GE_B850V3_FW) += megachips-stdpxxxx-ge-b850v > > obj-$(CONFIG_DRM_NXP_PTN3460) += nxp-ptn3460.o > > obj-$(CONFIG_DRM_PARADE_PS8622) += parade-ps8622.o > > obj-$(CONFIG_DRM_PARADE_PS8640) += parade-ps8640.o > > +obj-$(CONFIG_DRM_SEC_MIPI_DSIM) += sec-dsim.o > > obj-$(CONFIG_DRM_SIL_SII8620) += sil-sii8620.o > > obj-$(CONFIG_DRM_SII902X) += sii902x.o > > obj-$(CONFIG_DRM_SII9234) += sii9234.o > > diff --git a/drivers/gpu/drm/bridge/sec-dsim.c b/drivers/gpu/drm/bridge/sec-dsim.c > > new file mode 100644 > > index 000000000000..5b6645bb94e7 > > --- /dev/null > > +++ b/drivers/gpu/drm/bridge/sec-dsim.c > > @@ -0,0 +1,1535 @@ > > +// SPDX-License-Identifier: GPL-2.0-only > > +/* > > + * Samsung SEC MIPI DSIM Bridge > > + * > > + * Copyright (C) 2018 NXP > > + * Copyright (c) 2014 Samsung Electronics Co., Ltd > > + * Copyright (C) 2021 Amarula Solutions(India) > > + * > > + * Based on the drivers/gpu/drm/exynos/exynos_drm_dsi.c > > + * > > + * Authors: > > + * Tomasz Figa > > + * Andrzej Hajda > > + * Fancy Fang > > + * Jagan Teki > > + */ > > + > > +#include > > +#include > > +#include > > +#include > > +#include > > +#include > > +#include > > +#include > > +#include > > +#include > > + > > +#include > > +#include > > +#include > > +#include > > +#include > > +#include > > + > > +#include