Quoting Michał Winiarski (2017-12-11 15:15:20) > After GPU reset, GuC HW needs to be reinitialized (with FW reload). > Unfortunately, we're doing some extra work there (mostly allocating stuff), > work that can be moved to guc_init and called once at driver load time. > > As a side effect we're no longer hitting an assert in > i915_ggtt_enable_guc on suspend/resume. > > References: 04f7b24eccdf ("drm/i915/guc: Assert that we switch between known ggtt->invalidate functions") > Signed-off-by: Michał Winiarski <michal.winiarski@xxxxxxxxx> > Cc: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> > Cc: Joonas Lahtinen <joonas.lahtinen@xxxxxxxxxxxxxxx> > Cc: Michal Wajdeczko <michal.wajdeczko@xxxxxxxxx> > Cc: Sagar Arun Kamble <sagar.a.kamble@xxxxxxxxx> > --- > @@ -241,10 +238,44 @@ int intel_uc_init_hw(struct drm_i915_private *dev_priv) > * if we are planning to enable submission later > */ > ret = intel_guc_submission_init(guc); > - if (ret) > - goto err_guc; > + if (ret) { > + intel_guc_fini(guc); > + return ret; > + } > } > > + return 0; > +} > + > +void intel_uc_fini(struct drm_i915_private *dev_priv) I have a fondness for laying out the code in roughly the order it should be used in the API, quite often reverse order to keep forward decls to a minimum. Looks like it is a clean split and does what you say on the tin, Reviewed-by: Chris Wilson <chris@xxxxxxxxxxxxxxxxxx> -Chris _______________________________________________ Intel-gfx mailing list Intel-gfx@xxxxxxxxxxxxxxxxxxxxx https://lists.freedesktop.org/mailman/listinfo/intel-gfx