SWDEV-464927 - Update the Get by PCI BusId logic and Hop count

- Update the intra socket weight for partitions within single socket as
it is changed to 13 by the driver.
- Use the PCIe function to distinguish the partitions of the same device
such as TPX mode in gfx942.

Change-Id: I8e64023d44e37c2dbb105cbb343441a48021ba7b
Cette révision appartient à :
Satyanvesh Dittakavi
2024-06-06 08:34:09 +00:00
Parent 8f42ad6aa3
révision 1815fc808d
2 fichiers modifiés avec 8 ajouts et 4 suppressions
+1 -1
Voir le fichier
@@ -3356,7 +3356,7 @@ bool Device::findLinkInfo(const hsa_amd_memory_pool_t& pool,
distance += link_info[hop_idx].numa_distance;
}
uint32_t oneHopDistance
= (link_info[0].link_type == HSA_AMD_LINK_INFO_TYPE_XGMI) ? 15 : 20;
= (link_info[0].link_type == HSA_AMD_LINK_INFO_TYPE_XGMI) ? 13 : 20;
link_attr.second = static_cast<int32_t>(distance/oneHopDistance);
break;
}