From patchwork Tue Sep 6 18:36:41 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Morgan X-Patchwork-Id: 603584 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id BEABCECAAD5 for ; Tue, 6 Sep 2022 18:37:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229479AbiIFShI (ORCPT ); Tue, 6 Sep 2022 14:37:08 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37618 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229965AbiIFSg7 (ORCPT ); Tue, 6 Sep 2022 14:36:59 -0400 Received: from mail-oa1-x2f.google.com (mail-oa1-x2f.google.com [IPv6:2001:4860:4864:20::2f]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 78DB4844DA for ; Tue, 6 Sep 2022 11:36:47 -0700 (PDT) Received: by mail-oa1-x2f.google.com with SMTP id 586e51a60fabf-1278624b7c4so12106026fac.5 for ; Tue, 06 Sep 2022 11:36:47 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=VeAkYJr5cV7UOdIxHXK8x7A3sYToMzAJATkPDcxd6fI=; b=bCQ70kUcHUTtt9rFVZ5Od8WUAFgESMI/to12CwbZLkow3rucb6JtwGAQ1Nj+5LAH6g 27Ugslizd7++BDUk5czC9l2EQw2/ZII0WELNgprkopvuljx7OwDD5vj8wZYUuLkCBkto UCzXRbZ75vQW1cPd5nL+SElSY/c+YHCA078CpWB8sCIfjGHX8QnpNodlHsMKGHssDU48 OOELE19z32HfpHZ+i6iuPQ+TusZYGcq5WDBiLoxZG6mLRL5oIZ0/sDiUoryFi451vuJ4 L+QTRvuesYOSKGdH3zps/6uxIBJ9v6zlCy0GvPQ9nvhXYs3fox7OMA49+/dY9UhbN6zG WoKQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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; bh=VeAkYJr5cV7UOdIxHXK8x7A3sYToMzAJATkPDcxd6fI=; b=YHxOPUO+onlxURwQ7dHWzwErDi1O8vutCdYoIJ3wMiXD4rgaE9qKm5bGTeV7aP+vWq HTYEEnM2MFSSuTzHpvtH69SPn9vbIURAHMaNih8Pt1GTNLMX826E/8n5Kwq8HUAU9gW1 XC9NcJi7Hgk2gKkjp2zBTzcCiHiYQaiEmvl9r/HUMltvfaYfm+0XZxMX9RlmGC6wAWmw 5oYessU628N6B8N9NGPfIFL1cD+KCnfQdwSRaJMiZGFoJBielnYWEG7e3S98AFj0vUb2 DnGoPppMUbzBEQMl+Cs7bOvPTMGWL6sKmBkO9U9fh0ymQ1O3y4axKuFZLtj2/RwBys0L 69Eg== X-Gm-Message-State: ACgBeo17w+oCeRxc7xF37MQcXOu3V/1grXUV743m1w2W4l5H9LeUsV1c IcWVRTkA1WdrPW5Sfg/3/94= X-Google-Smtp-Source: AA6agR5WocPFsE3jYbjBJ9QILHNVCwf5Jv70R9n2QdLurAWCvwsdRgs51KteWK07As+QWPUt/vJq2Q== X-Received: by 2002:a05:6870:3449:b0:11d:1e78:266c with SMTP id i9-20020a056870344900b0011d1e78266cmr13232094oah.122.1662489406869; Tue, 06 Sep 2022 11:36:46 -0700 (PDT) Received: from wintermute.localdomain (cpe-76-183-134-35.tx.res.rr.com. [76.183.134.35]) by smtp.gmail.com with ESMTPSA id j22-20020a9d7f16000000b00638ef9bb847sm6158887otq.79.2022.09.06.11.36.46 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Sep 2022 11:36:46 -0700 (PDT) From: Chris Morgan To: dri-devel@lists.freedesktop.org Cc: devicetree@vger.kernel.org, krzysztof.kozlowski+dt@linaro.org, robh+dt@kernel.org, daniel@ffwll.ch, airlied@linux.ie, sam@ravnborg.org, thierry.reding@gmail.com, Chris Morgan Subject: [PATCH 1/2] dt-bindings: display: panel: Add Samsung AMS495QA01 panel bindings Date: Tue, 6 Sep 2022 13:36:41 -0500 Message-Id: <20220906183642.12505-2-macroalpha82@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220906183642.12505-1-macroalpha82@gmail.com> References: <20220906183642.12505-1-macroalpha82@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Chris Morgan Add documentation for the Samsung AMS495QA01 panel. Signed-off-by: Chris Morgan --- .../display/panel/samsung,ams495qa01.yaml | 49 +++++++++++++++++++ 1 file changed, 49 insertions(+) create mode 100644 Documentation/devicetree/bindings/display/panel/samsung,ams495qa01.yaml diff --git a/Documentation/devicetree/bindings/display/panel/samsung,ams495qa01.yaml b/Documentation/devicetree/bindings/display/panel/samsung,ams495qa01.yaml new file mode 100644 index 000000000000..e7373846e7d8 --- /dev/null +++ b/Documentation/devicetree/bindings/display/panel/samsung,ams495qa01.yaml @@ -0,0 +1,49 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/display/panel/samsung,ams495qa01.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Samsung AMS495QA01 4.95in 960x544 DSI/SPI panel + +maintainers: + - Chris Morgan + +allOf: + - $ref: panel-common.yaml# + +properties: + compatible: + const: samsung,ams495qa01 + reg: true + reset-gpios: true + elvdd-supply: + description: regulator that supplies voltage to the panel + enable-gpios: true + port: true + vdd-supply: + description: regulator that supplies voltage to panel logic + +required: + - compatible + - reg + - elvdd-supply + - vdd-supply + +additionalProperties: false + +examples: + - | + spi { + #address-cells = <1>; + #size-cells = <0>; + panel@0 { + compatible = "samsung,ams495qa01"; + reg = <0>; + backlight = <&backlight>; + elvdd-supply = <&vcc_sys>; + vdd-supply = <&vcc3v3_lcd0_n>; + }; + }; + +... From patchwork Tue Sep 6 18:52:08 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Morgan X-Patchwork-Id: 603582 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 vger.kernel.org (vger.kernel.org [23.128.96.18]) by smtp.lore.kernel.org (Postfix) with ESMTP id DCCBAECAAA1 for ; Tue, 6 Sep 2022 18:52:18 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229543AbiIFSwR (ORCPT ); Tue, 6 Sep 2022 14:52:17 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33618 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229540AbiIFSwQ (ORCPT ); Tue, 6 Sep 2022 14:52:16 -0400 Received: from mail-oa1-x29.google.com (mail-oa1-x29.google.com [IPv6:2001:4860:4864:20::29]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id C8D8380485 for ; Tue, 6 Sep 2022 11:52:14 -0700 (PDT) Received: by mail-oa1-x29.google.com with SMTP id 586e51a60fabf-1278a61bd57so11912132fac.7 for ; Tue, 06 Sep 2022 11:52:14 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:references:in-reply-to :message-id:date:subject:cc:to:from:from:to:cc:subject:date; bh=YPktpomhXdnRkrCR6CBSt1ACWZQ4QwUVMPMuYlEKAQY=; b=KD3PPj9zM4qIOSJ8HNwWjx9UBUAzvvhWfFP6G5FcSEA14hfbYhT0aL+nFiLcgw8kqv ckkWxMm1MxngkSDMbwuGLjyDBN4tdcGlvwEl7O2fv/AokVuBC5RRFTUb5HoDI8k3MYqC FK2Jm0myOjgpUzjxdK7R64ZGhSjzVnqi3RvYxwhL6pqexcTuc873E8I2rkOnLjIYYUeF kecnFCJoc4mHUh/xdJxZFHFOqnhaSZ/tPUZDrOwGmnMmWpdyNfBx8K9LDXObn+6c5qyK yr4f2on+wckduLtBZ/AtxM/rET/sS/QyARwKq2PexCUGWehmPGLxLDiugybbBL782oGS pRXg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; 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; bh=YPktpomhXdnRkrCR6CBSt1ACWZQ4QwUVMPMuYlEKAQY=; b=CuBq8qW2gvJktUOQ7oE+Ler/MyXcUzkLi+yrXvimHy/h95v4yKqQfRn3gUOvhKN1FS u9RTv6Kg7TaVFmIpTR2TBdzUoIO+I+4vsvMtDJhWrEmwOi0gJGyT6xIGrMp6xGXfWrWS mnFgq0IdpnYuKRy6tz9Kc3DrMKxyhCKevhzdzeDOLf4msATfcf1Jv1DvHWbnknYB1GvA sdw0X5L0ABWIeAB07LAbDCxfWSLQoSCwXmt/svym97fcmXMwbMVsMUx8qTLxonDIjNsQ LbGYtS+PsspeVjBoC6HBp2esN2ZX5AyeukudtDN365nAct5/fvwYtZB6JUMzTwZFIT41 n8XQ== X-Gm-Message-State: ACgBeo0co5HMkXTrmgfRD+N3D8WymhNzeqihIgFewzrsjjHQ41sgTSvB aIidTExmWglHiXEyk/Gp9ms= X-Google-Smtp-Source: AA6agR6u8zOSPs/1GVqrFF6x32x1I6ZTdEVVWxxhrVgg6BSaVxFh/XkVuH+hhCaSXqPgDmT17xCzXA== X-Received: by 2002:a05:6870:1718:b0:127:399a:b26f with SMTP id h24-20020a056870171800b00127399ab26fmr6811870oae.158.1662490333926; Tue, 06 Sep 2022 11:52:13 -0700 (PDT) Received: from wintermute.localdomain (cpe-76-183-134-35.tx.res.rr.com. [76.183.134.35]) by smtp.gmail.com with ESMTPSA id f205-20020aca38d6000000b003449ff2299esm5666177oia.4.2022.09.06.11.52.13 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Sep 2022 11:52:13 -0700 (PDT) From: Chris Morgan To: dri-devel@lists.freedesktop.org Cc: devicetree@vger.kernel.org, krzysztof.kozlowski+dt@linaro.org, robh+dt@kernel.org, daniel@ffwll.ch, airlied@linux.ie, sam@ravnborg.org, thierry.reding@gmail.com, Chris Morgan Subject: [PATCH 2/2] drm/panel: Add NewVision NV3051D MIPI-DSI LCD panel Date: Tue, 6 Sep 2022 13:52:08 -0500 Message-Id: <20220906185208.13395-3-macroalpha82@gmail.com> X-Mailer: git-send-email 2.25.1 In-Reply-To: <20220906185208.13395-1-macroalpha82@gmail.com> References: <20220906185208.13395-1-macroalpha82@gmail.com> MIME-Version: 1.0 Precedence: bulk List-ID: X-Mailing-List: devicetree@vger.kernel.org From: Chris Morgan Support NewVision NV3051D panels as found on the Anbernic RG353P and RG353V. The underlying panel part number for the RG353x devices is unknown, so the device name is used instead. Signed-off-by: Chris Morgan --- drivers/gpu/drm/panel/Kconfig | 9 + drivers/gpu/drm/panel/Makefile | 1 + .../gpu/drm/panel/panel-newvision-nv3051d.c | 478 ++++++++++++++++++ 3 files changed, 488 insertions(+) create mode 100644 drivers/gpu/drm/panel/panel-newvision-nv3051d.c diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig index a9043eacce97..7258d28dda2f 100644 --- a/drivers/gpu/drm/panel/Kconfig +++ b/drivers/gpu/drm/panel/Kconfig @@ -296,6 +296,15 @@ config DRM_PANEL_NEC_NL8048HL11 panel (found on the Zoom2/3/3630 SDP boards). To compile this driver as a module, choose M here. +config DRM_PANEL_NEWVISION_NV3051D + tristate "NewVision NV3051D DSI panel" + depends on OF + depends on DRM_MIPI_DSI + depends on BACKLIGHT_CLASS_DEVICE + help + This driver supports the NV3051D based panel found on the Anbernic + RG353P and RG353V. + config DRM_PANEL_NEWVISION_NV3052C tristate "NewVision NV3052C RGB/SPI panel" depends on OF && SPI diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile index 34e717382dbb..cb03b3a82738 100644 --- a/drivers/gpu/drm/panel/Makefile +++ b/drivers/gpu/drm/panel/Makefile @@ -27,6 +27,7 @@ obj-$(CONFIG_DRM_PANEL_LEADTEK_LTK500HD1829) += panel-leadtek-ltk500hd1829.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_NEC_NL8048HL11) += panel-nec-nl8048hl11.o +obj-$(CONFIG_DRM_PANEL_NEWVISION_NV3051D) += panel-newvision-nv3051d.o obj-$(CONFIG_DRM_PANEL_NEWVISION_NV3052C) += panel-newvision-nv3052c.o obj-$(CONFIG_DRM_PANEL_NOVATEK_NT35510) += panel-novatek-nt35510.o obj-$(CONFIG_DRM_PANEL_NOVATEK_NT35560) += panel-novatek-nt35560.o diff --git a/drivers/gpu/drm/panel/panel-newvision-nv3051d.c b/drivers/gpu/drm/panel/panel-newvision-nv3051d.c new file mode 100644 index 000000000000..c46edd4df765 --- /dev/null +++ b/drivers/gpu/drm/panel/panel-newvision-nv3051d.c @@ -0,0 +1,478 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * NV3051D MIPI-DSI panel driver for Anbernic RG353x + * Copyright (C) 2022 Chris Morgan + * + * based on + * + * Elida kd35t133 3.5" MIPI-DSI panel driver + * Copyright (C) Theobroma Systems 2020 + */ + +#include +#include +#include +#include +#include +#include + +#include