Skip to contentSkip to conversation

drm/panel: Add support for Truly NT35597 panel driver

PATCH RESEND Superseded Abhinav Kumar 4 participants 8 messages Aug 28, 2018 – Sep 5, 2018

Subsystems (5)

v6 of 10 Superseded Latest is v10 →

lore
Share & tools
lore
#0 lore raw

PATCH RESEND v6 1/2 drm/panel: Add support for Truly NT35597 panel driver

From: "[email protected]" <[email protected]>

Add support for Truly NT35597 panel driver used
in MSM reference platforms.

This panel driver supports both single DSI and dual DSI modes.

However, this patch series adds support only for
dual DSI mode.

Changes in v6:
- Introduce panel config to store panel specific details
- Bring back the size member for the panel command structure to make the design more scalable
- Move the display mode from the DT to driver
- Change the compatible string to indicate which which board and panel it will be used for
- Rename the functions to match the panel driver
- Have a data member for each compatible string
- Remove the panel commands split as its not required for the panel init functionality

---
 drivers/gpu/drm/panel/Kconfig               |   8 +
 drivers/gpu/drm/panel/Makefile              |   1 +
 drivers/gpu/drm/panel/panel-truly-nt35597.c | 705 ++++++++++++++++++++++++++++
 3 files changed, 714 insertions(+)
 create mode 100644 drivers/gpu/drm/panel/panel-truly-nt35597.c
drivers/gpu/drm/panel/Kconfig +8 -0
index 6020c30..7ae74c2 100644
@@ -186,4 +186,12 @@ config DRM_PANEL_SITRONIX_ST7789V
 	  Say Y here if you want to enable support for the Sitronix
 	  ST7789V controller for 240x320 LCD panels
 
+config DRM_PANEL_TRULY_NT35597_WQXGA
+	tristate "Truly WQXGA"
+	depends on OF
+	depends on DRM_MIPI_DSI
+	select VIDEOMODE_HELPERS
+	help
+	  Say Y here if you want to enable support for Truly NT35597 WQXGA Dual DSI
+	  Video Mode panel
 endmenu
drivers/gpu/drm/panel/Makefile +1 -0
index 5ccaaa9..80fd19f 100644
@@ -19,3 +19,4 @@ obj-$(CONFIG_DRM_PANEL_SEIKO_43WVF1G) += panel-seiko-43wvf1g.o
 obj-$(CONFIG_DRM_PANEL_SHARP_LQ101R1SX01) += panel-sharp-lq101r1sx01.o
 obj-$(CONFIG_DRM_PANEL_SHARP_LS043T1LE01) += panel-sharp-ls043t1le01.o
 obj-$(CONFIG_DRM_PANEL_SITRONIX_ST7789V) += panel-sitronix-st7789v.o
+obj-$(CONFIG_DRM_PANEL_TRULY_NT35597_WQXGA) += panel-truly-nt35597.o
drivers/gpu/drm/panel/panel-truly-nt35597.c new file +705 -0

705 lines not on this page · raw message

Signature · 7 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
#1 lore raw

PATCH RESEND v6 2/2 dt-bindings: Add Truly NT35597 panel driver bindings

From: "[email protected]" <[email protected]>

Add the device tree bindings for Truly NT35597 panel driver. This panel driver supports both single DSI and dual DSI.

However, this patch series supports only dual DSI.

Changes in v6:
- Change the compatible string to indicate the
reference board and the panel
- Remove the display timing node

---
 .../devicetree/bindings/display/truly,nt35597.txt  | 55 ++++++++++++++++++++++
 1 file changed, 55 insertions(+)
 create mode 100644 Documentation/devicetree/bindings/display/truly,nt35597.txt
Documentation/devicetree/bindings/display/truly,nt35597.txt new file +55 -0
new file mode 100644
index 0000000..68960a6
@@ -0,0 +1,55 @@
+Truly model NT35597 1440x2560 DSI Panel
+
+Required properties:
+- compatible: should be "qcom,sdm845-mtp-2K-display"
+- vdda-supply: phandle of the regulator that provides the supply voltage
+  Power IC supply
+- vdispp-supply: phandle of the regulator that provides the supply voltage
+  for positive LCD bias
+- vdispn-supply: phandle of the regulator that provides the supply voltage
+  for negative LCD bias
+- reset-gpios: phandle of gpio for reset line
+  This should be 8mA, gpio can be configured using mux, pinctrl, pinctrl-names
+- mode-gpios: phandle of the gpio for choosing the mode of the display
+  for single DSI or Dual DSI
+  This should be low for dual DSI and high for single DSI mode
+- ports: This device has two video ports driven by two DSIs. Their connections
+  are modelled using the OF graph bindings specified in
+  Documentation/devicetree/bindings/graph.txt.
+  - port@0: DSI input port driven by master DSI
+  - port@1: DSI input port driven by secondary DSI
+
+Example:
+
+	dsi@ae94000 {
+		panel@0 {
+			compatible = "qcom,sdm845-mtp-2K-display";
+			reg = <0>;
+			vdda-supply = <&pm8998_l14>;
+			vdispp-supply = <&lab_regulator>;
+			vdispn-supply = <&ibb_regulator>;
+			pinctrl-names = "default", "suspend";
+			pinctrl-0 = <&dpu_dsi_active>;
+			pinctrl-1 = <&dpu_dsi_suspend>;
+
+			reset-gpios = <&tlmm 6 0>;
+			mode-gpios = <&tlmm 52 0>;
+			ports {
+				#address-cells = <1>;
+				#size-cells = <0>;
+				port@0 {
+					reg = <0>;
+					panel0_in: endpoint {
+						remote-endpoint = <&dsi0_out>;
+					};
+				};
+
+				port@1 {
+					reg = <1>;
+					panel1_in: endpoint {
+						remote-endpoint = <&dsi1_out>;
+					};
+				};
+			};
+		};
+	};
Signature · 7 lines
The Qualcomm Innovation Center, Inc. is a member of the Code Aurora Forum,
a Linux Foundation Collaborative Project

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel
Reviewed-by on v6 2/2
#2 lore raw

Re: [PATCH RESEND v6 2/2] dt-bindings: Add Truly NT35597 panel driver bindings

Quoted 5 lines · Abhinav Kumar

From: "[email protected]" <[email protected]>

Add the device tree bindings for Truly NT35597 panel driver. This panel driver supports both single DSI and dual DSI.

Quoted 8 lines

However, this patch series supports only dual DSI.

Changes in v6:
- Change the compatible string to indicate the
reference board and the panel
- Remove the display timing node

I like this much better :)

Quoted 1 line

+Truly model NT35597 1440x2560 DSI Panel

Maybe say just
"Truly model NT35597 DSI display driver"

Then a blurb of text like this:

"The Truly NT35597 is a generic display driver, currently only configured for use in the 2K display on th Qualcomm SDM845."

The rest is fine.

With the above changes:

Yours,
Linus Walleij
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#3 lore raw
In reply to Abhinav Kumar

Hi Abhinav.

Quoted 5 lines · Abhinav Kumar

From: "[email protected]" <[email protected]>

Add support for Truly NT35597 panel driver used
in MSM reference platforms.

Quoted 7 lines

This panel driver supports both single DSI and dual DSI modes.

However, this patch series adds support only for
dual DSI mode.

Changes in v6:

...

Comments from:
https://lists.freedesktop.org/archives/dri-devel/2018-August/187562.html

seems not to be addressed? Did you miss them?

Sam
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#4 lore raw

Hi Sam

Yes, looks like I missed Philip's comments.

Will reply to his mail and fix them in v7.

Thanks for pointing it out.

Abhinav

Quoted 15 lines · Sam Ravnborg

Hi Abhinav.

Quoted 5 lines · Abhinav Kumar

From: "[email protected]" <[email protected]>

Add support for Truly NT35597 panel driver used
in MSM reference platforms.

Quoted 7 lines

This panel driver supports both single DSI and dual DSI modes.

However, this patch series adds support only for
dual DSI mode.

Changes in v6:

Quoted 8 lines

...

Comments from:
https://lists.freedesktop.org/archives/dri-devel/2018-August/187562.html

seems not to be addressed? Did you miss them?

Sam

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#5 lore raw
In reply to Abhinav Kumar
Quoted 26 lines · Abhinav Kumar

From: "[email protected]" <[email protected]>

Add support for Truly NT35597 panel driver used
in MSM reference platforms.

This panel driver supports both single DSI and dual DSI modes.

However, this patch series adds support only for
dual DSI mode.

Changes in v6:
- Introduce panel config to store panel specific details
- Bring back the size member for the panel command structure to make the design more scalable
- Move the display mode from the DT to driver
- Change the compatible string to indicate which which board and panel it will be used for
- Rename the functions to match the panel driver
- Have a data member for each compatible string
- Remove the panel commands split as its not required for the panel init functionality

[..]

Quoted 1 line
drivers/gpu/drm/panel/panel-truly-nt35597.c +0 -0

[..]

drivers/gpu/drm/panel/panel-truly-nt35597.c line 686

Quoted 1 line
drivers/gpu/drm/panel/panel-truly-nt35597.c +1 -0
+	{	.compatible = "qcom,sdm845-mtp-2K-display",

I do not agree with Linus here.

If I understand correctly the variability in the video timing comes from the fact that the LCD Driver IC (NT35597) can be paired with different LCD panels. As such I strongly believe that the compatible should describe this combo, not which phone/devkit you mounted a panel using this Driver IC on.

Regards,
Bjorn
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#6 lore raw
Quoted 32 lines · Bjorn Andersson
Quoted 26 lines · Abhinav Kumar

From: "[email protected]" <[email protected]>

Add support for Truly NT35597 panel driver used
in MSM reference platforms.

This panel driver supports both single DSI and dual DSI modes.

However, this patch series adds support only for
dual DSI mode.

Changes in v6:
- Introduce panel config to store panel specific details
- Bring back the size member for the panel command structure to make the design more scalable
- Move the display mode from the DT to driver
- Change the compatible string to indicate which which board and panel it will be used for
- Rename the functions to match the panel driver
- Have a data member for each compatible string
- Remove the panel commands split as its not required for the panel init functionality

[..]

Quoted 1 line
drivers/gpu/drm/panel/panel-truly-nt35597.c +0 -0

[..]

Quoted 1 line

+ { .compatible = "qcom,sdm845-mtp-2K-display",

Quoted 7 lines

I do not agree with Linus here.

If I understand correctly the variability in the video timing comes from the fact that the LCD Driver IC (NT35597) can be paired with different LCD panels. As such I strongly believe that the compatible should describe this combo, not which phone/devkit you mounted a panel using this Driver IC on.

I agree with that.

I just saw "it's some qualcomm string, not just the name of the LCD driver so OK".

The inability to parse the "qcom,*" string is just my ignorance, sorry for that.

Yours,
Linus Walleij
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

#7 lore raw

Hi Bjorn and Linus

Thanks for the comments.

Based on this, since we want to remove the dev/phone dependency but retain the driver + panel dependency on the compatible string, while addressing Philip's comments, I shall rename the string as "truly,nt35597-2K-display".

Let me know if there are any concerns with this.

Thanks

Abhinav

Quoted 50 lines · Linus Walleij
Quoted 32 lines · Bjorn Andersson
Quoted 26 lines · Abhinav Kumar

From: "[email protected]" <[email protected]>

Add support for Truly NT35597 panel driver used
in MSM reference platforms.

This panel driver supports both single DSI and dual DSI modes.

However, this patch series adds support only for
dual DSI mode.

Changes in v6:
- Introduce panel config to store panel specific details
- Bring back the size member for the panel command structure to make the design more scalable
- Move the display mode from the DT to driver
- Change the compatible string to indicate which which board and panel it will be used for
- Rename the functions to match the panel driver
- Have a data member for each compatible string
- Remove the panel commands split as its not required for the panel init functionality

[..]

Quoted 1 line
drivers/gpu/drm/panel/panel-truly-nt35597.c +0 -0

[..]

Quoted 1 line

+ { .compatible = "qcom,sdm845-mtp-2K-display",

Quoted 7 lines

I do not agree with Linus here.

If I understand correctly the variability in the video timing comes from the fact that the LCD Driver IC (NT35597) can be paired with different LCD panels. As such I strongly believe that the compatible should describe this combo, not which phone/devkit you mounted a panel using this Driver IC on.

I agree with that.

I just saw "it's some qualcomm string, not just the name of the LCD driver so OK".

The inability to parse the "qcom,*" string is just my ignorance, sorry for that.

Quoted 6 lines

Yours,
Linus Walleij
_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel

_______________________________________________
dri-devel mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/dri-devel