]> git.baikalelectronics.ru Git - kernel.git/commit
drm/amdgpu: get extended xgmi topology data
authorJonathan Kim <jonathan.kim@amd.com>
Tue, 3 Aug 2021 23:01:55 +0000 (19:01 -0400)
committerAlex Deucher <alexander.deucher@amd.com>
Wed, 18 Aug 2021 22:22:24 +0000 (18:22 -0400)
commit2c941910b572f640e8b13ee440c15be52212c69c
tree2cce7ef66e40d8c3652cdb4470c0fa6b5656ec54
parentcdc2a5e09ef9057de7731721e3e362834b945784
drm/amdgpu: get extended xgmi topology data

The TA has a limit to the amount of data that can be retrieved from
GET_TOPOLOGY.  For setups that exceed this limit, the xGMI topology
needs to be re-initialized and data needs to be re-fetched from the
extended link records by setting a flag in the shared command buffer.

The number of hops and the number of links must be accumulated by the
driver. Other data points are all fetched from the first request.
Because the TA has already exceeded its link record limit, it
cannot hold bidirectional information.  Otherwise the driver would
have to do more than two fetches so the driver has to reflect the
topology information in the opposite direction.

v2: squashed with internal reviewed fix

Signed-off-by: Jonathan Kim <jonathan.kim@amd.com>
Reviewed-by: Hawking Zhang <hawking.zhang@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_psp.c
drivers/gpu/drm/amd/amdgpu/amdgpu_psp.h
drivers/gpu/drm/amd/amdgpu/amdgpu_xgmi.c
drivers/gpu/drm/amd/amdgpu/ta_xgmi_if.h