drm/i915/uc: Sanitize uC options early
authorMichal Wajdeczko <michal.wajdeczko@intel.com>
Mon, 12 Mar 2018 13:03:06 +0000 (13:03 +0000)
committerChris Wilson <chris@chris-wilson.co.uk>
Mon, 12 Mar 2018 22:06:19 +0000 (22:06 +0000)
commit3c33fc7c1af9a3426eff9015e5bab08a21a5fa9d
tree544a828057d9c44dfd09666a98bb7be63b917d33
parent6f9ec414ec47eea3f3e2c5ad4c67b4265bbff2a3
drm/i915/uc: Sanitize uC options early

We are sanitizing uC related modparams together with other driver
modparams in intel_sanitize_options called from i915_driver_init_hw,
but this is too late for us as we will want to use USES_GUC/USES_HUC
macros at earlier stage. Since our sanitizing does not require any
MMIO access, we can do it in intel_uc_init_early right after we resolve
firmware names.

Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Cc: Sagar Arun Kamble <sagar.a.kamble@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Reviewed-by: Chris Wilson <chris@chris-wilson.co.uk>
Signed-off-by: Chris Wilson <chris@chris-wilson.co.uk>
Link: https://patchwork.freedesktop.org/patch/msgid/20180312130308.22952-2-michal.wajdeczko@intel.com
drivers/gpu/drm/i915/i915_drv.c
drivers/gpu/drm/i915/intel_uc.c
drivers/gpu/drm/i915/intel_uc.h