drm/amdgpu: define address map for host xgmi link (v3)
authorRajneesh Bhardwaj <rajneesh.bhardwaj@amd.com>
Wed, 21 Oct 2020 06:12:11 +0000 (14:12 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 24 Mar 2021 02:52:48 +0000 (22:52 -0400)
commit31691b8d1be4383f42d49de1f1393818470dcadc
treed40ff2e684b43c224b46b39528a4bcade3d26801
parentefce10005be4023e23ed51fe1c2e8380d5fe62d4
drm/amdgpu: define address map for host xgmi link (v3)

This applies to AMD Accelerated Processing Platforms that support host
gpu interconnect throguh a special link (xgmi). Aldebaran systems will
support this special feature for utilizing the benefits of host-gpu
cache coherence. This change outlines the basic framework for mapping
the GPU VRAM (HBM) to system address space making it accesible to the
host but managed by the amdgpu driver since this region is marked as
reserved memory in host address space by the underlying system firmware.

v2: switch to smuio callback function to check the type
of host-gpu interface (Hawking)
v3: use hub callbacks rather than direct function calls (Alex)

Reviewed-by: Oak Zeng <oak.zeng@amd.com>
Reviewed-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Rajneesh Bhardwaj <rajneesh.bhardwaj@amd.com>
Signed-off-by: Hawking Zhang <Hawking.Zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_gmc.h
drivers/gpu/drm/amd/amdgpu/gmc_v9_0.c
drivers/gpu/drm/amd/amdgpu/soc15.c