All of lore.kernel.org
 help / color / mirror / Atom feed
From: Gustavo Padovan <gustavo@padovan.org>
To: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
Cc: dri-devel@lists.freedesktop.org,
	Daniel Vetter <daniel.vetter@ffwll.ch>,
	intel-gfx@lists.freedesktop.org,
	"# v4 . 10+" <stable@vger.kernel.org>,
	Gustavo Padovan <gustavo.padovan@collabora.co.uk>
Subject: Re: [PATCH] drm/atomic: Handle -EDEADLK with out-fences correctly
Date: Fri, 18 Aug 2017 13:59:10 -0300	[thread overview]
Message-ID: <20170818165910.GA16306@jade> (raw)
In-Reply-To: <20170814100721.13340-1-maarten.lankhorst@linux.intel.com>

2017-08-14 Maarten Lankhorst <maarten.lankhorst@linux.intel.com>:

> complete_crtc_signaling is freeing fence_state, but when retrying
> num_fences and fence_state are not zero'd. This caused duplicate
> fd's in the fence_state array, followed by a BUG_ON in fs/file.c
> because we reallocate freed memory, and installing over an existing
> fd, or potential other fun.
> 
> Zero fence_state and num_fences correctly in the retry loop, which
> allows kms_atomic_transition to pass.
> 
> Fixes: beaf5af48034 ("drm/fence: add out-fences support")
> Cc: Gustavo Padovan <gustavo.padovan@collabora.co.uk>
> Cc: Brian Starkey <brian.starkey@arm.com> (v10)
> Cc: Sean Paul <seanpaul@chromium.org>
> Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
> Cc: Jani Nikula <jani.nikula@linux.intel.com>
> Cc: David Airlie <airlied@linux.ie>
> Signed-off-by: Maarten Lankhorst <maarten.lankhorst@linux.intel.com>
> Cc: <stable@vger.kernel.org> # v4.10+
> Testcase: kms_atomic_transitions.plane-all-modeset-transition-fencing
> (with CONFIG_DEBUG_WW_MUTEX_SLOWPATH=y)
> ---
>  drivers/gpu/drm/drm_atomic.c | 6 ++++--
>  1 file changed, 4 insertions(+), 2 deletions(-)

Reviewed-by: Gustavo Padovan <gustavo.padovan@collabora.com>

	Gustavo

  parent reply	other threads:[~2017-08-18 16:59 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2017-08-14 10:07 [PATCH] drm/atomic: Handle -EDEADLK with out-fences correctly Maarten Lankhorst
2017-08-14 10:30 ` ✓ Fi.CI.BAT: success for " Patchwork
2017-08-18 16:59 ` Gustavo Padovan [this message]
2017-08-18 20:13   ` [PATCH] " Daniel Vetter
2017-08-18 20:13     ` Daniel Vetter
2017-08-18 20:14     ` Daniel Vetter
2017-08-18 20:14       ` Daniel Vetter

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=20170818165910.GA16306@jade \
    --to=gustavo@padovan.org \
    --cc=daniel.vetter@ffwll.ch \
    --cc=dri-devel@lists.freedesktop.org \
    --cc=gustavo.padovan@collabora.co.uk \
    --cc=intel-gfx@lists.freedesktop.org \
    --cc=maarten.lankhorst@linux.intel.com \
    --cc=stable@vger.kernel.org \
    /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.