]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Only unpin the default ctx object if it exists
authorChris Wilson <chris@chris-wilson.co.uk>
Fri, 16 May 2014 17:59:00 +0000 (18:59 +0100)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Fri, 16 May 2014 19:41:12 +0000 (21:41 +0200)
commit22682dfdb01217d4954a76be30dcd8b9cf62165a
tree5b734d8d90c333038b08653cd330774f18a6f080
parent3c7ff864d4fa6f6d42e8b1a227f5cdc58c992ea2
drm/i915: Only unpin the default ctx object if it exists

Since commit a17f53d6e8cd4502886a470d434e3e52fa25ef06
Author: Chris Wilson <chris@chris-wilson.co.uk>
Date:   Wed Apr 9 09:07:36 2014 +0100

    drm/i915: Always use kref tracking for all contexts.

we have contexts everywhere, and so we must be careful to distinguish
fake contexts, which do not have an associated bo, and real ones, which
do. In particular, we now need to be careful not to dereference NULL
pointers.

This is one such example, as the commit highlighted above failed to move
the unpinning of the default ctx object into the real-context-only
branch.

Reported-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Bugzilla: https://bugs.freedesktop.org/show_bug.cgi?id=78792
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Cc: Ben Widawsky <benjamin.widawsky@intel.com>
Cc: Mika Kuoppala <mika.kuoppala@intel.com>
Cc: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_gem_context.c