From mboxrd@z Thu Jan 1 00:00:00 1970 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id 33A97C3DA79 for ; Fri, 23 Dec 2022 15:33:48 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S236215AbiLWPdr (ORCPT ); Fri, 23 Dec 2022 10:33:47 -0500 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:51744 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S230517AbiLWPdq (ORCPT ); Fri, 23 Dec 2022 10:33:46 -0500 Received: from out2.migadu.com (out2.migadu.com [188.165.223.204]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id D29B51DA4B; Fri, 23 Dec 2022 07:33:42 -0800 (PST) Message-ID: <7aa53ccc-2942-e2d4-9c84-32f1bdf462ad@ansari.sh> DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=ansari.sh; s=key1; t=1671809621; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version:content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=twU6G82PQpwC8zwHWIz8F9rsWmIFJuTai19fmGz1yi4=; b=kZQK5SU633nXGkPHLpetzQeS8JCb20af5MuZlypG9fGZdTBDX3hOl36eva92rErmdrYDxb Sz6qEfzRAYZBOKtZptqcVIa4zkM5tBlxVErVfJbsyfEtTbd+JjV6Lyao1Zqq18xVbvwILD 72kQymV7O/EjJzGvXY/kAZ3kktL7j+Q= Date: Fri, 23 Dec 2022 15:33:40 +0000 MIME-Version: 1.0 Subject: Re: [v2,3/4] drm/panel: Add driver for JDI LPM102A188A Content-Language: en-US To: Diogo Ivo Cc: devicetree@vger.kernel.org, krzysztof.kozlowski+dt@linaro.org, arnd@arndb.de, airlied@linux.ie, dri-devel@lists.freedesktop.org, jonathanh@nvidia.com, robh+dt@kernel.org, thierry.reding@gmail.com, linux-tegra@vger.kernel.org, sam@ravnborg.org References: <20221025153746.101278-4-diogo.ivo@tecnico.ulisboa.pt> X-Report-Abuse: Please report any abuse attempt to abuse@migadu.com and include these headers. From: Rayyan Ansari In-Reply-To: <20221025153746.101278-4-diogo.ivo@tecnico.ulisboa.pt> Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Migadu-Flow: FLOW_OUT Precedence: bulk List-ID: X-Mailing-List: linux-tegra@vger.kernel.org Hello, On 25/10/2022 16:37, Diogo Ivo wrote: > The JDI LPM102A188A is a 2560x1800 IPS panel found in the Google Pixel C. > This driver is based on the downstream GPLv2 driver released by Google > written by Sean Paul [1], which was then adapted to the newer kernel APIs. > > [1]: https://android.googlesource.com/kernel/tegra/+/refs/heads/android-tegra-dragon-3.18-oreo/drivers/gpu/drm/panel/panel-jdi-lpm102a188a.c > > Signed-off-by: Diogo Ivo > --- > Changes in v2: > - tuned backlight delays > > drivers/gpu/drm/panel/Kconfig | 11 + > drivers/gpu/drm/panel/Makefile | 1 + > drivers/gpu/drm/panel/panel-jdi-lpm102a188a.c | 509 ++++++++++++++++++ > 3 files changed, 521 insertions(+) > create mode 100644 drivers/gpu/drm/panel/panel-jdi-lpm102a188a.c > > diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig > index a582ddd583c2..80eda8f6bee0 100644 > --- a/drivers/gpu/drm/panel/Kconfig > +++ b/drivers/gpu/drm/panel/Kconfig > @@ -214,6 +214,17 @@ config DRM_PANEL_JDI_LT070ME05000 > The panel has a 1200(RGB)×1920 (WUXGA) resolution and uses > 24 bit per pixel. > > +config DRM_PANEL_JDI_LPM102A188A > + tristate "JDI LPM102A188A DSI panel" > + depends on OF && GPIOLIB > + depends on DRM_MIPI_DSI > + depends on BACKLIGHT_CLASS_DEVICE > + help > + Say Y here if you want to enable support for JDI LPM102A188A DSI > + control mode panel as found in Google Pixel C devices. Shouldn't this be "command mode panel" instead of "control mode panel"? > + The panel has a 2560×1800 resolution. It provides a MIPI DSI interface > + to the host. > + > config DRM_PANEL_JDI_R63452 > tristate "JDI R63452 Full HD DSI panel" > depends on OF > diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile > index 34e717382dbb..2870cba96d14 100644 > --- a/drivers/gpu/drm/panel/Makefile > +++ b/drivers/gpu/drm/panel/Makefile > @@ -19,6 +19,7 @@ obj-$(CONFIG_DRM_PANEL_ILITEK_ILI9881C) += panel-ilitek-ili9881c.o > obj-$(CONFIG_DRM_PANEL_INNOLUX_EJ030NA) += panel-innolux-ej030na.o > obj-$(CONFIG_DRM_PANEL_INNOLUX_P079ZCA) += panel-innolux-p079zca.o > obj-$(CONFIG_DRM_PANEL_JDI_LT070ME05000) += panel-jdi-lt070me05000.o > +obj-$(CONFIG_DRM_PANEL_JDI_LPM102A188A) += panel-jdi-lpm102a188a.o > obj-$(CONFIG_DRM_PANEL_JDI_R63452) += panel-jdi-fhd-r63452.o > obj-$(CONFIG_DRM_PANEL_KHADAS_TS050) += panel-khadas-ts050.o > obj-$(CONFIG_DRM_PANEL_KINGDISPLAY_KD097D04) += panel-kingdisplay-kd097d04.o > diff --git a/drivers/gpu/drm/panel/panel-jdi-lpm102a188a.c b/drivers/gpu/drm/panel/panel-jdi-lpm102a188a.c > new file mode 100644 > index 000000000000..980af82ad6d6 > --- /dev/null > +++ b/drivers/gpu/drm/panel/panel-jdi-lpm102a188a.c > @@ -0,0 +1,509 @@ > +// SPDX-License-Identifier: GPL-2.0-only > +/* > + * Copyright (C) 2014 Google, Inc. > + * > + * Copyright (C) 2022 Diogo Ivo > + * > + * Adapted from the downstream Pixel C driver written by Sean Paul > + */ > + > +#include > +#include > +#include > +#include > +#include > +#include > + > +#include