libhsakmt: Fix improper type range check in legacy queue creation

Enum type for compute AQL is defined as larger then targeted SDMAs
enum types.  We should only deny legacy calls for SDMA queues that
require targeted engines.

Change-Id: I6386a8700b3b18af825b6f0d2be27052cc8de0f5
Этот коммит содержится в:
Jonathan Kim
2024-08-28 11:13:03 -04:00
родитель 8ea62f1cea
Коммит ae99effb29
+1 -1
Просмотреть файл
@@ -602,7 +602,7 @@ HSAKMT_STATUS HSAKMTAPI hsaKmtCreateQueue(HSAuint32 NodeId,
HsaEvent *Event,
HsaQueueResource *QueueResource)
{
if (Type >= HSA_QUEUE_SDMA_BY_ENG_ID)
if (Type == HSA_QUEUE_SDMA_BY_ENG_ID)
return HSAKMT_STATUS_ERROR;
return hsaKmtCreateQueueExt(NodeId, Type, QueuePercentage, Priority, 0,