From patchwork Mon Mar 4 12:50:32 2019 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Josef_Lu=C5=A1tick=C3=BD?= X-Patchwork-Id: 10837783 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork-2.web.codeaurora.org (Postfix) with ESMTP id C433117E9 for ; Mon, 4 Mar 2019 12:51:12 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id B16332A148 for ; Mon, 4 Mar 2019 12:51:12 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id ACF0C2A15A; Mon, 4 Mar 2019 12:51:12 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-5.2 required=2.0 tests=BAYES_00,MAILING_LIST_MULTI, RCVD_IN_DNSWL_MED autolearn=ham version=3.3.1 Received: from gabe.freedesktop.org (gabe.freedesktop.org [131.252.210.177]) (using TLSv1.2 with cipher DHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.wl.linuxfoundation.org (Postfix) with ESMTPS id 96DCA29BF4 for ; Mon, 4 Mar 2019 12:51:11 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 3812A899B7; Mon, 4 Mar 2019 12:51:08 +0000 (UTC) X-Original-To: dri-devel@lists.freedesktop.org Delivered-To: dri-devel@lists.freedesktop.org Received: from mail-wm1-x341.google.com (mail-wm1-x341.google.com [IPv6:2a00:1450:4864:20::341]) by gabe.freedesktop.org (Postfix) with ESMTPS id B787C899B7 for ; Mon, 4 Mar 2019 12:51:05 +0000 (UTC) Received: by mail-wm1-x341.google.com with SMTP id y15so4589174wma.0 for ; Mon, 04 Mar 2019 04:51:05 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:mime-version:content-transfer-encoding; bh=W3Ki6S23j1KwLs/09J5b6YbSF0rjhrV/IQQcO7DWn/E=; b=tV30z6QCKp/6AJ+Km0GmXApHYhq2pQ5bxQ9n4l5Ezmz434OkK1DTJ3sS+N6+/sZNVA dtguBjUtX+m4rMq3o5m293OMJXtSEo9Yb6peINPFaHIkTtW+r2jVpPg0xvpLtqfOe4TQ 0dOxA6L/fomEfccbxyI4oLejc7MIXD00Zq4m/4BKqaeCAyGs/9RCyV0AHQ1xxl3eZgpV 2oVQzPqcxFHR+1ZiEVe6f/87oxY6t22M7wR7gkyMEpabRvXFDn2z0amSqKTBPXAhi3pG LGz+DHlaAR8Z1uhAJx9a31MpcsFCJSG6z2tykWlE/4ZYQxiARBrTZ6mAVoHpwZxWgdd8 UQBA== X-Gm-Message-State: AHQUAuZ5G0AOTmrRlGHEUJEw0QqlTRCoxV9Mu7UhvJOJnOo+7PceYEzP jO5iPIIlr8tIF1Lw6reAE3GmZQ== X-Google-Smtp-Source: AHgI3IbjdHZ1R7oz7vFNyTANFOzGdPLA93GhEmgmXMkQLga2+1JbH6bpSRwFvUP1PkREbuFD3gAXuQ== X-Received: by 2002:a1c:1d56:: with SMTP id d83mr11592748wmd.67.1551703864259; Mon, 04 Mar 2019 04:51:04 -0800 (PST) Received: from e430.riomail.cz (188-175-152-238.client.rionet.cz. [188.175.152.238]) by smtp.gmail.com with ESMTPSA id o18sm18377514wrg.40.2019.03.04.04.51.03 (version=TLS1_2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Mon, 04 Mar 2019 04:51:03 -0800 (PST) From: Josef Lusticky To: thierry.reding@gmail.com, daniel@ffwll.ch, dri-devel@lists.freedesktop.org Subject: [RFC PATCH 1/2] drm/panel: Add Ilitek ILI9341 parallel RGB panel driver Date: Mon, 4 Mar 2019 13:50:32 +0100 Message-Id: <20190304125033.28841-2-josef@lusticky.cz> X-Mailer: git-send-email 2.20.1 In-Reply-To: <20190304125033.28841-1-josef@lusticky.cz> References: <20190304125033.28841-1-josef@lusticky.cz> MIME-Version: 1.0 X-Mailman-Original-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=lusticky.cz; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :mime-version:content-transfer-encoding; bh=W3Ki6S23j1KwLs/09J5b6YbSF0rjhrV/IQQcO7DWn/E=; b=Ore9a6A4GoBhW7ocgLxKJV0vPMM9Movv1Wd9wdsepIUL+nooAYMJuYhYHqilbLClsU 6xxIyKXEgD2xQ3Qx9309iT4esn9CdLYYGkoGR+bVEsQ+WHwyCOXZ6Y6OOi0vG+QZf4Yn 3vVgZjqkaxEes+5dnNu4dovFNGNvZyY/Qy8zlDUq7RtjzfLmPV0jV6Z6euyHNKSX0xW4 CrBNOA8o4KDz6dsI8iit7KGXmCtWslqk23djGpvVix1AZ/ZS6aDVG6bGa5yUV252gAhy 6ALY0lm5LHe+sSQQOTNUHa9uG/DWa2kcZoxMLx/XHTs+WfIjT8AMVN1rSJFNofjX3xEr zkCw== X-BeenThere: dri-devel@lists.freedesktop.org X-Mailman-Version: 2.1.23 Precedence: list List-Id: Direct Rendering Infrastructure - Development List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Cc: maxime.ripard@bootlin.com, airlied@linux.ie, Josef Lusticky , devicetree@vger.kernel.org Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" X-Virus-Scanned: ClamAV using ClamSMTP --- MAINTAINERS | 6 + drivers/gpu/drm/panel/Kconfig | 7 + drivers/gpu/drm/panel/Makefile | 1 + drivers/gpu/drm/panel/panel-ilitek-ili9341.c | 320 +++++++++++++++++++ 4 files changed, 334 insertions(+) create mode 100644 drivers/gpu/drm/panel/panel-ilitek-ili9341.c diff --git a/MAINTAINERS b/MAINTAINERS index a4a4bf563f94..d2e03c5ad04d 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -4821,6 +4821,12 @@ S: Maintained F: drivers/gpu/drm/tinydrm/ili9225.c F: Documentation/devicetree/bindings/display/ilitek,ili9225.txt +DRM DRIVER FOR ILITEK ILI9341 PANELS +M: Josef Lusticky +S: Maintained +F: drivers/gpu/drm/panel/panel-ilitek-ili9341.c +F: Documentation/devicetree/bindings/display/panel/ilitek,ili9341.txt + DRM DRIVER FOR HX8357D PANELS M: Eric Anholt T: git git://anongit.freedesktop.org/drm/drm-misc diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig index f53f817356db..a59cfff614c0 100644 --- a/drivers/gpu/drm/panel/Kconfig +++ b/drivers/gpu/drm/panel/Kconfig @@ -46,6 +46,13 @@ config DRM_PANEL_ILITEK_IL9322 Say Y here if you want to enable support for Ilitek IL9322 QVGA (320x240) RGB, YUV and ITU-T BT.656 panels. +config DRM_PANEL_ILITEK_IL9341 + tristate "Ilitek ILI9341 240x320 panels" + depends on OF && SPI + help + Say Y here if you want to enable support for Ilitek IL9341 + QVGA (240x320) RGB panel. + 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 7834947a53b0..1ce3ff8d6204 100644 --- a/drivers/gpu/drm/panel/Makefile +++ b/drivers/gpu/drm/panel/Makefile @@ -3,6 +3,7 @@ obj-$(CONFIG_DRM_PANEL_ARM_VERSATILE) += panel-arm-versatile.o obj-$(CONFIG_DRM_PANEL_LVDS) += panel-lvds.o obj-$(CONFIG_DRM_PANEL_SIMPLE) += panel-simple.o obj-$(CONFIG_DRM_PANEL_ILITEK_IL9322) += panel-ilitek-ili9322.o +obj-$(CONFIG_DRM_PANEL_ILITEK_IL9341) += panel-ilitek-ili9341.o obj-$(CONFIG_DRM_PANEL_ILITEK_ILI9881C) += panel-ilitek-ili9881c.o obj-$(CONFIG_DRM_PANEL_INNOLUX_P079ZCA) += panel-innolux-p079zca.o obj-$(CONFIG_DRM_PANEL_JDI_LT070ME05000) += panel-jdi-lt070me05000.o diff --git a/drivers/gpu/drm/panel/panel-ilitek-ili9341.c b/drivers/gpu/drm/panel/panel-ilitek-ili9341.c new file mode 100644 index 000000000000..51ed03140f8d --- /dev/null +++ b/drivers/gpu/drm/panel/panel-ilitek-ili9341.c @@ -0,0 +1,320 @@ +// SPDX-License-Identifier: GPL-2.0+ +/* + * Ilitek ILI9341 drm_panel driver + * 240RGBx320 dots resolution TFT LCD display + * + * This driver support the following panel configurations: + * - 18-bit parallel RGB interface + * - 8-bit SPI with Data/Command GPIO + * + * Copyright (C) 2019 Josef Lusticky + * + */ + +#include +#include +#include + +#include +#include +#include +#include +#include +#include + +#include