Skip to content

Commit fd13269

Browse files
erichuang22hkasivis
authored andcommitted
drm/amdkfd: set uuid for each partition in topology
Currently each kfd compute partition/node is sharing the same uuid of AID, which doen't meet the CUDA spec for visible device, so corresponding XCD id for each partition in smu has been assigned to xcp, and exposed to kfd topology. v2: add NULL check (Lijo) Signed-off-by: Eric Huang <jinhuieric.huang@amd.com> Reviewed-by: Lijo Lazar <lijo.lazar@amd.com>
1 parent 6e0fe33 commit fd13269

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

drivers/gpu/drm/amd/amdkfd/kfd_topology.c

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -546,6 +546,8 @@ static ssize_t node_show(struct kobject *kobj, struct attribute *attr,
546546
sysfs_show_32bit_prop(buffer, offs, "sdma_fw_version",
547547
dev->gpu->kfd->sdma_fw_version);
548548
sysfs_show_64bit_prop(buffer, offs, "unique_id",
549+
dev->gpu->xcp ?
550+
dev->gpu->xcp->unique_id :
549551
dev->gpu->adev->unique_id);
550552
sysfs_show_32bit_prop(buffer, offs, "num_xcc",
551553
NUM_XCC(dev->gpu->xcc_mask));

0 commit comments

Comments
 (0)