From patchwork Tue Dec 5 10:52:55 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Dario Binacchi X-Patchwork-Id: 13479954 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 E9970C07E97 for ; Tue, 5 Dec 2023 10:54:21 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id A13F510E4EC; Tue, 5 Dec 2023 10:54:18 +0000 (UTC) Received: from mail-ej1-x630.google.com (mail-ej1-x630.google.com [IPv6:2a00:1450:4864:20::630]) by gabe.freedesktop.org (Postfix) with ESMTPS id ABF9C10E4ED for ; Tue, 5 Dec 2023 10:54:15 +0000 (UTC) Received: by mail-ej1-x630.google.com with SMTP id a640c23a62f3a-a1a0bc1e415so499989066b.0 for ; Tue, 05 Dec 2023 02:54:15 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=amarulasolutions.com; s=google; t=1701773654; x=1702378454; darn=lists.freedesktop.org; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date :message-id:reply-to; bh=2XKeSnE1o1bVHtCvXc9BPZG1WDGDESQII0YlQSzaFMY=; b=Ajy9sw8/KNG7Di5ZQVO3oTw2SzIrPtlkf6pj5jTAAdKvVOooq5IlQPaDUrrLYsPxP/ NLgFYehvLEDzoiJm9Js976ZMbjmcb3iMSHzU0AjFgo6r2ftZX076kjhWZAu235XAZ3if MpHGU3CjdyJrLX1ZcFwm8qZwkS1Xd1H300uxk= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1701773654; x=1702378454; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=2XKeSnE1o1bVHtCvXc9BPZG1WDGDESQII0YlQSzaFMY=; b=I6E/fagLIGl8S7rtd7sUWtRsXZ6kMnJTfdkXofUUBHbq9ABbKx2DVwmxzqMUFSXLsn xH8e4CQtFhqhTpu6cC6J6LlPsfeo0vw6GvPnCViwbJThEOMJ7payFya+mu6hjTWlHg9N B5Uh7R85+Bhs6oGzPMaklbm0j/SvYyma+5xm1CZygjJbqSyQQjkIppaDjdayndHjIGxe ytriMwQZJtE3khRDjClYAC8D+biiZBLsh5JuPvnv8vmOwaJYvMndIt/5TDnof1RLDODk xFugR5qf1dPYO3+4Zd+lQGdUd4puRG5v9zC1Krb9hWnwM7pAjkJjBLnYP5bgwER4qFyX M0Ug== X-Gm-Message-State: AOJu0YycG2QSXIOO44gWyDmC/nYVR7K7KSBkRXdKQTCnU2MYashU39FW FMMg3CJFBg3cFcFgF9lWjXeEkg== X-Google-Smtp-Source: AGHT+IEyxg6cFIuwPR8KPrHo26U1Lfl945XCHFUNx8NMkh1S/1HWEsns0iGYdQWzgxBPqDCOaLSgAA== X-Received: by 2002:a17:906:c4d1:b0:a19:a1ba:8ce4 with SMTP id cl17-20020a170906c4d100b00a19a1ba8ce4mr3247255ejb.130.1701773654190; Tue, 05 Dec 2023 02:54:14 -0800 (PST) Received: from dario-ThinkPad-T14s-Gen-2i.homenet.telecomitalia.it (host-82-54-95-129.retail.telecomitalia.it. [82.54.95.129]) by smtp.gmail.com with ESMTPSA id n23-20020a170906089700b0099297782aa9sm6413491eje.49.2023.12.05.02.54.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 05 Dec 2023 02:54:13 -0800 (PST) From: Dario Binacchi To: linux-kernel@vger.kernel.org Subject: [PATCH v4 08/10] drm/panel: Add Ilitek ILI9805 panel driver Date: Tue, 5 Dec 2023 11:52:55 +0100 Message-ID: <20231205105341.4100896-9-dario.binacchi@amarulasolutions.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20231205105341.4100896-1-dario.binacchi@amarulasolutions.com> References: <20231205105341.4100896-1-dario.binacchi@amarulasolutions.com> MIME-Version: 1.0 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: Neil Armstrong , Dario Binacchi , Thomas Zimmermann , Sam Ravnborg , Amarula patchwork , Maxime Ripard , dri-devel@lists.freedesktop.org, Jessica Zhang , michael@amarulasolutions.com Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" From: Michael Trimarchi The GPM1790A0 panel is based on the Ilitek ILI9805 Controller. Add a driver for it. Signed-off-by: Michael Trimarchi Signed-off-by: Dario Binacchi --- Changes in v4: - Remove duplicated code for prepare/unprepare callbacks MAINTAINERS | 6 + drivers/gpu/drm/panel/Kconfig | 9 + drivers/gpu/drm/panel/Makefile | 1 + drivers/gpu/drm/panel/panel-ilitek-ili9805.c | 353 +++++++++++++++++++ 4 files changed, 369 insertions(+) create mode 100644 drivers/gpu/drm/panel/panel-ilitek-ili9805.c diff --git a/MAINTAINERS b/MAINTAINERS index b82dc141d209..4dccc72a0ed6 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -6646,6 +6646,12 @@ T: git git://anongit.freedesktop.org/drm/drm-misc F: Documentation/devicetree/bindings/display/ilitek,ili9486.yaml F: drivers/gpu/drm/tiny/ili9486.c +DRM DRIVER FOR ILITEK ILI9805 PANELS +M: Michael Trimarchi +S: Maintained +F: Documentation/devicetree/bindings/display/panel/ilitek,ili9805.yaml +F: drivers/gpu/drm/panel/panel-ilitek-ili9805.c + DRM DRIVER FOR JADARD JD9365DA-H3 MIPI-DSI LCD PANELS M: Jagan Teki S: Maintained diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig index d018702be3dc..dad938cf6dec 100644 --- a/drivers/gpu/drm/panel/Kconfig +++ b/drivers/gpu/drm/panel/Kconfig @@ -194,6 +194,15 @@ config DRM_PANEL_ILITEK_ILI9341 QVGA (240x320) RGB panels. support serial & parallel rgb interface. +config DRM_PANEL_ILITEK_ILI9805 + tristate "Ilitek ILI9805-based panels" + depends on OF + depends on DRM_MIPI_DSI + depends on BACKLIGHT_CLASS_DEVICE + help + Say Y if you want to enable support for panels based on the + Ilitek ILI9805 controller. + 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 f267d932c2b5..d94a644d0a6c 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_ILI9805) += panel-ilitek-ili9805.o obj-$(CONFIG_DRM_PANEL_ILITEK_ILI9881C) += panel-ilitek-ili9881c.o obj-$(CONFIG_DRM_PANEL_ILITEK_ILI9882T) += panel-ilitek-ili9882t.o obj-$(CONFIG_DRM_PANEL_INNOLUX_EJ030NA) += panel-innolux-ej030na.o diff --git a/drivers/gpu/drm/panel/panel-ilitek-ili9805.c b/drivers/gpu/drm/panel/panel-ilitek-ili9805.c new file mode 100644 index 000000000000..e36984b46e14 --- /dev/null +++ b/drivers/gpu/drm/panel/panel-ilitek-ili9805.c @@ -0,0 +1,353 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * Copyright (C) 2020 BSH Hausgerate GmbH + */ + +#include +#include +#include +#include +#include +#include +#include +#include + +#include +#include + +#include +#include +#include + +#include