dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: alexdeucher@gmail.com
To: airlied@gmail.com, dri-devel@lists.freedesktop.org
Cc: Alex Deucher <alexander.deucher@amd.com>
Subject: [PATCH] drm/radeon/si: add missing radeon_bo_unreserve in si_rlc_init()
Date: Thu, 12 Apr 2012 16:13:55 -0400	[thread overview]
Message-ID: <1334261635-7334-1-git-send-email-alexdeucher@gmail.com> (raw)

From: Alex Deucher <alexander.deucher@amd.com>

Forget to unreserve after pinning.  This can lead to problems in
soft reset and resume.

Signed-off-by: Alex Deucher <alexander.deucher@amd.com>
---
 drivers/gpu/drm/radeon/si.c |    3 ++-
 1 files changed, 2 insertions(+), 1 deletions(-)

diff --git a/drivers/gpu/drm/radeon/si.c b/drivers/gpu/drm/radeon/si.c
index ac7a199..23a114c 100644
--- a/drivers/gpu/drm/radeon/si.c
+++ b/drivers/gpu/drm/radeon/si.c
@@ -3005,6 +3005,7 @@ int si_rlc_init(struct radeon_device *rdev)
 		si_rlc_fini(rdev);
 		return r;
 	}
+	radeon_bo_unreserve(rdev->rlc.save_restore_obj);
 
 	/* clear state block */
 	if (rdev->rlc.clear_state_obj == NULL) {
@@ -3024,12 +3025,12 @@ int si_rlc_init(struct radeon_device *rdev)
 	r = radeon_bo_pin(rdev->rlc.clear_state_obj, RADEON_GEM_DOMAIN_VRAM,
 			  &rdev->rlc.clear_state_gpu_addr);
 	if (r) {
-
 		radeon_bo_unreserve(rdev->rlc.clear_state_obj);
 		dev_warn(rdev->dev, "(%d) pin RLC c bo failed\n", r);
 		si_rlc_fini(rdev);
 		return r;
 	}
+	radeon_bo_unreserve(rdev->rlc.clear_state_obj);
 
 	return 0;
 }
-- 
1.7.7.5

             reply	other threads:[~2012-04-12 20:14 UTC|newest]

Thread overview: 3+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2012-04-12 20:13 alexdeucher [this message]
2012-04-13 13:54 ` [PATCH] drm/radeon/si: add missing radeon_bo_unreserve in si_rlc_init() Michel Dänzer
2012-04-13 14:26   ` [PATCH] drm/radeon/si: add missing radeon_bo_unreserve in si_rlc_init() v2 alexdeucher

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=1334261635-7334-1-git-send-email-alexdeucher@gmail.com \
    --to=alexdeucher@gmail.com \
    --cc=airlied@gmail.com \
    --cc=alexander.deucher@amd.com \
    --cc=dri-devel@lists.freedesktop.org \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox