From patchwork Wed Jul 19 15:21:47 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Luca Ceresoli X-Patchwork-Id: 13319127 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 gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.lore.kernel.org (Postfix) with ESMTPS id 72BF9C001B0 for ; Wed, 19 Jul 2023 15:22:14 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 8778E10E4CA; Wed, 19 Jul 2023 15:22:13 +0000 (UTC) X-Greylist: delayed 15772 seconds by postgrey-1.36 at gabe; Wed, 19 Jul 2023 15:22:05 UTC Received: from relay5-d.mail.gandi.net (relay5-d.mail.gandi.net [217.70.183.197]) by gabe.freedesktop.org (Postfix) with ESMTPS id C9D9410E4CA for ; Wed, 19 Jul 2023 15:22:05 +0000 (UTC) Received: by mail.gandi.net (Postfix) with ESMTPA id D8D241C0004; Wed, 19 Jul 2023 15:22:01 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=bootlin.com; s=gm1; t=1689780123; h=from:from:reply-to:subject:subject:date:date:message-id:message-id: to:to:cc:cc:mime-version:mime-version: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=CBg6tMAdVYwms8PoDmVDoX4vd6DGK68Jkg1jw+ADWwM=; b=aR/SHyNSTmmLtcNqB+J3ayR5nChFZV5WIIyU8NdO1DcHd5j80flvY2QDdSPni84XjSGeDo 46eiLd5R4x1b5doItnVZA4Ivvbbfpr/VZ1o9nqw1SPGZdL3RBbbkRv0NGh3GNFSrSc4h3k UskcvhjiS3knW6+l0tV6OOGPOlqlHLtEUmllA+rm+yQEZr8HI/khOaBvtWQYENgVKuBCBS 3tF0DTr/q+2k0TmY8IXiYwtMhCzC3YjJeg6pskSXeTnh9R58Ng1NrjFEOeYlRBrj6XrtnE FJ7bLk1uYtaZi2yaJH7cbi776JNbguv/4ud9i2F6hZ7pecEehFiNr0PazpLxxA== From: Luca Ceresoli To: Neil Armstrong , Sam Ravnborg , David Airlie , Daniel Vetter , Rob Herring , Krzysztof Kozlowski , Conor Dooley Subject: [PATCH 3/3] DRM: panel: add Ilitek ILI9806E driver Date: Wed, 19 Jul 2023 17:21:47 +0200 Message-Id: <20230719152147.355486-3-luca.ceresoli@bootlin.com> X-Mailer: git-send-email 2.34.1 In-Reply-To: <20230719152147.355486-1-luca.ceresoli@bootlin.com> References: <20230719152147.355486-1-luca.ceresoli@bootlin.com> MIME-Version: 1.0 X-GND-Sasl: luca.ceresoli@bootlin.com X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.29 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Paul Kocialkowski , Thomas Petazzoni , Luca Ceresoli Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Add a driver for the ILITEK ILI9806E 480x864 RGB LCD controller connected over SPI, and implement the ShenZhen New Display Co NDS040480800-V3 480x800 panel. Signed-off-by: Luca Ceresoli --- MAINTAINERS | 1 + drivers/gpu/drm/panel/Kconfig | 13 + drivers/gpu/drm/panel/Makefile | 1 + drivers/gpu/drm/panel/panel-ilitek-ili9806e.c | 384 ++++++++++++++++++ 4 files changed, 399 insertions(+) create mode 100644 drivers/gpu/drm/panel/panel-ilitek-ili9806e.c diff --git a/MAINTAINERS b/MAINTAINERS index 3c38699ee821..4d657a049acc 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -6520,6 +6520,7 @@ M: Luca Ceresoli S: Maintained T: git git://anongit.freedesktop.org/drm/drm-misc F: Documentation/devicetree/bindings/display/panel/ilitek,ili9806e.yaml +F: drivers/gpu/drm/panel/panel-ilitek-ili9806e.c DRM DRIVER FOR JADARD JD9365DA-H3 MIPI-DSI LCD PANELS M: Jagan Teki diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig index 203c0ef0bbfd..e3e89d86668a 100644 --- a/drivers/gpu/drm/panel/Kconfig +++ b/drivers/gpu/drm/panel/Kconfig @@ -194,6 +194,19 @@ config DRM_PANEL_ILITEK_ILI9341 QVGA (240x320) RGB panels. support serial & parallel rgb interface. +config DRM_PANEL_ILITEK_ILI9806E + tristate "Ilitek ILI9806E panel" + depends on OF + depends on BACKLIGHT_CLASS_DEVICE + select VIDEOMODE_HELPERS + select DRM_MIPI_DBI + help + Say Y here if you want to enable support for LCD panels connected + over SPI and based on the Ilitek ILI9806E controller. + + The ILI9806E is an LCD controller capable of driving 18-bit a-Si + TFT LCDs up to a resolution of 480x800. + config DRM_PANEL_ILITEK_ILI9881C tristate "Ilitek ILI9881C-based panels" depends on OF diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile index 30cf553c8d1d..f465140ae7df 100644 --- a/drivers/gpu/drm/panel/Makefile +++ b/drivers/gpu/drm/panel/Makefile @@ -17,6 +17,7 @@ obj-$(CONFIG_DRM_PANEL_FEIYANG_FY07024DI26A30D) += panel-feiyang-fy07024di26a30d obj-$(CONFIG_DRM_PANEL_HIMAX_HX8394) += panel-himax-hx8394.o obj-$(CONFIG_DRM_PANEL_ILITEK_IL9322) += panel-ilitek-ili9322.o obj-$(CONFIG_DRM_PANEL_ILITEK_ILI9341) += panel-ilitek-ili9341.o +obj-$(CONFIG_DRM_PANEL_ILITEK_ILI9806E) += panel-ilitek-ili9806e.o 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 diff --git a/drivers/gpu/drm/panel/panel-ilitek-ili9806e.c b/drivers/gpu/drm/panel/panel-ilitek-ili9806e.c new file mode 100644 index 000000000000..57c12bff70f8 --- /dev/null +++ b/drivers/gpu/drm/panel/panel-ilitek-ili9806e.c @@ -0,0 +1,384 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * Driver for the Ilitek ILI9806E a-Si TFT LCD controller. + * + * Copyright (c) 2023 Delcon SRL + * Luca Ceresoli + */ + +#include +#include +#include + +#include +#include +#include +#include +#include + +#include