drm/i915/guc: Use guc_class instead of engine_class in fw interface
authorDaniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Thu, 3 Jun 2021 05:16:30 +0000 (22:16 -0700)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Fri, 4 Jun 2021 08:42:41 +0000 (10:42 +0200)
commit84bdf4571d4dc36207bbc4b0fb2711723ee313d4
tree4b533d2344f0d0d883787f3bf1419b00ef629b42
parente09be87af54f703a67f6b573f6a12b8349c5c8f5
drm/i915/guc: Use guc_class instead of engine_class in fw interface

GuC has its own defines for the engine classes. They're currently
mapping 1:1 to the defines used by the driver, but there is no guarantee
this will continue in the future. Given that we've been caught off-guard
in the past by similar divergences, we can prepare for the changes by
introducing helper functions to convert from engine class to GuC class and
back again.

Signed-off-by: Daniele Ceraolo Spurio <daniele.ceraolospurio@intel.com>
Signed-off-by: Matthew Brost <matthew.brost@intel.com>
Reviewed-by: Matthew Brost <matthew.brost@intel.com>
Cc: John Harrison <John.C.Harrison@Intel.com>
Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
Link: https://patchwork.freedesktop.org/patch/msgid/20210603051630.2635-21-matthew.brost@intel.com
drivers/gpu/drm/i915/gt/intel_engine_cs.c
drivers/gpu/drm/i915/gt/uc/intel_guc_ads.c
drivers/gpu/drm/i915/gt/uc/intel_guc_fwif.h