drm/amdgpu: skip to create ras xxx_err_count node when ACA is enabled
Subsystems (2)
PATCH 1/1 drm/amdgpu: skip to create ras xxx_err_count node when ACA is enabled
skip to create 'xxx_err_count' node when ACA is enabled.
Signed-off-by Yang Wang <[email protected]>
--- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 6 ++++++ 1 file changed, 6 insertions(+)
drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c +6 -0
@@ -1756,6 +1756,9 @@ int amdgpu_ras_sysfs_create(struct amdgpu_device *adev,if (!obj || obj->attr_inuse)return -EINVAL ; +if (amdgpu_aca_is_enabled (adev)) +return 0 ; +get_obj (obj); snprintf(obj->fs_data.sysfs_name, sizeof(obj->fs_data.sysfs_name),
@@ -1790,6 +1793,9 @@ int amdgpu_ras_sysfs_remove(struct amdgpu_device *adev,if (!obj || !obj->attr_inuse)return -EINVAL ; +if (amdgpu_aca_is_enabled (adev)) +return 0 ; +if (adev->dev->kobj.sd) sysfs_remove_file_from_group(&adev->dev->kobj, &obj->sysfs_attr.attr,
Signature · 1 line
2.34.1
[AMD Official Use Only - General]
Reviewed-by Tao Zhou <[email protected]>
[Tao] it's better to add comment to explain how to get error count when aca is enabled.
BTW, according to the change, do we need to update ras tool?
Quoted 44 lines
-----Original Message-----
From: Wang, Yang(Kevin) <[email protected]>
Sent: Wednesday, April 24, 2024 10:50 AM
To: [email protected]
Cc: Zhang, Hawking <[email protected]>; Zhou1, Tao <[email protected]>
Subject: [PATCH] drm/amdgpu: skip to create rasxxx_err_countnode when ACA is enabledskip to create '
xxx_err_count' node when ACA is enabled.Signed-off-by Yang Wang <[email protected]>--- drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c | 6 ++++++ 1 file changed, 6 insertions(+)drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c +3
-0@@ -1756,6 +1756,9 @@ int amdgpu_ras_sysfs_create(struct amdgpu_device *adev, if (!obj || obj->attr_inuse) return -EINVAL; +if (amdgpu_aca_is_enabled (adev)) +return 0 ; +get_obj (obj);snprintf(obj->fs_data.sysfs_name, sizeof(obj->fs_data.sysfs_name), @@ - 1790,6 +1793,9 @@ int amdgpu_ras_sysfs_remove(struct amdgpu_device *adev, if (!obj || !obj->attr_inuse) return -EINVAL;drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c +3
-1+if (amdgpu_aca_is_enabled (adev)) +return 0 ; +if (adev->dev->kobj.sd) sysfs_remove_file_from_group(&adev->dev->kobj, &obj->sysfs_attr.attr, --2.34.1