[Intel-gfx] [PATCH 2/2] drm/i915: Test all fw tables during mock selftests
Chris Wilson
chris at chris-wilson.co.uk
Thu Dec 8 22:29:51 UTC 2016
On Thu, Dec 08, 2016 at 04:52:24PM +0000, Tvrtko Ursulin wrote:
> Idea for another late test:
>
> for (offset = 0; offset < 0x40000; offset++) {
> fw_domain = intel_uncore_forcewake_for_reg(dev_priv, { .reg =
> offset }, FW_REG_READ | FW_REG_WRITE);
> if (WARN_ON(fw_domain & ~dev_priv->uncore.fw_domains))
> return -EINVAL;
> }
>
> And then we could convert the existing related WARNs in the live
> code base to GEM_WARN_ONs.
I liked it enough to type something up... However, isn't the argument
for skipping some fw_domains that the associated register banks are
invalid/absent on those platforms? i.e. we can't simply walk
for (offset = 0; NEEDS_FORCE_WAKE(offset); offset++)
and expect every offset to correspond to a register (and so need a
covering fw_domain)?
-Chris
--
Chris Wilson, Intel Open Source Technology Centre
More information about the Intel-gfx
mailing list