From nobody Sun Feb 8 06:04:44 2026 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 59754C77B7F for ; Fri, 19 May 2023 14:25:45 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232006AbjESOZn (ORCPT ); Fri, 19 May 2023 10:25:43 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48926 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231955AbjESOZi (ORCPT ); Fri, 19 May 2023 10:25:38 -0400 Received: from mail-wm1-x32d.google.com (mail-wm1-x32d.google.com [IPv6:2a00:1450:4864:20::32d]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 3EE8A13D; Fri, 19 May 2023 07:25:36 -0700 (PDT) Received: by mail-wm1-x32d.google.com with SMTP id 5b1f17b1804b1-3f42711865eso21311715e9.0; Fri, 19 May 2023 07:25:36 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1684506335; x=1687098335; 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=rXL/sILoWENE3XBFz1jyrq42x+BgMkEmVV3BRtYQa0Q=; b=YcB1o1a36BNLAprjM6dWjokGpYysOeAU42OoeY4hhjvq+oZJ/O6ahscJvJJ+CLczDz sL5iYNswIapoQeBwm/FlDrHrTZ2j08UZ6wzgvGryd2MARBlmwMH0PeJL7rIztafeJwag Vub7GL3cKL6lCfTioP2cODsWWwkz6uwEZ2WFTRG0RQGNmKD3DbM28DUFhUrz6ctNXu5H eyk6oN0Wi6HmF2ts02vujMj+mK0+xHRN1zezCWjh/NcezmO9ZI28M33vrR0IZBNE4yjo HDJ38MberoUJbmx3l6bp+p+qjY42fkZhsIrClpyyHvn8ODIzGGyjmEhe27zsRudB3fQd VsTg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684506335; x=1687098335; 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=rXL/sILoWENE3XBFz1jyrq42x+BgMkEmVV3BRtYQa0Q=; b=GnY2/Q+BCJTZuNwxTK1+922bng0da64xvB5KXIz0Wj299oUyu+WFbNWsc3bLOdNyft URMb4JGx573hVrcmaGWERvuPNGSksbHTFaA2VX6urrPBzrjUMUQv90p1pku2mINU5Pr6 JKov5FnZoVK3iTn1ON+RQcGduiMK+V7Qjht3jMp6vTxHzgDwIxfrUep+/a0J0pWjYY5b EGWrhCo6ceZT146VXRFx9onSqDW5xjOQhIlVhiacTUXoI8//DAL0EPbtcBjYSK2zhm2p 6LYQGhYd65Lt/TbupLbU/K7MSmRs9tCh4EI7mZgWEgAnHSv8G092926sf1sT8GgAj2GK p3rA== X-Gm-Message-State: AC+VfDyZJ30eb7kLaC5/5qeUoXNUBcUOYV5JqUBlULWYOEl/XJKh5jko UR0hQ6mInnDd07eFKdMQb/Y= X-Google-Smtp-Source: ACHHUZ6DEEtxI4PqKANjVq7Q/b0VWEQq6K+AFaI3Nf8PB6N/OnFiCs10kk/8RYmpJIt9yL4yV3/qgw== X-Received: by 2002:a7b:ce96:0:b0:3f4:1a97:ab07 with SMTP id q22-20020a7bce96000000b003f41a97ab07mr1562669wmj.8.1684506334498; Fri, 19 May 2023 07:25:34 -0700 (PDT) Received: from fedora.. ([95.168.116.22]) by smtp.gmail.com with ESMTPSA id h12-20020a5d4fcc000000b003062b2c5255sm5451748wrw.40.2023.05.19.07.25.33 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 19 May 2023 07:25:34 -0700 (PDT) From: Paulo Pavacic To: neil.armstrong@linaro.org, sam@ravnborg.org, airlied@gmail.com, daniel@ffwll.ch, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Paulo Pavacic Subject: [PATCH 1/2] dt-bindings: display: panel: add fannal,c3004 Date: Fri, 19 May 2023 16:24:55 +0200 Message-Id: <20230519142456.2588145-2-pavacic.p@gmail.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230519142456.2588145-1-pavacic.p@gmail.com> References: <20230519142456.2588145-1-pavacic.p@gmail.com> MIME-Version: 1.0 Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Type: text/plain; charset="utf-8" Added fannal to vendor-prefixes and dt bindings for Fannal C3004. Fannal C3004 is a 480x800 MIPI DSI Panel which requires DCS initialization sequences with certain delays between certain commands. Signed-off-by: Paulo Pavacic --- v3 changelog: - renamed yml file - refactored yml file to describe fannal,c3004 - added matrix URI to MAINTAINERS v2 changelog: - revised driver title, now describes purpose - revised description, now describes hw - revised maintainers, now has only 1 mail - removed diacritics from commit/commit author - properties/compatible is now enum - compatible using only lowercase - revised dts example - modified MAINTAINERS in this commit (instead of driver commit) - dt_bindings_check checked yml - checkpatch warning fixed --- .../bindings/display/panel/fannal,c3004.yaml | 75 +++++++++++++++++++ .../devicetree/bindings/vendor-prefixes.yaml | 2 + MAINTAINERS | 6 ++ 3 files changed, 83 insertions(+) create mode 100644 Documentation/devicetree/bindings/display/panel/fannal,= c3004.yaml diff --git a/Documentation/devicetree/bindings/display/panel/fannal,c3004.y= aml b/Documentation/devicetree/bindings/display/panel/fannal,c3004.yaml new file mode 100644 index 000000000000..a86b5ce02aa2 --- /dev/null +++ b/Documentation/devicetree/bindings/display/panel/fannal,c3004.yaml @@ -0,0 +1,75 @@ +# SPDX-License-Identifier: (GPL-2.0-only OR BSD-2-Clause) +%YAML 1.2 +--- +$id: http://devicetree.org/schemas/display/panel/fannal,c3004.yaml# +$schema: http://devicetree.org/meta-schemas/core.yaml# + +title: Fannal C3004 MIPI-DSI + +maintainers: + - Paulo Pavacic + +description: | + Fannal C3004 is a 480x800 panel which requires DSI DCS + initialization sequences. + +allOf: + - $ref: panel-common.yaml# + +properties: + compatible: + items: + - const: fannal,c3004 + + reg: true + reset-gpios: true + + vdd-supply: + description: power supply voltage + vddio-supply: + description: power supply voltage for IO + + width-mm: + description: physical panel width [mm] + height-mm: + description: physical panel height [mm] + + panel-timing: true + +required: + - compatible + - reg + - reset-gpios + +additionalProperties: false + +examples: + - | + #include + dsi { + #address-cells =3D <1>; + #size-cells =3D <0>; + panel@0 { + compatible =3D "fannal,c3004"; + reg =3D <0>; + pinctrl-0 =3D <&pinctrl_mipi_dsi_rst>; + pinctrl-names =3D "default"; + reset-gpios =3D <&gpio1 9 GPIO_ACTIVE_LOW>; + vdd-supply =3D <®1>; + vddio-supply =3D <®2>; + width-mm =3D <93>; + height-mm =3D <56>; + panel-timing { + clock-frequency =3D <27000000>; + hactive =3D <480>; + vactive =3D <800>; + hfront-porch =3D <30>; + hback-porch =3D <30>; + hsync-len =3D <8>; + vback-porch =3D <30>; + vfront-porch =3D <30>; + vsync-len =3D <8>; + }; + }; + }; +... diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Docum= entation/devicetree/bindings/vendor-prefixes.yaml index 82d39ab0231b..f962750f630a 100644 --- a/Documentation/devicetree/bindings/vendor-prefixes.yaml +++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml @@ -462,6 +462,8 @@ patternProperties: description: Facebook "^fairphone,.*": description: Fairphone B.V. + "^fannal,.*": + description: Fannal Electronics Co., Ltd "^faraday,.*": description: Faraday Technology Corporation "^fastrax,.*": diff --git a/MAINTAINERS b/MAINTAINERS index 5c22c828ab46..62374c8424b9 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -6427,6 +6427,12 @@ T: git git://anongit.freedesktop.org/drm/drm-misc F: Documentation/devicetree/bindings/display/panel/ebbg,ft8719.yaml F: drivers/gpu/drm/panel/panel-ebbg-ft8719.c =20 +DRM DRIVER FOR FANNAL C3004373132019A +M: Paulo Pavacic +S: Maintained +C: matrix:r/mipi-dsi-bringup:matrix.org +F: Documentation/devicetree/bindings/display/panel/panel-fannal,c3004.yaml + DRM DRIVER FOR FARADAY TVE200 TV ENCODER M: Linus Walleij S: Maintained --=20 2.40.1 From nobody Sun Feb 8 06:04:44 2026 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 7452AC7EE23 for ; Fri, 19 May 2023 14:25:47 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S232027AbjESOZq (ORCPT ); Fri, 19 May 2023 10:25:46 -0400 Received: from lindbergh.monkeyblade.net ([23.128.96.19]:48964 "EHLO lindbergh.monkeyblade.net" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S231958AbjESOZl (ORCPT ); Fri, 19 May 2023 10:25:41 -0400 Received: from mail-wm1-x333.google.com (mail-wm1-x333.google.com [IPv6:2a00:1450:4864:20::333]) by lindbergh.monkeyblade.net (Postfix) with ESMTPS id 7C0291A7; Fri, 19 May 2023 07:25:38 -0700 (PDT) Received: by mail-wm1-x333.google.com with SMTP id 5b1f17b1804b1-3f475366514so22944985e9.2; Fri, 19 May 2023 07:25:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20221208; t=1684506337; x=1687098337; 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=HGSXtFQO6NZPOk9/bp/O9fgH0shFEyfhGNdkgmYVGuk=; b=gP5cE1b/0ZXeEFiOfsjll6LI92Gh55XL+puh5lPSfpz3Su+bnwT3deO34gYAhpmhep gAXMO/uYVE+b0SGBbkGePVDjPE4exPyTsvUJbPVVhAj+O1rTbzEge3HS+2aBCwE6/WnC UvTXFXS2N4Nc3uOapotB2ZI1WuoFlMBWCNwCBux7X3K90lEqlM5wkLzCv1rLiINHL5r/ zmxgu3SQ4O6MA0UVWHsol0kLNTkV0teGGj8hG2e0IhsJULEo9mNp0l430gPPugOdorrc QX0mBmZ70hCRxObi9HAzYys1pbLWEWEI80yvyzMshWHVvAS4DHTYUqXjNE6LeBUQ011D w/wg== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20221208; t=1684506337; x=1687098337; 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=HGSXtFQO6NZPOk9/bp/O9fgH0shFEyfhGNdkgmYVGuk=; b=hMRLs4N3K2IUeX0rBqas1X6pDAu9RiKtFSZDJwkQKF72eu/GvEXHxs2iBHtw+TzTd4 WZvjYvaLql8MFxuwDuWUKveOdryh8IJJhgDHfzIzXOhbgbn+K0arrg2bpB/moB+Kz1z8 FAZmUG37sswM1F3C07iARpDbYmLDMB3gCxRAm7VoCBbvueAtI/vOikxF8JLTEVKz1mu+ Hs/Muzd3BS3hLknkxYIR4iNiMGhxr4XeDG9ui6Hrq6C4Z48Y0A3oyDdAlVDWvzroH4ax wS2zpTBG3HUZUJ61WiN6EAgTh5YVhayAhZWX4HchYHoBRbT7clRuCzdI14neZQ/zT9Jw ysng== X-Gm-Message-State: AC+VfDwxBZKjv8CN4+FgGMIIyKdFlTfV5/N6+NUnANc5kw8T2GTn5A6U wayZCOuAj9R9ocMcLZ97TmA= X-Google-Smtp-Source: ACHHUZ6wshDE6e3HR9d8ljozNWEaOp6pCmm4m/YKPzlDN3j0tNsRZ1ZnvOHky38UeK85ImR3pz5y5A== X-Received: by 2002:a1c:4c10:0:b0:3f4:5058:a033 with SMTP id z16-20020a1c4c10000000b003f45058a033mr1524806wmf.24.1684506336808; Fri, 19 May 2023 07:25:36 -0700 (PDT) Received: from fedora.. ([95.168.116.22]) by smtp.gmail.com with ESMTPSA id h12-20020a5d4fcc000000b003062b2c5255sm5451748wrw.40.2023.05.19.07.25.35 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 19 May 2023 07:25:36 -0700 (PDT) From: Paulo Pavacic To: neil.armstrong@linaro.org, sam@ravnborg.org, airlied@gmail.com, daniel@ffwll.ch, robh+dt@kernel.org, krzysztof.kozlowski+dt@linaro.org, conor+dt@kernel.org Cc: dri-devel@lists.freedesktop.org, linux-kernel@vger.kernel.org, devicetree@vger.kernel.org, Paulo Pavacic Subject: [PATCH 2/2] drm/panel-fannal-c3004: Add fannal c3004 DSI panel Date: Fri, 19 May 2023 16:24:56 +0200 Message-Id: <20230519142456.2588145-3-pavacic.p@gmail.com> X-Mailer: git-send-email 2.40.1 In-Reply-To: <20230519142456.2588145-1-pavacic.p@gmail.com> References: <20230519142456.2588145-1-pavacic.p@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: quoted-printable Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Fannal C3004 is a 480x800 display made by fannal that requires DCS initialization sequences. Signed-off-by: Paulo Pavacic --- v2 changelog: - renamed from panel-mipi-dsi-bringup - only one MAINTAINER e-mail --- MAINTAINERS | 1 + drivers/gpu/drm/panel/Kconfig | 11 + drivers/gpu/drm/panel/Makefile | 1 + drivers/gpu/drm/panel/panel-fannal-c3004.c | 405 +++++++++++++++++++++ 4 files changed, 418 insertions(+) create mode 100644 drivers/gpu/drm/panel/panel-fannal-c3004.c diff --git a/MAINTAINERS b/MAINTAINERS index 62374c8424b9..93fc1ae6832f 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -6432,6 +6432,7 @@ M: Paulo Pavacic S: Maintained C: matrix:r/mipi-dsi-bringup:matrix.org F: Documentation/devicetree/bindings/display/panel/panel-fannal,c3004.yaml +F: drivers/gpu/drm/panel/panel-fannal-c3004.c =20 DRM DRIVER FOR FARADAY TVE200 TV ENCODER M: Linus Walleij diff --git a/drivers/gpu/drm/panel/Kconfig b/drivers/gpu/drm/panel/Kconfig index 2b9d6db7860b..a1041c1e6bf6 100644 --- a/drivers/gpu/drm/panel/Kconfig +++ b/drivers/gpu/drm/panel/Kconfig @@ -144,6 +144,17 @@ config DRM_PANEL_ELIDA_KD35T133 KD35T133 controller for 320x480 LCD panels with MIPI-DSI system interfaces. =20 +config DRM_PANEL_FANNAL_C3004 + tristate "Fannal C3004 panel" + depends on OF + depends on DRM_MIPI_DSI + help + Say Y here if you want to enable support for the Fannal C3004 + 2-lane 480x800 MIPI DSI panel which requires initialization + sequence. + + If M is selected the module will be called panel-fannal-c3004. + config DRM_PANEL_FEIXIN_K101_IM2BA02 tristate "Feixin K101 IM2BA02 panel" depends on OF diff --git a/drivers/gpu/drm/panel/Makefile b/drivers/gpu/drm/panel/Makefile index ff169781e82d..13c0f00038b5 100644 --- a/drivers/gpu/drm/panel/Makefile +++ b/drivers/gpu/drm/panel/Makefile @@ -12,6 +12,7 @@ obj-$(CONFIG_DRM_PANEL_SIMPLE) +=3D panel-simple.o obj-$(CONFIG_DRM_PANEL_EDP) +=3D panel-edp.o obj-$(CONFIG_DRM_PANEL_EBBG_FT8719) +=3D panel-ebbg-ft8719.o obj-$(CONFIG_DRM_PANEL_ELIDA_KD35T133) +=3D panel-elida-kd35t133.o +obj-$(CONFIG_DRM_PANEL_FANNAL_C3004) +=3D panel-fannal-c3004.o obj-$(CONFIG_DRM_PANEL_FEIXIN_K101_IM2BA02) +=3D panel-feixin-k101-im2ba02= .o obj-$(CONFIG_DRM_PANEL_FEIYANG_FY07024DI26A30D) +=3D panel-feiyang-fy07024= di26a30d.o obj-$(CONFIG_DRM_PANEL_HIMAX_HX8394) +=3D panel-himax-hx8394.o diff --git a/drivers/gpu/drm/panel/panel-fannal-c3004.c b/drivers/gpu/drm/p= anel/panel-fannal-c3004.c new file mode 100644 index 000000000000..decbd0c59093 --- /dev/null +++ b/drivers/gpu/drm/panel/panel-fannal-c3004.c @@ -0,0 +1,405 @@ +// SPDX-License-Identifier: GPL-2.0 +/* + * MIPI DSI driver for Fannal C3004. + * Copyright (C) 2023, Zenitel + * Author: Paulo Pavacic + */ + +// =E2=86=93 include headers, static values, static functions =E2=86=93 +#include +#include +#include +#include +#include + +#include