From patchwork Tue Jun 25 14:25:50 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Jerome Brunet X-Patchwork-Id: 13711240 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 1F2FDC2BBCA for ; Tue, 25 Jun 2024 14:26:30 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 75C5F10E673; Tue, 25 Jun 2024 14:26:29 +0000 (UTC) Authentication-Results: gabe.freedesktop.org; dkim=pass (2048-bit key; unprotected) header.d=baylibre-com.20230601.gappssmtp.com header.i=@baylibre-com.20230601.gappssmtp.com header.b="dwrPR//A"; dkim-atps=neutral Received: from mail-wm1-f44.google.com (mail-wm1-f44.google.com [209.85.128.44]) by gabe.freedesktop.org (Postfix) with ESMTPS id 7001D10E673 for ; Tue, 25 Jun 2024 14:26:21 +0000 (UTC) Received: by mail-wm1-f44.google.com with SMTP id 5b1f17b1804b1-4217990f997so41705085e9.2 for ; Tue, 25 Jun 2024 07:26:21 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=baylibre-com.20230601.gappssmtp.com; s=20230601; t=1719325579; x=1719930379; 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=hUnlDK2msKQOjLK3wL+RmE8TdQfuWckSjRfYqDGL9KQ=; b=dwrPR//Ap3PYDzPwL7GBvun8NQ2UDhpwA7eGT8wfmhW5RZ8vUUEAgToNY906JzV8Sh ult+/C+Ztuc/P2G8ezkhtzTM8IS8Ih4/CTOcE+GV0kBqNhQmiPGWa+Bv7ZYwNdc6EOxQ gqILh1LSj6y0mZW4a3RyHwht07SURo/JyGPiEHNdNIbX2qhHN89t2EdMoxBysgrZNsER /fbT77Y8NtQO9db7b1BhlrwBydQSjnKe1Ti4f8ocCt9J2+gbVnfGmQh2O/YIEcf5AioR z66Hg3m+hjHt/mwRPfKBQNgH6UvKUEI1leduLTZZqki+OTLAW9yu1KxdPDy4H9fQO+bQ aTpQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1719325579; x=1719930379; 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=hUnlDK2msKQOjLK3wL+RmE8TdQfuWckSjRfYqDGL9KQ=; b=vDQwGHy5G4d+jt/CQvkmOMV4XJ8DtnPXKRs6OJjHjMYbYxObWCRT+3t5Ch6GtuG2+2 cTIvL5rWKrUGPyKbRpdzeq/xR9WLILBIW1u2QgW03eLPSCyXZD/fJ27nhBeIdCD0EPPT wDI5q74Uihxb1e27eJQEVqD0BnNT+AbjxWmps5aVA9tylkIahBls5W3yD+ZaBLEdMm+i BvXEIWfqxUGOlmJTsUocJX810wDUKHtnyqB818gU7HSRgDMY9VCOFOcP+DCeTTVCeROu Jt8FQ/+qa/pSq1JIkvlFIE2tGR3PSmrDkxghusBlwvOV3Qo+Ji6GP452CM6ucAdCelQO d/EA== X-Forwarded-Encrypted: i=1; AJvYcCWE42wXFAKa7QZ0s1K1uhzm1F8h+zDWh4NiPUtoqSFgyZGpPKYFOVFGVfjj+H22OWRpKtRIB/kfh/2pvU093oNrRXAx0NY4Fz9snfpCKfCn X-Gm-Message-State: AOJu0YysgqI+4r52Hr/HpCFzVBczFtxEpSgQ1FThDKty85x0vQWszCFU llhZy1s0cS2VDkKbvGF9Qt3cK8muK+1ERxWHxRIvfh03ek1Mg0kYO0J2GNMlWD4= X-Google-Smtp-Source: AGHT+IGmMdR0rJvIyxVksyUH6PxxYdEPX/b3rlGUBjOv9iXFZymmefXVwDYeoY2rJN5UdeoRRGa2Og== X-Received: by 2002:a05:600c:434b:b0:424:abd7:2321 with SMTP id 5b1f17b1804b1-424abd72412mr1124715e9.12.1719325579403; Tue, 25 Jun 2024 07:26:19 -0700 (PDT) Received: from toaster.lan ([2a01:e0a:3c5:5fb1:b30c:4c5e:f49e:ab33]) by smtp.googlemail.com with ESMTPSA id 5b1f17b1804b1-4247d211881sm213770685e9.46.2024.06.25.07.26.18 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 25 Jun 2024 07:26:19 -0700 (PDT) From: Jerome Brunet To: Neil Armstrong , Jessica Zhang , Sam Ravnborg , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Daniel Vetter Cc: Jerome Brunet , linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Rob Herring , Krzysztof Kozlowski , Conor Dooley , dri-devel@lists.freedesktop.org Subject: [PATCH 3/3] drm/panel: add lincoln lcd197 support Date: Tue, 25 Jun 2024 16:25:50 +0200 Message-ID: <20240625142552.1000988-4-jbrunet@baylibre.com> X-Mailer: git-send-email 2.43.0 In-Reply-To: <20240625142552.1000988-1-jbrunet@baylibre.com> References: <20240625142552.1000988-1-jbrunet@baylibre.com> MIME-Version: 1.0 X-Patchwork-Bot: notify 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: , Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Add support for the Lincoln LCD197 1080x1920 DSI panel. Signed-off-by: Jerome Brunet --- drivers/gpu/drm/panel/Kconfig | 11 + drivers/gpu/drm/panel/Makefile | 1 + drivers/gpu/drm/panel/panel-lincoln-lcd197.c | 333 +++++++++++++++++++ 3 files changed, 345 insertions(+) create mode 100644 drivers/gpu/drm/panel/panel-lincoln-lcd197.c diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig index 2ae0eb0638f3..a4e68981e740 100644 --- a/drivers/gpu/drm/panel/Kconfig +++ b/drivers/gpu/drm/panel/Kconfig @@ -319,6 +319,17 @@ config DRM_PANEL_LEADTEK_LTK500HD1829 24 bit RGB per pixel. It provides a MIPI DSI interface to the host and has a built-in LED backlight. +config DRM_PANEL_LINCOLN_LCD197 + tristate "Lincoln lcd197 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 lincoln lcd197 + TFT-LCD modules. The panel has a 1080x1920 resolution and uses + 24 bit RGB per pixel. It provides a MIPI DSI interface to + the host. + config DRM_PANEL_LG_LB035Q02 tristate "LG LB035Q024573 RGB panel" depends on GPIOLIB && OF && SPI diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile index f0203f6e02f4..06141ec2e065 100644 --- a/drivers/gpu/drm/panel/Makefile +++ b/drivers/gpu/drm/panel/Makefile @@ -32,6 +32,7 @@ obj-$(CONFIG_DRM_PANEL_KHADAS_TS050) += panel-khadas-ts050.o obj-$(CONFIG_DRM_PANEL_KINGDISPLAY_KD097D04) += panel-kingdisplay-kd097d04.o obj-$(CONFIG_DRM_PANEL_LEADTEK_LTK050H3146W) += panel-leadtek-ltk050h3146w.o obj-$(CONFIG_DRM_PANEL_LEADTEK_LTK500HD1829) += panel-leadtek-ltk500hd1829.o +obj-$(CONFIG_DRM_PANEL_LINCOLN_LCD197) += panel-lincoln-lcd197.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 diff --git a/drivers/gpu/drm/panel/panel-lincoln-lcd197.c b/drivers/gpu/drm/panel/panel-lincoln-lcd197.c new file mode 100644 index 000000000000..977790797d70 --- /dev/null +++ b/drivers/gpu/drm/panel/panel-lincoln-lcd197.c @@ -0,0 +1,333 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * Copyright (C) 2023 BayLibre, SAS + * Author: Jerome Brunet + */ + +#include +#include +#include +#include +#include + +#include