Commit f1008370 authored by Oak Zeng's avatar Oak Zeng Committed by Alex Deucher

drm/amdgpu: fix compile error on architecture s390 (v2)

ioremap_cache is not supported on some architecture
such as s390. Put the codes into a #ifdef to fix
some compile error reported by test robot.

v2: squash in non-x86 fix
Signed-off-by: default avatarOak Zeng <Oak.Zeng@amd.com>
Reported-by: default avatarKernel test robot <lkp@intel.com>
Reviewed-by: default avatarChristian Konig <christian.koenig@amd.com>
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
parent 6dffd9dc
......@@ -1818,11 +1818,13 @@ int amdgpu_ttm_init(struct amdgpu_device *adev)
/* Change the size here instead of the init above so only lpfn is affected */
amdgpu_ttm_set_buffer_funcs_status(adev, false);
#ifdef CONFIG_64BIT
#ifdef CONFIG_X86
if (adev->gmc.xgmi.connected_to_cpu)
adev->mman.aper_base_kaddr = ioremap_cache(adev->gmc.aper_base,
adev->gmc.visible_vram_size);
else
#endif
adev->mman.aper_base_kaddr = ioremap_wc(adev->gmc.aper_base,
adev->gmc.visible_vram_size);
#endif
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment