From: Alex Deucher Date: Wed, 12 Mar 2014 20:20:44 +0000 (-0400) Subject: drm/radeon/cik: properly set compute ring status on disable X-Git-Tag: submit/tizen_common/20140905.094502~344 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=be9a7549a6a6fc7d2ccb32630e866c7b701dfabd;p=sdk%2Femulator%2Femulator-kernel.git drm/radeon/cik: properly set compute ring status on disable commit b2b3d8d952e4f8d6ac2ce80be96b937f29f6e42e upstream. When we disable the rings, set the status properly. If not other code pathes may try and use the rings which are not functional at this point. Signed-off-by: Alex Deucher Signed-off-by: Jiri Slaby --- diff --git a/drivers/gpu/drm/radeon/cik.c b/drivers/gpu/drm/radeon/cik.c index 071b77cc6c82..25370ac56b4b 100644 --- a/drivers/gpu/drm/radeon/cik.c +++ b/drivers/gpu/drm/radeon/cik.c @@ -3517,8 +3517,11 @@ static void cik_cp_compute_enable(struct radeon_device *rdev, bool enable) { if (enable) WREG32(CP_MEC_CNTL, 0); - else + else { WREG32(CP_MEC_CNTL, (MEC_ME1_HALT | MEC_ME2_HALT)); + rdev->ring[CAYMAN_RING_TYPE_CP1_INDEX].ready = false; + rdev->ring[CAYMAN_RING_TYPE_CP2_INDEX].ready = false; + } udelay(50); }