Skip to contentSkip to conversation

drm/amdgpu: Add message print when unable to get valid hive

PATCH In review Liu, Shaoyun 2 participants 3 messages Jan 4, 2019 – Jan 7, 2019 2 messages not in the archive

Subsystems (2)
lore
Share & tools
lore
#0 lore raw

PATCH 1/1 drm/amdgpu: Add message print when unable to get valid hive

Add message print out and return -EINVAL when driver can not get valid hive from hive arrary on xgmi configuration

Change-Id Ic03927904edf0e384b8c4651e19274bb3f2a7d9a
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_xgmi.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_xgmi.c +6 -1
index 8a8bc60..b226631 100644
@@ -113,8 +113,13 @@ int amdgpu_xgmi_add_device(struct amdgpu_device *adev)
 
 	mutex_lock(&xgmi_mutex);
 	hive = amdgpu_get_xgmi_hive(adev);
-	if (!hive)
+	if (!hive) {
+		ret = -EINVAL;
+		dev_err(adev->dev,
+			"XGMI: Can not matech hive 0xllx in the hive list.\n",
+			adev->gmc.xgmi.hive_id);
 		goto exit;
+	}
 
 	hive_topology = &hive->topology_info;
 
Signature · 6 lines
2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): 1546626542-29979-1-git-send-email-shaoyun.liu-5C7GfCeVMHo@public.gmane.org

#2 lore raw

Ping ...

-----Original Message-----
From: Liu, Shaoyun <[email protected]>
Sent: Friday, January 4, 2019 1:29 PM
To: [email protected]
Cc: Liu, Shaoyun <[email protected]>
Subject: [PATCH] drm/amdgpu: Add message print when unable to get valid hive

Add message print out and return -EINVAL when driver can not get valid hive from hive arrary on xgmi configuration

Change-Id Ic03927904edf0e384b8c4651e19274bb3f2a7d9a
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_xgmi.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_xgmi.c +6 -1
index 8a8bc60..b226631 100644
@@ -113,8 +113,13 @@ int amdgpu_xgmi_add_device(struct amdgpu_device *adev)
 
 	mutex_lock(&xgmi_mutex);
 	hive = amdgpu_get_xgmi_hive(adev);
-	if (!hive)
+	if (!hive) {
+		ret = -EINVAL;
+		dev_err(adev->dev,
+			"XGMI: Can not matech hive 0xllx in the hive list.\n",
+			adev->gmc.xgmi.hive_id);
 		goto exit;
+	}
 
 	hive_topology = &hive->topology_info;
 

--
2.7.4

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

A message that is not in the archive (sent off-list or not yet received): DM6PR12MB3241269A362C3E1ABE4D70C3F4890-lmeGfMZKVrEShx2hYn8pVQdYzm3356FpvxpqHgZTriW3zl9H0oFU5g@public.gmane.org

Reviewed-by
#4 lore raw

________________________________
From: amd-gfx <amd-gfx-bounces-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org> on behalf of Liu, Shaoyun <[email protected]>
Sent: Monday, January 7, 2019 11:01:51 AM
To: [email protected]
Subject: RE: [PATCH] drm/amdgpu: Add message print when unable to get valid hive

Ping ...

-----Original Message-----
From: Liu, Shaoyun <[email protected]>
Sent: Friday, January 4, 2019 1:29 PM
To: [email protected]
Cc: Liu, Shaoyun <[email protected]>
Subject: [PATCH] drm/amdgpu: Add message print when unable to get valid hive

Add message print out and return -EINVAL when driver can not get valid hive from hive arrary on xgmi configuration

Change-Id Ic03927904edf0e384b8c4651e19274bb3f2a7d9a
---
 drivers/gpu/drm/amd/amdgpu/amdgpu_xgmi.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)
drivers/gpu/drm/amd/amdgpu/amdgpu_xgmi.c +6 -1
index 8a8bc60..b226631 100644
@@ -113,8 +113,13 @@ int amdgpu_xgmi_add_device(struct amdgpu_device *adev)
 
         mutex_lock(&xgmi_mutex);
         hive = amdgpu_get_xgmi_hive(adev);
-       if (!hive)
+       if (!hive) {
+               ret = -EINVAL;
+               dev_err(adev->dev,
+                       "XGMI: Can not matech hive 0xllx in the hive list.\n",
+                       adev->gmc.xgmi.hive_id);
                 goto exit;
+       }
 
         hive_topology = &hive->topology_info;
 

--
2.7.4

_______________________________________________
amd-gfx mailing list [email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

_______________________________________________
amd-gfx mailing list
[email protected]
https://lists.freedesktop.org/mailman/listinfo/amd-gfx