From: Ben Widawsky <ben@bwidawsk.net>
To: Chris Wilson <chris@chris-wilson.co.uk>
Cc: intel-gfx@lists.freedesktop.org
Subject: Re: [PATCH] drm/i915: hangcheck timeout for debugfs
Date: Sat, 25 Jun 2011 17:20:11 -0700 [thread overview]
Message-ID: <20110626002011.GD9413@snipes.kumite> (raw)
In-Reply-To: <e0d58a$h7iq4@orsmga002.jf.intel.com>
On Sat, Jun 25, 2011 at 10:23:28AM +0100, Chris Wilson wrote:
> On Fri, 24 Jun 2011 08:46:53 -0700, Ben Widawsky <ben@bwidawsk.net> wrote:
> > On Fri, Jun 24, 2011 at 12:48:22AM +0100, Chris Wilson wrote:
> > > On Thu, 23 Jun 2011 15:49:14 -0700, Ben Widawsky <ben@bwidawsk.net> wrote:
> > > > Provide a user accessible way to change the hangcheck timer. This is
> > > > useful mostly for disabling the timer completely (value <= 0).
> > >
> > > Having i915.hangcheck_interval as a read/write module parameter was
> > > better. :-p
> > > -Chris
> >
> > I considered this, but I wasn't sure how to manage the sysfs parameters,
> > and prevent users from doing stupid things. Furthermore, I think to be
> > correct we must delete sync the timer if the user requests an interval
> > of 0, and we can only do that if we have struct mutex (again the sysfs
> > problem).
>
> You can either register a callback for when the parameter changes, but in
> this case it is as easy as deleting the timer in the next hangcheck before
> touching any GPU state. In that scenario the timer will only be enabled
> again after the next execbuffers, that's a restriction I can live with for
> simple code and keeping parameters out of debugfs.
>
> On the other hand, a debugfs would allow for a per-device parameter. For
> that day in the far far future with multiprocessor igfx. Surreal isn't it?
> -Chris
So what's the verdict? In term of LOC, your suggestion would probably be
smaller, but in terms of complexity I actually think the current patch
would be easier to understand, although to be fair, I didn't actually
try coding it to see.
If you feel strongly about a module parameter being the better solution,
I will code it up.
Ben
next prev parent reply other threads:[~2011-06-26 0:20 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2011-06-23 22:49 [PATCH] drm/i915: hangcheck timeout for debugfs Ben Widawsky
2011-06-23 23:48 ` Chris Wilson
2011-06-24 15:46 ` Ben Widawsky
2011-06-25 9:23 ` Chris Wilson
2011-06-26 0:20 ` Ben Widawsky [this message]
2011-06-26 8:38 ` 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=20110626002011.GD9413@snipes.kumite \
--to=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.