diff options
author | Michal Wajdeczko <michal.wajdeczko@intel.com> | 2017-10-24 10:50:56 +0000 |
---|---|---|
committer | Chris Wilson <chris@chris-wilson.co.uk> | 2017-10-26 21:35:21 +0100 |
commit | bad7b7e674cf94775cf86a7c4331bab61d79d7ea (patch) | |
tree | 1e4b83a185fa48ec878407d2275a3afe940ae3af /drivers/gpu/drm | |
parent | c41937fd994a449b4e862826d7eb9f366f6d33e9 (diff) | |
download | linux-stable-bad7b7e674cf94775cf86a7c4331bab61d79d7ea.tar.gz linux-stable-bad7b7e674cf94775cf86a7c4331bab61d79d7ea.tar.bz2 linux-stable-bad7b7e674cf94775cf86a7c4331bab61d79d7ea.zip |
drm/i915/huc: Use helper function while waiting for DMA completion
Waiting for DMA status register can be done with dedicated function.
Lets use it as additional bonus will be smaller driver footprint.
Signed-off-by: Michal Wajdeczko <michal.wajdeczko@intel.com>
Cc: Chris Wilson <chris@chris-wilson.co.uk>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.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/20171024105056.43276-1-michal.wajdeczko@intel.com
Diffstat (limited to 'drivers/gpu/drm')
-rw-r--r-- | drivers/gpu/drm/i915/intel_huc.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/gpu/drm/i915/intel_huc.c b/drivers/gpu/drm/i915/intel_huc.c index c8a48cbc2b7d..98d17254593c 100644 --- a/drivers/gpu/drm/i915/intel_huc.c +++ b/drivers/gpu/drm/i915/intel_huc.c @@ -151,7 +151,7 @@ static int huc_ucode_xfer(struct intel_uc_fw *huc_fw, struct i915_vma *vma) I915_WRITE(DMA_CTRL, _MASKED_BIT_ENABLE(HUC_UKERNEL | START_DMA)); /* Wait for DMA to finish */ - ret = wait_for((I915_READ(DMA_CTRL) & START_DMA) == 0, 100); + ret = intel_wait_for_register_fw(dev_priv, DMA_CTRL, START_DMA, 0, 100); DRM_DEBUG_DRIVER("HuC DMA transfer wait over with ret %d\n", ret); |