diff options
Diffstat (limited to 'drivers/gpu/drm/amd/pm/amdgpu_pm.c')
| -rw-r--r-- | drivers/gpu/drm/amd/pm/amdgpu_pm.c | 9 | 
1 files changed, 8 insertions, 1 deletions
diff --git a/drivers/gpu/drm/amd/pm/amdgpu_pm.c b/drivers/gpu/drm/amd/pm/amdgpu_pm.c index 082539c70fd4..e2cae97f4ff1 100644 --- a/drivers/gpu/drm/amd/pm/amdgpu_pm.c +++ b/drivers/gpu/drm/amd/pm/amdgpu_pm.c @@ -2090,7 +2090,8 @@ static int default_attr_update(struct amdgpu_device *adev, struct amdgpu_device_  	} else if (DEVICE_ATTR_IS(unique_id)) {  		if (asic_type != CHIP_VEGA10 &&  		    asic_type != CHIP_VEGA20 && -		    asic_type != CHIP_ARCTURUS) +		    asic_type != CHIP_ARCTURUS && +		    asic_type != CHIP_ALDEBARAN)  			*states = ATTR_STATE_UNSUPPORTED;  	} else if (DEVICE_ATTR_IS(pp_features)) {  		if (adev->flags & AMD_IS_APU || asic_type < CHIP_VEGA10) @@ -2133,6 +2134,12 @@ static int default_attr_update(struct amdgpu_device *adev, struct amdgpu_device_  		}  	} +	/* setting should not be allowed from VF */ +	if (amdgpu_sriov_vf(adev)) { +		dev_attr->attr.mode &= ~S_IWUGO; +		dev_attr->store = NULL; +	} +  #undef DEVICE_ATTR_IS  	return 0;  |