drm/i915/guc: Create vfuncs for the GuC interrupts control functions
Controlling and handling of the GuC interrupts is Gen specific. Create virtual functions to avoid redundant runtime Gen checks. Gen-specific versions of these functions will follow. v2: move vfuncs to struct guc (Daniele) v3: rebased Signed-off-by: Oscar Mateo <oscar.mateo@intel.com> Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com> Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> Cc: Tvrtko Ursulin <tvrtko.ursulin@intel.com> Cc: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> Reviewed-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com> Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk> Link: https://patchwork.freedesktop.org/patch/msgid/20190527183613.17076-12-michal.wajdeczko@intel.com
此提交包含在:
@@ -218,11 +218,26 @@ static void guc_free_load_err_log(struct intel_guc *guc)
|
||||
i915_gem_object_put(guc->load_err_log);
|
||||
}
|
||||
|
||||
static void guc_reset_interrupts(struct intel_guc *guc)
|
||||
{
|
||||
guc->interrupts.reset(guc_to_i915(guc));
|
||||
}
|
||||
|
||||
static void guc_enable_interrupts(struct intel_guc *guc)
|
||||
{
|
||||
guc->interrupts.enable(guc_to_i915(guc));
|
||||
}
|
||||
|
||||
static void guc_disable_interrupts(struct intel_guc *guc)
|
||||
{
|
||||
guc->interrupts.disable(guc_to_i915(guc));
|
||||
}
|
||||
|
||||
static int guc_enable_communication(struct intel_guc *guc)
|
||||
{
|
||||
struct drm_i915_private *i915 = guc_to_i915(guc);
|
||||
|
||||
gen9_enable_guc_interrupts(i915);
|
||||
guc_enable_interrupts(guc);
|
||||
|
||||
if (HAS_GUC_CT(i915))
|
||||
return intel_guc_ct_enable(&guc->ct);
|
||||
@@ -250,7 +265,7 @@ static void guc_disable_communication(struct intel_guc *guc)
|
||||
if (HAS_GUC_CT(i915))
|
||||
intel_guc_ct_disable(&guc->ct);
|
||||
|
||||
gen9_disable_guc_interrupts(i915);
|
||||
guc_disable_interrupts(guc);
|
||||
|
||||
guc->send = intel_guc_send_nop;
|
||||
guc->handler = intel_guc_to_host_event_handler_nop;
|
||||
@@ -391,7 +406,7 @@ int intel_uc_init_hw(struct drm_i915_private *i915)
|
||||
|
||||
GEM_BUG_ON(!HAS_GUC(i915));
|
||||
|
||||
gen9_reset_guc_interrupts(i915);
|
||||
guc_reset_interrupts(guc);
|
||||
|
||||
/* WaEnableuKernelHeaderValidFix:skl */
|
||||
/* WaEnableGuCBootHashCheckNotSet:skl,bxt,kbl */
|
||||
|
新增問題並參考
封鎖使用者