Consider invalid peer link type during topology report
Invalid peer links are labeled as N/A during topology report creation.
This invalid link type could be triggered by having a configuration
with CPU XGMI iolinks and disable XGMI peer to peer access. This can
be done by setting the driver parameter 'use_xgmi_p2p = 0'.
Signed-off-by: Alex Sierra <Alex.Sierra@amd.com>
Change-Id: Ifb09a8f3266a3f07686615dfb45781d6cfe55e83
[ROCm/amdsmi commit: 03fab6b2b6]
Этот коммит содержится в:
коммит произвёл
Alex Sierra
родитель
74b423b7f0
Коммит
ca07577907
@@ -2425,6 +2425,8 @@ def showWeightTopology(deviceList):
|
||||
gpu_links_weight[srcdevice][destdevice] = weight
|
||||
else:
|
||||
printErrLog(srcdevice, 'Cannot read Link Weight: Not supported on this machine')
|
||||
gpu_links_weight[srcdevice][destdevice] = None
|
||||
|
||||
|
||||
if PRINT_JSON:
|
||||
formatMatrixToJSON(deviceList, gpu_links_weight, "(Topology) Weight between DRM devices {} and {}")
|
||||
@@ -2441,6 +2443,8 @@ def showWeightTopology(deviceList):
|
||||
for gpu2 in deviceList:
|
||||
if (gpu1 == gpu2):
|
||||
printTableRow('%-12s', '0')
|
||||
elif (gpu_links_weight[gpu1][gpu2] == None):
|
||||
printTableRow('%-12s', 'N/A')
|
||||
else:
|
||||
printTableRow('%-12s', gpu_links_weight[gpu1][gpu2].value)
|
||||
printEmptyLine()
|
||||
@@ -2468,6 +2472,7 @@ def showHopsTopology(deviceList):
|
||||
gpu_links_hops[srcdevice][destdevice] = hops
|
||||
else:
|
||||
printErrLog(srcdevice, 'Cannot read Link Hops: Not supported on this machine')
|
||||
gpu_links_hops[srcdevice][destdevice] = None
|
||||
|
||||
if PRINT_JSON:
|
||||
formatMatrixToJSON(deviceList, gpu_links_hops, "(Topology) Hops between DRM devices {} and {}")
|
||||
@@ -2484,6 +2489,8 @@ def showHopsTopology(deviceList):
|
||||
for gpu2 in deviceList:
|
||||
if (gpu1 == gpu2):
|
||||
printTableRow('%-12s', '0')
|
||||
elif (gpu_links_hops[gpu1][gpu2] == None):
|
||||
printTableRow('%-12s', 'N/A')
|
||||
else:
|
||||
printTableRow('%-12s', gpu_links_hops[gpu1][gpu2].value)
|
||||
printEmptyLine()
|
||||
@@ -2516,6 +2523,8 @@ def showTypeTopology(deviceList):
|
||||
gpu_links_type[srcdevice][destdevice] = "XXXX"
|
||||
else:
|
||||
printErrLog(srcdevice, 'Cannot read Link Type: Not supported on this machine')
|
||||
gpu_links_type[srcdevice][destdevice] = "XXXX"
|
||||
|
||||
if PRINT_JSON:
|
||||
formatMatrixToJSON(deviceList, gpu_links_type, "(Topology) Link type between DRM devices {} and {}")
|
||||
return
|
||||
|
||||
Ссылка в новой задаче
Block a user