drm/amdgpu: Only create err_count sysfs when hw_op is supported
authorHawking Zhang <Hawking.Zhang@amd.com>
Mon, 31 Jul 2023 15:43:12 +0000 (23:43 +0800)
committerAlex Deucher <alexander.deucher@amd.com>
Mon, 7 Aug 2023 21:12:49 +0000 (17:12 -0400)
commitf957138cc30ae904346f117013fc7b428700c1f7
treece0ba9c14debe52cf701a0ee221237056744117b
parente013864479f7572153b27072b6693d45301e3cf6
drm/amdgpu: Only create err_count sysfs when hw_op is supported

Some IP blocks only support partial ras feature and don't
have ras counter and/or ras error status register at all.
Driver should not create err_count sysfs node for those
IP blocks.

Signed-off-by: Hawking Zhang <Hawking.Zhang@amd.com>
Reviewed-by: Tao Zhou <tao.zhou1@amd.com>
Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
drivers/gpu/drm/amd/amdgpu/amdgpu_ras.c