Quoting Mika Kuoppala (2018-09-04 13:56:07) > Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> writes: > > > Quoting Chris Wilson (2018-09-04 13:38:27) > >> Quoting Mika Kuoppala (2018-09-04 13:34:12) > >> > Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> writes: > >> > > >> > > Currently, if the user has enabled mmio-debug around each register > >> > > access, we presume that we have then checked them all. However, it is > >> > > still possible through omission (raw register access) or external > >> > > interaction that the unclaimed access was not highlighted. > >> > > > >> > > Signed-off-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> > >> > > Cc: Mika Kuoppala <mika.kuoppala@xxxxxxxxxxxxxxx> > >> > > --- > >> > > drivers/gpu/drm/i915/intel_uncore.c | 13 +++++++------ > >> > > 1 file changed, 7 insertions(+), 6 deletions(-) > >> > > > >> > > diff --git a/drivers/gpu/drm/i915/intel_uncore.c b/drivers/gpu/drm/i915/intel_uncore.c > >> > > index 20f2f5ad9c3f..05f0cda18501 100644 > >> > > --- a/drivers/gpu/drm/i915/intel_uncore.c > >> > > +++ b/drivers/gpu/drm/i915/intel_uncore.c > >> > > @@ -2283,15 +2283,16 @@ bool intel_uncore_unclaimed_mmio(struct drm_i915_private *dev_priv) > >> > > bool > >> > > intel_uncore_arm_unclaimed_mmio_detection(struct drm_i915_private *dev_priv) > >> > > { > >> > > - if (unlikely(i915_modparams.mmio_debug || > >> > > - dev_priv->uncore.unclaimed_mmio_check <= 0)) > >> > > + if (unlikely(dev_priv->uncore.unclaimed_mmio_check <= 0)) > >> > > return false; > >> > > > >> > > >> > We could catch the readers attention by marking this as READ_ONCE. > >> > > >> > > >> > And then take spinlock here before checking for unclaimed. > >> > >> Could do, feels like overkill, but not contentious. > > > > Implied here, is improving unclaimed_mmio_check a fundamental > > requirement for this patch or additional work? I think the latter. > > Additional work. Was just thinking aloud about the > possible races in this area. > > Patch does what it says. > > Reviewed-by: Mika Kuoppala <mika.kuoppala@xxxxxxxxxxxxxxx> Plonked itin . When I remember, I'll rerun the mmio-debugging patch for pm_rpm/module-reload and see what happens now. -Chris _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx