From: "Christian König" <ckoenig.leichtzumerken-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
To: amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org,
dri-devel-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Subject: [PATCH 6/7] drm/amdgpu: always reserve one more shared slot for pipelines BO moves
Date: Mon, 24 Sep 2018 13:58:18 +0200 [thread overview]
Message-ID: <20180924115819.2116-7-christian.koenig@amd.com> (raw)
In-Reply-To: <20180924115819.2116-1-christian.koenig-5C7GfCeVMHo@public.gmane.org>
This allows us to drop the extra reserve in TTM.
Signed-off-by: Christian König <christian.koenig@amd.com>
---
drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c | 6 +++---
drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c | 2 +-
2 files changed, 4 insertions(+), 4 deletions(-)
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
index cda8cf90777c..3e31561d141b 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_cs.c
@@ -50,7 +50,7 @@ static int amdgpu_cs_user_fence_chunk(struct amdgpu_cs_parser *p,
bo = amdgpu_bo_ref(gem_to_amdgpu_bo(gobj));
p->uf_entry.priority = 0;
p->uf_entry.tv.bo = &bo->tbo;
- p->uf_entry.tv.shared = 1;
+ p->uf_entry.tv.shared = 2;
p->uf_entry.user_pages = NULL;
drm_gem_object_put_unlocked(gobj);
@@ -599,7 +599,7 @@ static int amdgpu_cs_parser_bos(struct amdgpu_cs_parser *p,
}
amdgpu_bo_list_for_each_entry(e, p->bo_list)
- e->tv.shared = 1;
+ e->tv.shared = 2;
amdgpu_bo_list_get_list(p->bo_list, &p->validated);
if (p->bo_list->first_userptr != p->bo_list->num_entries)
@@ -723,7 +723,7 @@ static int amdgpu_cs_parser_bos(struct amdgpu_cs_parser *p,
amdgpu_bo_list_for_each_entry(e, p->bo_list) {
struct amdgpu_bo *bo = ttm_to_amdgpu_bo(e->tv.bo);
- e->tv.shared = bo->prime_shared_count ? 1 : 0;
+ e->tv.shared = bo->prime_shared_count ? 2 : 0;
e->bo_va = amdgpu_vm_bo_find(vm, bo);
}
diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
index 353367382874..96fcb33774b7 100644
--- a/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
+++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_vm.c
@@ -616,7 +616,7 @@ void amdgpu_vm_get_pd_bo(struct amdgpu_vm *vm,
{
entry->priority = 0;
entry->tv.bo = &vm->root.base.bo->tbo;
- entry->tv.shared = 2;
+ entry->tv.shared = 3;
entry->user_pages = NULL;
list_add(&entry->tv.head, validated);
}
--
2.14.1
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
next prev parent reply other threads:[~2018-09-24 11:58 UTC|newest]
Thread overview: 13+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-09-24 11:58 Improve reservation object shared slot function Christian König
[not found] ` <20180924115819.2116-1-christian.koenig-5C7GfCeVMHo@public.gmane.org>
2018-09-24 11:58 ` [PATCH 1/7] dma-buf: remove shared fence staging in reservation object Christian König
2018-09-24 11:58 ` [PATCH 2/7] dma-buf: allow reserving more than one shared fence slot Christian König
2018-09-24 11:58 ` [PATCH 3/7] drm/ttm: allow reserve more than one shared slot Christian König
2018-09-24 14:11 ` Michel Dänzer
2018-09-24 11:58 ` [PATCH 4/7] drm/amdgpu: fix using shared fence for exported BOs Christian König
2018-09-24 11:58 ` Christian König [this message]
2018-09-24 11:58 ` [PATCH 7/7] drm/ttm: drop the extra reservation for pipelines BO moves Christian König
2018-09-24 11:58 ` [PATCH 5/7] drm/amdgpu: always reserve two slots for the VM Christian König
[not found] ` <20180924115819.2116-6-christian.koenig-5C7GfCeVMHo@public.gmane.org>
2018-09-24 14:14 ` Michel Dänzer
2018-09-24 15:03 ` Improve reservation object shared slot function Daniel Vetter
[not found] ` <20180924150319.GV11082-dv86pmgwkMBes7Z6vYuT8azUEOm+Xw19@public.gmane.org>
2018-09-24 15:16 ` Christian König
[not found] ` <b84dbae6-12ce-5632-d80f-567cb7fe678b-Re5JQEeQqe8AvxtiuMwx3w@public.gmane.org>
2018-09-24 15:43 ` Daniel Vetter
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=20180924115819.2116-7-christian.koenig@amd.com \
--to=ckoenig.leichtzumerken-re5jqeeqqe8avxtiumwx3w@public.gmane.org \
--cc=amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
--cc=dri-devel-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