Skip to content

Commit

Permalink
drm/amdkfd: Check use_xgmi_p2p before reporting hive_id
Browse files Browse the repository at this point in the history
Recently introduced commit 158a05a ("drm/amdgpu: Add
use_xgmi_p2p module parameter") did not update XGMI iolinks
when use_xgmi_p2p is disabled. Add fix to not create XGMI
iolinks in KFD topology when this parameter is disabled.

Fixes: 158a05a ("drm/amdgpu: Add use_xgmi_p2p module parameter")
Signed-off-by: Divya Shikre <DivyaUday.Shikre@amd.com>
Reviewed-by: Felix Kuehling <Felix.Kuehling@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
  • Loading branch information
Divya Shikre authored and Alex Deucher committed Mar 25, 2022
1 parent b7dfbd2 commit c565032
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion drivers/gpu/drm/amd/amdkfd/kfd_device.c
Original file line number Diff line number Diff line change
Expand Up @@ -531,7 +531,8 @@ bool kgd2kfd_device_init(struct kfd_dev *kfd,
goto kfd_doorbell_error;
}

kfd->hive_id = kfd->adev->gmc.xgmi.hive_id;
if (amdgpu_use_xgmi_p2p)
kfd->hive_id = kfd->adev->gmc.xgmi.hive_id;

kfd->noretry = kfd->adev->gmc.noretry;

Expand Down

0 comments on commit c565032

Please sign in to comment.