All of lore.kernel.org
 help / color / mirror / Atom feed
From: Hoan <na-hoan@jinso.co.jp>
To: Laurent Pinchart <laurent.pinchart@ideasonboard.com>
Cc: linux-renesas-soc@vger.kernel.org, geert+renesas@glider.be,
	kuninori.morimoto.gx@renesas.com,
	yoshihiro.shimoda.uh@renesas.com, h-inayoshi@jinso.co.jp,
	nv-dung@jinso.co.jp, cv-dong@jinso.co.jp
Subject: Re: [PATCH] drm: rcar-du: Re-update the DSYSR register value for start/stop
Date: Wed, 24 Oct 2018 09:16:51 +0900	[thread overview]
Message-ID: <02fe926f-0f60-3106-1d83-8f4fa27995e2@jinso.co.jp> (raw)
In-Reply-To: <35008313.pubLakprOv@avalon>

[-- Attachment #1: Type: text/plain, Size: 3620 bytes --]

Dear Laurent-san

On 2018/10/22 20:23, Laurent Pinchart wrote:
> Hello Hoan,
>
> Thank you for the patch.
>
> On Monday, 22 October 2018 09:30:54 EEST Nguyen An Hoan wrote:
>> From: Hoan Nguyen An <na-hoan@jinso.co.jp>
>>
>>  From previous commit 0521ccb "drm: rcar-du: Cache DSYSR value to ensure
>> known initial value"
> What exact commit are you referring to ? The mainline commit that has this
> subject is 9144adc5e5a99577bce0d4ee2ca3615f53b9d296.
>
>> We only need to update DSYSR0, DSYSR2 for start/stop.
>> So using rgrp-> mmio_offset is enough, the change back from rcar_du_crtc ->
>> rcar_du_group -> rcar_du_crtc leading to mmio addresses for DSYSR may be
>> different.
> Is this fixing an actual problem ? If you look at the code, the line
>
> 	struct rcar_du_crtc *rcrtc = &rgrp->dev->crtcs[rgrp->index * 2];
>
> makes sure that we select DU0 or DU2 only, so the register write
>
> 	rcar_du_crtc_dsysr_clr_set(rcrtc, DSYSR_DRES | DSYSR_DEN,
> 				   start ? DSYSR_DEN : DSYSR_DRES);
>
> should only access DSYSR0 and DSYSR2.

Dear Laurent-san

I add information about the current error occurring at M3N-r8a77965

when probe rcar-du driver:

/[   13.027115] [drm:drm_atomic_helper_wait_for_flip_done] *ERROR* 
[CRTC:55:crtc-2] flip_done timed out//
//[   23.267103] [drm:drm_atomic_helper_wait_for_dependencies] *ERROR* 
[CRTC:55:crtc-2] flip_done timed out//
//[   33.507102] [drm:drm_atomic_helper_wait_for_dependencies] *ERROR* 
[CONNECTOR:57:VGA-1] flip_done timed out//
//[   43.747100] [drm:drm_atomic_helper_wait_for_dependencies] *ERROR* 
[PLANE:30:plane-1] flip_done timed out//
//[   53.987100] [drm:drm_atomic_helper_wait_for_flip_done] *ERROR* 
[CRTC:55:crtc-2] flip_done timed out//
//[   53.989913] Console: switching to colour frame buffer device 128x48//
//[   64.227102] [drm:drm_atomic_helper_wait_for_dependencies] *ERROR* 
[CRTC:55:crtc-2] flip_done timed out//
//[   74.467099] [drm:drm_atomic_helper_wait_for_dependencies] *ERROR* 
[CONNECTOR:57:VGA-1] flip_done timed out//
//[   84.707100] [drm:drm_atomic_helper_wait_for_dependencies] *ERROR* 
[PLANE:30:plane-1] flip_done timed out//
//[   94.947100] [drm:drm_atomic_helper_wait_for_flip_done] *ERROR* 
[CRTC:55:crtc-2] flip_done timed out//
//[   95.040076] rcar-du feb00000.display: fb0: DRM emulated frame 
buffer device//
//[   95.047747] [drm] Initialized rcar-du 1.0.0 20130110 for 
feb00000.display on minor 0//
//[   95.055512] [drm] Device feb00000.display probed//
//[   95.061252] bd9571mwv 7-0030: Device: BD9571MWV rev. 4/

on renesas-drivers/renesas-drivers-2018-10-09-v4.19-rc7

Thank you!

Hoan.


>> Signed-off-by: Hoan Nguyen An <na-hoan@jinso.co.jp>
>> ---
>>   drivers/gpu/drm/rcar-du/rcar_du_group.c | 7 +++----
>>   1 file changed, 3 insertions(+), 4 deletions(-)
>>
>> diff --git a/drivers/gpu/drm/rcar-du/rcar_du_group.c
>> b/drivers/gpu/drm/rcar-du/rcar_du_group.c index d85f0a1..a5f7eed 100644
>> --- a/drivers/gpu/drm/rcar-du/rcar_du_group.c
>> +++ b/drivers/gpu/drm/rcar-du/rcar_du_group.c
>> @@ -202,10 +202,9 @@ void rcar_du_group_put(struct rcar_du_group *rgrp)
>>
>>   static void __rcar_du_group_start_stop(struct rcar_du_group *rgrp, bool
>> start) {
>> -	struct rcar_du_crtc *rcrtc = &rgrp->dev->crtcs[rgrp->index * 2];
>> -
>> -	rcar_du_crtc_dsysr_clr_set(rcrtc, DSYSR_DRES | DSYSR_DEN,
>> -				   start ? DSYSR_DEN : DSYSR_DRES);
>> +	rcar_du_group_write(rgrp, DSYSR,
>> +			(rcar_du_group_read(rgrp, DSYSR) & ~(DSYSR_DRES | DSYSR_DEN)) |
>> +			(start ? DSYSR_DEN : DSYSR_DRES));
>>   }
>>
>>   void rcar_du_group_start_stop(struct rcar_du_group *rgrp, bool start)

[-- Attachment #2: Type: text/html, Size: 5343 bytes --]

      parent reply	other threads:[~2018-10-24  0:16 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-10-22  6:30 [PATCH] drm: rcar-du: Re-update the DSYSR register value for start/stop Nguyen An Hoan
2018-10-22  8:21 ` Sergei Shtylyov
2018-10-23  0:59   ` Hoan
2018-10-22 11:23 ` Laurent Pinchart
2018-10-23  1:01   ` Hoan
2018-11-22 23:29     ` Laurent Pinchart
2018-10-23 10:10   ` Hoan
2018-10-24  0:16   ` Hoan [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=02fe926f-0f60-3106-1d83-8f4fa27995e2@jinso.co.jp \
    --to=na-hoan@jinso.co.jp \
    --cc=cv-dong@jinso.co.jp \
    --cc=geert+renesas@glider.be \
    --cc=h-inayoshi@jinso.co.jp \
    --cc=kuninori.morimoto.gx@renesas.com \
    --cc=laurent.pinchart@ideasonboard.com \
    --cc=linux-renesas-soc@vger.kernel.org \
    --cc=nv-dung@jinso.co.jp \
    --cc=yoshihiro.shimoda.uh@renesas.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
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.