Re: [PATCH 1/2] drm/i915: Stop engines around GPU reset preparations

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> writes:

> Quoting Mika Kuoppala (2018-03-02 11:50:32)
>> Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> writes:
>> > +static void i915_engines_set_mode(struct drm_i915_private *dev_priv,
>> > +                               unsigned engine_mask,
>> > +                               u32 mode)
>> > +{
>> > +     struct intel_engine_cs *engine;
>> > +     enum intel_engine_id id;
>> > +
>> > +     if (INTEL_GEN(dev_priv) < 3)
>> > +             return;
>> > +
>> > +     for_each_engine_masked(engine, dev_priv, engine_mask, id)
>> > +             I915_WRITE_FW(RING_MI_MODE(engine->mmio_base), mode);
>> 
>> Is there reason to not use gen3_stop_engine in this level?
>
> It clears HEAD/TAIL, so undoing it in the case of no reset is a bit more
> tricky.

With this we now have 3 different flavours of stopping an engine.

I would like to see early on prepare reset to call engine->stop(),
which would be unified way of bring engine to halt. And limit
any further restoration of state if we can't really manage to reset it,
leaving it as stopped and dormant as we possibly could get it.

Then only on successful reset and restoration of init state, we would
have an engine->start().

But as this does stop the engine early on it is an improvement,
Reviewed-by: Mika Kuoppala <mika.kuoppala@xxxxxxxxxxxxxxx>
_______________________________________________
Intel-gfx mailing list
Intel-gfx@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/intel-gfx




[Index of Archives]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]
  Powered by Linux