linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
* [PATCH] drm/meson: venc: dmt mode must use encp
@ 2018-11-12 18:41 Jorge Ramirez-Ortiz
  2018-11-13  8:35 ` Neil Armstrong
  0 siblings, 1 reply; 3+ messages in thread
From: Jorge Ramirez-Ortiz @ 2018-11-12 18:41 UTC (permalink / raw)
  To: jramirez, narmstrong, airlied, carlo, khilman
  Cc: dri-devel, linux-amlogic, linux-arm-kernel, linux-kernel

From: Jorge Ramirez-Ortiz <jorge.ramirez.ortiz@gmail.com>

The video mode for DMT is only populated to support encp.

Signed-off-by: Jorge Ramirez-Ortiz <jorge.ramirez.ortiz@gmail.com>
---
 drivers/gpu/drm/meson/meson_venc.c | 15 ++++++++-------
 1 file changed, 8 insertions(+), 7 deletions(-)

diff --git a/drivers/gpu/drm/meson/meson_venc.c b/drivers/gpu/drm/meson/meson_venc.c
index 514245e..acbbad3 100644
--- a/drivers/gpu/drm/meson/meson_venc.c
+++ b/drivers/gpu/drm/meson/meson_venc.c
@@ -854,6 +854,13 @@ void meson_venc_hdmi_mode_set(struct meson_drm *priv, int vic,
 	unsigned int sof_lines;
 	unsigned int vsync_lines;
 
+	/* Use VENCI for 480i and 576i and double HDMI pixels */
+	if (mode->flags & DRM_MODE_FLAG_DBLCLK) {
+		hdmi_repeat = true;
+		use_enci = true;
+		venc_hdmi_latency = 1;
+	}
+
 	if (meson_venc_hdmi_supported_vic(vic)) {
 		vmode = meson_venc_hdmi_get_vic_vmode(vic);
 		if (!vmode) {
@@ -865,13 +872,7 @@ void meson_venc_hdmi_mode_set(struct meson_drm *priv, int vic,
 	} else {
 		meson_venc_hdmi_get_dmt_vmode(mode, &vmode_dmt);
 		vmode = &vmode_dmt;
-	}
-
-	/* Use VENCI for 480i and 576i and double HDMI pixels */
-	if (mode->flags & DRM_MODE_FLAG_DBLCLK) {
-		hdmi_repeat = true;
-		use_enci = true;
-		venc_hdmi_latency = 1;
+		use_enci = false;
 	}
 
 	/* Repeat VENC pixels for 480/576i/p, 720p50/60 and 1080p50/60 */
-- 
2.7.4


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

* Re: [PATCH] drm/meson: venc: dmt mode must use encp
  2018-11-12 18:41 [PATCH] drm/meson: venc: dmt mode must use encp Jorge Ramirez-Ortiz
@ 2018-11-13  8:35 ` Neil Armstrong
  2018-11-13 13:32   ` Neil Armstrong
  0 siblings, 1 reply; 3+ messages in thread
From: Neil Armstrong @ 2018-11-13  8:35 UTC (permalink / raw)
  To: Jorge Ramirez-Ortiz, airlied, carlo, khilman
  Cc: dri-devel, linux-amlogic, linux-arm-kernel, linux-kernel

On 12/11/2018 19:41, Jorge Ramirez-Ortiz wrote:
> From: Jorge Ramirez-Ortiz <jorge.ramirez.ortiz@gmail.com>
> 
> The video mode for DMT is only populated to support encp.
> 
> Signed-off-by: Jorge Ramirez-Ortiz <jorge.ramirez.ortiz@gmail.com>
> ---
>  drivers/gpu/drm/meson/meson_venc.c | 15 ++++++++-------
>  1 file changed, 8 insertions(+), 7 deletions(-)
> 
> diff --git a/drivers/gpu/drm/meson/meson_venc.c b/drivers/gpu/drm/meson/meson_venc.c
> index 514245e..acbbad3 100644
> --- a/drivers/gpu/drm/meson/meson_venc.c
> +++ b/drivers/gpu/drm/meson/meson_venc.c
> @@ -854,6 +854,13 @@ void meson_venc_hdmi_mode_set(struct meson_drm *priv, int vic,
>  	unsigned int sof_lines;
>  	unsigned int vsync_lines;
>  
> +	/* Use VENCI for 480i and 576i and double HDMI pixels */
> +	if (mode->flags & DRM_MODE_FLAG_DBLCLK) {
> +		hdmi_repeat = true;
> +		use_enci = true;
> +		venc_hdmi_latency = 1;
> +	}
> +
>  	if (meson_venc_hdmi_supported_vic(vic)) {
>  		vmode = meson_venc_hdmi_get_vic_vmode(vic);
>  		if (!vmode) {
> @@ -865,13 +872,7 @@ void meson_venc_hdmi_mode_set(struct meson_drm *priv, int vic,
>  	} else {
>  		meson_venc_hdmi_get_dmt_vmode(mode, &vmode_dmt);
>  		vmode = &vmode_dmt;
> -	}
> -
> -	/* Use VENCI for 480i and 576i and double HDMI pixels */
> -	if (mode->flags & DRM_MODE_FLAG_DBLCLK) {
> -		hdmi_repeat = true;
> -		use_enci = true;
> -		venc_hdmi_latency = 1;
> +		use_enci = false;
>  	}
>  
>  	/* Repeat VENC pixels for 480/576i/p, 720p50/60 and 1080p50/60 */
> 

Thanks !

Acked-by: Neil Armstrong <narmstrong@baylibre.com>

I'll apply to drm-misc-fixes !

Neil

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

* Re: [PATCH] drm/meson: venc: dmt mode must use encp
  2018-11-13  8:35 ` Neil Armstrong
@ 2018-11-13 13:32   ` Neil Armstrong
  0 siblings, 0 replies; 3+ messages in thread
From: Neil Armstrong @ 2018-11-13 13:32 UTC (permalink / raw)
  To: Jorge Ramirez-Ortiz, airlied, carlo, khilman
  Cc: dri-devel, linux-amlogic, linux-arm-kernel, linux-kernel

On 13/11/2018 09:35, Neil Armstrong wrote:
> On 12/11/2018 19:41, Jorge Ramirez-Ortiz wrote:
>> From: Jorge Ramirez-Ortiz <jorge.ramirez.ortiz@gmail.com>
>>
>> The video mode for DMT is only populated to support encp.
>>
>> Signed-off-by: Jorge Ramirez-Ortiz <jorge.ramirez.ortiz@gmail.com>
>> ---
>>  drivers/gpu/drm/meson/meson_venc.c | 15 ++++++++-------
>>  1 file changed, 8 insertions(+), 7 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/meson/meson_venc.c b/drivers/gpu/drm/meson/meson_venc.c
>> index 514245e..acbbad3 100644
>> --- a/drivers/gpu/drm/meson/meson_venc.c
>> +++ b/drivers/gpu/drm/meson/meson_venc.c
>> @@ -854,6 +854,13 @@ void meson_venc_hdmi_mode_set(struct meson_drm *priv, int vic,
>>  	unsigned int sof_lines;
>>  	unsigned int vsync_lines;
>>  
>> +	/* Use VENCI for 480i and 576i and double HDMI pixels */
>> +	if (mode->flags & DRM_MODE_FLAG_DBLCLK) {
>> +		hdmi_repeat = true;
>> +		use_enci = true;
>> +		venc_hdmi_latency = 1;
>> +	}
>> +
>>  	if (meson_venc_hdmi_supported_vic(vic)) {
>>  		vmode = meson_venc_hdmi_get_vic_vmode(vic);
>>  		if (!vmode) {
>> @@ -865,13 +872,7 @@ void meson_venc_hdmi_mode_set(struct meson_drm *priv, int vic,
>>  	} else {
>>  		meson_venc_hdmi_get_dmt_vmode(mode, &vmode_dmt);
>>  		vmode = &vmode_dmt;
>> -	}
>> -
>> -	/* Use VENCI for 480i and 576i and double HDMI pixels */
>> -	if (mode->flags & DRM_MODE_FLAG_DBLCLK) {
>> -		hdmi_repeat = true;
>> -		use_enci = true;
>> -		venc_hdmi_latency = 1;
>> +		use_enci = false;
>>  	}
>>  
>>  	/* Repeat VENC pixels for 480/576i/p, 720p50/60 and 1080p50/60 */
>>
> 
> Thanks !
> 
> Acked-by: Neil Armstrong <narmstrong@baylibre.com>
> 
> I'll apply to drm-misc-fixes !
> 
> Neil
> 

Applied.

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

end of thread, other threads:[~2018-11-13 13:32 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-11-12 18:41 [PATCH] drm/meson: venc: dmt mode must use encp Jorge Ramirez-Ortiz
2018-11-13  8:35 ` Neil Armstrong
2018-11-13 13:32   ` 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).