[Intel-gfx] Patch for crashing intel server

Chris Wilson chris at chris-wilson.co.uk
Tue Oct 15 10:25:41 CEST 2013

On Tue, Oct 15, 2013 at 03:46:08AM +0200, Bas Wijnen wrote:
> On Sun, Oct 13, 2013 at 10:43:49AM +0100, Chris Wilson wrote:
> > > > > My X server was crashing when playing video, and I wrote a patch to fix
> > > > > it.  Please find the background and the patch at
> > > > > http://bugs.debian.org/724944 .
> > 
> > Ok, I can see the allocation failure that leads to the crash:
> > 
> > commit f9a18c9f38d09c145eb513ca989966dc135c1e9b
> > Author: Chris Wilson <chris at chris-wilson.co.uk>
> > Date:   Sun Oct 13 10:36:35 2013 +0100
> This does indeed stop the server from crashing, but actually makes the
> problem worse: it used to play video for a few minutes and then crash
> when trying.  With my patch it would play video for a few minutes and
> then present black screens when trying.  With your patch, it presents
> black screens from the start.

Start of video, or beginning of X?

I made two changes. The first to check for a failed GPU pixmap
allocation during video playback and the second to check for a failed
malloc during Screen initialisation.

Neither should be likely.
> I must say I'm not entirely sure if the backtrace I sent you is a
> "typical" case; I managed to crash it sooner than usual, so perhaps it
> wasn't the bug that I triggered before.  It did stop the crashing
> however.
> > However, that still leaveas the question as to how you ended up being
> > unable to allocate bo...
> > 
> > You can watch /sys/kernel/debug/dri/0/i915_gem_objects (or just use
> > intel-gpu-overlay) and see if there is an object leak.
> I don't have enough knowledge about the internals to know how that
> works.  I can see the file if I mount the debugfs, but what am I looking
> for?

An increase in the number of total objects and allocated bytes.
> I don't seem to have intel-gpu-overlay on my system; does it make sense
> to install it?  If so, where do I get it?

It just presents the same information, so not really important if you
are happy with catting the debugfs file.
> While looking for it I did find and try intel-gpu-time, and noticed that
> it always reports the gpu 100% busy, even when running intel-gpu-time
> sleep 5 from a linux virtual terminal (so not even X is displayed).  Is
> that normal?

Hmm, looks like it should report correctly on i915.

Chris Wilson, Intel Open Source Technology Centre

More information about the Intel-gfx mailing list