linux-clk.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH 00/22] Add support for A100/A133 display
@ 2024-12-27 11:07 Parthiban Nallathambi
  2024-12-27 11:07 ` [PATCH 01/22] dt-bindings: iommu: sun50i: remove resets from required property Parthiban Nallathambi
                   ` (16 more replies)
  0 siblings, 17 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

This series depends on [1] for the eMMC/MMC controller to work and
[2] (lined up for 6.14) which adds support for the sram nodes and
display engine extends it's usage. Idea of this series to get initial
feedback and adjust, which will be rebased for 6.14 once [2] is merged.

This patch series adds support for A133 display pipeline based on
LVDS. dt-bindigs are organized in the start and later with code
changes.

PHY is shared between DSI and LVDS, so to control the PHY specific
to DSI/LVDS, phy_ops set_mode is introduced. To enable the DSI
using set_mode, analog control register MIPI Enable is used, which
may not be available for A31 (shares the same driver).

Otherwise, A133 also got hidden independent display engine i.e
mixer + tcon top to handle parallel display. But this patch series
adds only support for the 1 mixer which is documented.

[1]: https://lore.kernel.org/linux-sunxi/20241109003739.3440904-1-masterr3c0rd@epochal.quest/
[2]: https://lore.kernel.org/linux-sunxi/20241218-a100-syscon-v2-0-dae60b9ce192@epochal.quest/

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
Parthiban Nallathambi (22):
      dt-bindings: iommu: sun50i: remove resets from required property
      dt-bindings: display: sunxi: Add a100/a133 display engine compatibles
      dt-bindings: clock: sun8i de2 clock: Add PLL com clock
      dt-bindings: clock: sun8i de2 clock: Add a100/a133 compatible
      dt-bindings: display: sun4i: add phy property
      dt-bindings: display: sun4i: add a100/a133 tcon lcd
      dt-bindings: vendor-prefixes: Shenzhen Baijie Technology
      dt-bindings: arm: sunxi: document Szbaijie A133 helper board
      iommu: sun50i: make reset control optional
      pinctrl: sunxi: add missed lvds pins for a100/a133
      drm/sun4i: Add support for a100/a133 display engine
      drm/sun4i: Add support for a100/a133 mixer
      drm/sun4i: make tcon top tv0 optional
      drm/sun4i: add a100/a133 tcon top quirks
      clk: sunxi-ng: sun8i-de2: add pll-com clock support
      clk: sunxi-ng: sun8i-de2: Add support for a100/a133
      phy: allwinner: phy-sun6i-mipi-dphy: add LVDS support
      drm/sun4i: tcon: add a100/a133 lcd controller support
      arm64: dts: allwinner: a100: add iommu
      clk: sunxi-ng: add missing pll-com binding
      arm64: dts: allwinner: a100: add display pipeline
      arm64: dts: allwinner: a133: add szbaijie helper board

 Documentation/devicetree/bindings/arm/sunxi.yaml   |   6 +
 .../clock/allwinner,sun8i-a83t-de2-clk.yaml        |   6 +
 .../allwinner,sun4i-a10-display-engine.yaml        |   2 +
 .../bindings/display/allwinner,sun4i-a10-tcon.yaml |   7 +
 .../display/allwinner,sun8i-a83t-de2-mixer.yaml    |   1 +
 .../display/allwinner,sun8i-r40-tcon-top.yaml      |  17 ++
 .../bindings/iommu/allwinner,sun50i-h6-iommu.yaml  |   1 -
 .../devicetree/bindings/vendor-prefixes.yaml       |   2 +
 arch/arm64/boot/dts/allwinner/Makefile             |   1 +
 arch/arm64/boot/dts/allwinner/sun50i-a100.dtsi     | 165 ++++++++++++++++++
 .../dts/allwinner/sun50i-a133-helper-board.dts     | 129 ++++++++++++++
 .../dts/allwinner/sun50i-a133-helper-core.dtsi     | 190 +++++++++++++++++++++
 drivers/clk/sunxi-ng/ccu-sun8i-de2.c               |  23 ++-
 drivers/gpu/drm/sun4i/sun4i_drv.c                  |   1 +
 drivers/gpu/drm/sun4i/sun4i_tcon.c                 |  23 +++
 drivers/gpu/drm/sun4i/sun8i_mixer.c                |  13 ++
 drivers/gpu/drm/sun4i/sun8i_tcon_top.c             |  42 +++--
 drivers/iommu/sun50i-iommu.c                       |   2 +-
 drivers/phy/allwinner/phy-sun6i-mipi-dphy.c        |  23 ++-
 drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c        |  12 ++
 include/dt-bindings/clock/sun50i-a100-ccu.h        |   1 +
 21 files changed, 645 insertions(+), 22 deletions(-)
---
base-commit: 6c086b91df8c6619239c6d6d6cbf6ae50da6c110
change-id: 20241126-a133-display-support-ab43af32180a

Best regards,
-- 
Parthiban Nallathambi <parthiban@linumiz.com>


^ permalink raw reply	[flat|nested] 30+ messages in thread

* [PATCH 01/22] dt-bindings: iommu: sun50i: remove resets from required property
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2025-08-07 15:27   ` Paul Kocialkowski
  2024-12-27 11:07 ` [PATCH 02/22] dt-bindings: display: sunxi: Add a100/a133 display engine compatibles Parthiban Nallathambi
                   ` (15 subsequent siblings)
  16 siblings, 1 reply; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

iommu in a133/a100 does not have reset control. remove it
from required property to make it optional.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml | 1 -
 1 file changed, 1 deletion(-)

diff --git a/Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml b/Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml
index a8409db4a3e3..03176f68485b 100644
--- a/Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml
+++ b/Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml
@@ -42,7 +42,6 @@ required:
   - reg
   - interrupts
   - clocks
-  - resets
 
 additionalProperties: false
 

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 02/22] dt-bindings: display: sunxi: Add a100/a133 display engine compatibles
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
  2024-12-27 11:07 ` [PATCH 01/22] dt-bindings: iommu: sun50i: remove resets from required property Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2024-12-27 11:07 ` [PATCH 03/22] dt-bindings: clock: sun8i de2 clock: Add PLL com clock Parthiban Nallathambi
                   ` (14 subsequent siblings)
  16 siblings, 0 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

A100/A133 comes with display enginer 2.0 with 1 x Mixer with write
back support and 1 tcon top. Mixer can be used with lcd/lvds/dsi,
but shares the same GPIO bank.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 .../display/allwinner,sun4i-a10-display-engine.yaml     |  2 ++
 .../display/allwinner,sun8i-a83t-de2-mixer.yaml         |  1 +
 .../bindings/display/allwinner,sun8i-r40-tcon-top.yaml  | 17 +++++++++++++++++
 3 files changed, 20 insertions(+)

diff --git a/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-display-engine.yaml b/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-display-engine.yaml
index e6088f379f70..dc47c684fcb0 100644
--- a/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-display-engine.yaml
+++ b/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-display-engine.yaml
@@ -64,6 +64,7 @@ properties:
       - allwinner,sun9i-a80-display-engine
       - allwinner,sun20i-d1-display-engine
       - allwinner,sun50i-a64-display-engine
+      - allwinner,sun50i-a100-display-engine
       - allwinner,sun50i-h6-display-engine
 
   allwinner,pipelines:
@@ -96,6 +97,7 @@ if:
           - allwinner,sun9i-a80-display-engine
           - allwinner,sun20i-d1-display-engine
           - allwinner,sun50i-a64-display-engine
+          - allwinner,sun50i-a100-display-engine
 
 then:
   properties:
diff --git a/Documentation/devicetree/bindings/display/allwinner,sun8i-a83t-de2-mixer.yaml b/Documentation/devicetree/bindings/display/allwinner,sun8i-a83t-de2-mixer.yaml
index b75c1ec686ad..ebcddca2efb3 100644
--- a/Documentation/devicetree/bindings/display/allwinner,sun8i-a83t-de2-mixer.yaml
+++ b/Documentation/devicetree/bindings/display/allwinner,sun8i-a83t-de2-mixer.yaml
@@ -23,6 +23,7 @@ properties:
       - allwinner,sun20i-d1-de2-mixer-1
       - allwinner,sun50i-a64-de2-mixer-0
       - allwinner,sun50i-a64-de2-mixer-1
+      - allwinner,sun50i-a100-de2-mixer-0
       - allwinner,sun50i-h6-de3-mixer-0
 
   reg:
diff --git a/Documentation/devicetree/bindings/display/allwinner,sun8i-r40-tcon-top.yaml b/Documentation/devicetree/bindings/display/allwinner,sun8i-r40-tcon-top.yaml
index 7d849c4095a3..9b14b7fb2d2f 100644
--- a/Documentation/devicetree/bindings/display/allwinner,sun8i-r40-tcon-top.yaml
+++ b/Documentation/devicetree/bindings/display/allwinner,sun8i-r40-tcon-top.yaml
@@ -42,6 +42,7 @@ properties:
     enum:
       - allwinner,sun8i-r40-tcon-top
       - allwinner,sun20i-d1-tcon-top
+      - allwinner,sun50i-a100-tcon-top
       - allwinner,sun50i-h6-tcon-top
 
   reg:
@@ -179,6 +180,22 @@ allOf:
             - description: TCON TV0 output clock name
             - description: DSI output clock name
 
+  - if:
+      properties:
+        compatible:
+          contains:
+            const: allwinner,sun50i-a100-tcon-top
+
+    then:
+      properties:
+        clocks:
+          items:
+            - description: The TCON TOP interface clock
+
+        clock-names:
+          items:
+            - const: bus
+
   - if:
       properties:
         compatible:

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 03/22] dt-bindings: clock: sun8i de2 clock: Add PLL com clock
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
  2024-12-27 11:07 ` [PATCH 01/22] dt-bindings: iommu: sun50i: remove resets from required property Parthiban Nallathambi
  2024-12-27 11:07 ` [PATCH 02/22] dt-bindings: display: sunxi: Add a100/a133 display engine compatibles Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2024-12-27 13:16   ` Rob Herring (Arm)
  2024-12-27 11:07 ` [PATCH 04/22] dt-bindings: clock: sun8i de2 clock: Add a100/a133 compatible Parthiban Nallathambi
                   ` (13 subsequent siblings)
  16 siblings, 1 reply; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

Some platforms like A100/A133 also uses pll-com clock as additional
clock source for the display clock. This is not documents both in
user manual and DE 2.0 specification. These changes are mainly from
vendor BSP.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 .../devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.yaml         | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Documentation/devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.yaml b/Documentation/devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.yaml
index 70369bd633e4..3e00905b66ca 100644
--- a/Documentation/devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.yaml
+++ b/Documentation/devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.yaml
@@ -39,11 +39,13 @@ properties:
     items:
       - description: Bus Clock
       - description: Module Clock
+      - description: PLL common clock
 
   clock-names:
     items:
       - const: bus
       - const: mod
+      - const: pll-com
 
   resets:
     maxItems: 1

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 04/22] dt-bindings: clock: sun8i de2 clock: Add a100/a133 compatible
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (2 preceding siblings ...)
  2024-12-27 11:07 ` [PATCH 03/22] dt-bindings: clock: sun8i de2 clock: Add PLL com clock Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2024-12-27 11:07 ` [PATCH 05/22] dt-bindings: display: sun4i: add phy property Parthiban Nallathambi
                   ` (12 subsequent siblings)
  16 siblings, 0 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

A100/A133 uses one mixer without rotation support, which is same
as sun8i v3s. Add it with fallback to v3s compatible.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 .../devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.yaml       | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/Documentation/devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.yaml b/Documentation/devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.yaml
index 3e00905b66ca..ed038967929b 100644
--- a/Documentation/devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.yaml
+++ b/Documentation/devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.yaml
@@ -23,6 +23,7 @@ properties:
       - const: allwinner,sun8i-h3-de2-clk
       - const: allwinner,sun8i-v3s-de2-clk
       - const: allwinner,sun50i-a64-de2-clk
+      - const: allwinner,sun50i-a100-de2-clk
       - const: allwinner,sun50i-h5-de2-clk
       - const: allwinner,sun50i-h6-de3-clk
       - items:
@@ -31,6 +32,9 @@ properties:
       - items:
           - const: allwinner,sun20i-d1-de2-clk
           - const: allwinner,sun50i-h5-de2-clk
+      - items:
+          - const: allwinner,sun50i-a100-de2-clk
+          - const: allwinner,sun8i-v3s-de2-clk
 
   reg:
     maxItems: 1

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 05/22] dt-bindings: display: sun4i: add phy property
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (3 preceding siblings ...)
  2024-12-27 11:07 ` [PATCH 04/22] dt-bindings: clock: sun8i de2 clock: Add a100/a133 compatible Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2024-12-27 11:07 ` [PATCH 06/22] dt-bindings: display: sun4i: add a100/a133 tcon lcd Parthiban Nallathambi
                   ` (11 subsequent siblings)
  16 siblings, 0 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

lvds in A100/A133 platform uses phy from DSI block, which needs
to be handled in phy driver. Add phy property to tcon with
generic name 'phy'.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 .../devicetree/bindings/display/allwinner,sun4i-a10-tcon.yaml       | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-tcon.yaml b/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-tcon.yaml
index 724d93b9193b..6d8ae781c230 100644
--- a/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-tcon.yaml
+++ b/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-tcon.yaml
@@ -115,6 +115,12 @@ properties:
           - const: edp
           - const: lvds
 
+  phys:
+    maxItems: 1
+
+  phy-names:
+    const: phy
+
   ports:
     $ref: /schemas/graph.yaml#/properties/ports
 

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 06/22] dt-bindings: display: sun4i: add a100/a133 tcon lcd
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (4 preceding siblings ...)
  2024-12-27 11:07 ` [PATCH 05/22] dt-bindings: display: sun4i: add phy property Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2024-12-27 11:07 ` [PATCH 07/22] dt-bindings: vendor-prefixes: Shenzhen Baijie Technology Parthiban Nallathambi
                   ` (10 subsequent siblings)
  16 siblings, 0 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

A100/A133 has one 18 bit LCD / 2 x LVDS / 1 x DSI. All the controller
shares the same GPIO D block, where LVDS controller can co-exits.

Although 2 LVDS controller is available, there is no document details
for the second. Add compatible for a100 lcd controller.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 Documentation/devicetree/bindings/display/allwinner,sun4i-a10-tcon.yaml | 1 +
 1 file changed, 1 insertion(+)

diff --git a/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-tcon.yaml b/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-tcon.yaml
index 6d8ae781c230..7ea45a0a2073 100644
--- a/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-tcon.yaml
+++ b/Documentation/devicetree/bindings/display/allwinner,sun4i-a10-tcon.yaml
@@ -35,6 +35,7 @@ properties:
       - const: allwinner,sun9i-a80-tcon-tv
       - const: allwinner,sun20i-d1-tcon-lcd
       - const: allwinner,sun20i-d1-tcon-tv
+      - const: allwinner,sun50i-a100-tcon-lcd
 
       - items:
           - enum:

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 07/22] dt-bindings: vendor-prefixes: Shenzhen Baijie Technology
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (5 preceding siblings ...)
  2024-12-27 11:07 ` [PATCH 06/22] dt-bindings: display: sun4i: add a100/a133 tcon lcd Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2025-08-07 15:24   ` Paul Kocialkowski
  2024-12-27 11:07 ` [PATCH 08/22] dt-bindings: arm: sunxi: document Szbaijie A133 helper board Parthiban Nallathambi
                   ` (9 subsequent siblings)
  16 siblings, 1 reply; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

Add entry for Shenzhen Baijie Technology (https://szbaijie.com)

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml
index da01616802c7..81cbc8b6b195 100644
--- a/Documentation/devicetree/bindings/vendor-prefixes.yaml
+++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml
@@ -1466,6 +1466,8 @@ patternProperties:
   "^synopsys,.*":
     description: Synopsys, Inc. (deprecated, use snps)
     deprecated: true
+  "^szbaijie,.*":
+    description: Shenzhen Baijie Technology Co., Ltd.
   "^tbs,.*":
     description: TBS Technologies
   "^tbs-biometrics,.*":

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 08/22] dt-bindings: arm: sunxi: document Szbaijie A133 helper board
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (6 preceding siblings ...)
  2024-12-27 11:07 ` [PATCH 07/22] dt-bindings: vendor-prefixes: Shenzhen Baijie Technology Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2024-12-27 11:07 ` [PATCH 09/22] iommu: sun50i: make reset control optional Parthiban Nallathambi
                   ` (8 subsequent siblings)
  16 siblings, 0 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

Szbaijie Baijie Technology A133 helper board is an evaluation
board of their A133-Core SoM. Add its compatible (with the
SoM compatible) to the sunxi board DT binding file.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 Documentation/devicetree/bindings/arm/sunxi.yaml | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/Documentation/devicetree/bindings/arm/sunxi.yaml b/Documentation/devicetree/bindings/arm/sunxi.yaml
index 046536d02706..eb19f8b1fe68 100644
--- a/Documentation/devicetree/bindings/arm/sunxi.yaml
+++ b/Documentation/devicetree/bindings/arm/sunxi.yaml
@@ -891,6 +891,12 @@ properties:
           - const: allwinner,sl631
           - const: allwinner,sun8i-v3
 
+      - description: Szbaijie A133 Helper board
+        items:
+          - const: szbaijie,helper-a133
+          - const: szbaijie,helper-a133-core
+          - const: allwinner,sun50i-a133
+
       - description: Tanix TX1
         items:
           - const: oranth,tanix-tx1

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 09/22] iommu: sun50i: make reset control optional
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (7 preceding siblings ...)
  2024-12-27 11:07 ` [PATCH 08/22] dt-bindings: arm: sunxi: document Szbaijie A133 helper board Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2025-01-06 11:24   ` Joerg Roedel
  2025-08-07 15:29   ` Paul Kocialkowski
  2024-12-27 11:07 ` [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133 Parthiban Nallathambi
                   ` (7 subsequent siblings)
  16 siblings, 2 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

A133/A100 SoC doesn't have reset control from the CCU. Get reset
control line optionally.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 drivers/iommu/sun50i-iommu.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/iommu/sun50i-iommu.c b/drivers/iommu/sun50i-iommu.c
index 8d8f11854676..2ba804d682dc 100644
--- a/drivers/iommu/sun50i-iommu.c
+++ b/drivers/iommu/sun50i-iommu.c
@@ -1030,7 +1030,7 @@ static int sun50i_iommu_probe(struct platform_device *pdev)
 		goto err_free_cache;
 	}
 
-	iommu->reset = devm_reset_control_get(&pdev->dev, NULL);
+	iommu->reset = devm_reset_control_get_optional(&pdev->dev, NULL);
 	if (IS_ERR(iommu->reset)) {
 		dev_err(&pdev->dev, "Couldn't get our reset line.\n");
 		ret = PTR_ERR(iommu->reset);

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (8 preceding siblings ...)
  2024-12-27 11:07 ` [PATCH 09/22] iommu: sun50i: make reset control optional Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2025-01-13 14:30   ` Linus Walleij
  2025-06-25  8:46   ` Paul Kocialkowski
  2024-12-27 11:07 ` [PATCH 11/22] drm/sun4i: Add support for a100/a133 display engine Parthiban Nallathambi
                   ` (6 subsequent siblings)
  16 siblings, 2 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

lvds, lcd, dsi all shares the same GPIO D bank and lvds0
data 3 lines and lvds1 pins are missed, add them.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

diff --git a/drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c b/drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c
index df90c75fb3c5..b97de80ae2f3 100644
--- a/drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c
+++ b/drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c
@@ -256,72 +256,84 @@ static const struct sunxi_desc_pin a100_pins[] = {
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D12 */
+		  SUNXI_FUNCTION(0x3, "lvds0"),		/* D3P */
 		  SUNXI_FUNCTION(0x4, "dsi0"),		/* DP3 */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 8)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 9),
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D13 */
+		  SUNXI_FUNCTION(0x3, "lvds0"),		/* D3N */
 		  SUNXI_FUNCTION(0x4, "dsi0"),		/* DM3 */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 9)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 10),
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D14 */
+		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D0P */
 		  SUNXI_FUNCTION(0x4, "spi1"),		/* CS */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 10)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 11),
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D15 */
+		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D0N */
 		  SUNXI_FUNCTION(0x4, "spi1"),		/* CLK */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 11)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 12),
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D18 */
+		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D1P */
 		  SUNXI_FUNCTION(0x4, "spi1"),		/* MOSI */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 12)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 13),
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D19 */
+		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D1N */
 		  SUNXI_FUNCTION(0x4, "spi1"),		/* MISO */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 13)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 14),
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D20 */
+		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D2P */
 		  SUNXI_FUNCTION(0x4, "uart3"),		/* TX */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 14)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 15),
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D21 */
+		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D2N */
 		  SUNXI_FUNCTION(0x4, "uart3"),		/* RX */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 15)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 16),
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D22 */
+		  SUNXI_FUNCTION(0x3, "lvds1"),		/* CKP */
 		  SUNXI_FUNCTION(0x4, "uart3"),		/* RTS */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 16)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 17),
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D23 */
+		  SUNXI_FUNCTION(0x3, "lvds1"),		/* CKN */
 		  SUNXI_FUNCTION(0x4, "uart3"),		/* CTS */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 17)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 18),
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* CLK */
+		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D3P */
 		  SUNXI_FUNCTION(0x4, "uart4"),		/* TX */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 18)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 19),
 		  SUNXI_FUNCTION(0x0, "gpio_in"),
 		  SUNXI_FUNCTION(0x1, "gpio_out"),
 		  SUNXI_FUNCTION(0x2, "lcd0"),		/* DE */
+		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D3N */
 		  SUNXI_FUNCTION(0x4, "uart4"),		/* RX */
 		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 19)),
 	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 20),

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 11/22] drm/sun4i: Add support for a100/a133 display engine
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (9 preceding siblings ...)
  2024-12-27 11:07 ` [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133 Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2024-12-27 11:07 ` [PATCH 12/22] drm/sun4i: Add support for a100/a133 mixer Parthiban Nallathambi
                   ` (5 subsequent siblings)
  16 siblings, 0 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

Display Engine(DE2) in Allwinner A100/A133 has one mixers and tcon.
The routing for mixer0 is through tcon0 and connected to
LVDS/RGB/MIPI-DSI controller.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 drivers/gpu/drm/sun4i/sun4i_drv.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/gpu/drm/sun4i/sun4i_drv.c b/drivers/gpu/drm/sun4i/sun4i_drv.c
index 5eccf58f2e17..e012a6316bba 100644
--- a/drivers/gpu/drm/sun4i/sun4i_drv.c
+++ b/drivers/gpu/drm/sun4i/sun4i_drv.c
@@ -436,6 +436,7 @@ static const struct of_device_id sun4i_drv_of_table[] = {
 	{ .compatible = "allwinner,sun9i-a80-display-engine" },
 	{ .compatible = "allwinner,sun20i-d1-display-engine" },
 	{ .compatible = "allwinner,sun50i-a64-display-engine" },
+	{ .compatible = "allwinner,sun50i-a100-display-engine" },
 	{ .compatible = "allwinner,sun50i-h6-display-engine" },
 	{ }
 };

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 12/22] drm/sun4i: Add support for a100/a133 mixer
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (10 preceding siblings ...)
  2024-12-27 11:07 ` [PATCH 11/22] drm/sun4i: Add support for a100/a133 display engine Parthiban Nallathambi
@ 2024-12-27 11:07 ` Parthiban Nallathambi
  2024-12-27 11:08 ` [PATCH 13/22] drm/sun4i: make tcon top tv0 optional Parthiban Nallathambi
                   ` (4 subsequent siblings)
  16 siblings, 0 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:07 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

Mixers in Allwinner A100/A133 have similar capabilities as others
SoCs with DE2. Add support for them.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 drivers/gpu/drm/sun4i/sun8i_mixer.c | 13 +++++++++++++
 1 file changed, 13 insertions(+)

diff --git a/drivers/gpu/drm/sun4i/sun8i_mixer.c b/drivers/gpu/drm/sun4i/sun8i_mixer.c
index 8b41d33baa30..0a1fccb87d5d 100644
--- a/drivers/gpu/drm/sun4i/sun8i_mixer.c
+++ b/drivers/gpu/drm/sun4i/sun8i_mixer.c
@@ -714,6 +714,15 @@ static const struct sun8i_mixer_cfg sun50i_a64_mixer1_cfg = {
 	.vi_num		= 1,
 };
 
+static const struct sun8i_mixer_cfg sun50i_a100_mixer0_cfg = {
+	.ccsc		= CCSC_MIXER0_LAYOUT,
+	.mod_rate	= 300000000,
+	.scaler_mask	= 0xf,
+	.scanline_yuv	= 2560,
+	.ui_num		= 2,
+	.vi_num		= 2,
+};
+
 static const struct sun8i_mixer_cfg sun50i_h6_mixer0_cfg = {
 	.ccsc		= CCSC_MIXER0_LAYOUT,
 	.is_de3		= true,
@@ -765,6 +774,10 @@ static const struct of_device_id sun8i_mixer_of_table[] = {
 		.compatible = "allwinner,sun50i-a64-de2-mixer-1",
 		.data = &sun50i_a64_mixer1_cfg,
 	},
+	{
+		.compatible = "allwinner,sun50i-a100-de2-mixer-0",
+		.data = &sun50i_a100_mixer0_cfg,
+	},
 	{
 		.compatible = "allwinner,sun50i-h6-de3-mixer-0",
 		.data = &sun50i_h6_mixer0_cfg,

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 13/22] drm/sun4i: make tcon top tv0 optional
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (11 preceding siblings ...)
  2024-12-27 11:07 ` [PATCH 12/22] drm/sun4i: Add support for a100/a133 mixer Parthiban Nallathambi
@ 2024-12-27 11:08 ` Parthiban Nallathambi
  2024-12-27 11:08 ` [PATCH 14/22] drm/sun4i: add a100/a133 tcon top quirks Parthiban Nallathambi
                   ` (3 subsequent siblings)
  16 siblings, 0 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:08 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

current implementation of tcon top assumes tv0 is always present, which
isn't case in A100/A133 SoC's. Make tv0 optional by introducing another
control similar to tv1 and make existing users with true/present.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 drivers/gpu/drm/sun4i/sun8i_tcon_top.c | 34 ++++++++++++++++++++--------------
 1 file changed, 20 insertions(+), 14 deletions(-)

diff --git a/drivers/gpu/drm/sun4i/sun8i_tcon_top.c b/drivers/gpu/drm/sun4i/sun8i_tcon_top.c
index 8adda578c51b..bd9d0840ead7 100644
--- a/drivers/gpu/drm/sun4i/sun8i_tcon_top.c
+++ b/drivers/gpu/drm/sun4i/sun8i_tcon_top.c
@@ -16,6 +16,7 @@
 #include "sun8i_tcon_top.h"
 
 struct sun8i_tcon_top_quirks {
+	bool has_tcon_tv0;
 	bool has_tcon_tv1;
 	bool has_dsi;
 };
@@ -191,10 +192,11 @@ static int sun8i_tcon_top_bind(struct device *dev, struct device *master,
 	 * to TVE clock parent.
 	 */
 	i = 0;
-	clk_data->hws[CLK_TCON_TOP_TV0] =
-		sun8i_tcon_top_register_gate(dev, "tcon-tv0", regs,
-					     &tcon_top->reg_lock,
-					     TCON_TOP_TCON_TV0_GATE, i++);
+	if (quirks->has_tcon_tv0)
+		clk_data->hws[CLK_TCON_TOP_TV0] =
+			sun8i_tcon_top_register_gate(dev, "tcon-tv0", regs,
+						     &tcon_top->reg_lock,
+						     TCON_TOP_TCON_TV0_GATE, i++);
 
 	if (quirks->has_tcon_tv1)
 		clk_data->hws[CLK_TCON_TOP_TV1] =
@@ -208,16 +210,18 @@ static int sun8i_tcon_top_bind(struct device *dev, struct device *master,
 						     &tcon_top->reg_lock,
 						     TCON_TOP_TCON_DSI_GATE, i++);
 
-	for (i = 0; i < CLK_NUM; i++)
-		if (IS_ERR(clk_data->hws[i])) {
-			ret = PTR_ERR(clk_data->hws[i]);
-			goto err_unregister_gates;
-		}
+	if (i) {
+		for (i = 0; i < CLK_NUM; i++)
+			if (IS_ERR(clk_data->hws[i])) {
+				ret = PTR_ERR(clk_data->hws[i]);
+				goto err_unregister_gates;
+			}
 
-	ret = of_clk_add_hw_provider(dev->of_node, of_clk_hw_onecell_get,
-				     clk_data);
-	if (ret)
-		goto err_unregister_gates;
+		ret = of_clk_add_hw_provider(dev->of_node, of_clk_hw_onecell_get,
+				clk_data);
+		if (ret)
+			goto err_unregister_gates;
+	}
 
 	dev_set_drvdata(dev, tcon_top);
 
@@ -266,16 +270,18 @@ static void sun8i_tcon_top_remove(struct platform_device *pdev)
 }
 
 static const struct sun8i_tcon_top_quirks sun8i_r40_tcon_top_quirks = {
+	.has_tcon_tv0	= true,
 	.has_tcon_tv1	= true,
 	.has_dsi	= true,
 };
 
 static const struct sun8i_tcon_top_quirks sun20i_d1_tcon_top_quirks = {
+	.has_tcon_tv0	= true,
 	.has_dsi	= true,
 };
 
 static const struct sun8i_tcon_top_quirks sun50i_h6_tcon_top_quirks = {
-	/* Nothing special */
+	.has_tcon_tv0	= true,
 };
 
 /* sun4i_drv uses this list to check if a device node is a TCON TOP */

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 14/22] drm/sun4i: add a100/a133 tcon top quirks
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (12 preceding siblings ...)
  2024-12-27 11:08 ` [PATCH 13/22] drm/sun4i: make tcon top tv0 optional Parthiban Nallathambi
@ 2024-12-27 11:08 ` Parthiban Nallathambi
  2024-12-27 11:08 ` [PATCH 15/22] clk: sunxi-ng: sun8i-de2: add pll-com clock support Parthiban Nallathambi
                   ` (2 subsequent siblings)
  16 siblings, 0 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:08 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

A100/A133 comes with 2 x LVDS, 1 x DSI without TV support. Add
quirks with tv0 disabled. DSI support is not added.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 drivers/gpu/drm/sun4i/sun8i_tcon_top.c | 8 ++++++++
 1 file changed, 8 insertions(+)

diff --git a/drivers/gpu/drm/sun4i/sun8i_tcon_top.c b/drivers/gpu/drm/sun4i/sun8i_tcon_top.c
index bd9d0840ead7..a777b30ecea0 100644
--- a/drivers/gpu/drm/sun4i/sun8i_tcon_top.c
+++ b/drivers/gpu/drm/sun4i/sun8i_tcon_top.c
@@ -280,6 +280,10 @@ static const struct sun8i_tcon_top_quirks sun20i_d1_tcon_top_quirks = {
 	.has_dsi	= true,
 };
 
+static const struct sun8i_tcon_top_quirks sun50i_a100_tcon_top_quirks = {
+	/* TODO DSI support */
+};
+
 static const struct sun8i_tcon_top_quirks sun50i_h6_tcon_top_quirks = {
 	.has_tcon_tv0	= true,
 };
@@ -294,6 +298,10 @@ const struct of_device_id sun8i_tcon_top_of_table[] = {
 		.compatible = "allwinner,sun20i-d1-tcon-top",
 		.data = &sun20i_d1_tcon_top_quirks
 	},
+	{
+		.compatible = "allwinner,sun50i-a100-tcon-top",
+		.data = &sun50i_a100_tcon_top_quirks
+	},
 	{
 		.compatible = "allwinner,sun50i-h6-tcon-top",
 		.data = &sun50i_h6_tcon_top_quirks

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 15/22] clk: sunxi-ng: sun8i-de2: add pll-com clock support
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (13 preceding siblings ...)
  2024-12-27 11:08 ` [PATCH 14/22] drm/sun4i: add a100/a133 tcon top quirks Parthiban Nallathambi
@ 2024-12-27 11:08 ` Parthiban Nallathambi
  2024-12-27 11:08 ` [PATCH 16/22] clk: sunxi-ng: sun8i-de2: Add support for a100/a133 Parthiban Nallathambi
       [not found] ` <20241227-a133-display-support-v1-17-13b52f71fb14@linumiz.com>
  16 siblings, 0 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:08 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

add optional pll-com support which is available in some platforms
like A100/A133, which is used by the display clock. There is no
documentation reference or details in DE 2.0 specification.

But these changes are needed to get the display clock to work and
this is inherited from the vendor BSP.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 drivers/clk/sunxi-ng/ccu-sun8i-de2.c | 19 +++++++++++++++++--
 1 file changed, 17 insertions(+), 2 deletions(-)

diff --git a/drivers/clk/sunxi-ng/ccu-sun8i-de2.c b/drivers/clk/sunxi-ng/ccu-sun8i-de2.c
index f2aa71206bc2..3e28c32050e0 100644
--- a/drivers/clk/sunxi-ng/ccu-sun8i-de2.c
+++ b/drivers/clk/sunxi-ng/ccu-sun8i-de2.c
@@ -241,7 +241,7 @@ static const struct sunxi_ccu_desc sun50i_h5_de2_clk_desc = {
 
 static int sunxi_de2_clk_probe(struct platform_device *pdev)
 {
-	struct clk *bus_clk, *mod_clk;
+	struct clk *bus_clk, *mod_clk, *pll_clk;
 	struct reset_control *rstc;
 	void __iomem *reg;
 	const struct sunxi_ccu_desc *ccu_desc;
@@ -265,6 +265,11 @@ static int sunxi_de2_clk_probe(struct platform_device *pdev)
 		return dev_err_probe(&pdev->dev, PTR_ERR(mod_clk),
 				     "Couldn't get mod clk\n");
 
+	pll_clk = devm_clk_get_optional(&pdev->dev, "pll-com");
+	if (IS_ERR(pll_clk))
+		return dev_err_probe(&pdev->dev, PTR_ERR(pll_clk),
+				     "Couldn't get pll clk\n");
+
 	rstc = devm_reset_control_get_exclusive(&pdev->dev, NULL);
 	if (IS_ERR(rstc))
 		return dev_err_probe(&pdev->dev, PTR_ERR(rstc),
@@ -283,12 +288,20 @@ static int sunxi_de2_clk_probe(struct platform_device *pdev)
 		goto err_disable_bus_clk;
 	}
 
+	if (pll_clk) {
+		ret = clk_prepare_enable(pll_clk);
+		if (ret) {
+			dev_err(&pdev->dev, "Couldn't enable pll clk: %d\n", ret);
+			goto err_disable_mod_clk;
+		}
+	}
+
 	/* The reset control needs to be asserted for the controls to work */
 	ret = reset_control_deassert(rstc);
 	if (ret) {
 		dev_err(&pdev->dev,
 			"Couldn't deassert reset control: %d\n", ret);
-		goto err_disable_mod_clk;
+		goto err_disable_pll_clk;
 	}
 
 	ret = devm_sunxi_ccu_probe(&pdev->dev, reg, ccu_desc);
@@ -299,6 +312,8 @@ static int sunxi_de2_clk_probe(struct platform_device *pdev)
 
 err_assert_reset:
 	reset_control_assert(rstc);
+err_disable_pll_clk:
+	clk_disable_unprepare(pll_clk);
 err_disable_mod_clk:
 	clk_disable_unprepare(mod_clk);
 err_disable_bus_clk:

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* [PATCH 16/22] clk: sunxi-ng: sun8i-de2: Add support for a100/a133
  2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
                   ` (14 preceding siblings ...)
  2024-12-27 11:08 ` [PATCH 15/22] clk: sunxi-ng: sun8i-de2: add pll-com clock support Parthiban Nallathambi
@ 2024-12-27 11:08 ` Parthiban Nallathambi
       [not found] ` <20241227-a133-display-support-v1-17-13b52f71fb14@linumiz.com>
  16 siblings, 0 replies; 30+ messages in thread
From: Parthiban Nallathambi @ 2024-12-27 11:08 UTC (permalink / raw)
  To: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I
  Cc: iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy,
	Parthiban Nallathambi

Display clock uses 1 mixer without rotation support is same
as v3s. There is also a hidden independent display engine
with independent tcon_top available in A100/A133 bin (based
on vendor BSP).

Add new compatible for A100/A133 to accommodate the future changes
for the independent DE.

Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
---
 drivers/clk/sunxi-ng/ccu-sun8i-de2.c | 4 ++++
 1 file changed, 4 insertions(+)

diff --git a/drivers/clk/sunxi-ng/ccu-sun8i-de2.c b/drivers/clk/sunxi-ng/ccu-sun8i-de2.c
index 3e28c32050e0..067820ab704d 100644
--- a/drivers/clk/sunxi-ng/ccu-sun8i-de2.c
+++ b/drivers/clk/sunxi-ng/ccu-sun8i-de2.c
@@ -342,6 +342,10 @@ static const struct of_device_id sunxi_de2_clk_ids[] = {
 		.compatible = "allwinner,sun50i-a64-de2-clk",
 		.data = &sun50i_a64_de2_clk_desc,
 	},
+	{
+		.compatible = "allwinner,sun50i-a100-de2-clk",
+		.data = &sun8i_v3s_de2_clk_desc,
+	},
 	{
 		.compatible = "allwinner,sun50i-h5-de2-clk",
 		.data = &sun50i_h5_de2_clk_desc,

-- 
2.39.5


^ permalink raw reply related	[flat|nested] 30+ messages in thread

* Re: [PATCH 03/22] dt-bindings: clock: sun8i de2 clock: Add PLL com clock
  2024-12-27 11:07 ` [PATCH 03/22] dt-bindings: clock: sun8i de2 clock: Add PLL com clock Parthiban Nallathambi
@ 2024-12-27 13:16   ` Rob Herring (Arm)
  0 siblings, 0 replies; 30+ messages in thread
From: Rob Herring (Arm) @ 2024-12-27 13:16 UTC (permalink / raw)
  To: Parthiban Nallathambi
  Cc: linux-phy, Robin Murphy, dri-devel, linux-kernel,
	Kishon Vijay Abraham I, Jernej Skrabec, devicetree, Chen-Yu Tsai,
	Joerg Roedel, linux-gpio, Vinod Koul, iommu, Linus Walleij,
	Simona Vetter, Stephen Boyd, Maarten Lankhorst, David Airlie,
	Conor Dooley, linux-sunxi, Maxime Ripard, linux-clk,
	Samuel Holland, Michael Turquette, Philipp Zabel,
	Krzysztof Kozlowski, Thomas Zimmermann, linux-arm-kernel,
	Will Deacon


On Fri, 27 Dec 2024 16:37:50 +0530, Parthiban Nallathambi wrote:
> Some platforms like A100/A133 also uses pll-com clock as additional
> clock source for the display clock. This is not documents both in
> user manual and DE 2.0 specification. These changes are mainly from
> vendor BSP.
> 
> Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
> ---
>  .../devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.yaml         | 2 ++
>  1 file changed, 2 insertions(+)
> 

My bot found errors running 'make dt_binding_check' on your patch:

yamllint warnings/errors:

dtschema/dtc warnings/errors:
/builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.example.dtb: clock@1000000: clocks: [[4294967295, 48], [4294967295, 101]] is too short
	from schema $id: http://devicetree.org/schemas/clock/allwinner,sun8i-a83t-de2-clk.yaml#
/builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/clock/allwinner,sun8i-a83t-de2-clk.example.dtb: clock@1000000: clock-names: ['bus', 'mod'] is too short
	from schema $id: http://devicetree.org/schemas/clock/allwinner,sun8i-a83t-de2-clk.yaml#
/builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/bus/allwinner,sun50i-a64-de2.example.dtb: clock@0: clocks: [[4294967295, 52], [4294967295, 99]] is too short
	from schema $id: http://devicetree.org/schemas/clock/allwinner,sun8i-a83t-de2-clk.yaml#
/builds/robherring/dt-review-ci/linux/Documentation/devicetree/bindings/bus/allwinner,sun50i-a64-de2.example.dtb: clock@0: clock-names: ['bus', 'mod'] is too short
	from schema $id: http://devicetree.org/schemas/clock/allwinner,sun8i-a83t-de2-clk.yaml#

doc reference errors (make refcheckdocs):

See https://patchwork.ozlabs.org/project/devicetree-bindings/patch/20241227-a133-display-support-v1-3-13b52f71fb14@linumiz.com

The base for the series is generally the latest rc1. A different dependency
should be noted in *this* patch.

If you already ran 'make dt_binding_check' and didn't see the above
error(s), then make sure 'yamllint' is installed and dt-schema is up to
date:

pip3 install dtschema --upgrade

Please check and re-submit after running the above command yourself. Note
that DT_SCHEMA_FILES can be set to your schema file to speed up checking
your schema. However, it must be unset to test all examples with your schema.


^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 09/22] iommu: sun50i: make reset control optional
  2024-12-27 11:07 ` [PATCH 09/22] iommu: sun50i: make reset control optional Parthiban Nallathambi
@ 2025-01-06 11:24   ` Joerg Roedel
  2025-08-07 15:29   ` Paul Kocialkowski
  1 sibling, 0 replies; 30+ messages in thread
From: Joerg Roedel @ 2025-01-06 11:24 UTC (permalink / raw)
  To: Parthiban Nallathambi
  Cc: Will Deacon, Robin Murphy, Rob Herring, Krzysztof Kozlowski,
	Conor Dooley, Chen-Yu Tsai, Jernej Skrabec, Samuel Holland,
	Maxime Ripard, Maarten Lankhorst, Thomas Zimmermann, David Airlie,
	Simona Vetter, Michael Turquette, Stephen Boyd, Philipp Zabel,
	Linus Walleij, Vinod Koul, Kishon Vijay Abraham I, iommu,
	devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy

On Fri, Dec 27, 2024 at 04:37:56PM +0530, Parthiban Nallathambi wrote:
> A133/A100 SoC doesn't have reset control from the CCU. Get reset
> control line optionally.
> 
> Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
> ---
>  drivers/iommu/sun50i-iommu.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)

Acked-by: Joerg Roedel <jroedel@suse.de>


^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133
  2024-12-27 11:07 ` [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133 Parthiban Nallathambi
@ 2025-01-13 14:30   ` Linus Walleij
  2025-01-14 15:46     ` Andre Przywara
  2025-06-25  8:46   ` Paul Kocialkowski
  1 sibling, 1 reply; 30+ messages in thread
From: Linus Walleij @ 2025-01-13 14:30 UTC (permalink / raw)
  To: Parthiban Nallathambi
  Cc: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Vinod Koul, Kishon Vijay Abraham I,
	iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy

On Fri, Dec 27, 2024 at 12:09 PM Parthiban Nallathambi
<parthiban@linumiz.com> wrote:

> lvds, lcd, dsi all shares the same GPIO D bank and lvds0
> data 3 lines and lvds1 pins are missed, add them.
>
> Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>

Nobody seems to have any objections about this patch and it seems
technically correct so I just applied it to the pin control tree.

Yours,
Linus Walleij

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133
  2025-01-13 14:30   ` Linus Walleij
@ 2025-01-14 15:46     ` Andre Przywara
  0 siblings, 0 replies; 30+ messages in thread
From: Andre Przywara @ 2025-01-14 15:46 UTC (permalink / raw)
  To: Linus Walleij
  Cc: Parthiban Nallathambi, Joerg Roedel, Will Deacon, Robin Murphy,
	Rob Herring, Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai,
	Jernej Skrabec, Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Vinod Koul, Kishon Vijay Abraham I,
	iommu, devicetree, linux-arm-kernel, linux-sunxi, linux-kernel,
	dri-devel, linux-clk, linux-gpio, linux-phy

On Mon, 13 Jan 2025 15:30:24 +0100
Linus Walleij <linus.walleij@linaro.org> wrote:

> On Fri, Dec 27, 2024 at 12:09 PM Parthiban Nallathambi
> <parthiban@linumiz.com> wrote:
> 
> > lvds, lcd, dsi all shares the same GPIO D bank and lvds0
> > data 3 lines and lvds1 pins are missed, add them.
> >
> > Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>  
> 
> Nobody seems to have any objections about this patch and it seems
> technically correct so I just applied it to the pin control tree.

I think Parthiban had troubles with his email server, so not the whole
series was sent out:
https://lore.kernel.org/linux-sunxi/314b6bbe-613e-41a6-955e-50db6e11ef8e@linumiz.com/T/#u
At least that put me off from reviewing it in anger.

I do have a comment on this, will reply in another mail. So can you hold
this patch back still, for now?

Cheers,
Andre

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 17/22] phy: allwinner: phy-sun6i-mipi-dphy: add LVDS support
       [not found] ` <20241227-a133-display-support-v1-17-13b52f71fb14@linumiz.com>
@ 2025-06-25  8:41   ` Paul Kocialkowski
  2025-06-25  9:38     ` Parthiban
  0 siblings, 1 reply; 30+ messages in thread
From: Paul Kocialkowski @ 2025-06-25  8:41 UTC (permalink / raw)
  To: Parthiban Nallathambi
  Cc: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I, iommu, devicetree, linux-arm-kernel,
	linux-sunxi, linux-kernel, dri-devel, linux-clk, linux-gpio,
	linux-phy

[-- Attachment #1: Type: text/plain, Size: 3491 bytes --]

Hi,

Thanks for your work on this!

On Fri 27 Dec 24, 16:38, Parthiban Nallathambi wrote:
> DPHY in A100/A133 supports both LVDS and DSI. Combo phy register
> have BIT(2) for enabling LVDS specifically, but enabling it alone
> isn't functional.
> 
> Both MIPI and LVDS needs to be enabled in the combo phy to get
> the display working under LVDS mode. There is no specific enable
> bit for LVDS apart from the one in combo phy. MIPI got enable
> control in analog 4 register which must be disabled when using
> in LVDS mode.
> 
> Introduce set_mode in phy ops to control only for MIPI DSI.

Similar work was already submitted for D1/T113-S3 LVDS support, which seems to
be the exact same situation as the A133.

See: https://patchwork.freedesktop.org/series/145276/

I just made a review of that series and find it more elegant in various ways
(especially since configuring the registers in set_mode is not the right place).
So you probably want to follow-up on that series instead.

Note that both D1/T113-S3 and A133 support a second LVDS output, LVDS1, which
uses the traditional TCON0 LVDS PHY. It would be great to be able to support
both outputs as well as dual-link modes!

All the best,

Paul

> Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
> ---
>  drivers/phy/allwinner/phy-sun6i-mipi-dphy.c | 23 +++++++++++++++++++----
>  1 file changed, 19 insertions(+), 4 deletions(-)
> 
> diff --git a/drivers/phy/allwinner/phy-sun6i-mipi-dphy.c b/drivers/phy/allwinner/phy-sun6i-mipi-dphy.c
> index 36eab95271b2..d164b2ea5dfd 100644
> --- a/drivers/phy/allwinner/phy-sun6i-mipi-dphy.c
> +++ b/drivers/phy/allwinner/phy-sun6i-mipi-dphy.c
> @@ -314,13 +314,11 @@ static void sun50i_a100_mipi_dphy_tx_power_on(struct sun6i_dphy *dphy)
>  	/* Disable sigma-delta modulation. */
>  	regmap_write(dphy->regs, SUN50I_DPHY_PLL_REG2, 0);
>  
> -	regmap_update_bits(dphy->regs, SUN6I_DPHY_ANA4_REG,
> -			   SUN6I_DPHY_ANA4_REG_EN_MIPI,
> -			   SUN6I_DPHY_ANA4_REG_EN_MIPI);
> -
>  	regmap_update_bits(dphy->regs, SUN50I_COMBO_PHY_REG0,
> +			   SUN50I_COMBO_PHY_REG0_EN_LVDS |
>  			   SUN50I_COMBO_PHY_REG0_EN_MIPI |
>  			   SUN50I_COMBO_PHY_REG0_EN_COMBOLDO,
> +			   SUN50I_COMBO_PHY_REG0_EN_LVDS |
>  			   SUN50I_COMBO_PHY_REG0_EN_MIPI |
>  			   SUN50I_COMBO_PHY_REG0_EN_COMBOLDO);
>  
> @@ -528,6 +526,22 @@ static int sun6i_dphy_exit(struct phy *phy)
>  	return 0;
>  }
>  
> +static int sun6i_set_mode(struct phy *phy, enum phy_mode mode, int submode)
> +{
> +	struct sun6i_dphy *dphy = phy_get_drvdata(phy);
> +
> +	switch (mode) {
> +	case PHY_MODE_MIPI_DPHY:
> +		regmap_update_bits(dphy->regs, SUN6I_DPHY_ANA4_REG,
> +				   SUN6I_DPHY_ANA4_REG_EN_MIPI,
> +				   SUN6I_DPHY_ANA4_REG_EN_MIPI);
> +		break;
> +	default:
> +		return -EINVAL;
> +	}
> +
> +	return 0;
> +}
>  
>  static const struct phy_ops sun6i_dphy_ops = {
>  	.configure	= sun6i_dphy_configure,
> @@ -535,6 +549,7 @@ static const struct phy_ops sun6i_dphy_ops = {
>  	.power_off	= sun6i_dphy_power_off,
>  	.init		= sun6i_dphy_init,
>  	.exit		= sun6i_dphy_exit,
> +	.set_mode	= sun6i_set_mode,
>  };
>  
>  static const struct regmap_config sun6i_dphy_regmap_config = {
> 
> -- 
> 2.39.5
> 

-- 
Paul Kocialkowski,

Independent contractor - sys-base - https://www.sys-base.io/
Free software developer - https://www.paulk.fr/

Expert in multimedia, graphics and embedded hardware support with Linux.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133
  2024-12-27 11:07 ` [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133 Parthiban Nallathambi
  2025-01-13 14:30   ` Linus Walleij
@ 2025-06-25  8:46   ` Paul Kocialkowski
  2025-06-25  9:36     ` Parthiban
  1 sibling, 1 reply; 30+ messages in thread
From: Paul Kocialkowski @ 2025-06-25  8:46 UTC (permalink / raw)
  To: Parthiban Nallathambi
  Cc: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I, iommu, devicetree, linux-arm-kernel,
	linux-sunxi, linux-kernel, dri-devel, linux-clk, linux-gpio,
	linux-phy

[-- Attachment #1: Type: text/plain, Size: 4798 bytes --]

Hi and thanks for your work!

On Fri 27 Dec 24, 16:37, Parthiban Nallathambi wrote:
> lvds, lcd, dsi all shares the same GPIO D bank and lvds0
> data 3 lines and lvds1 pins are missed, add them.

Would it also make sense to submit device-tree pin definitions here?

Thanks!

Paul

> Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
> ---
>  drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c | 12 ++++++++++++
>  1 file changed, 12 insertions(+)
> 
> diff --git a/drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c b/drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c
> index df90c75fb3c5..b97de80ae2f3 100644
> --- a/drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c
> +++ b/drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c
> @@ -256,72 +256,84 @@ static const struct sunxi_desc_pin a100_pins[] = {
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D12 */
> +		  SUNXI_FUNCTION(0x3, "lvds0"),		/* D3P */
>  		  SUNXI_FUNCTION(0x4, "dsi0"),		/* DP3 */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 8)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 9),
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D13 */
> +		  SUNXI_FUNCTION(0x3, "lvds0"),		/* D3N */
>  		  SUNXI_FUNCTION(0x4, "dsi0"),		/* DM3 */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 9)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 10),
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D14 */
> +		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D0P */
>  		  SUNXI_FUNCTION(0x4, "spi1"),		/* CS */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 10)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 11),
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D15 */
> +		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D0N */
>  		  SUNXI_FUNCTION(0x4, "spi1"),		/* CLK */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 11)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 12),
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D18 */
> +		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D1P */
>  		  SUNXI_FUNCTION(0x4, "spi1"),		/* MOSI */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 12)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 13),
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D19 */
> +		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D1N */
>  		  SUNXI_FUNCTION(0x4, "spi1"),		/* MISO */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 13)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 14),
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D20 */
> +		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D2P */
>  		  SUNXI_FUNCTION(0x4, "uart3"),		/* TX */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 14)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 15),
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D21 */
> +		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D2N */
>  		  SUNXI_FUNCTION(0x4, "uart3"),		/* RX */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 15)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 16),
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D22 */
> +		  SUNXI_FUNCTION(0x3, "lvds1"),		/* CKP */
>  		  SUNXI_FUNCTION(0x4, "uart3"),		/* RTS */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 16)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 17),
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* D23 */
> +		  SUNXI_FUNCTION(0x3, "lvds1"),		/* CKN */
>  		  SUNXI_FUNCTION(0x4, "uart3"),		/* CTS */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 17)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 18),
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* CLK */
> +		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D3P */
>  		  SUNXI_FUNCTION(0x4, "uart4"),		/* TX */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 18)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 19),
>  		  SUNXI_FUNCTION(0x0, "gpio_in"),
>  		  SUNXI_FUNCTION(0x1, "gpio_out"),
>  		  SUNXI_FUNCTION(0x2, "lcd0"),		/* DE */
> +		  SUNXI_FUNCTION(0x3, "lvds1"),		/* D3N */
>  		  SUNXI_FUNCTION(0x4, "uart4"),		/* RX */
>  		  SUNXI_FUNCTION_IRQ_BANK(0x6, 2, 19)),
>  	SUNXI_PIN(SUNXI_PINCTRL_PIN(D, 20),
> 
> -- 
> 2.39.5
> 

-- 
Paul Kocialkowski,

Independent contractor - sys-base - https://www.sys-base.io/
Free software developer - https://www.paulk.fr/

Expert in multimedia, graphics and embedded hardware support with Linux.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133
  2025-06-25  8:46   ` Paul Kocialkowski
@ 2025-06-25  9:36     ` Parthiban
  2025-06-25 10:11       ` Paul Kocialkowski
  0 siblings, 1 reply; 30+ messages in thread
From: Parthiban @ 2025-06-25  9:36 UTC (permalink / raw)
  To: Paul Kocialkowski
  Cc: parthiban, Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I, iommu, devicetree, linux-arm-kernel,
	linux-sunxi, linux-kernel, dri-devel, linux-clk, linux-gpio,
	linux-phy


On 6/25/25 2:16 PM, Paul Kocialkowski wrote:
> Hi and thanks for your work!
> 
> On Fri 27 Dec 24, 16:37, Parthiban Nallathambi wrote:
>> lvds, lcd, dsi all shares the same GPIO D bank and lvds0
>> data 3 lines and lvds1 pins are missed, add them.
> Would it also make sense to submit device-tree pin definitions here?

this patch is already merged. 
git show --stat cef4f1b5ba99a964cd6dd248bb373520573c972f
commit cef4f1b5ba99a964cd6dd248bb373520573c972f
Author: Parthiban Nallathambi <parthiban@linumiz.com>
Date:   Fri Dec 27 16:37:57 2024 +0530

    pinctrl: sunxi: add missed lvds pins for a100/a133
    
    lvds, lcd, dsi all shares the same GPIO D bank and lvds0
    data 3 lines and lvds1 pins are missed, add them.
    
    Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
    Link: https://lore.kernel.org/20241227-a133-display-support-v1-10-13b52f71fb14@linumiz.com
    Signed-off-by: Linus Walleij <linus.walleij@linaro.org>

 drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c | 12 ++++++++++++
 1 file changed, 12 insertions(+)

Do you mean the consumer/board devicetree changes?

Thanks,
Parthiban

> 
> Thanks!
> 
> Paul


^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 17/22] phy: allwinner: phy-sun6i-mipi-dphy: add LVDS support
  2025-06-25  8:41   ` [PATCH 17/22] phy: allwinner: phy-sun6i-mipi-dphy: add LVDS support Paul Kocialkowski
@ 2025-06-25  9:38     ` Parthiban
  0 siblings, 0 replies; 30+ messages in thread
From: Parthiban @ 2025-06-25  9:38 UTC (permalink / raw)
  To: Paul Kocialkowski
  Cc: parthiban, Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I, iommu, devicetree, linux-arm-kernel,
	linux-sunxi, linux-kernel, dri-devel, linux-clk, linux-gpio,
	linux-phy

On 6/25/25 2:11 PM, Paul Kocialkowski wrote:
> Similar work was already submitted for D1/T113-S3 LVDS support, which seems to
> be the exact same situation as the A133.
> 
> See: https://patchwork.freedesktop.org/series/145276/
> 
> I just made a review of that series and find it more elegant in various ways
> (especially since configuring the registers in set_mode is not the right place).
> So you probably want to follow-up on that series instead.
> 
> Note that both D1/T113-S3 and A133 support a second LVDS output, LVDS1, which
> uses the traditional TCON0 LVDS PHY. It would be great to be able to support
> both outputs as well as dual-link modes!

Thanks for the inputs. Yes, am aware of that series in open. I couldn't find time
last weeks to clean this patch. Will do it in a week or two.

Thanks,
Parthiban

> 
> All the best,
> 
> Paul

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133
  2025-06-25  9:36     ` Parthiban
@ 2025-06-25 10:11       ` Paul Kocialkowski
  2025-06-25 10:46         ` Parthiban
  0 siblings, 1 reply; 30+ messages in thread
From: Paul Kocialkowski @ 2025-06-25 10:11 UTC (permalink / raw)
  To: Parthiban
  Cc: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I, iommu, devicetree, linux-arm-kernel,
	linux-sunxi, linux-kernel, dri-devel, linux-clk, linux-gpio,
	linux-phy

[-- Attachment #1: Type: text/plain, Size: 1626 bytes --]

On Wed 25 Jun 25, 15:06, Parthiban wrote:
> 
> On 6/25/25 2:16 PM, Paul Kocialkowski wrote:
> > Hi and thanks for your work!
> > 
> > On Fri 27 Dec 24, 16:37, Parthiban Nallathambi wrote:
> >> lvds, lcd, dsi all shares the same GPIO D bank and lvds0
> >> data 3 lines and lvds1 pins are missed, add them.
> > Would it also make sense to submit device-tree pin definitions here?
> 
> this patch is already merged. 
> git show --stat cef4f1b5ba99a964cd6dd248bb373520573c972f
> commit cef4f1b5ba99a964cd6dd248bb373520573c972f
> Author: Parthiban Nallathambi <parthiban@linumiz.com>
> Date:   Fri Dec 27 16:37:57 2024 +0530
> 
>     pinctrl: sunxi: add missed lvds pins for a100/a133
>     
>     lvds, lcd, dsi all shares the same GPIO D bank and lvds0
>     data 3 lines and lvds1 pins are missed, add them.
>     
>     Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
>     Link: https://lore.kernel.org/20241227-a133-display-support-v1-10-13b52f71fb14@linumiz.com
>     Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
> 
>  drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c | 12 ++++++++++++
>  1 file changed, 12 insertions(+)
> 
> Do you mean the consumer/board devicetree changes?

I mean the pin definitions for lvds in the sun50i-a100.dtsi device-tree.

But maybe you wanted to submit those after the bindings/driver changes are
merged?

Cheers,

Paul

-- 
Paul Kocialkowski,

Independent contractor - sys-base - https://www.sys-base.io/
Free software developer - https://www.paulk.fr/

Expert in multimedia, graphics and embedded hardware support with Linux.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133
  2025-06-25 10:11       ` Paul Kocialkowski
@ 2025-06-25 10:46         ` Parthiban
  0 siblings, 0 replies; 30+ messages in thread
From: Parthiban @ 2025-06-25 10:46 UTC (permalink / raw)
  To: Paul Kocialkowski
  Cc: parthiban, Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I, iommu, devicetree, linux-arm-kernel,
	linux-sunxi, linux-kernel, dri-devel, linux-clk, linux-gpio,
	linux-phy


On 6/25/25 3:41 PM, Paul Kocialkowski wrote:
> On Wed 25 Jun 25, 15:06, Parthiban wrote:
>>
>> On 6/25/25 2:16 PM, Paul Kocialkowski wrote:
>>> Hi and thanks for your work!
>>>
>>> On Fri 27 Dec 24, 16:37, Parthiban Nallathambi wrote:
>>>> lvds, lcd, dsi all shares the same GPIO D bank and lvds0
>>>> data 3 lines and lvds1 pins are missed, add them.
>>> Would it also make sense to submit device-tree pin definitions here?
>>
>> this patch is already merged. 
>> git show --stat cef4f1b5ba99a964cd6dd248bb373520573c972f
>> commit cef4f1b5ba99a964cd6dd248bb373520573c972f
>> Author: Parthiban Nallathambi <parthiban@linumiz.com>
>> Date:   Fri Dec 27 16:37:57 2024 +0530
>>
>>     pinctrl: sunxi: add missed lvds pins for a100/a133
>>     
>>     lvds, lcd, dsi all shares the same GPIO D bank and lvds0
>>     data 3 lines and lvds1 pins are missed, add them.
>>     
>>     Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
>>     Link: https://lore.kernel.org/20241227-a133-display-support-v1-10-13b52f71fb14@linumiz.com
>>     Signed-off-by: Linus Walleij <linus.walleij@linaro.org>
>>
>>  drivers/pinctrl/sunxi/pinctrl-sun50i-a100.c | 12 ++++++++++++
>>  1 file changed, 12 insertions(+)
>>
>> Do you mean the consumer/board devicetree changes?
> 
> I mean the pin definitions for lvds in the sun50i-a100.dtsi device-tree.
> 
> But maybe you wanted to submit those after the bindings/driver changes are
> merged?

                pio: pinctrl@300b000 {
                        compatible = "allwinner,sun50i-a100-pinctrl";
                        reg = <0x0300b000 0x400>;
                        interrupts = <GIC_SPI 54 IRQ_TYPE_LEVEL_HIGH>,
                                     <GIC_SPI 55 IRQ_TYPE_LEVEL_HIGH>,
                                     <GIC_SPI 56 IRQ_TYPE_LEVEL_HIGH>,
                                     <GIC_SPI 57 IRQ_TYPE_LEVEL_HIGH>,
                                     <GIC_SPI 58 IRQ_TYPE_LEVEL_HIGH>,
                                     <GIC_SPI 59 IRQ_TYPE_LEVEL_HIGH>,
                                     <GIC_SPI 60 IRQ_TYPE_LEVEL_HIGH>;
                        clocks = <&ccu CLK_APB1>, <&dcxo24M>, <&osc32k>;
                        clock-names = "apb", "hosc", "losc";
                        gpio-controller;
                        #gpio-cells = <3>;
                        interrupt-controller;
                        #interrupt-cells = <3>;
                        
                        lcd_lvds0_pins: lcd-lvds0-pins {
                                pins = "PD0", "PD1", "PD2", "PD3", "PD4",
                                        "PD5", "PD6", "PD7", "PD8", "PD9";
                                function = "lvds0";
                        };
                        
                        lcd_lvds1_pins: lcd-lvds1-pins {
                                pins = "PD10", "PD11", "PD12", "PD13", "PD14",
                                        "PD15", "PD16", "PD17", "PD18", "PD19";
                                function = "lvds1";
                        };
                        
                        dsi0_pins: dsi0-pins {
                                pins = "PD0", "PD1", "PD2", "PD3", "PD4",
                                        "PD5", "PD6", "PD7", "PD8", "PD9";
                                function = "dsi0";
                        };

                        mmc0_pins: mmc0-pins {
                                pins = "PF0", "PF1", "PF2", "PF3",
                                       "PF4", "PF5";
                                function = "mmc0";
                                drive-strength = <30>;
                                bias-pull-up;
                        };

It got missed when my email server refused to send all the patches.
I will send the revised full patch series after fixing the comments.
Anyways above are the pin definitions.

Thanks,
Parthiban
https://linumiz.com
https://www.linkedin.com/company/linumiz

Linumiz GmbH
Am Hohen Rott 9, 37170, Uslar
Registergericht: Amtsgericht Göttingen, HRB 207840
Geschäftsführer: Madan Raj Mohanraj

> 
> Cheers,
> 
> Paul
> 


^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 07/22] dt-bindings: vendor-prefixes: Shenzhen Baijie Technology
  2024-12-27 11:07 ` [PATCH 07/22] dt-bindings: vendor-prefixes: Shenzhen Baijie Technology Parthiban Nallathambi
@ 2025-08-07 15:24   ` Paul Kocialkowski
  0 siblings, 0 replies; 30+ messages in thread
From: Paul Kocialkowski @ 2025-08-07 15:24 UTC (permalink / raw)
  To: Parthiban Nallathambi
  Cc: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I, iommu, devicetree, linux-arm-kernel,
	linux-sunxi, linux-kernel, dri-devel, linux-clk, linux-gpio,
	linux-phy

[-- Attachment #1: Type: text/plain, Size: 1516 bytes --]

Hi,

On Fri 27 Dec 24, 16:37, Parthiban Nallathambi wrote:
> Add entry for Shenzhen Baijie Technology (https://szbaijie.com)
> 
> Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
> ---
>  Documentation/devicetree/bindings/vendor-prefixes.yaml | 2 ++
>  1 file changed, 2 insertions(+)
> 
> diff --git a/Documentation/devicetree/bindings/vendor-prefixes.yaml b/Documentation/devicetree/bindings/vendor-prefixes.yaml
> index da01616802c7..81cbc8b6b195 100644
> --- a/Documentation/devicetree/bindings/vendor-prefixes.yaml
> +++ b/Documentation/devicetree/bindings/vendor-prefixes.yaml
> @@ -1466,6 +1466,8 @@ patternProperties:
>    "^synopsys,.*":
>      description: Synopsys, Inc. (deprecated, use snps)
>      deprecated: true
> +  "^szbaijie,.*":

It's quite common for Chinese companies to have their main location as a prefix
in their name, for example Rockchip's full name is Fuzhou Rockchip Electronics
Co., Ltd.

Since the company here calls itself "Baijie Technology" I think the "sz" part
should be dropped from the vendor prefix and just be "baijie,.*".

All the best,

Paul

> +    description: Shenzhen Baijie Technology Co., Ltd.
>    "^tbs,.*":
>      description: TBS Technologies
>    "^tbs-biometrics,.*":
> 
> -- 
> 2.39.5
> 
> 

-- 
Paul Kocialkowski,

Independent contractor - sys-base - https://www.sys-base.io/
Free software developer - https://www.paulk.fr/

Expert in multimedia, graphics and embedded hardware support with Linux.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 01/22] dt-bindings: iommu: sun50i: remove resets from required property
  2024-12-27 11:07 ` [PATCH 01/22] dt-bindings: iommu: sun50i: remove resets from required property Parthiban Nallathambi
@ 2025-08-07 15:27   ` Paul Kocialkowski
  0 siblings, 0 replies; 30+ messages in thread
From: Paul Kocialkowski @ 2025-08-07 15:27 UTC (permalink / raw)
  To: Parthiban Nallathambi
  Cc: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I, iommu, devicetree, linux-arm-kernel,
	linux-sunxi, linux-kernel, dri-devel, linux-clk, linux-gpio,
	linux-phy

[-- Attachment #1: Type: text/plain, Size: 1401 bytes --]

Hi Parthiban,

On Fri 27 Dec 24, 16:37, Parthiban Nallathambi wrote:
> iommu in a133/a100 does not have reset control. remove it
> from required property to make it optional.
> 
> Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
> ---
>  Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml | 1 -
>  1 file changed, 1 deletion(-)
> 
> diff --git a/Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml b/Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml
> index a8409db4a3e3..03176f68485b 100644
> --- a/Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml
> +++ b/Documentation/devicetree/bindings/iommu/allwinner,sun50i-h6-iommu.yaml
> @@ -42,7 +42,6 @@ required:
>    - reg
>    - interrupts
>    - clocks
> -  - resets

Since it was previously specified that other platforms do need the reset line,
the required part should be applied conditionally based on the compatible, not
removed entirely.

Also your commit title and message would look better with uppercase first
letters at the start of a sentence :)

All the best,

Paul

>  additionalProperties: false

-- 
Paul Kocialkowski,

Independent contractor - sys-base - https://www.sys-base.io/
Free software developer - https://www.paulk.fr/

Expert in multimedia, graphics and embedded hardware support with Linux.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

* Re: [PATCH 09/22] iommu: sun50i: make reset control optional
  2024-12-27 11:07 ` [PATCH 09/22] iommu: sun50i: make reset control optional Parthiban Nallathambi
  2025-01-06 11:24   ` Joerg Roedel
@ 2025-08-07 15:29   ` Paul Kocialkowski
  1 sibling, 0 replies; 30+ messages in thread
From: Paul Kocialkowski @ 2025-08-07 15:29 UTC (permalink / raw)
  To: Parthiban Nallathambi
  Cc: Joerg Roedel, Will Deacon, Robin Murphy, Rob Herring,
	Krzysztof Kozlowski, Conor Dooley, Chen-Yu Tsai, Jernej Skrabec,
	Samuel Holland, Maxime Ripard, Maarten Lankhorst,
	Thomas Zimmermann, David Airlie, Simona Vetter, Michael Turquette,
	Stephen Boyd, Philipp Zabel, Linus Walleij, Vinod Koul,
	Kishon Vijay Abraham I, iommu, devicetree, linux-arm-kernel,
	linux-sunxi, linux-kernel, dri-devel, linux-clk, linux-gpio,
	linux-phy

[-- Attachment #1: Type: text/plain, Size: 1339 bytes --]

Hi,

On Fri 27 Dec 24, 16:37, Parthiban Nallathambi wrote:
> A133/A100 SoC doesn't have reset control from the CCU. Get reset
> control line optionally.

With the dt bindings fixed, this:
Reviewed-by: Paul Kocialkowski <paulk@sys-base.io>

Although feel free to use a first uppercase later in the title after sun50i!

Cheers,

Paul

> Signed-off-by: Parthiban Nallathambi <parthiban@linumiz.com>
> ---
>  drivers/iommu/sun50i-iommu.c | 2 +-
>  1 file changed, 1 insertion(+), 1 deletion(-)
> 
> diff --git a/drivers/iommu/sun50i-iommu.c b/drivers/iommu/sun50i-iommu.c
> index 8d8f11854676..2ba804d682dc 100644
> --- a/drivers/iommu/sun50i-iommu.c
> +++ b/drivers/iommu/sun50i-iommu.c
> @@ -1030,7 +1030,7 @@ static int sun50i_iommu_probe(struct platform_device *pdev)
>  		goto err_free_cache;
>  	}
>  
> -	iommu->reset = devm_reset_control_get(&pdev->dev, NULL);
> +	iommu->reset = devm_reset_control_get_optional(&pdev->dev, NULL);
>  	if (IS_ERR(iommu->reset)) {
>  		dev_err(&pdev->dev, "Couldn't get our reset line.\n");
>  		ret = PTR_ERR(iommu->reset);
> 
> -- 
> 2.39.5
> 
> 

-- 
Paul Kocialkowski,

Independent contractor - sys-base - https://www.sys-base.io/
Free software developer - https://www.paulk.fr/

Expert in multimedia, graphics and embedded hardware support with Linux.

[-- Attachment #2: signature.asc --]
[-- Type: application/pgp-signature, Size: 833 bytes --]

^ permalink raw reply	[flat|nested] 30+ messages in thread

end of thread, other threads:[~2025-08-07 15:29 UTC | newest]

Thread overview: 30+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-12-27 11:07 [PATCH 00/22] Add support for A100/A133 display Parthiban Nallathambi
2024-12-27 11:07 ` [PATCH 01/22] dt-bindings: iommu: sun50i: remove resets from required property Parthiban Nallathambi
2025-08-07 15:27   ` Paul Kocialkowski
2024-12-27 11:07 ` [PATCH 02/22] dt-bindings: display: sunxi: Add a100/a133 display engine compatibles Parthiban Nallathambi
2024-12-27 11:07 ` [PATCH 03/22] dt-bindings: clock: sun8i de2 clock: Add PLL com clock Parthiban Nallathambi
2024-12-27 13:16   ` Rob Herring (Arm)
2024-12-27 11:07 ` [PATCH 04/22] dt-bindings: clock: sun8i de2 clock: Add a100/a133 compatible Parthiban Nallathambi
2024-12-27 11:07 ` [PATCH 05/22] dt-bindings: display: sun4i: add phy property Parthiban Nallathambi
2024-12-27 11:07 ` [PATCH 06/22] dt-bindings: display: sun4i: add a100/a133 tcon lcd Parthiban Nallathambi
2024-12-27 11:07 ` [PATCH 07/22] dt-bindings: vendor-prefixes: Shenzhen Baijie Technology Parthiban Nallathambi
2025-08-07 15:24   ` Paul Kocialkowski
2024-12-27 11:07 ` [PATCH 08/22] dt-bindings: arm: sunxi: document Szbaijie A133 helper board Parthiban Nallathambi
2024-12-27 11:07 ` [PATCH 09/22] iommu: sun50i: make reset control optional Parthiban Nallathambi
2025-01-06 11:24   ` Joerg Roedel
2025-08-07 15:29   ` Paul Kocialkowski
2024-12-27 11:07 ` [PATCH 10/22] pinctrl: sunxi: add missed lvds pins for a100/a133 Parthiban Nallathambi
2025-01-13 14:30   ` Linus Walleij
2025-01-14 15:46     ` Andre Przywara
2025-06-25  8:46   ` Paul Kocialkowski
2025-06-25  9:36     ` Parthiban
2025-06-25 10:11       ` Paul Kocialkowski
2025-06-25 10:46         ` Parthiban
2024-12-27 11:07 ` [PATCH 11/22] drm/sun4i: Add support for a100/a133 display engine Parthiban Nallathambi
2024-12-27 11:07 ` [PATCH 12/22] drm/sun4i: Add support for a100/a133 mixer Parthiban Nallathambi
2024-12-27 11:08 ` [PATCH 13/22] drm/sun4i: make tcon top tv0 optional Parthiban Nallathambi
2024-12-27 11:08 ` [PATCH 14/22] drm/sun4i: add a100/a133 tcon top quirks Parthiban Nallathambi
2024-12-27 11:08 ` [PATCH 15/22] clk: sunxi-ng: sun8i-de2: add pll-com clock support Parthiban Nallathambi
2024-12-27 11:08 ` [PATCH 16/22] clk: sunxi-ng: sun8i-de2: Add support for a100/a133 Parthiban Nallathambi
     [not found] ` <20241227-a133-display-support-v1-17-13b52f71fb14@linumiz.com>
2025-06-25  8:41   ` [PATCH 17/22] phy: allwinner: phy-sun6i-mipi-dphy: add LVDS support Paul Kocialkowski
2025-06-25  9:38     ` Parthiban

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).