Skip to contentSkip to conversation

Add waveshare 7inch touchscreen panel support

PATCH In review Shengyang Chen 6 participants 18 messages Jan 9, 2024 – Jan 16, 2024

Subsystems (4)
lore
Share & tools
lore
#0 lore raw

v2 cover Add waveshare 7inch touchscreen panel support

This patchset adds waveshare 7inch touchscreen panel support for the StarFive JH7110 SoC.

changes since v1:
- Rebased on tag v6.7.

patch 1:
- Gave up original changing.
- Changed the commit message.
- Add compatible in panel-simple.yaml

patch 2:
- Gave up original changing.
- Changed the commit message.
- Add new mode for the panel in panel-simple.c

v1: https://patchwork.kernel.org/project/dri-devel/cover/[email protected]/

Shengyang Chen (2):
dt-bindings: display: panel: panel-simple: Add compatible property for
waveshare 7inch touchscreen panel
gpu: drm: panel: panel-simple: add new display mode for waveshare
7inch touchscreen panel

 .../bindings/display/panel/panel-simple.yaml  |  2 ++
 drivers/gpu/drm/panel/panel-simple.c          | 28 +++++++++++++++++++
 2 files changed, 30 insertions(+)
Signature · 1 line
2.17.1
#1 lore raw

PATCH v2 1/2 dt-bindings: display: panel: panel-simple: Add compatible property for waveshare 7inch touchscreen panel

The waveshare 7" 800x480 panel is a clone of Raspberry Pi 7" 800x480 panel It can be drived by Raspberry Pi panel's process but it needs different timing from Raspberry Pi panel. Add compatible property for it.

---
 .../devicetree/bindings/display/panel/panel-simple.yaml         | 2 ++
 1 file changed, 2 insertions(+)
Documentation/devicetree/bindings/display/panel/panel-simple.yaml +2 -0
index 11422af3477e..02f6b1b2ddc9 100644
@@ -335,6 +335,8 @@ properties:
       - vivax,tpc9150-panel
         # VXT 800x480 color TFT LCD panel
       - vxt,vl050-8048nt-c01
+        # Waveshare 7" (800x480) touchscreen LCD panel
+      - waveshare,7inch-touchscreen
         # Winstar Display Corporation 3.5" QVGA (320x240) TFT LCD panel
       - winstar,wf35ltiacd
         # Yes Optoelectronics YTC700TLAG-05-201C 7" TFT LCD panel
Signature · 1 line
2.17.1
#2 lore raw

Re: [PATCH v2 1/2] dt-bindings: display: panel: panel-simple: Add compatible property for waveshare 7inch touchscreen panel

Quoted 15 lines · Shengyang Chen

The waveshare 7" 800x480 panel is a clone of Raspberry Pi 7" 800x480 panel It can be drived by Raspberry Pi panel's process but it needs different timing from Raspberry Pi panel. Add compatible property for it.

---
 .../devicetree/bindings/display/panel/panel-simple.yaml         | 2 ++
 1 file changed, 2 insertions(+)
Documentation/devicetree/bindings/display/panel/panel-simple.yaml +0 -0
index 11422af3477e..02f6b1b2ddc9 100644

Documentation/devicetree/bindings/display/panel/panel-simple.yaml properties: · line 339

Quoted 5 lines
Documentation/devicetree/bindings/display/panel/panel-simple.yaml +2 -0
@@ -335,6 +335,8 @@ properties:
       - vivax,tpc9150-panel
         # VXT 800x480 color TFT LCD panel
       - vxt,vl050-8048nt-c01
+        # Waveshare 7" (800x480) touchscreen LCD panel
+      - waveshare,7inch-touchscreen

Is "7inch-touchscreen" really a specific enough identifier for this device?

Quoted 6 lines
Documentation/devicetree/bindings/display/panel/panel-simple.yaml +0 -0
         # Winstar Display Corporation 3.5" QVGA (320x240) TFT LCD panel
       - winstar,wf35ltiacd
         # Yes Optoelectronics YTC700TLAG-05-201C 7" TFT LCD panel
Signature · 1 line
2.17.1
#3 lore raw

Re: [PATCH v2 1/2] dt-bindings: display: panel: panel-simple: Add compatible property for waveshare 7inch touchscreen panel

Quoted 11 lines · Conor Dooley
Quoted 10 lines · Shengyang Chen

The waveshare 7" 800x480 panel is a clone of Raspberry Pi 7" 800x480 panel It can be drived by Raspberry Pi panel's process but it needs different timing from Raspberry Pi panel. Add compatible property for it.

---
  .../devicetree/bindings/display/panel/panel-simple.yaml         | 2 ++
  1 file changed, 2 insertions(+)
Quoted 13 lines

Documentation/devicetree/bindings/display/panel/panel-simple.yaml properties: · line 339

Quoted 10 lines
Documentation/devicetree/bindings/display/panel/panel-simple.yaml +2 -0
index 11422af3477e..02f6b1b2ddc9 100644
@@ -335,6 +335,8 @@ properties:
        - vivax,tpc9150-panel
          # VXT 800x480 color TFT LCD panel
        - vxt,vl050-8048nt-c01
+        # Waveshare 7" (800x480) touchscreen LCD panel
+      - waveshare,7inch-touchscreen

Is "7inch-touchscreen" really a specific enough identifier for this device?

Waveshare has very precise SKUs, this should be something like waveshare,7inch-dsi-sku19885 perhaps

Neil

Quoted 7 lines
Quoted 7 lines
Documentation/devicetree/bindings/display/panel/panel-simple.yaml +0 -0
          # Winstar Display Corporation 3.5" QVGA (320x240) TFT LCD panel
        - winstar,wf35ltiacd
          # Yes Optoelectronics YTC700TLAG-05-201C 7" TFT LCD panel
Signature · 1 line
2.17.1
#4 lore raw

RE: [PATCH v2 1/2] dt-bindings: display: panel: panel-simple: Add compatible property for waveshare 7inch touchscreen panel

Quoted 49 lines

-----Original Message-----
From: [email protected] <[email protected]>
Sent: 2024年1月10日 17:06
To: Conor Dooley <[email protected]>; Shengyang Chen <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Changhuang Liang <[email protected]>; Keith Zhao <[email protected]>; Jack Zhu <[email protected]>; [email protected]
Subject: Re: [PATCH v2 1/2] dt-bindings: display: panel: panel-simple: Add compatible property for waveshare 7inch touchscreen panel

Quoted 20 lines · Conor Dooley
Quoted 19 lines · Shengyang Chen

The waveshare 7" 800x480 panel is a clone of Raspberry Pi 7" 800x480 panel It can be drived by Raspberry Pi panel's process but it needs different timing from Raspberry Pi panel. Add compatible property for it.

---
  .../devicetree/bindings/display/panel/panel-simple.yaml         | 2 ++
  1 file changed, 2 insertions(+)

diff --git a/Documentation/devicetree/bindings/display/panel/panel-simple.yaml b/Documentation/devicetree/bindings/display/panel/panel-simple.yaml index 11422af3477e..02f6b1b2ddc9 100644
---
a/Documentation/devicetree/bindings/display/panel/panel-simple.yaml +++ b/Documentation/devicetree/bindings/display/panel/panel-simple.ya +++ ml

(quoted diff) +0 -0
@@ -335,6 +335,8 @@ properties:
Quoted 8 lines

Documentation/devicetree/bindings/display/panel/panel-simple.yaml properties: · line 339

Quoted 5 lines
Documentation/devicetree/bindings/display/panel/panel-simple.yaml +2 -0
        - vivax,tpc9150-panel
          # VXT 800x480 color TFT LCD panel
        - vxt,vl050-8048nt-c01
+        # Waveshare 7" (800x480) touchscreen LCD panel
+      - waveshare,7inch-touchscreen

Is "7inch-touchscreen" really a specific enough identifier for this device?

Quoted 4 lines

Waveshare has very precise SKUs, this should be something like waveshare,7inch-dsi-sku19885 perhaps

Neil

thanks for mention, It will be checked if next version is needed.

Quoted 9 lines
Quoted 3 lines

Review properties: · line 340

Quoted 3 lines
(quoted diff) +0 -0
          # Winstar Display Corporation 3.5" QVGA (320x240) TFT LCD

panel

Quoted 5 lines
Quoted 5 lines
Documentation/devicetree/bindings/display/panel/panel-simple.yaml +0 -1
        - winstar,wf35ltiacd
          # Yes Optoelectronics YTC700TLAG-05-201C 7" TFT LCD panel
--

2.17.1

#5 lore raw

RE: [PATCH v2 1/2] dt-bindings: display: panel: panel-simple: Add compatible property for waveshare 7inch touchscreen panel

In reply to Conor Dooley

Hi, Conor

Thanks for comment.

Quoted 27 lines

-----Original Message-----
From: Conor Dooley <[email protected]>
Sent: 2024年1月10日 0:32
To: Shengyang Chen <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Changhuang Liang <[email protected]>; Keith Zhao <[email protected]>; Jack Zhu <[email protected]>; [email protected]
Subject: Re: [PATCH v2 1/2] dt-bindings: display: panel: panel-simple: Add compatible property for waveshare 7inch touchscreen panel

Quoted 10 lines · Shengyang Chen

The waveshare 7" 800x480 panel is a clone of Raspberry Pi 7" 800x480 panel It can be drived by Raspberry Pi panel's process but it needs different timing from Raspberry Pi panel. Add compatible property for it.

---
 .../devicetree/bindings/display/panel/panel-simple.yaml         | 2 ++
 1 file changed, 2 insertions(+)
Quoted 17 lines
Quoted 9 lines

diff --git a/Documentation/devicetree/bindings/display/panel/panel-simple.yaml b/Documentation/devicetree/bindings/display/panel/panel-simple.yaml index 11422af3477e..02f6b1b2ddc9 100644
---
a/Documentation/devicetree/bindings/display/panel/panel-simple.yaml +++ b/Documentation/devicetree/bindings/display/panel/panel-simple.yam +++ l

Documentation/devicetree/bindings/display/panel/panel-simple.yaml properties: · line 339

Quoted 5 lines
Documentation/devicetree/bindings/display/panel/panel-simple.yaml +2 -0
@@ -335,6 +335,8 @@ properties:
       - vivax,tpc9150-panel
         # VXT 800x480 color TFT LCD panel
       - vxt,vl050-8048nt-c01
+        # Waveshare 7" (800x480) touchscreen LCD panel
+      - waveshare,7inch-touchscreen

Is "7inch-touchscreen" really a specific enough identifier for this device?

Referring to official website[1] and Neil's suggestion, maybe I should change to "7inch-touchscreen-dsi-lcd" or "waveshare,7inch-dsi-sku19885" if the next patch version is needed.

[1]: https://www.waveshare.com/7inch-dsi-lcd.htm

Quoted 6 lines
Quoted 6 lines
Documentation/devicetree/bindings/display/panel/panel-simple.yaml +0 -1
         # Winstar Display Corporation 3.5" QVGA (320x240) TFT LCD panel
       - winstar,wf35ltiacd
         # Yes Optoelectronics YTC700TLAG-05-201C 7" TFT LCD panel
--

2.17.1

Best Regards,
Shengyang

#6 lore raw

Re: [PATCH v2 1/2] dt-bindings: display: panel: panel-simple: Add compatible property for waveshare 7inch touchscreen panel

Quoted 49 lines · Shengyang Chen

Hi, Conor

Thanks for comment.

Quoted 27 lines

-----Original Message-----
From: Conor Dooley <[email protected]>
Sent: 2024年1月10日 0:32
To: Shengyang Chen <[email protected]>
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Changhuang Liang <[email protected]>; Keith Zhao <[email protected]>; Jack Zhu <[email protected]>; [email protected]
Subject: Re: [PATCH v2 1/2] dt-bindings: display: panel: panel-simple: Add compatible property for waveshare 7inch touchscreen panel

Quoted 10 lines · Shengyang Chen

The waveshare 7" 800x480 panel is a clone of Raspberry Pi 7" 800x480 panel It can be drived by Raspberry Pi panel's process but it needs different timing from Raspberry Pi panel. Add compatible property for it.

---
 .../devicetree/bindings/display/panel/panel-simple.yaml         | 2 ++
 1 file changed, 2 insertions(+)
Quoted 17 lines
Quoted 9 lines

diff --git a/Documentation/devicetree/bindings/display/panel/panel-simple.yaml b/Documentation/devicetree/bindings/display/panel/panel-simple.yaml index 11422af3477e..02f6b1b2ddc9 100644
---
a/Documentation/devicetree/bindings/display/panel/panel-simple.yaml +++ b/Documentation/devicetree/bindings/display/panel/panel-simple.yam +++ l

Documentation/devicetree/bindings/display/panel/panel-simple.yaml properties: · line 339

Quoted 5 lines
Documentation/devicetree/bindings/display/panel/panel-simple.yaml +2 -0
@@ -335,6 +335,8 @@ properties:
       - vivax,tpc9150-panel
         # VXT 800x480 color TFT LCD panel
       - vxt,vl050-8048nt-c01
+        # Waveshare 7" (800x480) touchscreen LCD panel
+      - waveshare,7inch-touchscreen

Is "7inch-touchscreen" really a specific enough identifier for this device?

Quoted 2 lines

Referring to official website[1] and Neil's suggestion, maybe I should change to "7inch-touchscreen-dsi-lcd" or "waveshare,7inch-dsi-sku19885" if the next patch version is needed.

The one with the sku certainly seems more specific, if a next version is needed I would use that.

Thanks,
Conor.

#7 lore raw

PATCH v2 2/2 gpu: drm: panel: panel-simple: add new display mode for waveshare 7inch touchscreen panel

In reply to Shengyang Chen

The waveshare 7" 800x480 panel is a clone of Raspberry Pi 7" 800x480 panel It also uses a Toshiba TC358762 DSI to DPI bridge chip but it needs different timing from Raspberry Pi panel. Add new timing for it.

---
 drivers/gpu/drm/panel/panel-simple.c | 28 ++++++++++++++++++++++++++++
 1 file changed, 28 insertions(+)
drivers/gpu/drm/panel/panel-simple.c +28 -0
index 9367a4572dcf..e0896873ea33 100644
@@ -4110,6 +4110,31 @@ static const struct panel_desc vl050_8048nt_c01 = {
 	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE,
 };
 
+static const struct drm_display_mode waveshare_7inch_mode = {
+	.clock = 29700000 / 1000,
+	.hdisplay = 800,
+	.hsync_start = 800 + 90,
+	.hsync_end = 800 + 90 + 5,
+	.htotal = 800 + 90 + 5 + 5,
+	.vdisplay = 480,
+	.vsync_start = 480 + 60,
+	.vsync_end = 480 + 60 + 5,
+	.vtotal = 480 + 60 + 5 + 5,
+	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
+};
+
+static const struct panel_desc waveshare_7inch = {
+	.modes = &waveshare_7inch_mode,
+	.num_modes = 1,
+	.bpc = 8,
+	.size = {
+		.width = 154,
+		.height = 86,
+	},
+	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
+	.connector_type = DRM_MODE_CONNECTOR_DSI,
+};
+
 static const struct drm_display_mode winstar_wf35ltiacd_mode = {
 	.clock = 6410,
 	.hdisplay = 320,
@@ -4592,6 +4617,9 @@ static const struct of_device_id platform_of_match[] = {
 	}, {
 		.compatible = "vxt,vl050-8048nt-c01",
 		.data = &vl050_8048nt_c01,
+	}, {
+		.compatible = "waveshare,7inch-touchscreen",
+		.data = &waveshare_7inch,
 	}, {
 		.compatible = "winstar,wf35ltiacd",
 		.data = &winstar_wf35ltiacd,
Signature · 1 line
2.17.1
Reviewed-by on v2 2/2
#8 lore raw

Re: [PATCH v2 2/2] gpu: drm: panel: panel-simple: add new display mode for waveshare 7inch touchscreen panel

Quoted 3 lines · Shengyang Chen

The waveshare 7" 800x480 panel is a clone of Raspberry Pi 7" 800x480 panel It also uses a Toshiba TC358762 DSI to DPI bridge chip but it needs different timing from Raspberry Pi panel. Add new timing for it.

Hi Shengyang,

The patch itself LGTM, but in case you have to put out a new revision, can you please use the "drm/panel: <driver name>:" prefix format that other drm/panel commits use?

Thanks,

Jessica Zhang

Quoted 56 lines
---
  drivers/gpu/drm/panel/panel-simple.c | 28 ++++++++++++++++++++++++++++
  1 file changed, 28 insertions(+)
drivers/gpu/drm/panel/panel-simple.c +28 -0
index 9367a4572dcf..e0896873ea33 100644
@@ -4110,6 +4110,31 @@ static const struct panel_desc vl050_8048nt_c01 = {
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH | DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE,
  };
 
+static const struct drm_display_mode waveshare_7inch_mode = {
+	.clock = 29700000 / 1000,
+	.hdisplay = 800,
+	.hsync_start = 800 + 90,
+	.hsync_end = 800 + 90 + 5,
+	.htotal = 800 + 90 + 5 + 5,
+	.vdisplay = 480,
+	.vsync_start = 480 + 60,
+	.vsync_end = 480 + 60 + 5,
+	.vtotal = 480 + 60 + 5 + 5,
+	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC,
+};
+
+static const struct panel_desc waveshare_7inch = {
+	.modes = &waveshare_7inch_mode,
+	.num_modes = 1,
+	.bpc = 8,
+	.size = {
+		.width = 154,
+		.height = 86,
+	},
+	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
+	.connector_type = DRM_MODE_CONNECTOR_DSI,
+};
+
  static const struct drm_display_mode winstar_wf35ltiacd_mode = {
  	.clock = 6410,
  	.hdisplay = 320,
@@ -4592,6 +4617,9 @@ static const struct of_device_id platform_of_match[] = {
  	}, {
  		.compatible = "vxt,vl050-8048nt-c01",
  		.data = &vl050_8048nt_c01,
+	}, {
+		.compatible = "waveshare,7inch-touchscreen",
+		.data = &waveshare_7inch,
  	}, {
  		.compatible = "winstar,wf35ltiacd",
  		.data = &winstar_wf35ltiacd,
Signature · 1 line
2.17.1
#9 lore raw

RE: [PATCH v2 2/2] gpu: drm: panel: panel-simple: add new display mode for waveshare 7inch touchscreen panel

Hi, Jessica

Thanks for your comment and review

Quoted 23 lines

-----Original Message-----
From: Jessica Zhang <[email protected]>
Sent: 2024年1月10日 2:26
To: Shengyang Chen <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Changhuang Liang <[email protected]>; Keith Zhao <[email protected]>; Jack Zhu <[email protected]>; [email protected]
Subject: Re: [PATCH v2 2/2] gpu: drm: panel: panel-simple: add new display mode for waveshare 7inch touchscreen panel

Quoted 3 lines · Shengyang Chen

The waveshare 7" 800x480 panel is a clone of Raspberry Pi 7" 800x480 panel It also uses a Toshiba TC358762 DSI to DPI bridge chip but it needs different timing from Raspberry Pi panel. Add new timing for it.

Quoted 6 lines

Hi Shengyang,

The patch itself LGTM, but in case you have to put out a new revision, can you please use the "drm/panel: <driver name>:" prefix format that other drm/panel commits use?

Thanks for your suggestion. The prefix format will be used if we have next version. btw, referring to the suggestions, we are going to try other timing from panel-simple in our platform. Maybe we are not necessary to submit new version. Thanks a lot

Quoted 53 lines

Thanks,

Jessica Zhang

Quoted 5 lines
---
  drivers/gpu/drm/panel/panel-simple.c | 28

++++++++++++++++++++++++++++

drivers/gpu/drm/panel/panel-simple.c static const struct panel_desc vl050_8048nt_c01

Quoted 8 lines
  1 file changed, 28 insertions(+)
drivers/gpu/drm/panel/panel-simple.c +0 -0
index 9367a4572dcf..e0896873ea33 100644
@@ -4110,6 +4110,31 @@ static const struct panel_desc vl050_8048nt_c01

= {

drivers/gpu/drm/panel/panel-simple.c static const struct panel_desc vl050_8048nt_c01 · line 4110

Quoted 1 line
drivers/gpu/drm/panel/panel-simple.c +0 -0
  	.bus_flags = DRM_BUS_FLAG_DE_HIGH |

DRM_BUS_FLAG_PIXDATA_SAMPLE_NEGEDGE,

drivers/gpu/drm/panel/panel-simple.c static const struct of_device_id

Quoted 29 lines
drivers/gpu/drm/panel/panel-simple.c +23 -0
  };
 
+static const struct drm_display_mode waveshare_7inch_mode = {
+	.clock = 29700000 / 1000,
+	.hdisplay = 800,
+	.hsync_start = 800 + 90,
+	.hsync_end = 800 + 90 + 5,
+	.htotal = 800 + 90 + 5 + 5,
+	.vdisplay = 480,
+	.vsync_start = 480 + 60,
+	.vsync_end = 480 + 60 + 5,
+	.vtotal = 480 + 60 + 5 + 5,
+	.flags = DRM_MODE_FLAG_NVSYNC | DRM_MODE_FLAG_NHSYNC, };
+
+static const struct panel_desc waveshare_7inch = {
+	.modes = &waveshare_7inch_mode,
+	.num_modes = 1,
+	.bpc = 8,
+	.size = {
+		.width = 154,
+		.height = 86,
+	},
+	.bus_format = MEDIA_BUS_FMT_RGB888_1X24,
+	.connector_type = DRM_MODE_CONNECTOR_DSI, };
+
  static const struct drm_display_mode winstar_wf35ltiacd_mode = {
  	.clock = 6410,
  	.hdisplay = 320,
@@ -4592,6 +4617,9 @@ static const struct of_device_id

platform_of_match[] = {

Quoted 12 lines
Quoted 10 lines
drivers/gpu/drm/panel/panel-simple.c +3 -1
  	}, {
  		.compatible = "vxt,vl050-8048nt-c01",
  		.data = &vl050_8048nt_c01,
+	}, {
+		.compatible = "waveshare,7inch-touchscreen",
+		.data = &waveshare_7inch,
  	}, {
  		.compatible = "winstar,wf35ltiacd",
  		.data = &winstar_wf35ltiacd,
--
Quoted 2 lines

2.17.1

thanks

Best Regards,
Shengyang

#10 lore raw
In reply to Shengyang Chen

Hi,

Quoted 2 lines · Shengyang Chen

This patchset adds waveshare 7inch touchscreen panel support for the StarFive JH7110 SoC.

Could you precise which SKU you're referring to ? is it 19885 => https://www.waveshare.com/7inch-dsi-lcd.htm ?

Are you sure it requires different timings from the RPi one ? In the Waveshare
wiki it explicitly uses the rpi setup (vc4-kms-dsi-7inch) to drive it: https://www.waveshare.com/wiki/7inch_DSI_LCD

Neil

Quoted 27 lines

changes since v1:
- Rebased on tag v6.7.

patch 1:
- Gave up original changing.
- Changed the commit message.
- Add compatible in panel-simple.yaml

patch 2:
- Gave up original changing.
- Changed the commit message.
- Add new mode for the panel in panel-simple.c

v1: https://patchwork.kernel.org/project/dri-devel/cover/[email protected]/

Shengyang Chen (2):
dt-bindings: display: panel: panel-simple: Add compatible property for
waveshare 7inch touchscreen panel
gpu: drm: panel: panel-simple: add new display mode for waveshare
7inch touchscreen panel

  .../bindings/display/panel/panel-simple.yaml  |  2 ++
  drivers/gpu/drm/panel/panel-simple.c          | 28 +++++++++++++++++++
  2 files changed, 30 insertions(+)
#11 lore raw

Hi Neil,

Am 09.01.24 um 12:19 schrieb [email protected]:

Quoted 6 lines

Hi,

Quoted 2 lines · Shengyang Chen

This patchset adds waveshare 7inch touchscreen panel support for the StarFive JH7110 SoC.

Quoted 7 lines

Could you precise which SKU you're referring to ? is it 19885 =>
https://www.waveshare.com/7inch-dsi-lcd.htm ?

Are you sure it requires different timings from the RPi one ? In the Waveshare
wiki it explicitly uses the rpi setup (vc4-kms-dsi-7inch) to drive it:
https://www.waveshare.com/wiki/7inch_DSI_LCD

i don't have an anser for your question, but the Raspberry Pi vendor tree use different timings than the Mainline kernel:

https://github.com/raspberrypi/linux/commit/222b9baa97cc4c880d040a8c6a5da80d6a42c8e8

Additionally the arm64/boot/dts/freescale/imx8mm-venice-gw72xx-0x-rpidsi.dtso suggests that it uses the Raspberry Pi 7inch, but uses the timings of powertip,ph800480t013-idf02 from panel-simple.

Maybe Shengyang could test these timings with the Waveshare touch. At the end this rely on a proper implementation on the underlying drivers.

Sorry, for adding more confusion.

Regards

Quoted 33 lines

Neil

Quoted 29 lines

changes since v1:
- Rebased on tag v6.7.

patch 1:
- Gave up original changing.
- Changed the commit message.
- Add compatible in panel-simple.yaml

patch 2:
- Gave up original changing.
- Changed the commit message.
- Add new mode for the panel in panel-simple.c

v1:
https://patchwork.kernel.org/project/dri-devel/cover/[email protected]/

Shengyang Chen (2):
   dt-bindings: display: panel: panel-simple: Add compatible property for
     waveshare 7inch touchscreen panel
   gpu: drm: panel: panel-simple: add new display mode for waveshare 7inch touchscreen panel

  .../bindings/display/panel/panel-simple.yaml  |  2 ++ drivers/gpu/drm/panel/panel-simple.c          | 28 +++++++++++++++++++

  2 files changed, 30 insertions(+)
#12 lore raw

Hi, Stefan

Thanks for your comment and suggestion.

Quoted 43 lines

-----Original Message-----
From: Stefan Wahren <[email protected]>
Sent: 2024年1月10日 1:22
To: [email protected]; Shengyang Chen <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Changhuang Liang <[email protected]>; Keith Zhao <[email protected]>; Jack Zhu <[email protected]>; [email protected]
Subject: Re: [PATCH v2 0/2] Add waveshare 7inch touchscreen panel support

Hi Neil,

Am 09.01.24 um 12:19 schrieb [email protected]:

Quoted 6 lines

Hi,

Quoted 2 lines · Shengyang Chen

This patchset adds waveshare 7inch touchscreen panel support for the StarFive JH7110 SoC.

Quoted 7 lines

Could you precise which SKU you're referring to ? is it 19885 =>
https://www.waveshare.com/7inch-dsi-lcd.htm ?

Are you sure it requires different timings from the RPi one ? In the Waveshare wiki it explicitly uses the rpi setup (vc4-kms-dsi-7inch) to drive it:
https://www.waveshare.com/wiki/7inch_DSI_LCD

i don't have an anser for your question, but the Raspberry Pi vendor tree use different timings than the Mainline kernel:

https://github.com/raspberrypi/linux/commit/222b9baa97cc4c880d040a8c6a5
da80d6a42c8e8

Additionally the arm64/boot/dts/freescale/imx8mm-venice-gw72xx-0x-rpidsi.dtso suggests that it uses the Raspberry Pi 7inch, but uses the timings of powertip,ph800480t013-idf02 from panel-simple.

Quoted 5 lines

Maybe Shengyang could test these timings with the Waveshare touch. At the end this rely on a proper implementation on the underlying drivers.

Sorry, for adding more confusion.

Thanks for suggestion.
We will try other timing from panel-simple.
Maybe we are not going to commit new panel timing patch if we find useful timing from panel-simple to drive the panel.

Quoted 36 lines

Regards

Quoted 35 lines

Neil

Quoted 31 lines

changes since v1:
- Rebased on tag v6.7.

patch 1:
- Gave up original changing.
- Changed the commit message.
- Add compatible in panel-simple.yaml

patch 2:
- Gave up original changing.
- Changed the commit message.
- Add new mode for the panel in panel-simple.c

v1:
https://patchwork.kernel.org/project/dri-devel/cover/20231124104451.4
[email protected]/

Shengyang Chen (2):
   dt-bindings: display: panel: panel-simple: Add compatible property for
     waveshare 7inch touchscreen panel
   gpu: drm: panel: panel-simple: add new display mode for waveshare 7inch touchscreen panel

  .../bindings/display/panel/panel-simple.yaml  |  2 ++ drivers/gpu/drm/panel/panel-simple.c          | 28
+++++++++++++++++++

  2 files changed, 30 insertions(+)

thanks

Best Regards,
Shengyang

#13 lore raw
In reply to [email protected]

Hi

Quoted 11 lines · On Tue, 9 Jan 2024 at 11:19, <[email protected]> wrote:

Hi,

Quoted 2 lines · Shengyang Chen

This patchset adds waveshare 7inch touchscreen panel support for the StarFive JH7110 SoC.

Could you precise which SKU you're referring to ? is it 19885 => https://www.waveshare.com/7inch-dsi-lcd.htm ?

Are you sure it requires different timings from the RPi one ? In the Waveshare
wiki it explicitly uses the rpi setup (vc4-kms-dsi-7inch) to drive it: https://www.waveshare.com/wiki/7inch_DSI_LCD

I raise the same question.

Keith Zhao earlier submitted effectively the same set of patches [1] and the response for the updated timing was:
<quote>
My platform dphy tx hardware has certain limitations. Only supports integer multiples of 10M bitrate:
such as 160M ,170M, 180M,190M,...1G(max)

as common dphy bitrate = pixclock*bpp/lanes. This value cannot match successfully in most cases.

so in order to match bitrate , I choose a bitrate value around pixclock*bpp/lanes,
Prevent overflow and underflow by fine-tuning the timing parameters:-( that will make the new timming value.
</quote>

I then suggested mode_fixup should be used in the DSI host driver, and Keith acknowledged that.

Is this new timing still because of the DSI host requirement?

Dave

[1] https://lists.freedesktop.org/archives/dri-devel/2023-December/434150.html

Quoted 30 lines

Neil

Quoted 27 lines

changes since v1:
- Rebased on tag v6.7.

patch 1:
- Gave up original changing.
- Changed the commit message.
- Add compatible in panel-simple.yaml

patch 2:
- Gave up original changing.
- Changed the commit message.
- Add new mode for the panel in panel-simple.c

v1: https://patchwork.kernel.org/project/dri-devel/cover/[email protected]/

Shengyang Chen (2):
dt-bindings: display: panel: panel-simple: Add compatible property for
waveshare 7inch touchscreen panel
gpu: drm: panel: panel-simple: add new display mode for waveshare
7inch touchscreen panel

  .../bindings/display/panel/panel-simple.yaml  |  2 ++
  drivers/gpu/drm/panel/panel-simple.c          | 28 +++++++++++++++++++
  2 files changed, 30 insertions(+)
#14 lore raw

Hi, Dave

Thanks for your comment

Quoted 50 lines

-----Original Message-----
From: Dave Stevenson <[email protected]>
Sent: 2024年1月10日 1:29
To: [email protected]
Cc: Shengyang Chen <[email protected]>; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Changhuang Liang <[email protected]>; Keith Zhao <[email protected]>; Jack Zhu <[email protected]>; [email protected]
Subject: Re: [PATCH v2 0/2] Add waveshare 7inch touchscreen panel support

Hi

Quoted 8 lines · On Tue, 9 Jan 2024 at 11:19, <[email protected]> wrote:

Hi,

Quoted 2 lines · Shengyang Chen

This patchset adds waveshare 7inch touchscreen panel support for the StarFive JH7110 SoC.

Could you precise which SKU you're referring to ? is it 19885 =>

https://www.waveshare.com/7inch-dsi-lcd.htm ?

Quoted 4 lines

Are you sure it requires different timings from the RPi one ? In the Waveshare wiki it explicitly uses the rpi setup (vc4-kms-dsi-7inch) to drive it: https://www.waveshare.com/wiki/7inch_DSI_LCD

I raise the same question.

Keith Zhao earlier submitted effectively the same set of patches [1] and the response for the updated timing was:
<quote>
My platform dphy tx hardware has certain limitations.
Only supports integer multiples of 10M bitrate:
such as 160M ,170M, 180M,190M,...1G(max)

as common dphy bitrate = pixclock*bpp/lanes. This value cannot match successfully in most cases.

so in order to match bitrate , I choose a bitrate value around pixclock*bpp/lanes, Prevent overflow and underflow by fine-tuning the timing parameters:-( that will make the new timming value.
</quote>

Quoted 5 lines

I then suggested mode_fixup should be used in the DSI host driver, and Keith acknowledged that.

Is this new timing still because of the DSI host requirement?

Actually, the mode fixup method is referred and used in DSI's new patch
https://patchwork.kernel.org/project/dri-devel/patch/[email protected]/
you can check it in cdns_dsi_jh7110_update()
This code is being reviewed and may need to be optimized later.

And the timing in this panel patch is tested and verified but we did not try other timing. Sorry about that. As Stefan suggested, we should try other timing from panel-simple for example "powertip,ph800480t013-idf02".

If the other timing from panel-simple can be used, maybe it is not necessary for us to submit panel timing patch.

Quoted 32 lines

Dave

[1]
https://lists.freedesktop.org/archives/dri-devel/2023-December/434150.html

Quoted 27 lines

Neil

Quoted 25 lines

changes since v1:
- Rebased on tag v6.7.

patch 1:
- Gave up original changing.
- Changed the commit message.
- Add compatible in panel-simple.yaml

patch 2:
- Gave up original changing.
- Changed the commit message.
- Add new mode for the panel in panel-simple.c

v1:
https://patchwork.kernel.org/project/dri-devel/cover/20231124104451.
[email protected]/

Shengyang Chen (2):
dt-bindings: display: panel: panel-simple: Add compatible property for
waveshare 7inch touchscreen panel
gpu: drm: panel: panel-simple: add new display mode for waveshare
7inch touchscreen panel

Quoted 6 lines
Quoted 2 lines
Quoted 2 lines
  .../bindings/display/panel/panel-simple.yaml  |  2 ++
  drivers/gpu/drm/panel/panel-simple.c          | 28

+++++++++++++++++++

Quoted 3 lines
Quoted 2 lines
  2 files changed, 30 insertions(+)

Best Regards,
Shengyang

#15 lore raw
In reply to [email protected]

Hi, Neil

Thanks for your comment.

Quoted 15 lines

-----Original Message-----
From: [email protected] <[email protected]>
Sent: 2024年1月9日 19:19
To: Shengyang Chen <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Changhuang Liang <[email protected]>; Keith Zhao <[email protected]>; Jack Zhu <[email protected]>; [email protected]
Subject: Re: [PATCH v2 0/2] Add waveshare 7inch touchscreen panel support

Quoted 9 lines

Hi,

Quoted 2 lines · Shengyang Chen

This patchset adds waveshare 7inch touchscreen panel support for the StarFive JH7110 SoC.

Could you precise which SKU you're referring to ? is it 19885 =>
https://www.waveshare.com/7inch-dsi-lcd.htm ?

yes, it is
sorry for confusing you.

Quoted 4 lines

Are you sure it requires different timings from the RPi one ? In the Waveshare wiki it explicitly uses the rpi setup (vc4-kms-dsi-7inch) to drive it:
https://www.waveshare.com/wiki/7inch_DSI_LCD

Referring to Keith's answer
https://lists.freedesktop.org/archives/dri-devel/2023-December/434200.html
the panel timing value is generated to fit phy's bitrate and prevent overflow and underflow.

Referring to the suggestion, we may try other timing from panel-simple to drive the panel.

Quoted 27 lines

Neil

Quoted 25 lines

changes since v1:
- Rebased on tag v6.7.

patch 1:
- Gave up original changing.
- Changed the commit message.
- Add compatible in panel-simple.yaml

patch 2:
- Gave up original changing.
- Changed the commit message.
- Add new mode for the panel in panel-simple.c

v1:
https://patchwork.kernel.org/project/dri-devel/cover/20231124104451.44
[email protected]/

Shengyang Chen (2):
dt-bindings: display: panel: panel-simple: Add compatible property for
waveshare 7inch touchscreen panel
gpu: drm: panel: panel-simple: add new display mode for waveshare
7inch touchscreen panel

Quoted 5 lines
Quoted 2 lines
  .../bindings/display/panel/panel-simple.yaml  |  2 ++
  drivers/gpu/drm/panel/panel-simple.c          | 28

+++++++++++++++++++

Quoted 2 lines
  2 files changed, 30 insertions(+)

Best Regards,
Shengyang

#16 lore raw
Quoted 37 lines · Shengyang Chen

Hi, Neil

Thanks for your comment.

Quoted 15 lines

-----Original Message-----
From: [email protected] <[email protected]>
Sent: 2024年1月9日 19:19
To: Shengyang Chen <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Changhuang Liang <[email protected]>; Keith Zhao <[email protected]>; Jack Zhu <[email protected]>; [email protected]
Subject: Re: [PATCH v2 0/2] Add waveshare 7inch touchscreen panel support

Quoted 9 lines

Hi,

Quoted 2 lines · Shengyang Chen

This patchset adds waveshare 7inch touchscreen panel support for the StarFive JH7110 SoC.

Could you precise which SKU you're referring to ? is it 19885 =>
https://www.waveshare.com/7inch-dsi-lcd.htm ?

yes, it is
sorry for confusing you.

Quoted 4 lines

Are you sure it requires different timings from the RPi one ? In the Waveshare wiki it explicitly uses the rpi setup (vc4-kms-dsi-7inch) to drive it:
https://www.waveshare.com/wiki/7inch_DSI_LCD

Quoted 5 lines

Referring to Keith's answer
https://lists.freedesktop.org/archives/dri-devel/2023-December/434200.html
the panel timing value is generated to fit phy's bitrate and prevent overflow and underflow.

Referring to the suggestion, we may try other timing from panel-simple to drive the panel.

Please implement a mode_fixup in your DSI host driver instead.

Neil

Quoted 37 lines
Quoted 28 lines

Neil

Quoted 25 lines

changes since v1:
- Rebased on tag v6.7.

patch 1:
- Gave up original changing.
- Changed the commit message.
- Add compatible in panel-simple.yaml

patch 2:
- Gave up original changing.
- Changed the commit message.
- Add new mode for the panel in panel-simple.c

v1:
https://patchwork.kernel.org/project/dri-devel/cover/20231124104451.44
[email protected]/

Shengyang Chen (2):
dt-bindings: display: panel: panel-simple: Add compatible property for
waveshare 7inch touchscreen panel
gpu: drm: panel: panel-simple: add new display mode for waveshare
7inch touchscreen panel

Quoted 5 lines
Quoted 2 lines
   .../bindings/display/panel/panel-simple.yaml  |  2 ++
   drivers/gpu/drm/panel/panel-simple.c          | 28

+++++++++++++++++++

Quoted 2 lines
   2 files changed, 30 insertions(+)

Best Regards,
Shengyang

#17 lore raw

Hi, Neil

Quoted 60 lines

-----Original Message-----
From: [email protected] <[email protected]>
Sent: 2024年1月16日 17:34
To: Shengyang Chen <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Changhuang Liang <[email protected]>; Keith Zhao <[email protected]>; Jack Zhu <[email protected]>; [email protected]
Subject: Re: [PATCH v2 0/2] Add waveshare 7inch touchscreen panel support

Quoted 44 lines · Shengyang Chen

Hi, Neil

Thanks for your comment.

Quoted 17 lines

-----Original Message-----
From: [email protected] <[email protected]>
Sent: 2024年1月9日 19:19
To: Shengyang Chen <[email protected]>; [email protected]; [email protected]
Cc: [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; [email protected]; Changhuang Liang <[email protected]>; Keith Zhao <[email protected]>; Jack Zhu <[email protected]>; [email protected]
Subject: Re: [PATCH v2 0/2] Add waveshare 7inch touchscreen panel support

Quoted 9 lines

Hi,

Quoted 2 lines · Shengyang Chen

This patchset adds waveshare 7inch touchscreen panel support for the StarFive JH7110 SoC.

Could you precise which SKU you're referring to ? is it 19885 =>
https://www.waveshare.com/7inch-dsi-lcd.htm ?

yes, it is
sorry for confusing you.

Quoted 4 lines

Are you sure it requires different timings from the RPi one ? In the Waveshare wiki it explicitly uses the rpi setup (vc4-kms-dsi-7inch) to drive it:
https://www.waveshare.com/wiki/7inch_DSI_LCD

Referring to Keith's answer
https://lists.freedesktop.org/archives/dri-devel/2023-December/434200.
html the panel timing value is generated to fit phy's bitrate and prevent overflow and underflow.

Quoted 5 lines
Quoted 1 line

Referring to the suggestion, we may try other timing from panel-simple to

drive the panel.

Please implement a mode_fixup in your DSI host driver instead.

The mode fixup method is already used. As reference:
https://patchwork.kernel.org/project/dri-devel/patch/[email protected]/
you can check it in cdns_dsi_jh7110_update().
This code is being reviewed and may need to be optimized later.

Quoted 39 lines

Neil

Quoted 37 lines
Quoted 28 lines

Neil

Quoted 25 lines

changes since v1:
- Rebased on tag v6.7.

patch 1:
- Gave up original changing.
- Changed the commit message.
- Add compatible in panel-simple.yaml

patch 2:
- Gave up original changing.
- Changed the commit message.
- Add new mode for the panel in panel-simple.c

v1:
https://patchwork.kernel.org/project/dri-devel/cover/20231124104451.
44 [email protected]/

Shengyang Chen (2):
dt-bindings: display: panel: panel-simple: Add compatible property for
waveshare 7inch touchscreen panel
gpu: drm: panel: panel-simple: add new display mode for waveshare
7inch touchscreen panel

Quoted 5 lines
Quoted 2 lines
   .../bindings/display/panel/panel-simple.yaml  |  2 ++
   drivers/gpu/drm/panel/panel-simple.c          | 28

+++++++++++++++++++

Quoted 2 lines
   2 files changed, 30 insertions(+)

Best Regards,
Shengyang

Best Regards,
Shengyang