mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
synced 2026-05-16 14:51:51 -04:00
drm/amdgpu: Query xgmi info from mmhub if available
Query xgmi info from mmhub if available Signed-off-by: Hawking Zhang <Hawking.Zhang@amd.com> Reviewed-by: Le Ma <le.ma@amd.com> Reviewed-by: Feifei Xu <Feifei.Xu@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
committed by
Alex Deucher
parent
20fe5d020f
commit
be3f235bb6
@@ -3878,9 +3878,21 @@ int amdgpu_device_init(struct amdgpu_device *adev,
|
||||
amdgpu_gmc_noretry_set(adev);
|
||||
/* Need to get xgmi info early to decide the reset behavior*/
|
||||
if (adev->gmc.xgmi.supported) {
|
||||
r = adev->gfxhub.funcs->get_xgmi_info(adev);
|
||||
if (r)
|
||||
return r;
|
||||
if (adev->gfxhub.funcs &&
|
||||
adev->gfxhub.funcs->get_xgmi_info) {
|
||||
r = adev->gfxhub.funcs->get_xgmi_info(adev);
|
||||
if (r)
|
||||
return r;
|
||||
}
|
||||
}
|
||||
|
||||
if (adev->gmc.xgmi.connected_to_cpu) {
|
||||
if (adev->mmhub.funcs &&
|
||||
adev->mmhub.funcs->get_xgmi_info) {
|
||||
r = adev->mmhub.funcs->get_xgmi_info(adev);
|
||||
if (r)
|
||||
return r;
|
||||
}
|
||||
}
|
||||
|
||||
/* enable PCIE atomic ops */
|
||||
|
||||
Reference in New Issue
Block a user