From: zhoucm1 <david1.zhou-5C7GfCeVMHo@public.gmane.org>
To: "Christian König"
<deathsimple-ANTagKRnAhcb1SvskN2V4Q@public.gmane.org>,
amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org
Subject: Re: [PATCH 00/19] shadow page table support V2
Date: Tue, 9 Aug 2016 16:37:11 +0800 [thread overview]
Message-ID: <57A99637.9010707@amd.com> (raw)
In-Reply-To: <9156b55f-8440-1003-6587-dc2e97a7a4cb-ANTagKRnAhcb1SvskN2V4Q@public.gmane.org>
On 2016年08月08日 19:04, Christian König wrote:
> Apart from that patch #1:
>> + amdgpu_ttm_placement_init(adev, &placement,
>> + placements, AMDGPU_GEM_DOMAIN_GTT,
>> + AMDGPU_GEM_CREATE_CPU_GTT_USWC);
>> +
>> + return amdgpu_bo_create_restricted(adev, size, byte_align, true,
>> + AMDGPU_GEM_DOMAIN_GTT,
>> + AMDGPU_GEM_CREATE_CPU_GTT_USWC,
>> + NULL, &placement,
>> + bo->tbo.resv,
>> + &bo->shadow);
> You need to set bo->shadow->parent to the parent BO when you use the
> reservation object here. See the VM code on how to do this, otherwise
> TTM could free the parent reservation object first and the crash when
> it wants to free the shadow.
I've tried to add parent for shadow bo, I trouble how to free shadow bo.
My old though is the life cycle of shadow bo is same as parent. That
means parent bo refers shadow bo when initialization, unref shadow bo
when BO is freeing, other people cannot refer shadow bo.
So if we set bo->shadow->parent and reference it, then the bo cannot be
freed.
Regards,
David Zhou
>
> Additional to that do we really need the placement here? That looks
> quite odd.
_______________________________________________
amd-gfx mailing list
amd-gfx@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/amd-gfx
next prev parent reply other threads:[~2016-08-09 8:37 UTC|newest]
Thread overview: 28+ messages / expand[flat|nested] mbox.gz Atom feed top
2016-08-05 9:38 [PATCH 00/19] shadow page table support V2 Chunming Zhou
[not found] ` <1470389926-5719-1-git-send-email-David1.Zhou-5C7GfCeVMHo@public.gmane.org>
2016-08-05 9:38 ` [PATCH 01/19] drm/amdgpu: add shadow bo support Chunming Zhou
2016-08-05 9:38 ` [PATCH 02/19] drm/amdgpu: validate shadow as well when validating bo Chunming Zhou
2016-08-05 9:38 ` [PATCH 03/19] drm/amdgpu: allocate shadow for pd/pt bo Chunming Zhou
2016-08-05 9:38 ` [PATCH 04/19] drm/amdgpu: add shadow flag Chunming Zhou
2016-08-05 9:38 ` [PATCH 05/19] drm/amdgpu: sync bo and shadow Chunming Zhou
2016-08-05 9:38 ` [PATCH 06/19] drm/amdgpu: implement vm recovery function from shadow Chunming Zhou
[not found] ` <1470389926-5719-7-git-send-email-David1.Zhou-5C7GfCeVMHo@public.gmane.org>
2016-08-11 8:39 ` Christian König
[not found] ` <17dc9ee4-35d0-3e20-8402-15524e667327-ANTagKRnAhcb1SvskN2V4Q@public.gmane.org>
2016-08-11 8:42 ` zhoucm1
2016-08-05 9:38 ` [PATCH 07/19] drm/amdgpu: fix vm init error path Chunming Zhou
2016-08-05 9:38 ` [PATCH 08/19] drm/amdgpu: add shadow_entity for shadow page table updates Chunming Zhou
2016-08-05 9:38 ` [PATCH 09/19] drm/amdgpu: update pd shadow bo Chunming Zhou
2016-08-05 9:38 ` [PATCH 10/19] drm/amdgpu: update pt shadow Chunming Zhou
2016-08-05 9:38 ` [PATCH 11/19] drm/amd: add last fence in sched entity Chunming Zhou
2016-08-05 9:38 ` [PATCH 12/19] drm/amdgpu: link all vm clients Chunming Zhou
2016-08-05 9:38 ` [PATCH 13/19] drm/amdgpu: add vm_list_lock Chunming Zhou
2016-08-05 9:38 ` [PATCH 14/19] drm/amd: add block entity function Chunming Zhou
2016-08-05 9:38 ` [PATCH 15/19] drm/amdgpu: add shadow fence owner Chunming Zhou
2016-08-05 9:38 ` [PATCH 16/19] drm/amd: block entity Chunming Zhou
2016-08-05 9:38 ` [PATCH 17/19] drm/amdgpu: recover page tables after gpu reset Chunming Zhou
2016-08-05 9:38 ` [PATCH 18/19] drm/amdgpu: add need backup function Chunming Zhou
2016-08-05 9:38 ` [PATCH 19/19] drm/amdgpu: add backup condition for vm Chunming Zhou
2016-08-05 10:12 ` [PATCH 00/19] shadow page table support V2 Edward O'Callaghan
2016-08-08 11:04 ` Christian König
[not found] ` <9156b55f-8440-1003-6587-dc2e97a7a4cb-ANTagKRnAhcb1SvskN2V4Q@public.gmane.org>
2016-08-09 8:37 ` zhoucm1 [this message]
2016-08-10 6:02 ` zhoucm1
[not found] ` <57AAC38B.7070101-5C7GfCeVMHo@public.gmane.org>
2016-08-10 11:14 ` Christian König
[not found] ` <ea9315d9-cbeb-c5ad-0589-04d04ce16f1e-ANTagKRnAhcb1SvskN2V4Q@public.gmane.org>
2016-08-10 21:19 ` Deucher, Alexander
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=57A99637.9010707@amd.com \
--to=david1.zhou-5c7gfcevmho@public.gmane.org \
--cc=amd-gfx-PD4FTy7X32lNgt0PjOBp9y5qC8QIuHrW@public.gmane.org \
--cc=deathsimple-ANTagKRnAhcb1SvskN2V4Q@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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.