From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from mail-lf1-f48.google.com (mail-lf1-f48.google.com [209.85.167.48]) (using TLSv1.2 with cipher ECDHE-RSA-AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 239982FF167 for ; Mon, 10 Nov 2025 09:15:27 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=209.85.167.48 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762766130; cv=none; b=OrJhZuFmaKGtFuvCwGY2yJcxi4Z/ug+psV9m+HpCufcIWPEUnnJpoZwf2bCM3Tx0PxyQGO2nxrwTeTg4G0Jvekc4aH8Fi4JuPD6wP3dW6/k6zrM61IUfyISMgKMX9FwdwW/BbJ3Qc4G3LKgSkoBAJCHfIpmPZQXYtIsftmR/R+0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1762766130; c=relaxed/simple; bh=/CXzj5jTIsG6xjXWB8a3Ddy3m9DDciOJ66r1kBk8d4s=; h=From:To:Cc:Subject:Date:Message-ID:In-Reply-To:References: MIME-Version; b=Zwo1l931IS2SBOwTKplWV+/OcopBlHsBF4k8J325NeDn36sbLZLKfxdo+kPoLKBAYQCBW1vFq8F0eHaYiZofGxz4KhsUQpbzFO28nrKSEslOWOqfNGoRXkRV4kwJPPd7iEXtPjuToEMRIixBuKTm4PL59K48h79yIrs1HszHdWg= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com; spf=pass smtp.mailfrom=gmail.com; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b=jlACDDgO; arc=none smtp.client-ip=209.85.167.48 Authentication-Results: smtp.subspace.kernel.org; dmarc=pass (p=none dis=none) header.from=gmail.com Authentication-Results: smtp.subspace.kernel.org; spf=pass smtp.mailfrom=gmail.com Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=gmail.com header.i=@gmail.com header.b="jlACDDgO" Received: by mail-lf1-f48.google.com with SMTP id 2adb3069b0e04-594285c6509so3010105e87.0 for ; Mon, 10 Nov 2025 01:15:27 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20230601; t=1762766126; x=1763370926; darn=vger.kernel.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=veHv/uRfxtfoSVQhbpvYC1/mXF+mOr0qW/T/KMequQ0=; b=jlACDDgO/Jko1OYxe3joBkbnlS8cjWjuLBITuikjzfm+6EEJyj3CB/oJPU/dXF6rF/ yUEJ6j+PTOF02j9lwCDf7ZUJu6tWh9mS25j7roA2CziVPbGKeM9xZQSL+mevMaLG1myG cS+5DwR+Sw+JRGiT22DJvtanXLwRbBbAiXF70k8nkjIA5tM0puWc+yZMbyCzCLxVH69j TM7/MzqtqMgMTJPrDrzq01vyrlngabruhCLT8739DajvSsvpqQ0bZ/njUQDE1vdjTn1n xYkAq4NRBi06kY1cCPqUYnctzjYHHSRQZadFrKKyBdQA3F+AOoLUTaSeeUjZjHjyKqSN /umQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20230601; t=1762766126; x=1763370926; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:x-gm-gg:x-gm-message-state:from :to:cc:subject:date:message-id:reply-to; bh=veHv/uRfxtfoSVQhbpvYC1/mXF+mOr0qW/T/KMequQ0=; b=rkPh7sDrjIldN7XA1CDH/+obBMN++paqIHWD8r0zyC3eF6uCLsvc27Rgf+HhIW0j6q mg6kgO1whtw2Ejta4wjV4BdtW4u8ifKpNNfT38xpdmM6pXwdUaifr22+AhxFUjWtoMN1 xsSZwRTN/CRbRaF6qNenhnMg4eo8CLu4yMFHqJOae4ehJzG5P6O9eJhwCJ8ixDYHTCQT ckwJtLNyPQoUFuTEFWdExody6TPHdXdoQfpBhqwA1Xu3US5C2RvZ25MolcW/UGQFyuTE Y6lN9VCtULPsAdaGX+doCZq957bmijDxYrutigWnnGqaEE2XgRaTi51+tqmxHz8dpzy2 cOrw== X-Forwarded-Encrypted: i=1; AJvYcCXvqWxUs84D3Ju6Spz/7vQwYOXwWd9UsDVBuQCJdS7nsg883aZwS7+RiDmAFaQzdPVhcNzLX1jV+HUHeQM=@vger.kernel.org X-Gm-Message-State: AOJu0YzL+MpF+ocFpeSxZHJKr5rJ39kt2zHKGF7Wu7lB6cNlHi4K0brK PkmULL7Yse2h6EbOBp+j6pMyovahkI2U3es+UqvF7Y5E29tgHa8WHLiO X-Gm-Gg: ASbGnctdWgvgfTuN2OrWHVrJK/A34QcUjpJyvxEKwc3iwIag+VT1q8PkwlqKbCmn8VN +Cr8PGP90uez9UhlR2w1sfRhpY0LK7Q45ZzU/UalhtULHLt5RiUzdbQH7XMZJO5Plne3N3WOJK9 V+btZ4TccPyCkafCgo3Vqe0V9OmLLa/94EnGP93M4cTL5za5gFouiMAjh1S91jk1B5EySG4igw9 +CYbd9Yx3ANcRKgwVO02gmI6Uh95XwFAImp9EZbrWV9uFQmmy7lYR4IhKv3u2lneouC8qw6zgf4 LReEyON3r9ua6z0MvLt9EVVvH9hYwSOHX2bEwvSy1tmAl5hyEeeE+0daDYPqD943InecC1Q6dS2 AoV4HK0esDLyWaqPhxFtX2gAHzg6A5nvI6iwtUEsdpAfMvryZr3yjG4e3yaNgqFIN X-Google-Smtp-Source: AGHT+IEYKC+UVtlSAdBpY8qGaxywx7G3p1nhsry/fr15fjGb+9mY1iP3g5oIkKF/qfU4YqicbtZh9Q== X-Received: by 2002:a05:6512:a96:b0:592:f44e:a28b with SMTP id 2adb3069b0e04-5945f1dfb7bmr2195041e87.57.1762766125833; Mon, 10 Nov 2025 01:15:25 -0800 (PST) Received: from xeon ([188.163.112.74]) by smtp.gmail.com with ESMTPSA id 2adb3069b0e04-5944a0b76f4sm3852006e87.73.2025.11.10.01.15.24 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 10 Nov 2025 01:15:25 -0800 (PST) From: Svyatoslav Ryhel To: Neil Armstrong , Maarten Lankhorst , Maxime Ripard , Thomas Zimmermann , David Airlie , Simona Vetter , Rob Herring , Krzysztof Kozlowski , Conor Dooley , Thierry Reding , Jonathan Hunter , Douglas Anderson , Svyatoslav Ryhel , Sam Ravnborg Cc: dri-devel@lists.freedesktop.org, devicetree@vger.kernel.org, linux-kernel@vger.kernel.org, linux-tegra@vger.kernel.org Subject: [PATCH v3 2/7 RESEND] gpu/drm: panel: add support for LG LD070WX3-SL01 MIPI DSI panel Date: Mon, 10 Nov 2025 11:14:32 +0200 Message-ID: <20251110091440.5251-3-clamor95@gmail.com> X-Mailer: git-send-email 2.51.0 In-Reply-To: <20251110091440.5251-1-clamor95@gmail.com> References: <20251110091440.5251-1-clamor95@gmail.com> Precedence: bulk X-Mailing-List: linux-kernel@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Transfer-Encoding: 8bit The LD070WX3 is a Color Active Matrix Liquid Crystal Display with an integral Light Emitting Diode (LED) backlight system. The matrix employs a-Si Thin Film Transistor as the active element. It is a transmissive type display operating in the normally Black mode. This TFT-LCD has 7.0 inches diagonally measured active display area with WXGA resolution (800 by 1280 pixel array). LG LD070WX3-SL01 MIPI DSI panel was treated as simple DSI panel when it is actually not and requires proper setup for correct work. Simple panel work relied on preliminary configuration done by bootloader. Signed-off-by: Svyatoslav Ryhel Reviewed-by: Douglas Anderson --- drivers/gpu/drm/panel/Kconfig | 13 ++ drivers/gpu/drm/panel/Makefile | 1 + drivers/gpu/drm/panel/panel-lg-ld070wx3.c | 184 ++++++++++++++++++++++ drivers/gpu/drm/panel/panel-simple.c | 31 ---- 4 files changed, 198 insertions(+), 31 deletions(-) create mode 100644 drivers/gpu/drm/panel/panel-lg-ld070wx3.c diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig index 045ffb2ccd0f..1f660ba065a1 100644 --- a/drivers/gpu/drm/panel/Kconfig +++ b/drivers/gpu/drm/panel/Kconfig @@ -408,6 +408,19 @@ config DRM_PANEL_LG_LB035Q02 (found on the Gumstix Overo Palo35 board). To compile this driver as a module, choose M here. +config DRM_PANEL_LG_LD070WX3 + tristate "LG LD070WX3 MIPI DSI panel" + depends on OF + depends on DRM_MIPI_DSI + depends on BACKLIGHT_CLASS_DEVICE + select VIDEOMODE_HELPERS + help + Say Y here if you want to enable support for the LD070WX3 MIPI DSI + panel found in the NVIDIA Tegra Note 7 tablet. + + To compile this driver as a module, choose M here: the module will + be called panel-lg-ld070wx3. + config DRM_PANEL_LG_LG4573 tristate "LG4573 RGB/SPI panel" depends on OF && SPI diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile index 0356775a443a..9281221183ac 100644 --- a/drivers/gpu/drm/panel/Makefile +++ b/drivers/gpu/drm/panel/Makefile @@ -41,6 +41,7 @@ obj-$(CONFIG_DRM_PANEL_LEADTEK_LTK050H3146W) += panel-leadtek-ltk050h3146w.o obj-$(CONFIG_DRM_PANEL_LEADTEK_LTK500HD1829) += panel-leadtek-ltk500hd1829.o obj-$(CONFIG_DRM_PANEL_LINCOLNTECH_LCD197) += panel-lincolntech-lcd197.o obj-$(CONFIG_DRM_PANEL_LG_LB035Q02) += panel-lg-lb035q02.o +obj-$(CONFIG_DRM_PANEL_LG_LD070WX3) += panel-lg-ld070wx3.o obj-$(CONFIG_DRM_PANEL_LG_LG4573) += panel-lg-lg4573.o obj-$(CONFIG_DRM_PANEL_LG_SW43408) += panel-lg-sw43408.o obj-$(CONFIG_DRM_PANEL_MAGNACHIP_D53E6EA8966) += panel-magnachip-d53e6ea8966.o diff --git a/drivers/gpu/drm/panel/panel-lg-ld070wx3.c b/drivers/gpu/drm/panel/panel-lg-ld070wx3.c new file mode 100644 index 000000000000..00cbfc5518a5 --- /dev/null +++ b/drivers/gpu/drm/panel/panel-lg-ld070wx3.c @@ -0,0 +1,184 @@ +// SPDX-License-Identifier: GPL-2.0-only + +#include +#include +#include +#include +#include +#include +#include +#include + +#include