libhsakmt: add Integrated property

To differentiate discrete and integrated GPU more flexibly in runtime,
this will aid in querying HSA_AMD_MEMORY_PROPERTY_AGENT_IS_APU
and hipDeviceAttributeIntegrated.

Change-Id: Ic8a6c9aea3b4bd19c4d5f6729af7e64c328fc61d
Signed-off-by: Lang Yu <Lang.Yu@amd.com>
Signed-off-by: Chris Freehill <cfreehil@amd.com>
Cette révision appartient à :
Lang Yu
2024-05-06 13:06:18 +08:00
révisé par Chris Freehill
Parent 9316b6e4e4
révision ae3ede062f
2 fichiers modifiés avec 2 ajouts et 1 suppressions
+1 -1
Voir le fichier
@@ -321,7 +321,7 @@ typedef struct _HsaNodeProperties
HSAuint8 NumSdmaQueuesPerEngine;// number of SDMA queue per one engine
HSAuint8 NumCpQueues; // number of Compute queues
HSAuint8 NumGws; // number of GWS barriers
HSAuint8 Reserved2;
HSAuint8 Integrated; // 0 - discrete GPU, 1 - integrated GPU (including small APU and APP APU)
HSAuint32 Domain; // PCI domain of the GPU
HSAuint64 UniqueID; // Globally unique immutable id
+1
Voir le fichier
@@ -1046,6 +1046,7 @@ static int topology_get_node_props_from_drm(HsaNodeProperties *props)
}
props->FamilyID = gpu_info.family_id;
props->Integrated = !!(gpu_info.ids_flags & AMDGPU_IDS_FLAGS_FUSION);
err_query_gpu_info:
amdgpu_device_deinitialize(device_handle);