summaryrefslogtreecommitdiffstats
path: root/drivers/gpu/drm/amd
diff options
context:
space:
mode:
authorMonk Liu <Monk.Liu@amd.com>2017-03-21 18:58:53 +0800
committerAlex Deucher <alexander.deucher@amd.com>2017-03-29 23:55:39 -0400
commit32833fb732a80cd27f3756b2ead7aaf85ec1a780 (patch)
tree043dcd68fa9d8f1e63988bb0a4148c57f5918d45 /drivers/gpu/drm/amd
parentca82a746b0e20a70fc39101ca376a90d26dd1b28 (diff)
downloadop-kernel-dev-32833fb732a80cd27f3756b2ead7aaf85ec1a780.zip
op-kernel-dev-32833fb732a80cd27f3756b2ead7aaf85ec1a780.tar.gz
drm/amdgpu:two fixings for sdma v4 for SRIOV
no hw_fini for SRIOV, otherwise other VF will be affected no CG for SRIOV Signed-off-by: Monk Liu <Monk.Liu@amd.com> Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
Diffstat (limited to 'drivers/gpu/drm/amd')
-rw-r--r--drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c b/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
index f8eb53b..bc19e5e 100644
--- a/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/sdma_v4_0.c
@@ -1172,6 +1172,9 @@ static int sdma_v4_0_hw_fini(void *handle)
{
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
+ if (amdgpu_sriov_vf(adev))
+ return 0;
+
sdma_v4_0_ctx_switch_enable(adev, false);
sdma_v4_0_enable(adev, false);
@@ -1406,6 +1409,9 @@ static int sdma_v4_0_set_clockgating_state(void *handle,
{
struct amdgpu_device *adev = (struct amdgpu_device *)handle;
+ if (amdgpu_sriov_vf(adev))
+ return 0;
+
switch (adev->asic_type) {
case CHIP_VEGA10:
sdma_v4_0_update_medium_grain_clock_gating(adev,
OpenPOWER on IntegriCloud