linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH v4 0/2] Reduce lcm_reset to DSI LP11 send cmd time
@ 2023-05-15  9:49 Shuijing Li
  2023-05-15  9:49 ` [PATCH v4 1/2] drm/panel: boe-tv101wum-nl6: Remove extra delay Shuijing Li
                   ` (3 more replies)
  0 siblings, 4 replies; 5+ messages in thread
From: Shuijing Li @ 2023-05-15  9:49 UTC (permalink / raw)
  To: neil.armstrong, sam, airlied, daniel, matthias.bgg,
	angelogioacchino.delregno, dri-devel
  Cc: linux-kernel, linux-arm-kernel, linux-mediatek,
	Project_Global_Chrome_Upstream_Group, jitao.shi, Shuijing Li

The panel spec stipulates that after lcm_reset is pulled high, cmd
should be sent to initialize the panel. Within the allowable range of
the DSI spec, this time needs to be reduced to avoid panel exceptions.

Base on the branch of linus/master v6.3.

Change since v3:
1. Rebase.

Change since v2:
1. Remove the applied patch.
2. Change the commit title and the description.

Change since v1:
1. Added fine-tuning panel power sequence modification.

Shuijing Li (2):
  drm/panel: boe-tv101wum-nl6: Remove extra delay
  drm/panel: boe-tv101wum-nl6: Fine tune the panel power sequence

 drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)

-- 
2.40.1


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

* [PATCH v4 1/2] drm/panel: boe-tv101wum-nl6: Remove extra delay
  2023-05-15  9:49 [PATCH v4 0/2] Reduce lcm_reset to DSI LP11 send cmd time Shuijing Li
@ 2023-05-15  9:49 ` Shuijing Li
  2023-05-15  9:49 ` [PATCH v4 2/2] drm/panel: boe-tv101wum-nl6: Fine tune the panel power sequence Shuijing Li
                   ` (2 subsequent siblings)
  3 siblings, 0 replies; 5+ messages in thread
From: Shuijing Li @ 2023-05-15  9:49 UTC (permalink / raw)
  To: neil.armstrong, sam, airlied, daniel, matthias.bgg,
	angelogioacchino.delregno, dri-devel
  Cc: linux-kernel, linux-arm-kernel, linux-mediatek,
	Project_Global_Chrome_Upstream_Group, jitao.shi, Shuijing Li,
	Xinlei Lee

Reduce the delay after LCM reset by removing an extra delay in the
initialization commands array. The required delay of at least 6ms after
reset is guaranteed by boe_panel_prepare().

Signed-off-by: Shuijing Li <shuijing.li@mediatek.com>
Signed-off-by: Xinlei Lee <xinlei.lee@mediatek.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
---
 drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c | 1 -
 1 file changed, 1 deletion(-)

diff --git a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c
index 783234ae0f57..a5652d38acda 100644
--- a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c
+++ b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c
@@ -780,7 +780,6 @@ static const struct panel_init_cmd inx_hj110iz_init_cmd[] = {
 };
 
 static const struct panel_init_cmd boe_init_cmd[] = {
-	_INIT_DELAY_CMD(24),
 	_INIT_DCS_CMD(0xB0, 0x05),
 	_INIT_DCS_CMD(0xB1, 0xE5),
 	_INIT_DCS_CMD(0xB3, 0x52),
-- 
2.40.1


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

* [PATCH v4 2/2] drm/panel: boe-tv101wum-nl6: Fine tune the panel power sequence
  2023-05-15  9:49 [PATCH v4 0/2] Reduce lcm_reset to DSI LP11 send cmd time Shuijing Li
  2023-05-15  9:49 ` [PATCH v4 1/2] drm/panel: boe-tv101wum-nl6: Remove extra delay Shuijing Li
@ 2023-05-15  9:49 ` Shuijing Li
  2023-05-15 12:52 ` [PATCH v4 0/2] Reduce lcm_reset to DSI LP11 send cmd time Neil Armstrong
  2023-05-16  8:25 ` Neil Armstrong
  3 siblings, 0 replies; 5+ messages in thread
From: Shuijing Li @ 2023-05-15  9:49 UTC (permalink / raw)
  To: neil.armstrong, sam, airlied, daniel, matthias.bgg,
	angelogioacchino.delregno, dri-devel
  Cc: linux-kernel, linux-arm-kernel, linux-mediatek,
	Project_Global_Chrome_Upstream_Group, jitao.shi, Shuijing Li,
	Xinlei Lee

For "boe,tv105wum-nw0" this special panel, it is stipulated in
the panel spec that MIPI needs to keep the LP11 state before
the lcm_reset pin is pulled high.

Signed-off-by: Shuijing Li <shuijing.li@mediatek.com>
Signed-off-by: Xinlei Lee <xinlei.lee@mediatek.com>
Reviewed-by: AngeloGioacchino Del Regno <angelogioacchino.delregno@collabora.com>
---
 drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c | 6 ++++++
 1 file changed, 6 insertions(+)

diff --git a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c
index a5652d38acda..64e462f49c60 100644
--- a/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c
+++ b/drivers/gpu/drm/panel/panel-boe-tv101wum-nl6.c
@@ -36,6 +36,7 @@ struct panel_desc {
 	const struct panel_init_cmd *init_cmds;
 	unsigned int lanes;
 	bool discharge_on_disable;
+	bool lp11_before_reset;
 };
 
 struct boe_panel {
@@ -1365,6 +1366,10 @@ static int boe_panel_prepare(struct drm_panel *panel)
 
 	usleep_range(10000, 11000);
 
+	if (boe->desc->lp11_before_reset) {
+		mipi_dsi_dcs_nop(boe->dsi);
+		usleep_range(1000, 2000);
+	}
 	gpiod_set_value(boe->enable_gpio, 1);
 	usleep_range(1000, 2000);
 	gpiod_set_value(boe->enable_gpio, 0);
@@ -1591,6 +1596,7 @@ static const struct panel_desc boe_tv105wum_nw0_desc = {
 	.mode_flags = MIPI_DSI_MODE_VIDEO | MIPI_DSI_MODE_VIDEO_SYNC_PULSE |
 		      MIPI_DSI_MODE_LPM,
 	.init_cmds = boe_init_cmd,
+	.lp11_before_reset = true,
 };
 
 static const struct drm_display_mode starry_qfh032011_53g_default_mode = {
-- 
2.40.1


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

* Re: [PATCH v4 0/2] Reduce lcm_reset to DSI LP11 send cmd time
  2023-05-15  9:49 [PATCH v4 0/2] Reduce lcm_reset to DSI LP11 send cmd time Shuijing Li
  2023-05-15  9:49 ` [PATCH v4 1/2] drm/panel: boe-tv101wum-nl6: Remove extra delay Shuijing Li
  2023-05-15  9:49 ` [PATCH v4 2/2] drm/panel: boe-tv101wum-nl6: Fine tune the panel power sequence Shuijing Li
@ 2023-05-15 12:52 ` Neil Armstrong
  2023-05-16  8:25 ` Neil Armstrong
  3 siblings, 0 replies; 5+ messages in thread
From: Neil Armstrong @ 2023-05-15 12:52 UTC (permalink / raw)
  To: sam, airlied, daniel, matthias.bgg, angelogioacchino.delregno,
	dri-devel, Shuijing Li
  Cc: linux-kernel, linux-arm-kernel, linux-mediatek,
	Project_Global_Chrome_Upstream_Group, jitao.shi

Hi,

On Mon, 15 May 2023 17:49:53 +0800, Shuijing Li wrote:
> The panel spec stipulates that after lcm_reset is pulled high, cmd
> should be sent to initialize the panel. Within the allowable range of
> the DSI spec, this time needs to be reduced to avoid panel exceptions.
> 
> Base on the branch of linus/master v6.3.
> 
> Change since v3:
> 1. Rebase.
> 
> [...]

Thanks, Applied to https://anongit.freedesktop.org/git/drm/drm-misc.git (drm-misc-next)

[1/2] drm/panel: boe-tv101wum-nl6: Remove extra delay
      https://cgit.freedesktop.org/drm/drm-misc/commit/?id=fe7f4e8d496552f880d7368b482d2ccac33780b7
[2/2] drm/panel: boe-tv101wum-nl6: Fine tune the panel power sequence
      https://cgit.freedesktop.org/drm/drm-misc/commit/?id=812562b8d881ce6d33fed8052b3a10b718430fb5

-- 
Neil


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

* Re: [PATCH v4 0/2] Reduce lcm_reset to DSI LP11 send cmd time
  2023-05-15  9:49 [PATCH v4 0/2] Reduce lcm_reset to DSI LP11 send cmd time Shuijing Li
                   ` (2 preceding siblings ...)
  2023-05-15 12:52 ` [PATCH v4 0/2] Reduce lcm_reset to DSI LP11 send cmd time Neil Armstrong
@ 2023-05-16  8:25 ` Neil Armstrong
  3 siblings, 0 replies; 5+ messages in thread
From: Neil Armstrong @ 2023-05-16  8:25 UTC (permalink / raw)
  To: sam, airlied, daniel, matthias.bgg, angelogioacchino.delregno,
	dri-devel, Shuijing Li
  Cc: linux-kernel, linux-arm-kernel, linux-mediatek,
	Project_Global_Chrome_Upstream_Group, jitao.shi

Hi,

On Mon, 15 May 2023 17:49:53 +0800, Shuijing Li wrote:
> The panel spec stipulates that after lcm_reset is pulled high, cmd
> should be sent to initialize the panel. Within the allowable range of
> the DSI spec, this time needs to be reduced to avoid panel exceptions.
> 
> Base on the branch of linus/master v6.3.
> 
> Change since v3:
> 1. Rebase.
> 
> [...]

Thanks, Applied to https://anongit.freedesktop.org/git/drm/drm-misc.git (drm-misc-next)

[1/2] drm/panel: boe-tv101wum-nl6: Remove extra delay
      https://cgit.freedesktop.org/drm/drm-misc/commit/?id=fe7f4e8d496552f880d7368b482d2ccac33780b7
[2/2] drm/panel: boe-tv101wum-nl6: Fine tune the panel power sequence
      https://cgit.freedesktop.org/drm/drm-misc/commit/?id=812562b8d881ce6d33fed8052b3a10b718430fb5

-- 
Neil


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

end of thread, other threads:[~2023-05-16  8:25 UTC | newest]

Thread overview: 5+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2023-05-15  9:49 [PATCH v4 0/2] Reduce lcm_reset to DSI LP11 send cmd time Shuijing Li
2023-05-15  9:49 ` [PATCH v4 1/2] drm/panel: boe-tv101wum-nl6: Remove extra delay Shuijing Li
2023-05-15  9:49 ` [PATCH v4 2/2] drm/panel: boe-tv101wum-nl6: Fine tune the panel power sequence Shuijing Li
2023-05-15 12:52 ` [PATCH v4 0/2] Reduce lcm_reset to DSI LP11 send cmd time Neil Armstrong
2023-05-16  8:25 ` Neil Armstrong

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).