Commit 2fa60f6d authored by Mika Kuoppala's avatar Mika Kuoppala Committed by Daniel Vetter

drm/i915: Check workaround status on dfs read time

As the workaround list has the value as initialization time
constant, we can do the simple checking on the go without
negleting igt.
Signed-off-by: default avatarMika Kuoppala <mika.kuoppala@intel.com>
Reviewed-by: default avatarArun Siluvery <arun.siluvery@linux.intel.com>
Signed-off-by: default avatarDaniel Vetter <daniel.vetter@ffwll.ch>
parent 7225342a
...@@ -2657,16 +2657,16 @@ static int i915_wa_registers(struct seq_file *m, void *unused) ...@@ -2657,16 +2657,16 @@ static int i915_wa_registers(struct seq_file *m, void *unused)
seq_printf(m, "Workarounds applied: %d\n", dev_priv->workarounds.count); seq_printf(m, "Workarounds applied: %d\n", dev_priv->workarounds.count);
for (i = 0; i < dev_priv->workarounds.count; ++i) { for (i = 0; i < dev_priv->workarounds.count; ++i) {
u32 addr, mask; u32 addr, mask, value, read;
bool ok;
addr = dev_priv->workarounds.reg[i].addr; addr = dev_priv->workarounds.reg[i].addr;
mask = dev_priv->workarounds.reg[i].mask; mask = dev_priv->workarounds.reg[i].mask;
dev_priv->workarounds.reg[i].value = I915_READ(addr) | mask; value = dev_priv->workarounds.reg[i].value;
if (dev_priv->workarounds.reg[i].addr) read = I915_READ(addr);
seq_printf(m, "0x%X: 0x%08X, mask: 0x%08X\n", ok = (value & mask) == (read & mask);
dev_priv->workarounds.reg[i].addr, seq_printf(m, "0x%X: 0x%08X, mask: 0x%08X, read: 0x%08x, status: %s\n",
dev_priv->workarounds.reg[i].value, addr, value, mask, read, ok ? "OK" : "FAIL");
dev_priv->workarounds.reg[i].mask);
} }
intel_runtime_pm_put(dev_priv); intel_runtime_pm_put(dev_priv);
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment