mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/stable/linux.git
synced 2024-10-29 23:53:32 +00:00
drm/amd/amdgpu: Fix flow control in uvd_v4_2_stop()
Break out of outer loop properly. Signed-off-by: Tom St Denis <tom.stdenis@amd.com> Reported-by: Dan Carpenter <dan.carpenter@oracle.com> Reviewed-by: Christian König <christian.koenig@amd.com> Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
This commit is contained in:
parent
fce293ca3d
commit
e89d5b5c20
1 changed files with 6 additions and 3 deletions
|
@ -401,7 +401,8 @@ static void uvd_v4_2_stop(struct amdgpu_device *adev)
|
|||
break;
|
||||
mdelay(1);
|
||||
}
|
||||
break;
|
||||
if (status & 2)
|
||||
break;
|
||||
}
|
||||
|
||||
for (i = 0; i < 10; ++i) {
|
||||
|
@ -411,7 +412,8 @@ static void uvd_v4_2_stop(struct amdgpu_device *adev)
|
|||
break;
|
||||
mdelay(1);
|
||||
}
|
||||
break;
|
||||
if (status & 0xf)
|
||||
break;
|
||||
}
|
||||
|
||||
/* Stall UMC and register bus before resetting VCPU */
|
||||
|
@ -424,7 +426,8 @@ static void uvd_v4_2_stop(struct amdgpu_device *adev)
|
|||
break;
|
||||
mdelay(1);
|
||||
}
|
||||
break;
|
||||
if (status & 0x240)
|
||||
break;
|
||||
}
|
||||
|
||||
WREG32_P(0x3D49, 0, ~(1 << 2));
|
||||
|
|
Loading…
Reference in a new issue