[Intel-gfx] [PATCH] drm/i915: Waterproof verification of gen9 forcewake table ranges

Tvrtko Ursulin tursulin at ursulin.net
Thu Nov 17 13:13:55 UTC 2016


From: Tvrtko Ursulin <tvrtko.ursulin at intel.com>

We have to make sure there are no holes in the table in Gen9.

Signed-off-by: Tvrtko Ursulin <tvrtko.ursulin at intel.com>
Suggested-by: Chris Wilson <chris at chris-wilson.co.uk>
Cc: Chris Wilson <chris at chris-wilson.co.uk>
---
 drivers/gpu/drm/i915/intel_uncore.c | 2 ++
 1 file changed, 2 insertions(+)

diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c
index a0944dde7c41..deb8e9e6f9ea 100644
--- a/drivers/gpu/drm/i915/intel_uncore.c
+++ b/drivers/gpu/drm/i915/intel_uncore.c
@@ -647,6 +647,8 @@ intel_fw_table_check(struct drm_i915_private *dev_priv)
 	num_ranges = dev_priv->uncore.fw_domains_table_entries;
 
 	for (i = 0, prev = -1; i < num_ranges; i++, ranges++) {
+		WARN_ON_ONCE(IS_GEN9(dev_priv) &&
+			     (prev + 1) != (s32)ranges->start);
 		WARN_ON_ONCE(prev >= (s32)ranges->start);
 		prev = ranges->start;
 		WARN_ON_ONCE(prev >= (s32)ranges->end);
-- 
2.7.4



More information about the Intel-gfx mailing list