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>
Tá an tiomantas seo le fáil i:
Lang Yu
2024-05-06 13:06:18 +08:00
tiomanta ag Chris Freehill
tuismitheoir 9316b6e4e4
tiomantas ae3ede062f
D'athraigh 2 comhad le 2 breiseanna agus 1 scriosta
+1 -1
Féach ar an gComhad
@@ -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
Féach ar an gComhad
@@ -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);