Received: by 2002:ab2:1149:0:b0:1f3:1f8c:d0c6 with SMTP id z9csp2334875lqz; Tue, 2 Apr 2024 14:18:32 -0700 (PDT) X-Forwarded-Encrypted: i=3; AJvYcCVw3GzfPKW4Fj49zoFWue2oTsApHjaA9A1rdveMt8GTAS1n3l8OM/wP7RHxxFIrxA3/fAzVfc9SQ5Bwbkp7GbdSyOJvEvYUsU+yoTTW5Q== X-Google-Smtp-Source: AGHT+IFliai8f2VioE/T6/9FtXHUBP+lg5TQL5mhYt76Y2fnpnIf5VdHYv04BNWvktFU4YYcZt1U X-Received: by 2002:a05:6a00:39a3:b0:6ea:c15d:9916 with SMTP id fi35-20020a056a0039a300b006eac15d9916mr14570497pfb.32.1712092712471; Tue, 02 Apr 2024 14:18:32 -0700 (PDT) ARC-Seal: i=2; a=rsa-sha256; t=1712092712; cv=pass; d=google.com; s=arc-20160816; b=BDZs1IuilkBpOVBD94m5X2mrj49TYNaPz9Im4I2ghT7ctl1n65O42qCV0dz2uY5jHt FVcbGijQ2VKb0NtCWRKKrBlvMSdYvSejNNNazTbnYCPyh3FGEy3C02eK2XjSvej6yKbs Zsssf2W5bhDg4TFSGNItcd86IYQiAbRAnOHXaw1bVNtsBCEOVJE8/gXKIEfuV8vu9J2L BXQOIb892goFX8HjiFU/mvSWAvyMTXtH9XP/0EEqzbi/iQJod70neiO8zMXnE4hVdxaP VbW0SSO4PEegtqN7H/Yhap/R5b02rsEmTV4Knf2hjrbFLagupjiQDKzIszurNQ8Bnxw0 sunA== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date; bh=t6yN97ZbxMb0RnbwJlZNeQuZo8UViSP6oe4PGJOxT2M=; fh=VyAv4MXqqCUVajaTa91XNW3HtMLtv/8y1MWp72AOgns=; b=s1D2CYm6BSe7euOrGO1rDj6d/p9MPW/wKVVamCT7BBX8h5W2KRfSXkmXn7P0Dfpg46 ibL5tzLylKrAJpXPq1GmJL7p4DX1KieqS3ErbJj4KnJlLCHjh88I4KRDP5VnAYKi11f6 AO+KTXTM5tgkr7X039Wz62aQ5p/YZW1CXC0QUIfwNDb0OK87XbEcxhl6fZPvpyMKKS57 28B/5vWwuNHnQcai1xetDDpvI5cabaG/es+wuR/0nddi/Uuzid8NNQ92lYc08dTPg5mI pbHQoQafK10tmZE50DlgjfEnphIysYghqHZj5qIAAu98RGjy45xWTSb82shrZIsqK/mw FqKA==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; arc=pass (i=1 spf=pass spfdomain=somainline.org); spf=pass (google.com: domain of linux-kernel+bounces-128717-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-128717-linux.lists.archive=gmail.com@vger.kernel.org" Return-Path: Received: from sv.mirrors.kernel.org (sv.mirrors.kernel.org. [2604:1380:45e3:2400::1]) by mx.google.com with ESMTPS id n1-20020aa79841000000b006e69b04677asi11663762pfq.28.2024.04.02.14.18.32 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 02 Apr 2024 14:18:32 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel+bounces-128717-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) client-ip=2604:1380:45e3:2400::1; Authentication-Results: mx.google.com; arc=pass (i=1 spf=pass spfdomain=somainline.org); spf=pass (google.com: domain of linux-kernel+bounces-128717-linux.lists.archive=gmail.com@vger.kernel.org designates 2604:1380:45e3:2400::1 as permitted sender) smtp.mailfrom="linux-kernel+bounces-128717-linux.lists.archive=gmail.com@vger.kernel.org" Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sv.mirrors.kernel.org (Postfix) with ESMTPS id 25610287D35 for ; Tue, 2 Apr 2024 21:18:32 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id 28D1915E5BE; Tue, 2 Apr 2024 21:18:00 +0000 (UTC) Received: from relay04.th.seeweb.it (relay04.th.seeweb.it [5.144.164.165]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id C8D9115E1F9 for ; Tue, 2 Apr 2024 21:17:56 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=5.144.164.165 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712092679; cv=none; b=QX+SGB7xfUtRR1tibPMiKM+9fatW5moXJVn2MFXjzjka1KvqLra0oZhWOgZUch8RrswZ0e/B4nXg0XcqV7WjSrJ9xxJQZgWrH9SXIlS2Ogxz1YfY05E71Qy5vpZNH1PZINK4wZ/njPAskJmkwH7C8wV5xqxzMCQEUsE5ZIRGS/Q= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1712092679; c=relaxed/simple; bh=St1ttzqJ5d5x8tdYcsFF6U8Y4/2Vm+U3Vxv0m1HJ1BM=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=Giyo5HcnFYLS3KpMxecDM+veiQtAcyeNbJPHlqBpYXL/R32sl1afGjJ/DHYaRcdSEChLCYA3FRd5zIi2hL00WotlCyoX+Qhn81jqvQagdzjUXcBkOQhVi4uNaUczYAHcRg7QgqfrJYJcQrTVxc6U1qlODN4EfXALulVAnXroj4c= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=somainline.org; spf=pass smtp.mailfrom=somainline.org; arc=none smtp.client-ip=5.144.164.165 Authentication-Results: smtp.subspace.kernel.org; dmarc=none (p=none dis=none) header.from=somainline.org Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=somainline.org Received: from SoMainline.org (94-211-6-86.cable.dynamic.v4.ziggo.nl [94.211.6.86]) (using TLSv1.3 with cipher TLS_AES_256_GCM_SHA384 (256/256 bits) key-exchange ECDHE (prime256v1) server-signature RSA-PSS (2048 bits) server-digest SHA256) (No client certificate requested) by m-r1.th.seeweb.it (Postfix) with ESMTPSA id 3392C202FB; Tue, 2 Apr 2024 23:17:54 +0200 (CEST) Date: Tue, 2 Apr 2024 23:17:52 +0200 From: Marijn Suijten To: Dmitry Baryshkov Cc: Sumit Semwal , Caleb Connolly , Neil Armstrong , Jessica Zhang , Sam Ravnborg , David Airlie , Daniel Vetter , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , Rob Herring , Krzysztof Kozlowski , Conor Dooley , dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-arm-msm@vger.kernel.org, Vinod Koul , Caleb Connolly Subject: Re: [PATCH v3 4/4] drm: panel: Add LG sw43408 panel driver Message-ID: <3hh7nfqflj73422q47p6do7aiormxwspwkfg557epeqn2krtcc@dsufsohfaz4l> References: <20240402-lg-sw43408-panel-v3-0-144f17a11a56@linaro.org> <20240402-lg-sw43408-panel-v3-4-144f17a11a56@linaro.org> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20240402-lg-sw43408-panel-v3-4-144f17a11a56@linaro.org> On 2024-04-02 02:51:15, Dmitry Baryshkov wrote: > From: Sumit Semwal > > LG SW43408 is 1080x2160, 4-lane MIPI-DSI panel, used in some Pixel3 > phones. @60Hz? > > Signed-off-by: Sumit Semwal > [vinod: Add DSC support] > Signed-off-by: Vinod Koul > [caleb: cleanup and support turning off the panel] > Signed-off-by: Caleb Connolly > [DB: partially rewrote the driver and fixed DSC programming] > Signed-off-by: Dmitry Baryshkov Some small nits but I think this deserves a: Reviewed-by: Marijn Suijten > --- > MAINTAINERS | 8 + > drivers/gpu/drm/panel/Kconfig | 11 ++ > drivers/gpu/drm/panel/Makefile | 1 + > drivers/gpu/drm/panel/panel-lg-sw43408.c | 326 +++++++++++++++++++++++++++++++ > 4 files changed, 346 insertions(+) > > diff --git a/MAINTAINERS b/MAINTAINERS > index d36c19c1bf81..4cc43c16e07e 100644 > --- a/MAINTAINERS > +++ b/MAINTAINERS > @@ -6789,6 +6789,14 @@ S: Maintained > F: Documentation/devicetree/bindings/display/panel/jadard,jd9365da-h3.yaml > F: drivers/gpu/drm/panel/panel-jadard-jd9365da-h3.c > > +DRM DRIVER FOR LG SW43408 PANELS > +M: Sumit Semwal > +M: Caleb Connolly > +S: Maintained > +T: git git://anongit.freedesktop.org/drm/drm-misc > +F: Documentation/devicetree/bindings/display/panel/lg,sw43408.yaml > +F: drivers/gpu/drm/panel/panel-lg-sw43408.c > + > DRM DRIVER FOR LOGICVC DISPLAY CONTROLLER > M: Paul Kocialkowski > S: Supported > diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig > index 6dc451f58a3e..a55e9437c8cf 100644 > --- a/drivers/gpu/drm/panel/Kconfig > +++ b/drivers/gpu/drm/panel/Kconfig > @@ -335,6 +335,17 @@ config DRM_PANEL_LG_LG4573 > Say Y here if you want to enable support for LG4573 RGB panel. > To compile this driver as a module, choose M here. > > +config DRM_PANEL_LG_SW43408 > + tristate "LG SW43408 panel" > + depends on OF > + depends on DRM_MIPI_DSI > + depends on BACKLIGHT_CLASS_DEVICE > + help > + Say Y here if you want to enable support for LG sw43408 panel. > + The panel has a 1080x2160 resolution and uses > + 24 bit RGB per pixel. It provides a MIPI DSI interface to > + the host and has a built-in LED backlight. > + > config DRM_PANEL_MAGNACHIP_D53E6EA8966 > tristate "Magnachip D53E6EA8966 DSI panel" > depends on OF && SPI > diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile > index 24a02655d726..0b40b010e8e7 100644 > --- a/drivers/gpu/drm/panel/Makefile > +++ b/drivers/gpu/drm/panel/Makefile > @@ -34,6 +34,7 @@ obj-$(CONFIG_DRM_PANEL_LEADTEK_LTK050H3146W) += panel-leadtek-ltk050h3146w.o > obj-$(CONFIG_DRM_PANEL_LEADTEK_LTK500HD1829) += panel-leadtek-ltk500hd1829.o > obj-$(CONFIG_DRM_PANEL_LG_LB035Q02) += panel-lg-lb035q02.o > obj-$(CONFIG_DRM_PANEL_LG_LG4573) += panel-lg-lg4573.o > +obj-$(CONFIG_DRM_PANEL_LG_SW43408) += panel-lg-sw43408.o > obj-$(CONFIG_DRM_PANEL_MAGNACHIP_D53E6EA8966) += panel-magnachip-d53e6ea8966.o > obj-$(CONFIG_DRM_PANEL_NEC_NL8048HL11) += panel-nec-nl8048hl11.o > obj-$(CONFIG_DRM_PANEL_NEWVISION_NV3051D) += panel-newvision-nv3051d.o > diff --git a/drivers/gpu/drm/panel/panel-lg-sw43408.c b/drivers/gpu/drm/panel/panel-lg-sw43408.c > new file mode 100644 > index 000000000000..c7611bfa796b > --- /dev/null > +++ b/drivers/gpu/drm/panel/panel-lg-sw43408.c > @@ -0,0 +1,326 @@ > +// SPDX-License-Identifier: GPL-2.0+ > +/* > + * Copyright (C) 2019-2024 Linaro Ltd > + * Author: Sumit Semwal > + * Dmitry Baryshkov > + */ > + > +#include > +#include > +#include > +#include > +#include > +#include > + > +#include