summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/i915/i915_gem_gtt.h
diff options
context:
space:
mode:
authorChris Wilson <chris@chris-wilson.co.uk>2018-06-14 19:42:18 +0100
committerChris Wilson <chris@chris-wilson.co.uk>2018-06-14 20:25:54 +0100
commita0fbacb58ce1b5885475d38338b8ad3e8c86e5e9 (patch)
treea31725089a2ad18a0b1b47c091a1e8e81a94b01d /drivers/gpu/drm/i915/i915_gem_gtt.h
parent986dbac4803c7eb2be0d0dac7bc642744502d080 (diff)
downloadlinux-stable-a0fbacb58ce1b5885475d38338b8ad3e8c86e5e9.tar.gz
linux-stable-a0fbacb58ce1b5885475d38338b8ad3e8c86e5e9.tar.bz2
linux-stable-a0fbacb58ce1b5885475d38338b8ad3e8c86e5e9.zip
drm/i915/gtt: Reduce a pair of runtime asserts
We can stop asserting using WARN_ON as given sufficient CI coverage, we can rely on using GEM_BUG_ON() to catch problems before merging. Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Cc: Mika Kuoppala <mika.kuoppala@linux.intel.com> Cc: Matthew Auld <matthew.william.auld@gmail.com> Reviewed-by: Matthew Auld <matthew.william.auld@gmail.com> Link: https://patchwork.freedesktop.org/patch/msgid/20180614184218.1606-2-chris@chris-wilson.co.uk
Diffstat (limited to 'drivers/gpu/drm/i915/i915_gem_gtt.h')
-rw-r--r--drivers/gpu/drm/i915/i915_gem_gtt.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/drivers/gpu/drm/i915/i915_gem_gtt.h b/drivers/gpu/drm/i915/i915_gem_gtt.h
index 7ff5cc612771..9a4824cae68d 100644
--- a/drivers/gpu/drm/i915/i915_gem_gtt.h
+++ b/drivers/gpu/drm/i915/i915_gem_gtt.h
@@ -464,8 +464,8 @@ static inline u32 i915_pte_count(u64 addr, u64 length, unsigned int pde_shift)
const u64 mask = ~((1ULL << pde_shift) - 1);
u64 end;
- WARN_ON(length == 0);
- WARN_ON(offset_in_page(addr|length));
+ GEM_BUG_ON(length == 0);
+ GEM_BUG_ON(offset_in_page(addr | length));
end = addr + length;