]> git.baikalelectronics.ru Git - kernel.git/commit
drm/i915/gem: Fix a lockdep warning the __i915_gem_is_lmem() function
authorThomas Hellström <thomas.hellstrom@linux.intel.com>
Wed, 22 Sep 2021 08:38:05 +0000 (10:38 +0200)
committerThomas Hellström <thomas.hellstrom@linux.intel.com>
Fri, 24 Sep 2021 06:17:39 +0000 (08:17 +0200)
commitac4db814d0646b672e03d23e7e152d5673e1d3c0
tree7b7765e125d3215a14ac282194ad8bac2a1df312
parent9aa728a2e66e5d7a24e9760ee28072be908d8f7e
drm/i915/gem: Fix a lockdep warning the __i915_gem_is_lmem() function

Somehow we managed to invert the test for i915_gem_object_evictable(),
which causes a warning in DG1 BAT, igt@debugfs_test@read_all_entries.

Fix the lock check to only warn if the object *is* indeed evictable and
not protected from eviction by fences.

Cc: Matthew Brost <matthew.brost@intel.com>
Fixes: cb49e73f6841 ("drm/i915: Take pinning into account in __i915_gem_object_is_lmem")
Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Reviewed-by: Matthew Auld <matthew.auld@intel.com>
Link: https://patchwork.freedesktop.org/patch/msgid/20210922083807.888206-2-thomas.hellstrom@linux.intel.com
drivers/gpu/drm/i915/gem/i915_gem_lmem.c