Commit d2c72d96 authored by Alex Deucher's avatar Alex Deucher

drm/amdgpu: enable enforce_isolation sysfs node on VFs

It should be enabled on both bare metal and VFs.

Fixes: e189be9b ("drm/amdgpu: Add enforce_isolation sysfs attribute")
Signed-off-by: default avatarAlex Deucher <alexander.deucher@amd.com>
Cc: Srinivasan Shanmugam <srinivasan.shanmugam@amd.com>
Cc: Amber Lin <Amber.Lin@amd.com>
Reviewed-by: default avatarSrinivasan Shanmugam <srinivasan.shanmugam@amd.com>
(cherry picked from commit dc8847b054fd6679866ed4ee861e069e54c10799)
parent 8e929cb5
...@@ -1635,11 +1635,9 @@ int amdgpu_gfx_sysfs_isolation_shader_init(struct amdgpu_device *adev) ...@@ -1635,11 +1635,9 @@ int amdgpu_gfx_sysfs_isolation_shader_init(struct amdgpu_device *adev)
{ {
int r; int r;
if (!amdgpu_sriov_vf(adev)) { r = device_create_file(adev->dev, &dev_attr_enforce_isolation);
r = device_create_file(adev->dev, &dev_attr_enforce_isolation); if (r)
if (r) return r;
return r;
}
r = device_create_file(adev->dev, &dev_attr_run_cleaner_shader); r = device_create_file(adev->dev, &dev_attr_run_cleaner_shader);
if (r) if (r)
...@@ -1650,8 +1648,7 @@ int amdgpu_gfx_sysfs_isolation_shader_init(struct amdgpu_device *adev) ...@@ -1650,8 +1648,7 @@ int amdgpu_gfx_sysfs_isolation_shader_init(struct amdgpu_device *adev)
void amdgpu_gfx_sysfs_isolation_shader_fini(struct amdgpu_device *adev) void amdgpu_gfx_sysfs_isolation_shader_fini(struct amdgpu_device *adev)
{ {
if (!amdgpu_sriov_vf(adev)) device_remove_file(adev->dev, &dev_attr_enforce_isolation);
device_remove_file(adev->dev, &dev_attr_enforce_isolation);
device_remove_file(adev->dev, &dev_attr_run_cleaner_shader); device_remove_file(adev->dev, &dev_attr_run_cleaner_shader);
} }
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment