AMD-GFX Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: Emily Deng <Emily.Deng-5C7GfCeVMHo@public.gmane.org>
To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Cc: Emily Deng <Emily.Deng-5C7GfCeVMHo@public.gmane.org>
Subject: [PATCH] drm/amdgpu: Don't need to call csb_vram_unpin
Date: Fri, 24 May 2019 18:33:22 +0800	[thread overview]
Message-ID: <1558694002-19915-1-git-send-email-Emily.Deng@amd.com> (raw)

As it will destory clear_state_obj, and also will
unpin it in the gfx_v9_0_sw_fini, so don't need to
call csb_vram unpin in gfx_v9_0_hw_fini, or it will
have unpin warning.

Signed-off-by: Emily Deng <Emily.Deng@amd.com>
---
 drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c | 16 ----------------
 1 file changed, 16 deletions(-)

diff --git a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
index c763733..231b9e0 100644
--- a/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
+++ b/drivers/gpu/drm/amd/amdgpu/gfx_v9_0.c
@@ -1154,20 +1154,6 @@ static int gfx_v9_0_csb_vram_pin(struct amdgpu_device *adev)
 	return r;
 }
 
-static void gfx_v9_0_csb_vram_unpin(struct amdgpu_device *adev)
-{
-	int r;
-
-	if (!adev->gfx.rlc.clear_state_obj)
-		return;
-
-	r = amdgpu_bo_reserve(adev->gfx.rlc.clear_state_obj, true);
-	if (likely(r == 0)) {
-		amdgpu_bo_unpin(adev->gfx.rlc.clear_state_obj);
-		amdgpu_bo_unreserve(adev->gfx.rlc.clear_state_obj);
-	}
-}
-
 static void gfx_v9_0_mec_fini(struct amdgpu_device *adev)
 {
 	amdgpu_bo_free_kernel(&adev->gfx.mec.hpd_eop_obj, NULL, NULL);
@@ -3385,8 +3371,6 @@ static int gfx_v9_0_hw_fini(void *handle)
 	gfx_v9_0_cp_enable(adev, false);
 	adev->gfx.rlc.funcs->stop(adev);
 
-	gfx_v9_0_csb_vram_unpin(adev);
-
 	return 0;
 }
 
-- 
2.7.4

_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx

             reply	other threads:[~2019-05-24 10:33 UTC|newest]

Thread overview: 11+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2019-05-24 10:33 Emily Deng [this message]
     [not found] ` <1558694002-19915-1-git-send-email-Emily.Deng-5C7GfCeVMHo@public.gmane.org>
2019-05-27  3:08   ` [PATCH] drm/amdgpu: Don't need to call csb_vram_unpin Deng, Emily
     [not found]     ` <MWHPR12MB1326D8B853B29C387FC1874B8F1D0-Gy0DoCVfaSVaj5rVPFIlogdYzm3356FpvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2019-05-27  6:26       ` Quan, Evan
  -- strict thread matches above, loose matches on Subject: below --
2019-05-27  8:41 Emily Deng
     [not found] ` <1558946487-18034-1-git-send-email-Emily.Deng-5C7GfCeVMHo@public.gmane.org>
2019-05-27  9:31   ` Quan, Evan
2019-05-27 11:02   ` Christian König
     [not found]     ` <e15ac75c-fb1a-2a05-b857-d3761f5c905e-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2019-05-28  1:42       ` Quan, Evan
     [not found]         ` <MN2PR12MB3344714A52B709FCE058F48DE41E0-rweVpJHSKToDMgCC8P//OwdYzm3356FpvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2019-05-28  7:03           ` Koenig, Christian
     [not found]             ` <82dfcb34-109c-b7d6-c511-404008589869-5C7GfCeVMHo@public.gmane.org>
2019-05-28  7:38               ` Deng, Emily
     [not found]                 ` <MWHPR12MB132646027A5B99282AB6557A8F1E0-Gy0DoCVfaSVaj5rVPFIlogdYzm3356FpvxpqHgZTriW3zl9H0oFU5g@public.gmane.org>
2019-05-28  7:43                   ` Koenig, Christian
     [not found]                     ` <daf490f4-49fd-3688-84ff-5dc47eaa535c-5C7GfCeVMHo@public.gmane.org>
2019-05-28  7:48                       ` Deng, Emily

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=1558694002-19915-1-git-send-email-Emily.Deng@amd.com \
    --to=emily.deng-5c7gfcevmho@public.gmane.org \
    --cc=amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.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