From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Vincent Abriou <vincent.abriou@st.com>
Cc: Benjamin Gaignard <benjamin.gaignard@linaro.org>,
dri-devel@lists.freedesktop.org,
Fabien Dessenne <fabien.dessenne@st.com>
Subject: Re: [PATCH 1/1] drm: fix drm_update_vblank_count for software vblank counter
Date: Wed, 30 Sep 2015 17:11:33 +0300 [thread overview]
Message-ID: <20150930141133.GP26517@intel.com> (raw)
In-Reply-To: <1443616189-8286-1-git-send-email-vincent.abriou@st.com>
On Wed, Sep 30, 2015 at 02:29:49PM +0200, Vincent Abriou wrote:
> Drivers with software vblank counter relies on the on drm core to update
> vblank counter and they should not be concern about the warning that
> check hardware counter coherency.
>
> Further, the generic message that tracks the current and last counter
> values must be counter type (hardware or software) agnostic.
>
> Cc: Ville Syrj?l? <ville.syrjala@linux.intel.com>
> Signed-off-by: Vincent Abriou <vincent.abriou@st.com>
I sent a patch to get rid of the drm_vblank_count() abuse in all
drivers. That will get rid of the WARN too.
> ---
> drivers/gpu/drm/drm_irq.c | 7 ++++---
> 1 file changed, 4 insertions(+), 3 deletions(-)
>
> diff --git a/drivers/gpu/drm/drm_irq.c b/drivers/gpu/drm/drm_irq.c
> index 88fbee4..88041b4 100644
> --- a/drivers/gpu/drm/drm_irq.c
> +++ b/drivers/gpu/drm/drm_irq.c
> @@ -219,11 +219,12 @@ static void drm_update_vblank_count(struct drm_device *dev, unsigned int pipe,
> } else {
> /* some kind of default for drivers w/o accurate vbl timestamping */
> diff = (flags & DRM_CALLED_FROM_VBLIRQ) != 0;
> + if (diff == 0)
> + return;
> }
>
> - DRM_DEBUG("updating vblank count on crtc %u:"
> - " current=%u, diff=%u, hw=%u hw_last=%u\n",
> - pipe, vblank->count, diff, cur_vblank, vblank->last);
> + DRM_DEBUG("updating vblank count on crtc %u: diff=%u cur=%u last=%u\n",
> + pipe, diff, cur_vblank, vblank->last);
>
> if (diff == 0) {
> WARN_ON_ONCE(cur_vblank != vblank->last);
> --
> 1.9.1
--
Ville Syrjälä
Intel OTC
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/dri-devel
prev parent reply other threads:[~2015-09-30 14:11 UTC|newest]
Thread overview: 2+ messages / expand[flat|nested] mbox.gz Atom feed top
2015-09-30 12:29 [PATCH 1/1] drm: fix drm_update_vblank_count for software vblank counter Vincent Abriou
2015-09-30 14:11 ` Ville Syrjälä [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=20150930141133.GP26517@intel.com \
--to=ville.syrjala@linux.intel.com \
--cc=benjamin.gaignard@linaro.org \
--cc=dri-devel@lists.freedesktop.org \
--cc=fabien.dessenne@st.com \
--cc=vincent.abriou@st.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