All of lore.kernel.org
 help / color / mirror / Atom feed
From: Boris Brezillon <boris.brezillon@bootlin.com>
To: Eric Anholt <eric@anholt.net>
Cc: dri-devel@lists.freedesktop.org
Subject: Re: [PATCH v3 1/2] drm/vc4: Fix NULL pointer dereference in the async update path
Date: Thu, 15 Nov 2018 17:58:24 +0100	[thread overview]
Message-ID: <20181115175824.170c16c2@bbrezillon> (raw)
In-Reply-To: <87wopez4s3.fsf@anholt.net>

On Thu, 15 Nov 2018 08:25:48 -0800
Eric Anholt <eric@anholt.net> wrote:

> Boris Brezillon <boris.brezillon@bootlin.com> writes:
> 
> > vc4_plane_atomic_async_update() calls vc4_plane_atomic_check()
> > which in turn calls vc4_plane_setup_clipping_and_scaling(), and since
> > commit 58a6a36fe8e0 ("drm/vc4: Use
> > drm_atomic_helper_check_plane_state() to simplify the logic"), this
> > function accesses plane_state->state which will be NULL when called
> > from the async update path because we're passing the current plane
> > state, and plane_state->state has been assigned to NULL in
> > drm_atomic_helper_swap_state().
> >
> > Pass the new state instead of the current one (the new state has  
> > ->state set to a non-NULL value).  
> >
> > Fixes: 58a6a36fe8e0 ("drm/vc4: Use drm_atomic_helper_check_plane_state() to simplify the logic")
> > Signed-off-by: Boris Brezillon <boris.brezillon@bootlin.com>  
> 
> I'm glad this worked!
> 
> Reviewed-by: Eric Anholt <eric@anholt.net>

Series applied to drm-misc-fixes.
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel

      reply	other threads:[~2018-11-15 16:58 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2018-11-15 10:58 [PATCH v3 1/2] drm/vc4: Fix NULL pointer dereference in the async update path Boris Brezillon
2018-11-15 10:58 ` [PATCH v3 2/2] drm/vc4: Set ->legacy_cursor_update to false when doing non-async updates Boris Brezillon
2018-11-15 16:25 ` [PATCH v3 1/2] drm/vc4: Fix NULL pointer dereference in the async update path Eric Anholt
2018-11-15 16:58   ` Boris Brezillon [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=20181115175824.170c16c2@bbrezillon \
    --to=boris.brezillon@bootlin.com \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=eric@anholt.net \
    /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.