[RFC 4/5] drm/amdgpu: Use preferred placement for VRAM+GTT

2024-05-08 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Now that TTM has the preferred placement flag, extend the current workaround which assumes the GTT placement as fallback in the presence of the additional VRAM placement. By marking the VRAM placement as preferred we will make the buffer re- validation phase actually

Re: [PATCH v3 5/6] drm/xe: Add helper to accumulate exec queue runtime

2024-05-08 Thread Tvrtko Ursulin
On 07/05/2024 23:45, Lucas De Marchi wrote: From: Umesh Nerlige Ramappa Add a helper to accumulate per-client runtime of all its exec queues. This is called every time a sched job is finished. v2: - Use guc_exec_queue_free_job() and execlist_job_free() to accumulate runtime when job

Re: [PATCH v2 6/6] drm/xe/client: Print runtime to fdinfo

2024-05-08 Thread Tvrtko Ursulin
On 07/05/2024 22:35, Lucas De Marchi wrote: On Fri, Apr 26, 2024 at 11:47:37AM GMT, Tvrtko Ursulin wrote: On 24/04/2024 00:56, Lucas De Marchi wrote: Print the accumulated runtime for client when printing fdinfo. Each time a query is done it first does 2 things: 1) loop through all the

Re: drm scheduler and wq flavours

2024-05-07 Thread Tvrtko Ursulin
On 07/05/2024 00:23, Matthew Brost wrote: On Thu, May 02, 2024 at 03:33:50PM +0100, Tvrtko Ursulin wrote: Hi all, Continuing after the brief IRC discussion yesterday regarding work queues being prone to deadlocks or not, I had a browse around the code base and ended up a bit confused. When

Re: [PATCH] Documentation/gpu: Document the situation with unqualified drm-memory-

2024-05-03 Thread Tvrtko Ursulin
On 03/05/2024 16:58, Alex Deucher wrote: On Fri, May 3, 2024 at 11:33 AM Daniel Vetter wrote: On Fri, May 03, 2024 at 01:58:38PM +0100, Tvrtko Ursulin wrote: [And I forgot dri-devel.. doing well!] On 03/05/2024 13:40, Tvrtko Ursulin wrote: [Correcting Christian's email] On 03/05

Re: [PATCH] Documentation/gpu: Document the situation with unqualified drm-memory-

2024-05-03 Thread Tvrtko Ursulin
On 03/05/2024 14:39, Alex Deucher wrote: On Fri, May 3, 2024 at 8:58 AM Tvrtko Ursulin wrote: [And I forgot dri-devel.. doing well!] On 03/05/2024 13:40, Tvrtko Ursulin wrote: [Correcting Christian's email] On 03/05/2024 13:36, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Current

Re: [PATCH] Documentation/gpu: Document the situation with unqualified drm-memory-

2024-05-03 Thread Tvrtko Ursulin
[And I forgot dri-devel.. doing well!] On 03/05/2024 13:40, Tvrtko Ursulin wrote: [Correcting Christian's email] On 03/05/2024 13:36, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Currently it is not well defined what is drm-memory- compared to other categories. In practice the only d

drm scheduler and wq flavours

2024-05-02 Thread Tvrtko Ursulin
Hi all, Continuing after the brief IRC discussion yesterday regarding work queues being prone to deadlocks or not, I had a browse around the code base and ended up a bit confused. When drm_sched_init documents and allocates an *ordered* wq, if no custom one was provided, could someone remi

Re: [PATCH] drm/sysfs: Add drm class-wide attribute to get active device clients

2024-05-01 Thread Tvrtko Ursulin
Hi, On 24/04/2024 15:48, Adrián Larumbe wrote: Hi Tvrtko, On 15.04.2024 13:50, Tvrtko Ursulin wrote: On 05/04/2024 18:59, Rob Clark wrote: On Wed, Apr 3, 2024 at 11:37 AM Adrián Larumbe wrote: Up to this day, all fdinfo-based GPU profilers must traverse the entire /proc directory

Re: [PATCH v4 8/8] drm/v3d: Add modparam for turning off Big/Super Pages

2024-04-29 Thread Tvrtko Ursulin
type = get_fs_type("tmpfs"); if (!type) goto err; Reviewed-by: Tvrtko Ursulin Regards, Tvrtko

Re: [PATCH v2 3/6] drm/xe: Add helper to accumulate exec queue runtime

2024-04-29 Thread Tvrtko Ursulin
On 26/04/2024 19:59, Umesh Nerlige Ramappa wrote: On Fri, Apr 26, 2024 at 11:49:32AM +0100, Tvrtko Ursulin wrote: On 24/04/2024 00:56, Lucas De Marchi wrote: From: Umesh Nerlige Ramappa Add a helper to accumulate per-client runtime of all its exec queues. Currently that is done in 2

Re: [PATCH] MAINTAINERS: Move the drm-intel repo location to fd.o GitLab

2024-04-26 Thread Tvrtko Ursulin
: Lucas De Marchi Also Cc'ing maintainers Thanks, Acked-by: Tvrtko Ursulin Regards, Tvrtko --- MAINTAINERS | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/MAINTAINERS b/MAINTAINERS index d6327dc12cb1..fbf7371a0bb0 100644 --- a/MAINTAINERS +++ b/MAINTAINERS @@ -10

Re: [PATCH v2 3/6] drm/xe: Add helper to accumulate exec queue runtime

2024-04-26 Thread Tvrtko Ursulin
On 24/04/2024 00:56, Lucas De Marchi wrote: From: Umesh Nerlige Ramappa Add a helper to accumulate per-client runtime of all its exec queues. Currently that is done in 2 places: 1. when the exec_queue is destroyed 2. when the sched job is completed Signed-off-by: Umesh Nerli

Re: [PATCH v2 6/6] drm/xe/client: Print runtime to fdinfo

2024-04-26 Thread Tvrtko Ursulin
On 24/04/2024 00:56, Lucas De Marchi wrote: Print the accumulated runtime for client when printing fdinfo. Each time a query is done it first does 2 things: 1) loop through all the exec queues for the current client and accumulate the runtime, per engine class. CTX_TIMESTAMP is used for

Re: [PATCH v3 8/8] drm/v3d: Add modparam for turning off Big/Super Pages

2024-04-22 Thread Tvrtko Ursulin
On 21/04/2024 22:44, Maíra Canal wrote: Add a modparam for turning off Big/Super Pages to make sure that if an user doesn't want Big/Super Pages enabled, it can disabled it by setting the modparam to false. Signed-off-by: Maíra Canal --- drivers/gpu/drm/v3d/v3d_drv.c | 8 driver

Re: [PATCH v3 7/8] drm/v3d: Use gemfs/THP in BO creation if available

2024-04-22 Thread Tvrtko Ursulin
align = SZ_64K; + else + align = SZ_4K; V3d has one GPU address space, right? I wonder if one day fragmentation could become an issue but it's a problem for another day. Patch looks fine to me. Reviewed-by: Tvrtko Ursulin Regards, Tvrtko + spin_lock(&v3d-&g

Re: [PATCH v3 6/8] drm/v3d: Support Big/Super Pages when writing out PTEs

2024-04-22 Thread Tvrtko Ursulin
On 22/04/2024 10:57, Tvrtko Ursulin wrote: On 21/04/2024 22:44, Maíra Canal wrote: The V3D MMU also supports 64KB and 1MB pages, called big and super pages, respectively. In order to set a 64KB page or 1MB page in the MMU, we need to make sure that page table entries for all 4KB pages within

Re: [PATCH v3 6/8] drm/v3d: Support Big/Super Pages when writing out PTEs

2024-04-22 Thread Tvrtko Ursulin
len -= page_size; + } } WARN_ON_ONCE(page - bo->node.start != It looks correct to me. Reviewed-by: Tvrtko Ursulin Regards, Tvrtko

Re: [PATCH v3 4/5] drm/v3d: Decouple stats calculation from printing

2024-04-22 Thread Tvrtko Ursulin
_runtime); + timestamp, jobs_completed, active_runtime); } return len; Reviewed-by: Tvrtko Ursulin Regards, Tvrtko

Re: [PATCH v2 4/4] drm/v3d: Fix race-condition between sysfs/fdinfo and interrupt handler

2024-04-17 Thread Tvrtko Ursulin
ck for GPU usage stats") Reported-by: Tvrtko Ursulin Signed-off-by: Maíra Canal --- drivers/gpu/drm/v3d/v3d_drv.c | 10 ++ drivers/gpu/drm/v3d/v3d_drv.h | 21 + drivers/gpu/drm/v3d/v3d_gem.c | 7 +-- drivers/gpu/drm/v3d/v3d_sched.c | 7 +++

Re: Proposal to add CRIU support to DRM render nodes

2024-04-16 Thread Tvrtko Ursulin
On 01/04/2024 18:58, Felix Kuehling wrote: On 2024-04-01 12:56, Tvrtko Ursulin wrote: On 01/04/2024 17:37, Felix Kuehling wrote: On 2024-04-01 11:09, Tvrtko Ursulin wrote: On 28/03/2024 20:42, Felix Kuehling wrote: On 2024-03-28 12:03, Tvrtko Ursulin wrote: Hi Felix, I had one more

Re: [PATCH 1/5] drm/v3d: Don't increment `enabled_ns` twice

2024-04-16 Thread Tvrtko Ursulin
should be added just once. Therefore, delete the leftovers from commit 509433d8146c ("drm/v3d: Expose the total GPU usage stats on sysfs"). Fixes: 509433d8146c ("drm/v3d: Expose the total GPU usage stats on sysfs") Reported-by: Tvrtko Ursulin Signed-off-by: Maíra Canal ---   dr

Re: [PATCH] drm/sysfs: Add drm class-wide attribute to get active device clients

2024-04-15 Thread Tvrtko Ursulin
zillon Cc: Tvrtko Ursulin Cc: Christopher Healy Signed-off-by: Adrián Larumbe It does seem like a good idea.. idk if there is some precedent to prefer binary vs ascii in sysfs, but having a way to avoid walking _all_ processes is a good idea. I naturally second that it is a needed feature, bu

Re: [PATCH v2 4/6] drm/gem: Create shmem GEM object in a given mountpoint

2024-04-15 Thread Tvrtko Ursulin
ze_t size, + struct vfsmount *gemfs); void drm_gem_shmem_free(struct drm_gem_shmem_object *shmem); void drm_gem_shmem_put_pages(struct drm_gem_shmem_object *shmem); Reviewed-by: Tvrtko Ursulin Regards, Tvrtko

Re: [PATCH v2 2/6] drm/gem: Create a drm_gem_object_init_with_mnt() function

2024-04-15 Thread Tvrtko Ursulin
nd was once annoyed by trivial wrappers / function calls. But some other are then annoyed by static inlines.. so dunno.) For either flavour: Reviewed-by: Tvrtko Ursulin Regards, Tvrtko /** diff --git a/include/drm/drm_gem.h b/include/drm/drm_gem.h index bae4865b2101..2ebf6e10cc44 1006

Re: [PATCH 5/5] drm/v3d: Fix race-condition between sysfs/fdinfo and interrupt handler

2024-04-15 Thread Tvrtko Ursulin
ts") Reported-by: Tvrtko Ursulin Signed-off-by: Maíra Canal --- drivers/gpu/drm/v3d/v3d_drv.c | 16 drivers/gpu/drm/v3d/v3d_drv.h | 7 +++ drivers/gpu/drm/v3d/v3d_gem.c | 7 +-- drivers/gpu/drm/v3d/v3d_sched.c | 9 + drivers/gpu/drm

Re: [PATCH v2 6/6] drm/v3d: Enable big and super pages

2024-04-15 Thread Tvrtko Ursulin
On 05/04/2024 19:29, Maíra Canal wrote: The V3D MMU also supports 64KB and 1MB pages, called big and super pages, respectively. In order to set a 64KB page or 1MB page in the MMU, we need to make sure that page table entries for all 4KB pages within a big/super page must be correctly configured

Re: [PATCH 4/5] drm/v3d: Create function to update a set of GPU stats

2024-04-15 Thread Tvrtko Ursulin
_stats->start_ns; - global_stats->jobs_sent++; - global_stats->start_ns = 0; + v3d_stats_update(local_stats); + v3d_stats_update(global_stats); } static struct dma_fence *v3d_bin_job_run(struct drm_sched_job *sched_job) Reviewed-by: Tvrtko Ursulin Regards, Tvrtko

Re: [PATCH 3/5] drm/v3d: Create a struct to store the GPU stats

2024-04-15 Thread Tvrtko Ursulin
;%s\t%llu\t%llu\t%llu\n", v3d_queue_to_string(queue), timestamp, - v3d->queue[queue].jobs_sent, -v3d->queue[queue].enabled_ns + active_runtime); +stats->jobs_sent, +stats->enabled_ns + active_runtime); } return len; Reviewed-by: Tvrtko Ursulin Regards, Tvrtko

Re: [PATCH 1/5] drm/v3d: Don't increment `enabled_ns` twice

2024-04-15 Thread Tvrtko Ursulin
eftovers from commit 509433d8146c ("drm/v3d: Expose the total GPU usage stats on sysfs"). Fixes: 509433d8146c ("drm/v3d: Expose the total GPU usage stats on sysfs") Reported-by: Tvrtko Ursulin Signed-off-by: Maíra Canal --- drivers/gpu/drm/v3d/v3d_irq.c | 4 1 file changed, 4 de

Re: Proposal to add CRIU support to DRM render nodes

2024-04-01 Thread Tvrtko Ursulin
On 01/04/2024 17:37, Felix Kuehling wrote: On 2024-04-01 11:09, Tvrtko Ursulin wrote: On 28/03/2024 20:42, Felix Kuehling wrote: On 2024-03-28 12:03, Tvrtko Ursulin wrote: Hi Felix, I had one more thought while browsing around the amdgpu CRIU plugin. It appears it relies on the KFD

Re: drm-misc migration to Gitlab server

2024-04-01 Thread Tvrtko Ursulin
On 12/03/2024 13:56, Maxime Ripard wrote: Hi, On Tue, Feb 20, 2024 at 09:49:25AM +0100, Maxime Ripard wrote: ## Changing the default location repo Dim gets its repos list in the drm-rerere nightly.conf file. We will need to change that file to match the gitlab repo, and drop the old cgit URL

Re: Proposal to add CRIU support to DRM render nodes

2024-04-01 Thread Tvrtko Ursulin
On 28/03/2024 20:42, Felix Kuehling wrote: On 2024-03-28 12:03, Tvrtko Ursulin wrote: Hi Felix, I had one more thought while browsing around the amdgpu CRIU plugin. It appears it relies on the KFD support being compiled in and /dev/kfd present, correct? AFAICT at least, it relies on that

Re: [PATCH] dma-buf: Do not build debugfs related code when !CONFIG_DEBUG_FS

2024-04-01 Thread Tvrtko Ursulin
On 01/04/2024 13:45, Christian König wrote: Am 01.04.24 um 14:39 schrieb Tvrtko Ursulin: On 29/03/2024 00:00, T.J. Mercier wrote: On Thu, Mar 28, 2024 at 7:53 AM Tvrtko Ursulin wrote: From: Tvrtko Ursulin There is no point in compiling in the list and mutex operations which are only

Re: [PATCH] dma-buf: Do not build debugfs related code when !CONFIG_DEBUG_FS

2024-04-01 Thread Tvrtko Ursulin
On 29/03/2024 00:00, T.J. Mercier wrote: On Thu, Mar 28, 2024 at 7:53 AM Tvrtko Ursulin wrote: From: Tvrtko Ursulin There is no point in compiling in the list and mutex operations which are only used from the dma-buf debugfs code, if debugfs is not compiled in. Put the code in questions

Re: Proposal to add CRIU support to DRM render nodes

2024-03-28 Thread Tvrtko Ursulin
for things like re-assigned minor numbers due driver reload. Otherwise I am eagerly awaiting to hear more about the design specifics around dma-buf handling. And also seeing how to extend to other DRM related anonymous fds. Regards, Tvrtko On 15/03/2024 18:36, Tvrtko Ursulin wrote: On 15/03

[PATCH] dma-buf: Do not build debugfs related code when !CONFIG_DEBUG_FS

2024-03-28 Thread Tvrtko Ursulin
From: Tvrtko Ursulin There is no point in compiling in the list and mutex operations which are only used from the dma-buf debugfs code, if debugfs is not compiled in. Put the code in questions behind some kconfig guards and so save some text and maybe even a pointer per object at runtime when

Re: [PATCH] drm/i915/gem: Replace dev_priv with i915

2024-03-28 Thread Tvrtko Ursulin
os of the 'dev_priv' name keep sneaking it in. Signed-off-by: Andi Shyti Cc: Jani Nikula Cc: Joonas Lahtinen Cc: Rodrigo Vivi Cc: Tvrtko Ursulin --- drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c | 4 ++-- drivers/gpu/drm/i915/gem/i915_gem_shmem.c | 6 +++--- drivers/gpu

Re: [PATCH v6 0/3] Disable automatic load CCS load balancing

2024-03-20 Thread Tvrtko Ursulin
On 20/03/2024 15:06, Andi Shyti wrote: Ping! Any thoughts here? I only casually observed the discussion after I saw Matt suggested further simplifications. As I understood it, you will bring back the uabi engine games when adding the dynamic behaviour and that is fine by me. Regards, Tvr

Re: [PATCH 2/5] drm/gem: Add a mountpoint parameter to drm_gem_object_init()

2024-03-18 Thread Tvrtko Ursulin
8/24 10:10, Christian König wrote: Am 18.03.24 um 13:42 schrieb Maíra Canal: Hi Christian, On 3/12/24 10:48, Christian König wrote: Am 12.03.24 um 14:09 schrieb Tvrtko Ursulin: On 12/03/2024 10:37, Christian König wrote: Am 12.03.24 um 11:31 schrieb Tvrtko Ursulin: On 12/03/2024 10:23, Christian K

Re: Proposal to add CRIU support to DRM render nodes

2024-03-15 Thread Tvrtko Ursulin
On 15/03/2024 02:33, Felix Kuehling wrote: On 2024-03-12 5:45, Tvrtko Ursulin wrote: On 11/03/2024 14:48, Tvrtko Ursulin wrote: Hi Felix, On 06/12/2023 21:23, Felix Kuehling wrote: Executive Summary: We need to add CRIU support to DRM render nodes in order to maintain CRIU support for

Re: [PATCH 5/5] drm/v3d: Enable super pages

2024-03-12 Thread Tvrtko Ursulin
Hi Maira, On 11/03/2024 10:06, Maíra Canal wrote: The V3D MMU also supports 1MB pages, called super pages. In order to set a 1MB page in the MMU, we need to make sure that page table entries for all 4KB pages within a super page must be correctly configured. Therefore, if the BO is larger tha

Re: [PATCH 2/5] drm/gem: Add a mountpoint parameter to drm_gem_object_init()

2024-03-12 Thread Tvrtko Ursulin
On 12/03/2024 10:37, Christian König wrote: Am 12.03.24 um 11:31 schrieb Tvrtko Ursulin: On 12/03/2024 10:23, Christian König wrote: Am 12.03.24 um 10:30 schrieb Tvrtko Ursulin: On 12/03/2024 08:59, Christian König wrote: Am 12.03.24 um 09:51 schrieb Tvrtko Ursulin: Hi Maira, On 11/03

Re: [PATCH 2/5] drm/gem: Add a mountpoint parameter to drm_gem_object_init()

2024-03-12 Thread Tvrtko Ursulin
On 12/03/2024 10:23, Christian König wrote: Am 12.03.24 um 10:30 schrieb Tvrtko Ursulin: On 12/03/2024 08:59, Christian König wrote: Am 12.03.24 um 09:51 schrieb Tvrtko Ursulin: Hi Maira, On 11/03/2024 10:05, Maíra Canal wrote: For some applications, such as using huge pages, we might

Re: [PATCH 0/5] drm/i915: cleanup dead code

2024-03-12 Thread Tvrtko Ursulin
On 11/03/2024 19:27, Lucas De Marchi wrote: On Mon, Mar 11, 2024 at 05:43:00PM +, Tvrtko Ursulin wrote: On 06/03/2024 19:36, Lucas De Marchi wrote: Remove platforms that never had their PCI IDs added to the driver and are of course marked with requiring force_probe. Note that most of

Re: Proposal to add CRIU support to DRM render nodes

2024-03-12 Thread Tvrtko Ursulin
On 11/03/2024 14:48, Tvrtko Ursulin wrote: Hi Felix, On 06/12/2023 21:23, Felix Kuehling wrote: Executive Summary: We need to add CRIU support to DRM render nodes in order to maintain CRIU support for ROCm application once they start relying on render nodes for more GPU memory management

Re: [PATCH 2/5] drm/gem: Add a mountpoint parameter to drm_gem_object_init()

2024-03-12 Thread Tvrtko Ursulin
On 12/03/2024 08:59, Christian König wrote: Am 12.03.24 um 09:51 schrieb Tvrtko Ursulin: Hi Maira, On 11/03/2024 10:05, Maíra Canal wrote: For some applications, such as using huge pages, we might want to have a different mountpoint, for which we pass in mount flags that better match our

Re: [PATCH 3/5] drm/v3d: Introduce gemfs

2024-03-12 Thread Tvrtko Ursulin
Hi, On 11/03/2024 10:06, Maíra Canal wrote: Create a separate "tmpfs" kernel mount for V3D. This will allow us to move away from the shmemfs `shm_mnt` and gives the flexibility to do things like set our own mount options. Here, the interest is to use "huge=", which should allow us to enable th

Re: [PATCH 2/5] drm/gem: Add a mountpoint parameter to drm_gem_object_init()

2024-03-12 Thread Tvrtko Ursulin
Hi Maira, On 11/03/2024 10:05, Maíra Canal wrote: For some applications, such as using huge pages, we might want to have a different mountpoint, for which we pass in mount flags that better match our usecase. Therefore, add a new parameter to drm_gem_object_init() that allow us to define the

Re: [PATCH 0/5] drm/i915: cleanup dead code

2024-03-11 Thread Tvrtko Ursulin
On 06/03/2024 19:36, Lucas De Marchi wrote: Remove platforms that never had their PCI IDs added to the driver and are of course marked with requiring force_probe. Note that most of the code for those platforms is actually used by subsequent ones, so it's not a huge amount of code being removed.

Re: Proposal to add CRIU support to DRM render nodes

2024-03-11 Thread Tvrtko Ursulin
Hi Felix, On 06/12/2023 21:23, Felix Kuehling wrote: Executive Summary: We need to add CRIU support to DRM render nodes in order to maintain CRIU support for ROCm application once they start relying on render nodes for more GPU memory management. In this email I'm providing some background w

Re: [PATCH v3 1/1] drm/panfrost: Replace fdinfo's profiling debugfs knob with sysfs

2024-03-06 Thread Tvrtko Ursulin
On 06/03/2024 01:56, Adrián Larumbe wrote: Debugfs isn't always available in production builds that try to squeeze every single byte out of the kernel image, but we still need a way to toggle the timestamp and cycle counter registers so that jobs can be profiled for fdinfo's drm engine and cycl

[PATCH] MAINTAINERS: Update email address for Tvrtko Ursulin

2024-02-28 Thread Tvrtko Ursulin
From: Tvrtko Ursulin I will lose access to my @.*intel.com e-mail addresses soon so let me adjust the maintainers entry and update the mailmap too. While at it consolidate a few other of my old emails to point to the main one. Signed-off-by: Tvrtko Ursulin Cc: Daniel Vetter Cc: Dave Airlie

[PULL] drm-intel-gt-next

2024-02-28 Thread Tvrtko Ursulin
. Regards, Tvrtko drm-intel-gt-next-2024-02-28: Driver Changes: Fixes: - Add some boring kerneldoc (Tvrtko Ursulin) - Check before removing mm notifier (Nirmoy The following changes since commit eb927f01dfb6309c8a184593c2c0618c4000c481: drm/i915/gt: Restart the heartbeat timer when forcing a

Re: [PATCH] drm/i915: check before removing mm notifier

2024-02-28 Thread Tvrtko Ursulin
On 27/02/2024 09:26, Nirmoy Das wrote: Hi Tvrtko, On 2/27/2024 10:04 AM, Tvrtko Ursulin wrote: On 21/02/2024 11:52, Nirmoy Das wrote: Merged it to drm-intel-gt-next with s/check/Check Shouldn't this have had: Fixes: ed29c2691188 ("drm/i915: Fix userptr so we do not have to wo

Re: [PATCH v2] drm/i915/guc: Use context hints for GT freq

2024-02-28 Thread Tvrtko Ursulin
/sushmave/mesa/-/commits/compute_hint v2: Rename flags as per review suggestions (Rodrigo, Tvrtko). Also, use flag bits in intel_context as it allows finer control for toggling per engine if needed (Tvrtko). Cc: Rodrigo Vivi Cc: Tvrtko Ursulin Cc: Sushma Venkatesh Reddy Signed-off-by: Vinay Belgaumkar

Re: [PATCH] drm/i915: check before removing mm notifier

2024-02-27 Thread Tvrtko Ursulin
On 21/02/2024 11:52, Nirmoy Das wrote: Merged it to drm-intel-gt-next with s/check/Check Shouldn't this have had: Fixes: ed29c2691188 ("drm/i915: Fix userptr so we do not have to worry about obj->mm.lock, v7.") Cc: # v5.13+ ? Regards, Tvrtko On 2/19/2024 1:50 PM, Nirmoy Das wrote: E

Re: [PATCH 2/2] drm/i915: Support replaying GPU hangs with captured context image

2024-02-26 Thread Tvrtko Ursulin
On 22/02/2024 21:07, Rodrigo Vivi wrote: On Wed, Feb 21, 2024 at 02:22:45PM +, Tvrtko Ursulin wrote: From: Tvrtko Ursulin When debugging GPU hangs Mesa developers are finding it useful to replay the captured error state against the simulator. But due various simulator limitations which

Re: [PATCH] drm/i915/guc: Add Compute context hint

2024-02-26 Thread Tvrtko Ursulin
On 26/02/2024 08:47, Tvrtko Ursulin wrote: On 23/02/2024 19:25, Rodrigo Vivi wrote: On Fri, Feb 23, 2024 at 10:31:41AM -0800, Belgaumkar, Vinay wrote: On 2/23/2024 12:51 AM, Tvrtko Ursulin wrote: On 22/02/2024 23:31, Belgaumkar, Vinay wrote: On 2/22/2024 7:32 AM, Tvrtko Ursulin wrote

Re: [PATCH] drm/i915/guc: Add Compute context hint

2024-02-26 Thread Tvrtko Ursulin
On 23/02/2024 19:25, Rodrigo Vivi wrote: On Fri, Feb 23, 2024 at 10:31:41AM -0800, Belgaumkar, Vinay wrote: On 2/23/2024 12:51 AM, Tvrtko Ursulin wrote: On 22/02/2024 23:31, Belgaumkar, Vinay wrote: On 2/22/2024 7:32 AM, Tvrtko Ursulin wrote: On 21/02/2024 21:28, Rodrigo Vivi wrote

Re: [PATCH] drm/i915/guc: Add Compute context hint

2024-02-23 Thread Tvrtko Ursulin
On 22/02/2024 23:31, Belgaumkar, Vinay wrote: On 2/22/2024 7:32 AM, Tvrtko Ursulin wrote: On 21/02/2024 21:28, Rodrigo Vivi wrote: On Wed, Feb 21, 2024 at 09:42:34AM +, Tvrtko Ursulin wrote: On 21/02/2024 00:14, Vinay Belgaumkar wrote: Allow user to provide a context hint. When this

Re: [PATCH] drm/i915/guc: Add Compute context hint

2024-02-22 Thread Tvrtko Ursulin
On 21/02/2024 21:28, Rodrigo Vivi wrote: On Wed, Feb 21, 2024 at 09:42:34AM +, Tvrtko Ursulin wrote: On 21/02/2024 00:14, Vinay Belgaumkar wrote: Allow user to provide a context hint. When this is set, KMD will send a hint to GuC which results in special handling for this context. SLPC

Re: [PATCH 0/1] Always record job cycle and timestamp information

2024-02-21 Thread Tvrtko Ursulin
re and how exactly TBD. Regards, Tvrtko On 16.02.2024 17:43, Tvrtko Ursulin wrote: On 16/02/2024 16:57, Daniel Vetter wrote: On Wed, Feb 14, 2024 at 01:52:05PM +, Steven Price wrote: Hi Adrián, On 14/02/2024 12:14, Adrián Larumbe wrote: A driver user expressed interest in being able to a

[PATCH 1/2] drm/i915: Shadow default engine context image in the context

2024-02-21 Thread Tvrtko Ursulin
From: Tvrtko Ursulin To enable adding override of the default engine context image let us start shadowing the per engine state in the context. Signed-off-by: Tvrtko Ursulin Cc: Lionel Landwerlin Cc: Carlos Santa Cc: Rodrigo Vivi --- drivers/gpu/drm/i915/gt/intel_context_types.h | 2

[PATCH 2/2] drm/i915: Support replaying GPU hangs with captured context image

2024-02-21 Thread Tvrtko Ursulin
From: Tvrtko Ursulin When debugging GPU hangs Mesa developers are finding it useful to replay the captured error state against the simulator. But due various simulator limitations which prevent replicating all hangs, one step further is being able to replay against a real GPU. This is almost

[PATCH v2 0/2] GPU hang replay

2024-02-21 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Please see 2/2 for explanation and rationale. v2: * Extracted shadowing of default state into a leading patch. Tvrtko Ursulin (2): drm/i915: Shadow default engine context image in the context drm/i915: Support replaying GPU hangs with captured context image drivers

Re: [PATCH v2 2/2] drm/i915/gt: Enable only one CCS for compute workload

2024-02-21 Thread Tvrtko Ursulin
On 21/02/2024 12:08, Tvrtko Ursulin wrote: On 21/02/2024 11:19, Andi Shyti wrote: Hi Tvrtko, On Wed, Feb 21, 2024 at 08:19:34AM +, Tvrtko Ursulin wrote: On 21/02/2024 00:14, Andi Shyti wrote: On Tue, Feb 20, 2024 at 02:48:31PM +, Tvrtko Ursulin wrote: On 20/02/2024 14:35, Andi

Re: [PATCH v2 2/2] drm/i915/gt: Enable only one CCS for compute workload

2024-02-21 Thread Tvrtko Ursulin
On 21/02/2024 11:19, Andi Shyti wrote: Hi Tvrtko, On Wed, Feb 21, 2024 at 08:19:34AM +, Tvrtko Ursulin wrote: On 21/02/2024 00:14, Andi Shyti wrote: On Tue, Feb 20, 2024 at 02:48:31PM +, Tvrtko Ursulin wrote: On 20/02/2024 14:35, Andi Shyti wrote: Enable only one CCS engine by

Re: [PATCH] drm/i915/guc: Add Compute context hint

2024-02-21 Thread Tvrtko Ursulin
On 21/02/2024 00:14, Vinay Belgaumkar wrote: Allow user to provide a context hint. When this is set, KMD will send a hint to GuC which results in special handling for this context. SLPC will ramp the GT frequency aggressively every time it switches to this context. The down freq threshold will

Re: [RFC] drm/i915: Support replaying GPU hangs with captured context image

2024-02-21 Thread Tvrtko Ursulin
On 20/02/2024 22:50, Rodrigo Vivi wrote: On Tue, Feb 13, 2024 at 01:14:34PM +, Tvrtko Ursulin wrote: From: Tvrtko Ursulin When debugging GPU hangs Mesa developers are finding it useful to replay the captured error state against the simulator. But due various simulator limitations which

Re: [PATCH v2 2/2] drm/i915/gt: Enable only one CCS for compute workload

2024-02-21 Thread Tvrtko Ursulin
On 21/02/2024 00:14, Andi Shyti wrote: Hi Tvrtko, On Tue, Feb 20, 2024 at 02:48:31PM +, Tvrtko Ursulin wrote: On 20/02/2024 14:35, Andi Shyti wrote: Enable only one CCS engine by default with all the compute sices slices Thanks! diff --git a/drivers/gpu/drm/i915/gt

Re: [PATCH v2 2/2] drm/i915/gt: Enable only one CCS for compute workload

2024-02-20 Thread Tvrtko Ursulin
On 20/02/2024 14:35, Andi Shyti wrote: Enable only one CCS engine by default with all the compute sices slices allocated to it. While generating the list of UABI engines to be exposed to the user, exclude any additional CCS engines beyond the first instance. This change can be tested with

Re: [PATCH 2/2] drm/i915/gt: Set default CCS mode '1'

2024-02-20 Thread Tvrtko Ursulin
On 20/02/2024 14:20, Andi Shyti wrote: Since CCS automatic load balancing is disabled, we will impose a fixed balancing policy that involves setting all the CCS engines to work together on the same load. Erm *all* CSS engines work together.. Simultaneously, the user will see only 1 CCS rath

Re: [PATCH] drm/i915: Fix possible null pointer dereference after drm_dbg_printer conversion

2024-02-20 Thread Tvrtko Ursulin
On 20/02/2024 10:36, Maxime Ripard wrote: On Tue, Feb 20, 2024 at 09:16:43AM +, Tvrtko Ursulin wrote: On 19/02/2024 20:02, Rodrigo Vivi wrote: On Mon, Feb 19, 2024 at 01:14:23PM +, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Request can be NULL if no guilty request was identified

Re: [PATCH 2/2] drm/i915/gt: Set default CCS mode '1'

2024-02-20 Thread Tvrtko Ursulin
On 20/02/2024 10:11, Andi Shyti wrote: Hi Tvrtko, On Mon, Feb 19, 2024 at 12:51:44PM +, Tvrtko Ursulin wrote: On 19/02/2024 11:16, Tvrtko Ursulin wrote: On 15/02/2024 13:59, Andi Shyti wrote: ... +/* + * Exclude unavailable engines. + * + * Only the first CCS engine is utilized due

Re: [PATCH] drm/i915: Fix possible null pointer dereference after drm_dbg_printer conversion

2024-02-20 Thread Tvrtko Ursulin
On 19/02/2024 20:02, Rodrigo Vivi wrote: On Mon, Feb 19, 2024 at 01:14:23PM +, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Request can be NULL if no guilty request was identified so simply use engine->i915 instead. Signed-off-by: Tvrtko Ursulin Fixes: d50892a9554c ("drm/i915

[PATCH] drm/i915: Add some boring kerneldoc

2024-02-19 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Tooling appears very strict so lets pacify it by adding some comments, even if fields are completely self-explanatory. Signed-off-by: Tvrtko Ursulin Fixes: b11236486749 ("drm/i915: Add GuC submission interface version query") Reported-by: Stephen Rothwell Cc:

[PATCH] drm/i915: Fix possible null pointer dereference after drm_dbg_printer conversion

2024-02-19 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Request can be NULL if no guilty request was identified so simply use engine->i915 instead. Signed-off-by: Tvrtko Ursulin Fixes: d50892a9554c ("drm/i915: switch from drm_debug_printer() to device specific drm_dbg_printer()") Reported-by: Dan Carpenter Cc: Ja

Re: [PATCH 2/2] drm/i915/gt: Set default CCS mode '1'

2024-02-19 Thread Tvrtko Ursulin
On 19/02/2024 11:16, Tvrtko Ursulin wrote: On 15/02/2024 13:59, Andi Shyti wrote: Since CCS automatic load balancing is disabled, we will impose a fixed balancing policy that involves setting all the CCS engines to work together on the same load. Simultaneously, the user will see only 1 CCS

Re: [PATCH 2/2] drm/i915/gt: Set default CCS mode '1'

2024-02-19 Thread Tvrtko Ursulin
On 15/02/2024 13:59, Andi Shyti wrote: Since CCS automatic load balancing is disabled, we will impose a fixed balancing policy that involves setting all the CCS engines to work together on the same load. Simultaneously, the user will see only 1 CCS rather than the actual number. As of now, thi

Re: [PATCH 0/1] Always record job cycle and timestamp information

2024-02-16 Thread Tvrtko Ursulin
On 16/02/2024 16:57, Daniel Vetter wrote: On Wed, Feb 14, 2024 at 01:52:05PM +, Steven Price wrote: Hi Adrián, On 14/02/2024 12:14, Adrián Larumbe wrote: A driver user expressed interest in being able to access engine usage stats through fdinfo when debugfs is not built into their kernel

[PULL] drm-intel-gt-next

2024-02-15 Thread Tvrtko Ursulin
submission version query which Mesa wants for implementing Vulkan async compute queues. Regards, Tvrtko drm-intel-gt-next-2024-02-15: UAPI Changes: - Add GuC submission interface version query (Tvrtko Ursulin) Driver Changes: Fixes/improvements/new stuff: - Atomically invalidate userptr on mmu

[RFC] drm/i915: Support replaying GPU hangs with captured context image

2024-02-13 Thread Tvrtko Ursulin
From: Tvrtko Ursulin When debugging GPU hangs Mesa developers are finding it useful to replay the captured error state against the simulator. But due various simulator limitations which prevent replicating all hangs, one step further is being able to replay against a real GPU. This is almost

Re: [PATCH] drm/i915: Add flex arrays to struct i915_syncmap

2024-02-12 Thread Tvrtko Ursulin
On 08/02/2024 18:13, Erick Archer wrote: The "struct i915_syncmap" uses a dynamically sized set of trailing elements. It can use an "u32" array or a "struct i915_syncmap *" array. So, use the preferred way in the kernel declaring flexible arrays [1]. Because there are two possibilities for the

Re: [PATCH v2] drm/i915: Add GuC submission interface version query

2024-02-09 Thread Tvrtko Ursulin
On 08/02/2024 17:55, Souza, Jose wrote: On Thu, 2024-02-08 at 07:19 -0800, José Roberto de Souza wrote: On Thu, 2024-02-08 at 14:59 +, Tvrtko Ursulin wrote: On 08/02/2024 14:30, Souza, Jose wrote: On Thu, 2024-02-08 at 08:25 +, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Add a new

Re: [PATCH v2] drm/i915: Add GuC submission interface version query

2024-02-08 Thread Tvrtko Ursulin
On 08/02/2024 14:30, Souza, Jose wrote: On Thu, 2024-02-08 at 08:25 +, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Add a new query to the GuC submission interface version. Mesa intends to use this information to check for old firmware versions with a known bug where using the render and

Re: [RFC] drm/i915: Add GuC submission interface version query

2024-02-08 Thread Tvrtko Ursulin
On 07/02/2024 19:34, John Harrison wrote: On 2/7/2024 10:49, Tvrtko Ursulin wrote: On 07/02/2024 18:12, John Harrison wrote: On 2/7/2024 03:56, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Add a new query to the GuC submission interface version. Mesa intends to use this information to

[PATCH v2] drm/i915: Add GuC submission interface version query

2024-02-08 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Add a new query to the GuC submission interface version. Mesa intends to use this information to check for old firmware versions with a known bug where using the render and compute command streamers simultaneously can cause GPU hangs due issues in firmware scheduling

Re: [RFC] drm/i915: Add GuC submission interface version query

2024-02-07 Thread Tvrtko Ursulin
On 07/02/2024 18:12, John Harrison wrote: On 2/7/2024 03:56, Tvrtko Ursulin wrote: From: Tvrtko Ursulin Add a new query to the GuC submission interface version. Mesa intends to use this information to check for old firmware versions with a known bug where using the render and compute

[RFC] drm/i915: Add GuC submission interface version query

2024-02-07 Thread Tvrtko Ursulin
From: Tvrtko Ursulin Add a new query to the GuC submission interface version. Mesa intends to use this information to check for old firmware versions with a known bug where using the render and compute command streamers simultaneously can cause GPU hangs due issues in firmware scheduling

Re: [PATCH] drm/i915/gt: Prevent possible NULL dereference in __caps_show()

2024-02-07 Thread Tvrtko Ursulin
Hi, On 06/02/2024 16:45, Nikita Zhandarovich wrote: After falling through the switch statement to default case 'repr' is initialized with NULL, which will lead to incorrect dereference of '!repr[n]' in the following loop. Fix it with the help of an additional check for NULL. Found by Linux V

Re: [PATCH 5/6] drm/i915: Update shared stats to use the new gem helper

2024-01-30 Thread Tvrtko Ursulin
stats[id].shared += sz; else stats[id].private += sz; Reviewed-by: Tvrtko Ursulin Good that you remembered this story, I completely forgot! Regards, Tvrtko

Re: [PATCH 3/6] drm: update drm_show_memory_stats() for dma-bufs

2024-01-30 Thread Tvrtko Ursulin
ts(obj)) { status.shared += obj->size; } else { status.private += obj->size; Reviewed-by: Tvrtko Ursulin Regards, Tvrtko

Re: [PATCH 2/6] drm: add drm_gem_object_is_shared_for_memory_stats() helper

2024-01-30 Thread Tvrtko Ursulin
/** Not sure what the local view on static inlines, but fine nevertheless. Reviewed-by: Tvrtko Ursulin Regards, Tvrtko

Re: [PATCH 1/6] Documentation/gpu: Update documentation on drm-shared-*

2024-01-30 Thread Tvrtko Ursulin
-total-: [KiB|MiB] Reviewed-by: Tvrtko Ursulin Regards, Tvrtko

Re: [PATCH 2/2] drm/amdgpu: add shared fdinfo stats

2024-01-09 Thread Tvrtko Ursulin
On 09/01/2024 14:57, Christian König wrote: Am 09.01.24 um 15:26 schrieb Daniel Vetter: On Tue, 9 Jan 2024 at 14:25, Tvrtko Ursulin wrote: On 09/01/2024 12:54, Daniel Vetter wrote: On Tue, Jan 09, 2024 at 09:30:15AM +, Tvrtko Ursulin wrote: On 09/01/2024 07:56, Christian König wrote

Re: [PATCH 2/2] drm/amdgpu: add shared fdinfo stats

2024-01-09 Thread Tvrtko Ursulin
On 09/01/2024 12:54, Daniel Vetter wrote: On Tue, Jan 09, 2024 at 09:30:15AM +, Tvrtko Ursulin wrote: On 09/01/2024 07:56, Christian König wrote: Am 07.12.23 um 19:02 schrieb Alex Deucher: Add shared stats.  Useful for seeing shared memory. v2: take dma-buf into account as well

Re: [PATCH 2/2] drm/amdgpu: add shared fdinfo stats

2024-01-09 Thread Tvrtko Ursulin
On 09/01/2024 07:56, Christian König wrote: Am 07.12.23 um 19:02 schrieb Alex Deucher: Add shared stats.  Useful for seeing shared memory. v2: take dma-buf into account as well Signed-off-by: Alex Deucher Cc: Rob Clark ---   drivers/gpu/drm/amd/amdgpu/amdgpu_fdinfo.c |  4   drivers/gp

Re: [PATCH v2 1/3] drm/i915/gt: Support fixed CCS mode

2024-01-09 Thread Tvrtko Ursulin
On 08/01/2024 15:13, Joonas Lahtinen wrote: Quoting Tvrtko Ursulin (2024-01-05 12:39:31) On 04/01/2024 21:23, Andi Shyti wrote: +void intel_gt_apply_ccs_mode(struct intel_gt *gt) +{ + mutex_lock(>->ccs.mutex); + __intel_gt_apply_ccs_mode(gt); + mutex_unlock(>-&

Re: [PATCH v2 1/3] drm/i915/gt: Support fixed CCS mode

2024-01-05 Thread Tvrtko Ursulin
On 04/01/2024 21:23, Andi Shyti wrote: Hi Tvrtko, [1] + /* +* Loop over all available slices and assign each a user engine. +* +* With 1 engine (ccs0): +* slice 0, 1, 2, 3: ccs0 +* +* With 2 engines (ccs0, ccs1): +* slice 0, 2

<    1   2   3   4   5   6   7   8   9   10   >