From patchwork Tue Sep 6 18:52:07 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Morgan X-Patchwork-Id: 603156 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 91C9FC38145 for ; Tue, 6 Sep 2022 18:52:16 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229446AbiIFSwP (ORCPT ); Tue, 6 Sep 2022 14:52:15 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:33598 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229504AbiIFSwO (ORCPT ); Tue, 6 Sep 2022 14:52:14 -0400 Received: from mail-oa1-x36.google.com (mail-oa1-x36.google.com [IPv6:2001:4860:4864:20::36]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 970F1804B9 for ; Tue, 6 Sep 2022 11:52:13 -0700 (PDT) Received: by mail-oa1-x36.google.com with SMTP id 586e51a60fabf-1225219ee46so30530135fac.2 for ; Tue, 06 Sep 2022 11:52:13 -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=MidhS3igYoUpLnAxSJdLelh/Ov0WSVkJewFCKlWvPtM=; b=Azs+faEsfXk3//86XNbsAdPMreNFiOcqhTuB4uMpN5PPZ4wClgRTo+oMDFPk8o1M5H /ELKD7c62CPYnMaQYa3jZcJgJwE6ZyNYC2N5GfOcLXbyl4zCWJ5zGIdVfPRTMewIS8Ha 0Y2HeK3XeVg1TJF7eKAIs+DCEQrfm0a+kHQhiWxrZLpzGRr4BCJV9xF26N35tHTrhcR3 8e9KF0mJn+Xoj0Dcn/YXU89ghZz4jWU4EQyP3cFg1dcEdCnjTil5/yVWB384sbmM39Ea 0wPLAk8RUeYFqbidFTRD0m0CESO+4usuWAb0z+XI+Qk3TDzbDpSkg3z+vClGVx6TlkNe e6Nw== 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=MidhS3igYoUpLnAxSJdLelh/Ov0WSVkJewFCKlWvPtM=; b=tu1pGrUPM8Qm26oRQzO6Mi0/5GNj7OlAwJy8u8IfuVRl3L2uwsqrRjI1+7EJsg2iWN mddWOLIQKNTCN+DWXYIacQzm/fOjvmzX69xXAovii0u/GSgxUXEZuoBPdKXwj2V4v4D9 0OlgaZLESZ7Zn7im4xz8GRyo/y/aMOm5ztJ2+id+bgrFrc3HGh5G7GOJ+wF3B4FWw+lN NaHyc1zbLSNNqXwfNEodJDwXtKNQ4i7bPPyrAgy+ZT2Cm83IdGc69fdBDEa9x0JtrShZ 6NFmHRNo9BNfsolQWz2f1JMkQAHhF1H2CvREnIYPPpTB5Z7Ku1D6ZeQs72U4Xz9vNY0H 1Asw== X-Gm-Message-State: ACgBeo3W/pyr8N2YFMXIrcOAu0rqF9h5CwTd7SXryO4zFamrgb875BN2 Tt4hVBi8Tfgj1mT/3knXeNw= X-Google-Smtp-Source: AA6agR4BYZZ1kZJXckhyO4mbuTaJAsiCAB6z0uGN28nhIcyOGFqx4mExeJ8uyakOA9d9+pxgkO/dkA== X-Received: by 2002:a05:6808:190f:b0:343:ba2:7d4d with SMTP id bf15-20020a056808190f00b003430ba27d4dmr9902396oib.227.1662490333007; 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.12 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Tue, 06 Sep 2022 11:52:12 -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 NewVision NV3051D panel bindings Date: Tue, 6 Sep 2022 13:52:07 -0500 Message-Id: <20220906185208.13395-2-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 Add documentation for the NewVision NV3051D panel bindings. Note that for the two expected consumers of this panel binding the underlying LCD model is unknown. Signed-off-by: Chris Morgan --- .../display/panel/newvision,nv3051d.yaml | 48 +++++++++++++++++++ 1 file changed, 48 insertions(+) create mode 100644 Documentation/devicetree/bindings/display/panel/newvision,nv3051d.yaml diff --git a/Documentation/devicetree/bindings/display/panel/newvision,nv3051d.yaml b/Documentation/devicetree/bindings/display/panel/newvision,nv3051d.yaml new file mode 100644 index 000000000000..016168d8d7b2 --- /dev/null +++ b/Documentation/devicetree/bindings/display/panel/newvision,nv3051d.yaml @@ -0,0 +1,48 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/display/panel/newvision,nv3051d.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: NewVision NV3051D based DSI panel driver + +maintainers: + - Chris Morgan + +allOf: + - $ref: panel-common.yaml# + +properties: + compatible: + enum: + - anbernic,rg353p-panel + - anbernic,rg353v-panel + reg: true + backlight: true + port: true + reset-gpios: true + vdd-supply: + description: regulator that supplies the vdd voltage + +required: + - compatible + - reg + - backlight + - vdd-supply + +additionalProperties: false + +examples: + - | + dsi { + #address-cells = <1>; + #size-cells = <0>; + panel@0 { + compatible = "anbernic,rg353p-panel"; + reg = <0>; + backlight = <&backlight>; + vdd-supply = <&vcc3v3_lcd>; + }; + }; + +... From patchwork Tue Sep 6 18:36:42 2022 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Chris Morgan X-Patchwork-Id: 603157 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 43F94ECAAA1 for ; Tue, 6 Sep 2022 18:37:37 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S229514AbiIFShG (ORCPT ); Tue, 6 Sep 2022 14:37:06 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:37724 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S229918AbiIFShC (ORCPT ); Tue, 6 Sep 2022 14:37:02 -0400 Received: from mail-oa1-x30.google.com (mail-oa1-x30.google.com [IPv6:2001:4860:4864:20::30]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 4B2F19E2ED for ; Tue, 6 Sep 2022 11:36:49 -0700 (PDT) Received: by mail-oa1-x30.google.com with SMTP id 586e51a60fabf-11e9a7135easo30340369fac.6 for ; Tue, 06 Sep 2022 11:36:49 -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=y9g1AFP23iUxIbJ/LupHZ67b+12wZhLD3PiLPF+2Q5E=; b=ZDlPY9byR8JEcQu/dH3WKXa0aCDcAavSMotIz6syh2sUJv8mzy5U68jLhCCb78j//m aW6AhoCIFr47+jwmEyTMqZ+gTITnNufGsNqXCC/bLB51sa7kaCVz3vEhvL6skbsQ4p/l FWsZIf6yeH1NCP/6hP0CLLR+2TzV/VCyQER/OqJkj/QLopQtnIqSd+fP/PDIgwiPB/tq 1bV57+hcujLuAU4HO/Gkf+fTgBLy3mchyS/NG/DUCj6tyvqco5WJnuEu8YYhoLTKQhXU h21RZJ8VZWLSNOIwwYfE89BBtJ3hAxxuMaQQl6EUD0Jr82fvzoYQqg58ZFsf67wx/2dX T+Xw== 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=y9g1AFP23iUxIbJ/LupHZ67b+12wZhLD3PiLPF+2Q5E=; b=JTH3VDBrRejP5CHYCAC/NvHr05948Qe2c09dYnDIZWfAo6+jwl2AbrQouFJeGLh/No 6JxYTfuWFjyx4kJ3DPqpJSQEDSZ1PDbrnioEYjYpZz4l83vFWUh/WAzB571jocGsqsJE N9oXKAI2jAkbOigs15Edzy5+V7So92reqyGVoFZBAVlpwxfxOcPAFvfowa4PkNCk1lm2 Aw6laAM6MJxsX/Y91Rt4g1tSsxEr0JmjiVhK7GiE4d3HtkoJLB4WUa2HU5imVbNl5ol8 U/Ea++sYFso/jfr6tJiZuceY++5Qt/Ftw3IYKSvoDlMp84IaNHPVnU9JKgK//iZIZOmy 6NFg== X-Gm-Message-State: ACgBeo37mes0UbUkYZYc1Mi8cyToyA17v+omtoKdycfmkQ63pkhtQBiy hZuKBJFcZgMkq/3FofD5DtE= X-Google-Smtp-Source: AA6agR65tKewA/n8u3zJssvGA00Lj56dHbucb4LIBfb85mT7+/Pp0kVZ2UyelV6wT6DGV/upx/fk3g== X-Received: by 2002:a05:6808:643:b0:343:1207:b0b7 with SMTP id z3-20020a056808064300b003431207b0b7mr10624055oih.97.1662489407838; Tue, 06 Sep 2022 11:36:47 -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:47 -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 Samsung AMS495QA01 MIPI-DSI LCD panel Date: Tue, 6 Sep 2022 13:36:42 -0500 Message-Id: <20220906183642.12505-3-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 Support Samsung AMS495QA01 panel as found on the Anbernic RG503. Note This panel receives video signals via DSI, however it receives commands via 3-wire SPI. Signed-off-by: Chris Morgan --- drivers/gpu/drm/panel/Kconfig | 10 + drivers/gpu/drm/panel/Makefile | 1 + .../gpu/drm/panel/panel-samsung-ams495qa01.c | 468 ++++++++++++++++++ 3 files changed, 479 insertions(+) create mode 100644 drivers/gpu/drm/panel/panel-samsung-ams495qa01.c diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig index a9043eacce97..954b66a2adee 100644 --- a/drivers/gpu/drm/panel/Kconfig +++ b/drivers/gpu/drm/panel/Kconfig @@ -444,6 +444,16 @@ config DRM_PANEL_RONBO_RB070D30 Say Y here if you want to enable support for Ronbo Electronics RB070D30 1024x600 DSI panel. +config DRM_PANEL_SAMSUNG_AMS495QA01 + tristate "Samsung AMS495QA01 DSI panel" + depends on OF && SPI + depends on DRM_MIPI_DSI + select DRM_MIPI_DBI + help + DRM panel driver for the Samsung AMS495QA01 panel. This panel + receives video data via DSI but commands via 3-Wire 9-bit + SPI. + config DRM_PANEL_SAMSUNG_ATNA33XC20 tristate "Samsung ATNA33XC20 eDP panel" depends on OF diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile index 34e717382dbb..de0b57baf851 100644 --- a/drivers/gpu/drm/panel/Makefile +++ b/drivers/gpu/drm/panel/Makefile @@ -42,6 +42,7 @@ obj-$(CONFIG_DRM_PANEL_RASPBERRYPI_TOUCHSCREEN) += panel-raspberrypi-touchscreen obj-$(CONFIG_DRM_PANEL_RAYDIUM_RM67191) += panel-raydium-rm67191.o obj-$(CONFIG_DRM_PANEL_RAYDIUM_RM68200) += panel-raydium-rm68200.o obj-$(CONFIG_DRM_PANEL_RONBO_RB070D30) += panel-ronbo-rb070d30.o +obj-$(CONFIG_DRM_PANEL_SAMSUNG_AMS495QA01) += panel-samsung-ams495qa01.o obj-$(CONFIG_DRM_PANEL_SAMSUNG_ATNA33XC20) += panel-samsung-atna33xc20.o obj-$(CONFIG_DRM_PANEL_SAMSUNG_DB7430) += panel-samsung-db7430.o obj-$(CONFIG_DRM_PANEL_SAMSUNG_LD9040) += panel-samsung-ld9040.o diff --git a/drivers/gpu/drm/panel/panel-samsung-ams495qa01.c b/drivers/gpu/drm/panel/panel-samsung-ams495qa01.c new file mode 100644 index 000000000000..60afea40a60e --- /dev/null +++ b/drivers/gpu/drm/panel/panel-samsung-ams495qa01.c @@ -0,0 +1,468 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * Samsung ams495qa01 MIPI-DSI panel driver + * Copyright (C) 2022 Chris Morgan + */ + +#include +#include +#include +#include + +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include +#include + +#include