From: "Khatri, Sunil" <sukhatri@amd.com>
To: "Christian König" <ckoenig.leichtzumerken@gmail.com>,
tursulin@ursulin.net, Alexander.Deucher@amd.com,
Prike.Liang@amd.com, SRINIVASAN.SHANMUGAM@amd.com,
christian.koenig@amd.com
Cc: amd-gfx@lists.freedesktop.org
Subject: Re: [PATCH 10/10] drm/amdgpu: WIP sync amdgpu_ttm_fill_mem only to kernel fences
Date: Tue, 17 Mar 2026 17:33:46 +0530 [thread overview]
Message-ID: <d51093a6-859b-4326-98df-750113541eec@amd.com> (raw)
In-Reply-To: <20260317105501.21479-10-christian.koenig@amd.com>
[-- Attachment #1: Type: text/plain, Size: 2500 bytes --]
Acked-by: Sunil Khatri <sunil.khatri@amd.com>
On 17-03-2026 04:25 pm, Christian König wrote:
> That's not even remotely correct, but should unblock testing for now.
>
> Signed-off-by: Christian König<christian.koenig@amd.com>
> ---
> drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c | 12 +++++++-----
> 1 file changed, 7 insertions(+), 5 deletions(-)
>
> diff --git a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
> index 714fd8d12ca5..69f52a078022 100644
> --- a/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
> +++ b/drivers/gpu/drm/amd/amdgpu/amdgpu_ttm.c
> @@ -2428,12 +2428,14 @@ static int amdgpu_ttm_prepare_job(struct amdgpu_device *adev,
> struct amdgpu_ttm_buffer_entity *entity,
> unsigned int num_dw,
> struct dma_resv *resv,
> + enum dma_resv_usage usage,
> bool vm_needs_flush,
> struct amdgpu_job **job,
> u64 k_job_id)
> {
> enum amdgpu_ib_pool_type pool = AMDGPU_IB_POOL_DELAYED;
> int r;
> +
> r = amdgpu_job_alloc_with_ib(adev, &entity->base,
> AMDGPU_FENCE_OWNER_UNDEFINED,
> num_dw * 4, pool, job, k_job_id);
> @@ -2449,8 +2451,7 @@ static int amdgpu_ttm_prepare_job(struct amdgpu_device *adev,
> if (!resv)
> return 0;
>
> - return drm_sched_job_add_resv_dependencies(&(*job)->base, resv,
> - DMA_RESV_USAGE_BOOKKEEP);
> + return drm_sched_job_add_resv_dependencies(&(*job)->base, resv, usage);
> }
>
> int amdgpu_copy_buffer(struct amdgpu_device *adev,
> @@ -2479,9 +2480,9 @@ int amdgpu_copy_buffer(struct amdgpu_device *adev,
> max_bytes = adev->mman.buffer_funcs->copy_max_bytes;
> num_loops = DIV_ROUND_UP(byte_count, max_bytes);
> num_dw = ALIGN(num_loops * adev->mman.buffer_funcs->copy_num_dw, 8);
> - r = amdgpu_ttm_prepare_job(adev, entity, num_dw,
> - resv, vm_needs_flush, &job,
> - AMDGPU_KERNEL_JOB_ID_TTM_COPY_BUFFER);
> + r = amdgpu_ttm_prepare_job(adev, entity, num_dw, resv,
> + DMA_RESV_USAGE_BOOKKEEP, vm_needs_flush,
> + &job, AMDGPU_KERNEL_JOB_ID_TTM_COPY_BUFFER);
> if (r)
> goto error_free;
>
> @@ -2524,6 +2525,7 @@ static int amdgpu_ttm_fill_mem(struct amdgpu_device *adev,
> num_loops = DIV_ROUND_UP_ULL(byte_count, max_bytes);
> num_dw = ALIGN(num_loops * adev->mman.buffer_funcs->fill_num_dw, 8);
> r = amdgpu_ttm_prepare_job(adev, entity, num_dw, resv,
> + DMA_RESV_USAGE_KERNEL,
> vm_needs_flush, &job, k_job_id);
> if (r)
> return r;
[-- Attachment #2: Type: text/html, Size: 3026 bytes --]
prev parent reply other threads:[~2026-03-17 12:03 UTC|newest]
Thread overview: 12+ messages / expand[flat|nested] mbox.gz Atom feed top
2026-03-17 10:54 [PATCH 01/10] drm/amdgpu: completely rework eviction fence handling v2 Christian König
2026-03-17 10:54 ` [PATCH 02/10] drm/amdgpu: fix eviction fence and userq manager shutdown Christian König
2026-03-17 10:54 ` [PATCH 03/10] drm/amdgpu: fix adding eviction fence Christian König
2026-03-17 10:54 ` [PATCH 04/10] drm/amdgpu: rework amdgpu_userq_wait_ioctl v4 Christian König
2026-03-17 10:54 ` [PATCH 05/10] drm/amdgpu: make amdgpu_user_wait_ioctl more resilent v2 Christian König
2026-03-17 10:54 ` [PATCH 06/10] drm/amdgpu: annotate eviction fence signaling path Christian König
2026-03-17 10:54 ` [PATCH 07/10] drm/amdgpu: fix some more bug in amdgpu_gem_va_ioctl Christian König
2026-03-17 10:54 ` [PATCH 08/10] drm/amdgpu: revert to old status lock handling v4 Christian König
2026-03-17 10:54 ` [PATCH 09/10] drm/amdgpu: restructure VM state machine v2 Christian König
2026-03-17 12:03 ` Khatri, Sunil
2026-03-17 10:55 ` [PATCH 10/10] drm/amdgpu: WIP sync amdgpu_ttm_fill_mem only to kernel fences Christian König
2026-03-17 12:03 ` Khatri, Sunil [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=d51093a6-859b-4326-98df-750113541eec@amd.com \
--to=sukhatri@amd.com \
--cc=Alexander.Deucher@amd.com \
--cc=Prike.Liang@amd.com \
--cc=SRINIVASAN.SHANMUGAM@amd.com \
--cc=amd-gfx@lists.freedesktop.org \
--cc=christian.koenig@amd.com \
--cc=ckoenig.leichtzumerken@gmail.com \
--cc=tursulin@ursulin.net \
/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