From: Tomi Valkeinen <tomi.valkeinen@ti.com>
To: Jyri Sarha <jsarha@ti.com>, dri-devel@lists.freedesktop.org
Cc: bcousson@baylibre.com, laurent.pinchart@ideasonboard.com
Subject: Re: [PATCH v2 3/6] drm/tilcdc: Move waiting of LCDC_FRAME_DONE IRQ into stop()
Date: Thu, 16 Jun 2016 12:25:13 +0300 [thread overview]
Message-ID: <57627079.5040800@ti.com> (raw)
In-Reply-To: <c71f012049fd7c622f1f2d0f975468882ae3047d.1465979902.git.jsarha@ti.com>
[-- Attachment #1.1.1: Type: text/plain, Size: 1705 bytes --]
On 15/06/16 11:39, Jyri Sarha wrote:
> Move wait queue waiting of LCDC_FRAME_DONE IRQ from tilcdc_crtc_dpms()
> into stop() function.
You could mention the reason for this, which is just a cleanup here (I
presume).
> Signed-off-by: Jyri Sarha <jsarha@ti.com>
> ---
> drivers/gpu/drm/tilcdc/tilcdc_crtc.c | 31 ++++++++++++++++---------------
> 1 file changed, 16 insertions(+), 15 deletions(-)
>
> diff --git a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
> index 1343717..cfa1a4e 100644
> --- a/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
> +++ b/drivers/gpu/drm/tilcdc/tilcdc_crtc.c
> @@ -113,9 +113,25 @@ static void start(struct drm_crtc *crtc)
>
> static void stop(struct drm_crtc *crtc)
> {
> + struct tilcdc_crtc *tilcdc_crtc = to_tilcdc_crtc(crtc);
> struct drm_device *dev = crtc->dev;
> + struct tilcdc_drm_private *priv = dev->dev_private;
>
> + tilcdc_crtc->frame_done = false;
> tilcdc_clear(dev, LCDC_RASTER_CTRL_REG, LCDC_RASTER_ENABLE);
> +
> + /*
> + * if necessary wait for framedone irq which will still come
> + * before putting things to sleep..
> + */
> + if (priv->rev == 2) {
> + int ret = wait_event_timeout(tilcdc_crtc->frame_done_wq,
> + tilcdc_crtc->frame_done,
> + msecs_to_jiffies(50));
Not part of this patch, but I think the timeout could be increased quite
a bit. It's never supposed to happen. And while video timings with 50ms
frames are not common, I don't see that as impossible either.
Of course, optimally the timeout would be calculated from the video
timings, which shouldn't be too difficult either...
Anyway, as I said, not part of this patch.
Tomi
[-- Attachment #1.2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 819 bytes --]
[-- Attachment #2: Type: text/plain, Size: 160 bytes --]
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
next prev parent reply other threads:[~2016-06-16 9:25 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-06-15 8:39 [PATCH v2 0/6] drm/tilcdc Fixes and cleanups Jyri Sarha
2016-06-15 8:39 ` [PATCH v2 1/6] drm/tilcdc: Restore old dpms state in pm_resume() Jyri Sarha
2016-06-16 9:13 ` Tomi Valkeinen
2016-06-15 8:39 ` [PATCH v2 2/6] drm/tilcdc: Write to LCDC_END_OF_INT_IND_REG at the end of IRQ function Jyri Sarha
2016-06-16 9:19 ` Tomi Valkeinen
2016-06-15 8:39 ` [PATCH v2 3/6] drm/tilcdc: Move waiting of LCDC_FRAME_DONE IRQ into stop() Jyri Sarha
2016-06-16 9:25 ` Tomi Valkeinen [this message]
2016-06-15 8:39 ` [PATCH v2 4/6] drm/tilcdc: Call drm_crtc_vblank_on() and *_off() in start() and stop() Jyri Sarha
2016-06-15 8:39 ` [PATCH v2 5/6] drm/tilcdc: Refer to panel.txt and tfp410.txt bindings in tilcdc.txt Jyri Sarha
2016-06-15 8:39 ` [PATCH v2 6/6] drm/tilcdc: Avoid error print by of_graph_get_next_endpoint() Jyri Sarha
2016-06-15 12:29 ` [PATCH v2 0/6] drm/tilcdc Fixes and cleanups Jyri Sarha
2016-06-16 9:30 ` Tomi Valkeinen
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=57627079.5040800@ti.com \
--to=tomi.valkeinen@ti.com \
--cc=bcousson@baylibre.com \
--cc=dri-devel@lists.freedesktop.org \
--cc=jsarha@ti.com \
--cc=laurent.pinchart@ideasonboard.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox