diff options
author | Arkadiusz Hiler <arkadiusz.hiler@intel.com> | 2017-03-14 15:28:13 +0100 |
---|---|---|
committer | Joonas Lahtinen <joonas.lahtinen@linux.intel.com> | 2017-03-15 14:26:30 +0200 |
commit | b551f610b36e3f04d6e583cd732cb8805fe86b87 (patch) | |
tree | ac355ab0014e27a600ce91897bb4e629f9da8ffb /drivers/gpu/drm/i915/intel_huc.c | |
parent | 8fc2a4e427991433ea6358117fdbcc07494ff8c5 (diff) | |
download | op-kernel-dev-b551f610b36e3f04d6e583cd732cb8805fe86b87.zip op-kernel-dev-b551f610b36e3f04d6e583cd732cb8805fe86b87.tar.gz |
drm/i915/uc: Separate firmware selection and preparation
intel_{h,g}uc_init_fw selects correct firmware and then triggers it's
preparation (fetch + initial parsing).
This change separates out select steps, so those can be called by
the sanitize_options().
Then, during the init_fw(), we prepare the firmware if the firmware was
selected.
Cc: Michal Winiarski <michal.winiarski@intel.com>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Signed-off-by: Arkadiusz Hiler <arkadiusz.hiler@intel.com>
Reviewed-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Signed-off-by: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Diffstat (limited to 'drivers/gpu/drm/i915/intel_huc.c')
-rw-r--r-- | drivers/gpu/drm/i915/intel_huc.c | 14 |
1 files changed, 2 insertions, 12 deletions
diff --git a/drivers/gpu/drm/i915/intel_huc.c b/drivers/gpu/drm/i915/intel_huc.c index 5fadd55..ea67abc 100644 --- a/drivers/gpu/drm/i915/intel_huc.c +++ b/drivers/gpu/drm/i915/intel_huc.c @@ -141,18 +141,10 @@ static int huc_ucode_xfer(struct drm_i915_private *dev_priv) } /** - * intel_huc_init_fw() - select and prepare firmware for loading + * intel_huc_select_fw() - selects HuC firmware for loading * @huc: intel_huc struct - * - * Called early during driver load, but after GEM is initialised. The loading - * will continue only when driver explicitly specify firmware name and version. - * All other cases are considered as INTEL_UC_FIRMWARE_NONE either because HW - * is not capable or driver yet support it. And there will be no error message - * for INTEL_UC_FIRMWARE_NONE cases. - * - * The DMA-copying to HW is done later when intel_huc_init_hw() is called. */ -void intel_huc_init_fw(struct intel_huc *huc) +void intel_huc_select_fw(struct intel_huc *huc) { struct drm_i915_private *dev_priv = huc_to_i915(huc); @@ -177,8 +169,6 @@ void intel_huc_init_fw(struct intel_huc *huc) DRM_ERROR("No HuC firmware known for platform with HuC!\n"); return; } - - intel_uc_prepare_fw(dev_priv, &huc->fw); } /** |