From: "Ville Syrjälä" <ville.syrjala@linux.intel.com>
To: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Rob Clark <rob@ti.com>,
Intel Graphics Development <intel-gfx@lists.freedesktop.org>,
DRI Development <dri-devel@lists.freedesktop.org>
Subject: Re: [PATCH] drm: Don't set the plane->fb to NULL on successfull set_plane
Date: Fri, 15 Feb 2013 22:26:04 +0200 [thread overview]
Message-ID: <20130215202604.GF9135@intel.com> (raw)
In-Reply-To: <1360959697-23322-1-git-send-email-daniel.vetter@ffwll.ch>
On Fri, Feb 15, 2013 at 09:21:37PM +0100, Daniel Vetter wrote:
> We need to clear the local variable to get the refcounting right
> (since the reference drm_mode_setplane holds is transferred to the
> plane->fb pointer). But should be done _after_ we update the pointer.
>
> Breakage introduced in
>
> commit 6c2a75325c800de286166c693e0cd33c3a1c5ec8
> Author: Daniel Vetter <daniel.vetter@ffwll.ch>
> Date: Tue Dec 11 00:59:24 2012 +0100
>
> drm: refcounting for sprite framebuffers
>
> Reported-by: Jesse Barnes <jbarnes@virtuousgeek.org>
> Cc: Jesse Barnes <jbarnes@virtuousgeek.org>
> Cc: Rob Clark <rob@ti.com>
> Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Ville Syrjälä <ville.syrjala@linux.intel.com>
> ---
> drivers/gpu/drm/drm_crtc.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/gpu/drm/drm_crtc.c b/drivers/gpu/drm/drm_crtc.c
> index 826a5ca..1960418 100644
> --- a/drivers/gpu/drm/drm_crtc.c
> +++ b/drivers/gpu/drm/drm_crtc.c
> @@ -1982,9 +1982,9 @@ int drm_mode_setplane(struct drm_device *dev, void *data,
> plane_req->src_w, plane_req->src_h);
> if (!ret) {
> old_fb = plane->fb;
> - fb = NULL;
> plane->crtc = crtc;
> plane->fb = fb;
> + fb = NULL;
> }
> drm_modeset_unlock_all(dev);
>
> --
> 1.7.10.4
>
> _______________________________________________
> Intel-gfx mailing list
> Intel-gfx@lists.freedesktop.org
> http://lists.freedesktop.org/mailman/listinfo/intel-gfx
--
Ville Syrjälä
Intel OTC
next prev parent reply other threads:[~2013-02-15 20:26 UTC|newest]
Thread overview: 4+ messages / expand[flat|nested] mbox.gz Atom feed top
2013-02-15 20:21 [PATCH] drm: Don't set the plane->fb to NULL on successfull set_plane Daniel Vetter
2013-02-15 20:24 ` Jesse Barnes
2013-02-15 20:26 ` Ville Syrjälä [this message]
2013-02-19 15:37 ` Thierry Reding
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=20130215202604.GF9135@intel.com \
--to=ville.syrjala@linux.intel.com \
--cc=daniel.vetter@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=intel-gfx@lists.freedesktop.org \
--cc=rob@ti.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