]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915: Simplify i915_gem_release_all_mmaps()
authorChris Wilson <chris@chris-wilson.co.uk>
Mon, 16 Jun 2014 07:57:44 +0000 (08:57 +0100)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Mon, 16 Jun 2014 17:52:20 +0000 (19:52 +0200)
commit0ef3988a7fd8882e65a84181a5f12ee1f64e3faa
tree6c6f5517f445cb153f6622fd62170e9142d574f3
parent7318b4bda80211b75b2de5b389eaedc590dbc5d3
drm/i915: Simplify i915_gem_release_all_mmaps()

An object can only have an active gtt mapping if it is currently bound
into the global gtt. Therefore we can simply walk the list of all bound
objects and check the flag upon those for an active gtt mapping.

From commit ec08c5309ac23b83f9f568504511fc10e1721b31
Author: Paulo Zanoni <paulo.r.zanoni@intel.com>
Date:   Fri Dec 13 15:22:31 2013 -0200

    drm/i915: release the GTT mmaps when going into D3

Also note that the WARN is inappropriate for this function as GPU
activity is orthogonal to GTT mmap status. Rather it is the caller that
relies upon this condition and so it should assert that the GPU is idle
itself.

References: https://bugs.freedesktop.org/show_bug.cgi?id=80081
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Paulo Zanoni <paulo.r.zanoni@intel.com>
Cc: Rodrigo Vivi <rodrigo.vivi@gmail.com>
Cc: Daniel Vetter <daniel.vetter@ffwll.ch>
Reviewed-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Tested-by: Paulo Zanoni <paulo.r.zanoni@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/i915_gem.c