From: Nirmoy <nirmodas@amd.com>
To: "Christian König" <christian.koenig@amd.com>,
"Nirmoy Das" <nirmoy.das@amd.com>,
dri-devel@lists.freedesktop.org
Cc: daniel.vetter@ffwll.ch, sroland@vmware.com
Subject: Re: [PATCH 1/1] drm/vmwgfx: free ttm resource before assigning a new one
Date: Mon, 3 May 2021 20:13:37 +0200 [thread overview]
Message-ID: <5efb01ab-d1d4-defe-eec7-466ce48e6aa3@amd.com> (raw)
In-Reply-To: <88e1b9af-9570-fdbc-346b-86b55f1f7575@amd.com>
On 5/3/21 7:39 PM, Christian König wrote:
> Am 03.05.21 um 19:26 schrieb Nirmoy Das:
>> TTM BO resource need to be freed before calling ttm_bo_assign_mem().
>>
>> Signed-off-by: Nirmoy Das <nirmoy.das@amd.com>
>> ---
>> drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c | 1 +
>> 1 file changed, 1 insertion(+)
>>
>> diff --git a/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c
>> b/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c
>> index 2dc031fe4a90..93e4cf34a3a3 100644
>> --- a/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c
>> +++ b/drivers/gpu/drm/vmwgfx/vmwgfx_ttm_buffer.c
>> @@ -738,6 +738,7 @@ static int vmw_move(struct ttm_buffer_object *bo,
>> if (old_man->use_tt && new_man->use_tt) {
>> if (bo->mem.mem_type == TTM_PL_SYSTEM) {
>> + ttm_resource_free(bo, &bo->mem);
>> ttm_bo_assign_mem(bo, new_mem);
>
> Mhm, we should probably rather call ttm_bo_move_null here like other
> drivers do.
>
Thanks Christian, I will send a updated patch.
Nirmoy
> Christian.
>
>> return 0;
>> }
>
_______________________________________________
dri-devel mailing list
dri-devel@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/dri-devel
prev parent reply other threads:[~2021-05-03 18:13 UTC|newest]
Thread overview: 3+ messages / expand[flat|nested] mbox.gz Atom feed top
2021-05-03 17:26 [PATCH 1/1] drm/vmwgfx: free ttm resource before assigning a new one Nirmoy Das
2021-05-03 17:39 ` Christian König
2021-05-03 18:13 ` Nirmoy [this message]
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=5efb01ab-d1d4-defe-eec7-466ce48e6aa3@amd.com \
--to=nirmodas@amd.com \
--cc=christian.koenig@amd.com \
--cc=daniel.vetter@ffwll.ch \
--cc=dri-devel@lists.freedesktop.org \
--cc=nirmoy.das@amd.com \
--cc=sroland@vmware.com \
/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