drm/i915/guc: Do not partition WOPCM if GuC is not used

There seems to be no reason for doing extra work on WOPCM partitioning
in the case GuC is not used, as the partitioning will not be used by the
intel_wopcm_init_hw function anyway.

Signed-off-by: Jakub Bartmiński <jakub.bartminski@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Michał Winiarski <michal.winiarski@intel.com>
Cc: Michal Wajdeczko <michal.wajdeczko@intel.com>
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/20180727141148.30874-2-jakub.bartminski@intel.com
This commit is contained in:
Jakub Bartmiński 2018-07-27 16:11:44 +02:00 committed by Chris Wilson
parent 9936ef55f2
commit b6445e1779
1 changed files with 3 additions and 0 deletions

View File

@ -163,6 +163,9 @@ int intel_wopcm_init(struct intel_wopcm *wopcm)
u32 guc_wopcm_rsvd;
int err;
if (!USES_GUC(dev_priv))
return 0;
GEM_BUG_ON(!wopcm->size);
if (guc_fw_size >= wopcm->size) {