* [PATCH] drm/bridge/synopsys: dsi: allow sending longer LP commands
@ 2020-07-01 14:31 ` Yannick Fertre
0 siblings, 0 replies; 9+ messages in thread
From: Yannick Fertre @ 2020-07-01 14:31 UTC (permalink / raw)
To: Yannick Fertre, Philippe Cornu, Benjamin Gaignard, David Airlie,
Daniel Vetter, Maxime Coquelin, Alexandre Torgue, dri-devel,
linux-stm32, linux-arm-kernel, linux-kernel
From: Antonio Borneo <antonio.borneo@st.com>
Current code does not properly computes the max length of LP
commands that can be send during H or V sync, and rely on static
values.
Limiting the max LP length to 4 byte during the V-sync is overly
conservative.
Relax the limit and allows longer LP commands (16 bytes) to be
sent during V-sync.
Signed-off-by: Antonio Borneo <antonio.borneo@st.com>
---
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
index d580b2aa4ce9..1a24ea648ef8 100644
--- a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
+++ b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
@@ -360,6 +360,15 @@ static void dw_mipi_message_config(struct dw_mipi_dsi *dsi,
bool lpm = msg->flags & MIPI_DSI_MSG_USE_LPM;
u32 val = 0;
+ /*
+ * TODO dw drv improvements
+ * largest packet sizes during hfp or during vsa/vpb/vfp
+ * should be computed according to byte lane, lane number and only
+ * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
+ */
+ dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(16)
+ | INVACT_LPCMD_TIME(4));
+
if (msg->flags & MIPI_DSI_MSG_REQ_ACK)
val |= ACK_RQST_EN;
if (lpm)
@@ -611,14 +620,6 @@ static void dw_mipi_dsi_dpi_config(struct dw_mipi_dsi *dsi,
dsi_write(dsi, DSI_DPI_VCID, DPI_VCID(dsi->channel));
dsi_write(dsi, DSI_DPI_COLOR_CODING, color);
dsi_write(dsi, DSI_DPI_CFG_POL, val);
- /*
- * TODO dw drv improvements
- * largest packet sizes during hfp or during vsa/vpb/vfp
- * should be computed according to byte lane, lane number and only
- * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
- */
- dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(4)
- | INVACT_LPCMD_TIME(4));
}
static void dw_mipi_dsi_packet_handler_config(struct dw_mipi_dsi *dsi)
--
2.17.1
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH] drm/bridge/synopsys: dsi: allow sending longer LP commands
@ 2020-07-01 14:31 ` Yannick Fertre
0 siblings, 0 replies; 9+ messages in thread
From: Yannick Fertre @ 2020-07-01 14:31 UTC (permalink / raw)
To: Yannick Fertre, Philippe Cornu, Benjamin Gaignard, David Airlie,
Daniel Vetter, Maxime Coquelin, Alexandre Torgue, dri-devel,
linux-stm32, linux-arm-kernel, linux-kernel
From: Antonio Borneo <antonio.borneo@st.com>
Current code does not properly computes the max length of LP
commands that can be send during H or V sync, and rely on static
values.
Limiting the max LP length to 4 byte during the V-sync is overly
conservative.
Relax the limit and allows longer LP commands (16 bytes) to be
sent during V-sync.
Signed-off-by: Antonio Borneo <antonio.borneo@st.com>
---
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
index d580b2aa4ce9..1a24ea648ef8 100644
--- a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
+++ b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
@@ -360,6 +360,15 @@ static void dw_mipi_message_config(struct dw_mipi_dsi *dsi,
bool lpm = msg->flags & MIPI_DSI_MSG_USE_LPM;
u32 val = 0;
+ /*
+ * TODO dw drv improvements
+ * largest packet sizes during hfp or during vsa/vpb/vfp
+ * should be computed according to byte lane, lane number and only
+ * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
+ */
+ dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(16)
+ | INVACT_LPCMD_TIME(4));
+
if (msg->flags & MIPI_DSI_MSG_REQ_ACK)
val |= ACK_RQST_EN;
if (lpm)
@@ -611,14 +620,6 @@ static void dw_mipi_dsi_dpi_config(struct dw_mipi_dsi *dsi,
dsi_write(dsi, DSI_DPI_VCID, DPI_VCID(dsi->channel));
dsi_write(dsi, DSI_DPI_COLOR_CODING, color);
dsi_write(dsi, DSI_DPI_CFG_POL, val);
- /*
- * TODO dw drv improvements
- * largest packet sizes during hfp or during vsa/vpb/vfp
- * should be computed according to byte lane, lane number and only
- * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
- */
- dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(4)
- | INVACT_LPCMD_TIME(4));
}
static void dw_mipi_dsi_packet_handler_config(struct dw_mipi_dsi *dsi)
--
2.17.1
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply related [flat|nested] 9+ messages in thread
* [PATCH] drm/bridge/synopsys: dsi: allow sending longer LP commands
@ 2020-07-01 14:31 ` Yannick Fertre
0 siblings, 0 replies; 9+ messages in thread
From: Yannick Fertre @ 2020-07-01 14:31 UTC (permalink / raw)
To: Yannick Fertre, Philippe Cornu, Benjamin Gaignard, David Airlie,
Daniel Vetter, Maxime Coquelin, Alexandre Torgue, dri-devel,
linux-stm32, linux-arm-kernel, linux-kernel
From: Antonio Borneo <antonio.borneo@st.com>
Current code does not properly computes the max length of LP
commands that can be send during H or V sync, and rely on static
values.
Limiting the max LP length to 4 byte during the V-sync is overly
conservative.
Relax the limit and allows longer LP commands (16 bytes) to be
sent during V-sync.
Signed-off-by: Antonio Borneo <antonio.borneo@st.com>
---
drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 17 +++++++++--------
1 file changed, 9 insertions(+), 8 deletions(-)
diff --git a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
index d580b2aa4ce9..1a24ea648ef8 100644
--- a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
+++ b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
@@ -360,6 +360,15 @@ static void dw_mipi_message_config(struct dw_mipi_dsi *dsi,
bool lpm = msg->flags & MIPI_DSI_MSG_USE_LPM;
u32 val = 0;
+ /*
+ * TODO dw drv improvements
+ * largest packet sizes during hfp or during vsa/vpb/vfp
+ * should be computed according to byte lane, lane number and only
+ * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
+ */
+ dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(16)
+ | INVACT_LPCMD_TIME(4));
+
if (msg->flags & MIPI_DSI_MSG_REQ_ACK)
val |= ACK_RQST_EN;
if (lpm)
@@ -611,14 +620,6 @@ static void dw_mipi_dsi_dpi_config(struct dw_mipi_dsi *dsi,
dsi_write(dsi, DSI_DPI_VCID, DPI_VCID(dsi->channel));
dsi_write(dsi, DSI_DPI_COLOR_CODING, color);
dsi_write(dsi, DSI_DPI_CFG_POL, val);
- /*
- * TODO dw drv improvements
- * largest packet sizes during hfp or during vsa/vpb/vfp
- * should be computed according to byte lane, lane number and only
- * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
- */
- dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(4)
- | INVACT_LPCMD_TIME(4));
}
static void dw_mipi_dsi_packet_handler_config(struct dw_mipi_dsi *dsi)
--
2.17.1
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply related [flat|nested] 9+ messages in thread
* Re: [PATCH] drm/bridge/synopsys: dsi: allow sending longer LP commands
2020-07-01 14:31 ` Yannick Fertre
(?)
@ 2020-07-10 8:47 ` Philippe CORNU
-1 siblings, 0 replies; 9+ messages in thread
From: Philippe CORNU @ 2020-07-10 8:47 UTC (permalink / raw)
To: Yannick FERTRE, Benjamin GAIGNARD, David Airlie, Daniel Vetter,
Maxime Coquelin, Alexandre TORGUE, dri-devel, linux-stm32,
linux-arm-kernel, linux-kernel, Antonio BORNEO
On 7/1/20 4:31 PM, Yannick Fertre wrote:
> From: Antonio Borneo <antonio.borneo@st.com>
>
> Current code does not properly computes the max length of LP
> commands that can be send during H or V sync, and rely on static
> values.
> Limiting the max LP length to 4 byte during the V-sync is overly
> conservative.
>
> Relax the limit and allows longer LP commands (16 bytes) to be
> sent during V-sync.
>
> Signed-off-by: Antonio Borneo <antonio.borneo@st.com>
> ---
> drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 17 +++++++++--------
> 1 file changed, 9 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> index d580b2aa4ce9..1a24ea648ef8 100644
> --- a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> +++ b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> @@ -360,6 +360,15 @@ static void dw_mipi_message_config(struct dw_mipi_dsi *dsi,
> bool lpm = msg->flags & MIPI_DSI_MSG_USE_LPM;
> u32 val = 0;
>
> + /*
> + * TODO dw drv improvements
> + * largest packet sizes during hfp or during vsa/vpb/vfp
> + * should be computed according to byte lane, lane number and only
> + * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> + */
> + dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(16)
> + | INVACT_LPCMD_TIME(4));
> +
> if (msg->flags & MIPI_DSI_MSG_REQ_ACK)
> val |= ACK_RQST_EN;
> if (lpm)
> @@ -611,14 +620,6 @@ static void dw_mipi_dsi_dpi_config(struct dw_mipi_dsi *dsi,
> dsi_write(dsi, DSI_DPI_VCID, DPI_VCID(dsi->channel));
> dsi_write(dsi, DSI_DPI_COLOR_CODING, color);
> dsi_write(dsi, DSI_DPI_CFG_POL, val);
> - /*
> - * TODO dw drv improvements
> - * largest packet sizes during hfp or during vsa/vpb/vfp
> - * should be computed according to byte lane, lane number and only
> - * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> - */
> - dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(4)
> - | INVACT_LPCMD_TIME(4));
> }
>
> static void dw_mipi_dsi_packet_handler_config(struct dw_mipi_dsi *dsi)
>
(+ Antonio)
Hi Yannick & Antonio,
Reviewed-by: Philippe Cornu <philippe.cornu@st.com>
Tested-by: Philippe Cornu <philippe.cornu@st.com>
(Tested with the 3 patches named
drm/bridge/synopsys: dsi: allow LP commands in video mode
drm/bridge/synopsys: dsi: allow sending longer LP commands
drm/bridge/synopsys: dsi: add support for non-continuous HS clock
on various dsi bridges + stm32mp157 disco board)
Many thanks
Philippe :-)
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] drm/bridge/synopsys: dsi: allow sending longer LP commands
@ 2020-07-10 8:47 ` Philippe CORNU
0 siblings, 0 replies; 9+ messages in thread
From: Philippe CORNU @ 2020-07-10 8:47 UTC (permalink / raw)
To: Yannick FERTRE, Benjamin GAIGNARD, David Airlie, Daniel Vetter,
Maxime Coquelin, Alexandre TORGUE, dri-devel, linux-stm32,
linux-arm-kernel, linux-kernel, Antonio BORNEO
On 7/1/20 4:31 PM, Yannick Fertre wrote:
> From: Antonio Borneo <antonio.borneo@st.com>
>
> Current code does not properly computes the max length of LP
> commands that can be send during H or V sync, and rely on static
> values.
> Limiting the max LP length to 4 byte during the V-sync is overly
> conservative.
>
> Relax the limit and allows longer LP commands (16 bytes) to be
> sent during V-sync.
>
> Signed-off-by: Antonio Borneo <antonio.borneo@st.com>
> ---
> drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 17 +++++++++--------
> 1 file changed, 9 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> index d580b2aa4ce9..1a24ea648ef8 100644
> --- a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> +++ b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> @@ -360,6 +360,15 @@ static void dw_mipi_message_config(struct dw_mipi_dsi *dsi,
> bool lpm = msg->flags & MIPI_DSI_MSG_USE_LPM;
> u32 val = 0;
>
> + /*
> + * TODO dw drv improvements
> + * largest packet sizes during hfp or during vsa/vpb/vfp
> + * should be computed according to byte lane, lane number and only
> + * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> + */
> + dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(16)
> + | INVACT_LPCMD_TIME(4));
> +
> if (msg->flags & MIPI_DSI_MSG_REQ_ACK)
> val |= ACK_RQST_EN;
> if (lpm)
> @@ -611,14 +620,6 @@ static void dw_mipi_dsi_dpi_config(struct dw_mipi_dsi *dsi,
> dsi_write(dsi, DSI_DPI_VCID, DPI_VCID(dsi->channel));
> dsi_write(dsi, DSI_DPI_COLOR_CODING, color);
> dsi_write(dsi, DSI_DPI_CFG_POL, val);
> - /*
> - * TODO dw drv improvements
> - * largest packet sizes during hfp or during vsa/vpb/vfp
> - * should be computed according to byte lane, lane number and only
> - * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> - */
> - dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(4)
> - | INVACT_LPCMD_TIME(4));
> }
>
> static void dw_mipi_dsi_packet_handler_config(struct dw_mipi_dsi *dsi)
>
(+ Antonio)
Hi Yannick & Antonio,
Reviewed-by: Philippe Cornu <philippe.cornu@st.com>
Tested-by: Philippe Cornu <philippe.cornu@st.com>
(Tested with the 3 patches named
drm/bridge/synopsys: dsi: allow LP commands in video mode
drm/bridge/synopsys: dsi: allow sending longer LP commands
drm/bridge/synopsys: dsi: add support for non-continuous HS clock
on various dsi bridges + stm32mp157 disco board)
Many thanks
Philippe :-)
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] drm/bridge/synopsys: dsi: allow sending longer LP commands
@ 2020-07-10 8:47 ` Philippe CORNU
0 siblings, 0 replies; 9+ messages in thread
From: Philippe CORNU @ 2020-07-10 8:47 UTC (permalink / raw)
To: Yannick FERTRE, Benjamin GAIGNARD, David Airlie, Daniel Vetter,
Maxime Coquelin, Alexandre TORGUE, dri-devel, linux-stm32,
linux-arm-kernel, linux-kernel, Antonio BORNEO
On 7/1/20 4:31 PM, Yannick Fertre wrote:
> From: Antonio Borneo <antonio.borneo@st.com>
>
> Current code does not properly computes the max length of LP
> commands that can be send during H or V sync, and rely on static
> values.
> Limiting the max LP length to 4 byte during the V-sync is overly
> conservative.
>
> Relax the limit and allows longer LP commands (16 bytes) to be
> sent during V-sync.
>
> Signed-off-by: Antonio Borneo <antonio.borneo@st.com>
> ---
> drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 17 +++++++++--------
> 1 file changed, 9 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> index d580b2aa4ce9..1a24ea648ef8 100644
> --- a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> +++ b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> @@ -360,6 +360,15 @@ static void dw_mipi_message_config(struct dw_mipi_dsi *dsi,
> bool lpm = msg->flags & MIPI_DSI_MSG_USE_LPM;
> u32 val = 0;
>
> + /*
> + * TODO dw drv improvements
> + * largest packet sizes during hfp or during vsa/vpb/vfp
> + * should be computed according to byte lane, lane number and only
> + * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> + */
> + dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(16)
> + | INVACT_LPCMD_TIME(4));
> +
> if (msg->flags & MIPI_DSI_MSG_REQ_ACK)
> val |= ACK_RQST_EN;
> if (lpm)
> @@ -611,14 +620,6 @@ static void dw_mipi_dsi_dpi_config(struct dw_mipi_dsi *dsi,
> dsi_write(dsi, DSI_DPI_VCID, DPI_VCID(dsi->channel));
> dsi_write(dsi, DSI_DPI_COLOR_CODING, color);
> dsi_write(dsi, DSI_DPI_CFG_POL, val);
> - /*
> - * TODO dw drv improvements
> - * largest packet sizes during hfp or during vsa/vpb/vfp
> - * should be computed according to byte lane, lane number and only
> - * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> - */
> - dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(4)
> - | INVACT_LPCMD_TIME(4));
> }
>
> static void dw_mipi_dsi_packet_handler_config(struct dw_mipi_dsi *dsi)
>
(+ Antonio)
Hi Yannick & Antonio,
Reviewed-by: Philippe Cornu <philippe.cornu@st.com>
Tested-by: Philippe Cornu <philippe.cornu@st.com>
(Tested with the 3 patches named
drm/bridge/synopsys: dsi: allow LP commands in video mode
drm/bridge/synopsys: dsi: allow sending longer LP commands
drm/bridge/synopsys: dsi: add support for non-continuous HS clock
on various dsi bridges + stm32mp157 disco board)
Many thanks
Philippe :-)
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] drm/bridge/synopsys: dsi: allow sending longer LP commands
2020-07-01 14:31 ` Yannick Fertre
(?)
@ 2020-09-07 8:02 ` Neil Armstrong
-1 siblings, 0 replies; 9+ messages in thread
From: Neil Armstrong @ 2020-09-07 8:02 UTC (permalink / raw)
To: Yannick Fertre, Philippe Cornu, Benjamin Gaignard, David Airlie,
Daniel Vetter, Maxime Coquelin, Alexandre Torgue, dri-devel,
linux-stm32, linux-arm-kernel, linux-kernel
On 01/07/2020 16:31, Yannick Fertre wrote:
> From: Antonio Borneo <antonio.borneo@st.com>
>
> Current code does not properly computes the max length of LP
> commands that can be send during H or V sync, and rely on static
> values.
> Limiting the max LP length to 4 byte during the V-sync is overly
> conservative.
>
> Relax the limit and allows longer LP commands (16 bytes) to be
> sent during V-sync.
>
> Signed-off-by: Antonio Borneo <antonio.borneo@st.com>
> ---
> drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 17 +++++++++--------
> 1 file changed, 9 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> index d580b2aa4ce9..1a24ea648ef8 100644
> --- a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> +++ b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> @@ -360,6 +360,15 @@ static void dw_mipi_message_config(struct dw_mipi_dsi *dsi,
> bool lpm = msg->flags & MIPI_DSI_MSG_USE_LPM;
> u32 val = 0;
>
> + /*
> + * TODO dw drv improvements
> + * largest packet sizes during hfp or during vsa/vpb/vfp
> + * should be computed according to byte lane, lane number and only
> + * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> + */
> + dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(16)
> + | INVACT_LPCMD_TIME(4));
> +
> if (msg->flags & MIPI_DSI_MSG_REQ_ACK)
> val |= ACK_RQST_EN;
> if (lpm)
> @@ -611,14 +620,6 @@ static void dw_mipi_dsi_dpi_config(struct dw_mipi_dsi *dsi,
> dsi_write(dsi, DSI_DPI_VCID, DPI_VCID(dsi->channel));
> dsi_write(dsi, DSI_DPI_COLOR_CODING, color);
> dsi_write(dsi, DSI_DPI_CFG_POL, val);
> - /*
> - * TODO dw drv improvements
> - * largest packet sizes during hfp or during vsa/vpb/vfp
> - * should be computed according to byte lane, lane number and only
> - * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> - */
> - dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(4)
> - | INVACT_LPCMD_TIME(4));
> }
>
> static void dw_mipi_dsi_packet_handler_config(struct dw_mipi_dsi *dsi)
>
Tested on Amlogic AXG (v1.21a)
Acked-by: Neil Armstrong <narmstrong@baylibre.com>
Applying to drm-misc-next
Thanks !
Neil
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] drm/bridge/synopsys: dsi: allow sending longer LP commands
@ 2020-09-07 8:02 ` Neil Armstrong
0 siblings, 0 replies; 9+ messages in thread
From: Neil Armstrong @ 2020-09-07 8:02 UTC (permalink / raw)
To: Yannick Fertre, Philippe Cornu, Benjamin Gaignard, David Airlie,
Daniel Vetter, Maxime Coquelin, Alexandre Torgue, dri-devel,
linux-stm32, linux-arm-kernel, linux-kernel
On 01/07/2020 16:31, Yannick Fertre wrote:
> From: Antonio Borneo <antonio.borneo@st.com>
>
> Current code does not properly computes the max length of LP
> commands that can be send during H or V sync, and rely on static
> values.
> Limiting the max LP length to 4 byte during the V-sync is overly
> conservative.
>
> Relax the limit and allows longer LP commands (16 bytes) to be
> sent during V-sync.
>
> Signed-off-by: Antonio Borneo <antonio.borneo@st.com>
> ---
> drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 17 +++++++++--------
> 1 file changed, 9 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> index d580b2aa4ce9..1a24ea648ef8 100644
> --- a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> +++ b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> @@ -360,6 +360,15 @@ static void dw_mipi_message_config(struct dw_mipi_dsi *dsi,
> bool lpm = msg->flags & MIPI_DSI_MSG_USE_LPM;
> u32 val = 0;
>
> + /*
> + * TODO dw drv improvements
> + * largest packet sizes during hfp or during vsa/vpb/vfp
> + * should be computed according to byte lane, lane number and only
> + * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> + */
> + dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(16)
> + | INVACT_LPCMD_TIME(4));
> +
> if (msg->flags & MIPI_DSI_MSG_REQ_ACK)
> val |= ACK_RQST_EN;
> if (lpm)
> @@ -611,14 +620,6 @@ static void dw_mipi_dsi_dpi_config(struct dw_mipi_dsi *dsi,
> dsi_write(dsi, DSI_DPI_VCID, DPI_VCID(dsi->channel));
> dsi_write(dsi, DSI_DPI_COLOR_CODING, color);
> dsi_write(dsi, DSI_DPI_CFG_POL, val);
> - /*
> - * TODO dw drv improvements
> - * largest packet sizes during hfp or during vsa/vpb/vfp
> - * should be computed according to byte lane, lane number and only
> - * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> - */
> - dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(4)
> - | INVACT_LPCMD_TIME(4));
> }
>
> static void dw_mipi_dsi_packet_handler_config(struct dw_mipi_dsi *dsi)
>
Tested on Amlogic AXG (v1.21a)
Acked-by: Neil Armstrong <narmstrong@baylibre.com>
Applying to drm-misc-next
Thanks !
Neil
_______________________________________________
linux-arm-kernel mailing list
linux-arm-kernel@lists.infradead.org
http://lists.infradead.org/mailman/listinfo/linux-arm-kernel
^ permalink raw reply [flat|nested] 9+ messages in thread
* Re: [PATCH] drm/bridge/synopsys: dsi: allow sending longer LP commands
@ 2020-09-07 8:02 ` Neil Armstrong
0 siblings, 0 replies; 9+ messages in thread
From: Neil Armstrong @ 2020-09-07 8:02 UTC (permalink / raw)
To: Yannick Fertre, Philippe Cornu, Benjamin Gaignard, David Airlie,
Daniel Vetter, Maxime Coquelin, Alexandre Torgue, dri-devel,
linux-stm32, linux-arm-kernel, linux-kernel
On 01/07/2020 16:31, Yannick Fertre wrote:
> From: Antonio Borneo <antonio.borneo@st.com>
>
> Current code does not properly computes the max length of LP
> commands that can be send during H or V sync, and rely on static
> values.
> Limiting the max LP length to 4 byte during the V-sync is overly
> conservative.
>
> Relax the limit and allows longer LP commands (16 bytes) to be
> sent during V-sync.
>
> Signed-off-by: Antonio Borneo <antonio.borneo@st.com>
> ---
> drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c | 17 +++++++++--------
> 1 file changed, 9 insertions(+), 8 deletions(-)
>
> diff --git a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> index d580b2aa4ce9..1a24ea648ef8 100644
> --- a/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> +++ b/drivers/gpu/drm/bridge/synopsys/dw-mipi-dsi.c
> @@ -360,6 +360,15 @@ static void dw_mipi_message_config(struct dw_mipi_dsi *dsi,
> bool lpm = msg->flags & MIPI_DSI_MSG_USE_LPM;
> u32 val = 0;
>
> + /*
> + * TODO dw drv improvements
> + * largest packet sizes during hfp or during vsa/vpb/vfp
> + * should be computed according to byte lane, lane number and only
> + * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> + */
> + dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(16)
> + | INVACT_LPCMD_TIME(4));
> +
> if (msg->flags & MIPI_DSI_MSG_REQ_ACK)
> val |= ACK_RQST_EN;
> if (lpm)
> @@ -611,14 +620,6 @@ static void dw_mipi_dsi_dpi_config(struct dw_mipi_dsi *dsi,
> dsi_write(dsi, DSI_DPI_VCID, DPI_VCID(dsi->channel));
> dsi_write(dsi, DSI_DPI_COLOR_CODING, color);
> dsi_write(dsi, DSI_DPI_CFG_POL, val);
> - /*
> - * TODO dw drv improvements
> - * largest packet sizes during hfp or during vsa/vpb/vfp
> - * should be computed according to byte lane, lane number and only
> - * if sending lp cmds in high speed is enable (PHY_TXREQUESTCLKHS)
> - */
> - dsi_write(dsi, DSI_DPI_LP_CMD_TIM, OUTVACT_LPCMD_TIME(4)
> - | INVACT_LPCMD_TIME(4));
> }
>
> static void dw_mipi_dsi_packet_handler_config(struct dw_mipi_dsi *dsi)
>
Tested on Amlogic AXG (v1.21a)
Acked-by: Neil Armstrong <narmstrong@baylibre.com>
Applying to drm-misc-next
Thanks !
Neil
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
^ permalink raw reply [flat|nested] 9+ messages in thread
end of thread, other threads:[~2020-09-07 8:03 UTC | newest]
Thread overview: 9+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-07-01 14:31 [PATCH] drm/bridge/synopsys: dsi: allow sending longer LP commands Yannick Fertre
2020-07-01 14:31 ` Yannick Fertre
2020-07-01 14:31 ` Yannick Fertre
2020-07-10 8:47 ` Philippe CORNU
2020-07-10 8:47 ` Philippe CORNU
2020-07-10 8:47 ` Philippe CORNU
2020-09-07 8:02 ` Neil Armstrong
2020-09-07 8:02 ` Neil Armstrong
2020-09-07 8:02 ` Neil Armstrong
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.