From patchwork Mon Jan 9 08:49:30 2023 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Neil Armstrong X-Patchwork-Id: 13093157 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 23CDCC677F1 for ; Mon, 9 Jan 2023 08:49:49 +0000 (UTC) Received: from gabe.freedesktop.org (localhost [127.0.0.1]) by gabe.freedesktop.org (Postfix) with ESMTP id 0B16F10E380; Mon, 9 Jan 2023 08:49:42 +0000 (UTC) Received: from mail-wm1-x32a.google.com (mail-wm1-x32a.google.com [IPv6:2a00:1450:4864:20::32a]) by gabe.freedesktop.org (Postfix) with ESMTPS id 24C7910E380 for ; Mon, 9 Jan 2023 08:49:38 +0000 (UTC) Received: by mail-wm1-x32a.google.com with SMTP id z8-20020a05600c220800b003d33b0bda11so6734670wml.0 for ; Mon, 09 Jan 2023 00:49:38 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:from:to:cc:subject:date:message-id :reply-to; bh=wXjPbyrPP49p0O5pBUzIB0DmkgrdNUpNzhSiFyPfgoA=; b=Gx7m7H9c/IYeWajz26M6CvOCQCe2cb0oyXpme52MlMumm11e3e/9Q3qqlT1DZplIu/ wcGPQGjI749KBAdx+YLIKojTvavTo4xa70sY2QoHcMLgv+hsOTrbcSqouQClmI4GLT0F peKXtroZnl61mRObSTJ+PSkbcY7fOFw3cRsqMe83vWvXOjCy7gxvCxHR3LXyUZh0vH1H gH9amwsU2bjovidpdPklQdZxfnj2xE/eo3enKgbYjkeCe/6Oa3+X0WUkJHhQWJSBwkFT Jn5ftX1HsLMgDrr+GxahXeKx7FTxyjeIaIB+juSP6XCxp+SYMhm2xBclKiSunPxuMU7C iY8g== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=cc:to:in-reply-to:references:message-id:content-transfer-encoding :mime-version:subject:date:from:x-gm-message-state:from:to:cc :subject:date:message-id:reply-to; bh=wXjPbyrPP49p0O5pBUzIB0DmkgrdNUpNzhSiFyPfgoA=; b=w9ybd85GM7f9y8akVdIvOOTvTBzMLWNHiu6YPo+o2w7mHvakNIC0W3cf4G844Wecgw pH8M/6F5B+8OtKPwt80a1Jb0op4nz27TM/wX71B5hhRFU3NyX44z1YUbHdMdn3Sd0gh0 3N9TPWOs6z4fLwCGbtTS8aU5p4z8RT3vlwtShYvdleo4zchVunFJUlJDJNbY2NltyntH 12bq8sNlwuuflJzVKZchpN1oOvUrj8DvzOeLerUL6Yv8aZZXubL6ateYFCmI5hLuplFR dFUEQEdmV3ccdeXejuRHp1S+H/87sws7AvRvEg+Zlqkv7pI/TMJimnb+1DOyZSTNCEuX mq+g== X-Gm-Message-State: AFqh2krdqFkxqpjY8hyUMu9Fetw6puRAuEEFapDJTOnl+KEXwbdBC9bR Tn9HzG/Hb4vZMFHY8Q/eyZM8dQ== X-Google-Smtp-Source: AMrXdXu3vyy+JqtqbmdkKBAObq+6OFv4a8O1t+Zw78NtfIKj24rxOaXikO/bbgEDhmEjTk3IiUTANg== X-Received: by 2002:a05:600c:35d1:b0:3d3:58d1:2588 with SMTP id r17-20020a05600c35d100b003d358d12588mr47000653wmq.41.1673254176578; Mon, 09 Jan 2023 00:49:36 -0800 (PST) Received: from arrakeen.starnux.net ([2a01:e0a:982:cbb0:52eb:f6ff:feb3:451a]) by smtp.gmail.com with ESMTPSA id az28-20020a05600c601c00b003cf57329221sm15039619wmb.14.2023.01.09.00.49.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 09 Jan 2023 00:49:36 -0800 (PST) From: Neil Armstrong Date: Mon, 09 Jan 2023 09:49:30 +0100 Subject: [PATCH v2 2/2] drm/panel: add visionox vtdr6130 DSI panel driver MIME-Version: 1.0 Message-Id: <20230103-topic-sm8550-upstream-vtdr6130-panel-v2-2-dd6200f47a76@linaro.org> References: <20230103-topic-sm8550-upstream-vtdr6130-panel-v2-0-dd6200f47a76@linaro.org> In-Reply-To: <20230103-topic-sm8550-upstream-vtdr6130-panel-v2-0-dd6200f47a76@linaro.org> To: Thierry Reding , Sam Ravnborg , David Airlie , Daniel Vetter , Rob Herring , Krzysztof Kozlowski X-Mailer: b4 0.11.1 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, Neil Armstrong , linux-arm-msm@vger.kernel.org, linux-kernel@vger.kernel.org, dri-devel@lists.freedesktop.org, Krzysztof Kozlowski Errors-To: dri-devel-bounces@lists.freedesktop.org Sender: "dri-devel" Add support for the 1080x2400 Visionox VTDR6130 AMOLED DSI panel found on the Qualcomm SM8550 MTP board. By default the the panel is configured to work with DSI compressed streams, but can work in uncompressed video mode since 1080x2400 in RGB888 fits in the 4 DSI lanes bandwidth. While display compression is preferred for performance and power reasons, let's start with the uncompressed video mode support and add the DSC support later on. Signed-off-by: Neil Armstrong Reviewed-by: Sam Ravnborg --- drivers/gpu/drm/panel/Kconfig | 8 + drivers/gpu/drm/panel/Makefile | 1 + drivers/gpu/drm/panel/panel-visionox-vtdr6130.c | 358 ++++++++++++++++++++++++ 3 files changed, 367 insertions(+) diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig index 737edcdf9eef..fd1d7e6f536b 100644 --- a/drivers/gpu/drm/panel/Kconfig +++ b/drivers/gpu/drm/panel/Kconfig @@ -717,6 +717,14 @@ config DRM_PANEL_VISIONOX_RM69299 Say Y here if you want to enable support for Visionox RM69299 DSI Video Mode panel. +config DRM_PANEL_VISIONOX_VTDR6130 + tristate "Visionox VTDR6130" + depends on OF + depends on DRM_MIPI_DSI + help + Say Y here if you want to enable support for Visionox + VTDR6130 1080x2400 AMOLED DSI panel. + config DRM_PANEL_WIDECHIPS_WS2401 tristate "Widechips WS2401 DPI panel driver" depends on SPI && GPIOLIB diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile index f8f9d9f6a307..1966404fcf7a 100644 --- a/drivers/gpu/drm/panel/Makefile +++ b/drivers/gpu/drm/panel/Makefile @@ -73,5 +73,6 @@ obj-$(CONFIG_DRM_PANEL_TPO_TD043MTEA1) += panel-tpo-td043mtea1.o obj-$(CONFIG_DRM_PANEL_TPO_TPG110) += panel-tpo-tpg110.o obj-$(CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA) += panel-truly-nt35597.o obj-$(CONFIG_DRM_PANEL_VISIONOX_RM69299) += panel-visionox-rm69299.o +obj-$(CONFIG_DRM_PANEL_VISIONOX_VTDR6130) += panel-visionox-vtdr6130.o obj-$(CONFIG_DRM_PANEL_WIDECHIPS_WS2401) += panel-widechips-ws2401.o obj-$(CONFIG_DRM_PANEL_XINPENG_XPP055C272) += panel-xinpeng-xpp055c272.o diff --git a/drivers/gpu/drm/panel/panel-visionox-vtdr6130.c b/drivers/gpu/drm/panel/panel-visionox-vtdr6130.c new file mode 100644 index 000000000000..c107c88b22b4 --- /dev/null +++ b/drivers/gpu/drm/panel/panel-visionox-vtdr6130.c @@ -0,0 +1,358 @@ +// SPDX-License-Identifier: GPL-2.0-only +// Copyright (c) 2023, Linaro Limited + +#include +#include +#include +#include +#include +#include + +#include +#include +#include +#include + +#include