All of lore.kernel.org
 help / color / mirror / Atom feed
From: Daniel Vetter <daniel@ffwll.ch>
To: Chris Wilson <chris@chris-wilson.co.uk>,
	Daniel Vetter <daniel@ffwll.ch>, Ben Widawsky <ben@bwidawsk.net>,
	intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915: Rework GPU reset sequence to match driver load & thaw
Date: Tue, 29 Jul 2014 12:32:42 +0200	[thread overview]
Message-ID: <20140729103242.GN4747@phenom.ffwll.local> (raw)
In-Reply-To: <20140729073633.GC21570@nuc-i3427.alporthouse.com>

On Tue, Jul 29, 2014 at 08:36:33AM +0100, Chris Wilson wrote:
> On Mon, Jul 28, 2014 at 11:26:38AM +0200, Daniel Vetter wrote:
> > Oh, I guess that's the tricky bit why the old approach never worked -
> > because reset_in_progress is set we failed the context/ppgtt loading
> > through the rings and screwed up.
> > 
> > Problem with your approach is that we want to bail out here if a reset is
> > in progress, so we can't just eat the EAGAIN. If we do that we potentially
> > deadlock or overflow the ring.
> > 
> > I think we need a different hack here, and a few layers down (i.e. at the
> > place where we actually generate that offending -EAGAIN).
> > 
> > - Around the re-init sequence in the reset function we set
> >   dev_priv->mm.reload_in_reset or similar. Since we hold dev->struct_mutex
> >   no one will see that, as long as we never leak it out of the critical
> >   section.
> > 
> > - In the ring_begin code that checks for gpu hangs we ignore
> >   reset_in_progress if this bit is set.
> > 
> > - Both places need fairly big comments to explain what exactly is going
> >   on.
> 
> This is going from bad to worse. I think you can do better if you looked
> at the problem afresh.

Well we can't really reset reset_in_progress at that point, since not all
reset is done yet. Especially the modeset stuff. So I don't think that
reordering the reset sequence would get us out of this ugly spot. And I
don't see any other solution really. Do you?
-Daniel
-- 
Daniel Vetter
Software Engineer, Intel Corporation
+41 (0) 79 365 57 48 - http://blog.ffwll.ch

  reply	other threads:[~2014-07-29 10:32 UTC|newest]

Thread overview: 30+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2014-07-16 15:05 [PATCH] drm/i915: Rework GPU reset sequence to match driver load & thaw alistair.mcaulay
2014-07-26  1:05 ` Ben Widawsky
2014-07-28  9:26   ` Daniel Vetter
2014-07-28 17:12     ` Mcaulay, Alistair
2014-07-29  0:16       ` Ben Widawsky
2014-07-29 17:25         ` Mcaulay, Alistair
2014-07-29 18:12           ` Daniel Vetter
2014-07-29  7:36     ` Chris Wilson
2014-07-29 10:32       ` Daniel Vetter [this message]
2014-07-30 16:59         ` Mcaulay, Alistair
2014-07-30 21:00           ` Daniel Vetter
2014-07-31 16:37             ` Mcaulay, Alistair
2014-08-04  7:52               ` Daniel Vetter
2014-08-05  8:47 ` [PATCH v2] " alistair.mcaulay
2014-08-06 12:58   ` Mcaulay, Alistair
2014-08-06 16:24   ` Mika Kuoppala
2014-08-15 13:33     ` Mcaulay, Alistair
2014-08-15 15:41       ` Daniel Vetter
2014-08-15 17:03       ` Mika Kuoppala
2014-08-15 17:51         ` [PATCH v3] " alistair.mcaulay
2014-08-19 10:12           ` Mcaulay, Alistair
2014-08-19 12:35             ` Mika Kuoppala
2014-08-21 12:38               ` Mcaulay, Alistair
2014-08-25 20:28                 ` Daniel Vetter
2014-08-20 14:46           ` Daniel, Thomas
2014-08-20 14:58             ` Chris Wilson
2014-08-20 15:21               ` Mcaulay, Alistair
2014-08-20 15:56                 ` Chris Wilson
2014-08-25 20:18                   ` Daniel Vetter
2014-08-26  6:09                     ` Chris Wilson

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=20140729103242.GN4747@phenom.ffwll.local \
    --to=daniel@ffwll.ch \
    --cc=ben@bwidawsk.net \
    --cc=chris@chris-wilson.co.uk \
    --cc=intel-gfx@lists.freedesktop.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.