From: Christian König Date: Tue, 23 Aug 2016 09:18:59 +0000 (+0200) Subject: drm/amdgpu: use memcpy_toio for VCE firmware upload X-Git-Tag: MMI-PSA29.97-13-9~6932^2~37^2 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=7b4d3e297e8a7d3b82e68231ff077e891c370349;p=GitHub%2FMotorolaMobilityLLC%2Fkernel-slsi.git drm/amdgpu: use memcpy_toio for VCE firmware upload Try to be clean here, even when it's a noop on x86. Signed-off-by: Christian König Reviewed-by: Alex Deucher Signed-off-by: Alex Deucher --- diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c index 05865ce35351..da52af2a935a 100644 --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vce.c @@ -282,8 +282,8 @@ int amdgpu_vce_resume(struct amdgpu_device *adev) hdr = (const struct common_firmware_header *)adev->vce.fw->data; offset = le32_to_cpu(hdr->ucode_array_offset_bytes); - memcpy(cpu_addr, (adev->vce.fw->data) + offset, - (adev->vce.fw->size) - offset); + memcpy_toio(cpu_addr, adev->vce.fw->data + offset, + adev->vce.fw->size - offset); amdgpu_bo_kunmap(adev->vce.vcpu_bo);