[PATCH 04/10] drm/i915: remove intel_memory_region avail

2022-05-25 Thread Matthew Auld
No longer used. Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Lionel Landwerlin Cc: Tvrtko Ursulin Cc: Jon Bloomfield Cc: Daniel Vetter Cc: Jordan Justen Cc: Kenneth Graunke Cc: Akeem G Abodunrin --- drivers/gpu/drm/i915/intel_memory_region.c | 4 +--- drivers/gpu/drm/i915

[PATCH 02/10] drm/i915/uapi: add probed_cpu_visible_size

2022-05-25 Thread Matthew Auld
case of plumbing that through to the region query. Testcase: igt@i915_query@query-regions-sanity-check Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Lionel Landwerlin Cc: Tvrtko Ursulin Cc: Jon Bloomfield Cc: Daniel Vetter Cc: Jordan Justen Cc: Kenneth Graunke Cc: Akeem G Abodunrin

[PATCH 03/10] drm/i915/uapi: expose the avail tracking

2022-05-25 Thread Matthew Auld
-sanity-check Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Lionel Landwerlin Cc: Tvrtko Ursulin Cc: Jon Bloomfield Cc: Daniel Vetter Cc: Jordan Justen Cc: Kenneth Graunke Cc: Akeem G Abodunrin --- drivers/gpu/drm/i915/i915_query.c | 10 +- drivers/gpu/drm/i915

[PATCH 01/10] drm/doc: add rfc section for small BAR uapi

2022-05-25 Thread Matthew Auld
over. (Tvrtko) Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Lionel Landwerlin Cc: Tvrtko Ursulin Cc: Jon Bloomfield Cc: Daniel Vetter Cc: Jordan Justen Cc: Kenneth Graunke Cc: Akeem G Abodunrin Cc: mesa-...@lists.freedesktop.org Acked-by: Tvrtko Ursulin Acked-by: Akeem G Abodu

[PATCH 00/10] small BAR uapi bits

2022-05-25 Thread Matthew Auld
Test-with: 20220525183702.490989-1-matthew.a...@intel.com -- 2.34.3

Re:

2022-05-19 Thread Matthew Auld
On Thu, 19 May 2022 at 10:55, Christian König wrote: > > Just sending that out once more to intel-gfx to let the CI systems take > a look. If all went well it should normally appear at [1][2], if CI was able to pick up the series. Since it's not currently there, I assume it's temporarily stuck

[PATCH v4] drm/doc: add rfc section for small BAR uapi

2022-05-17 Thread Matthew Auld
over. (Tvrtko) Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Lionel Landwerlin Cc: Tvrtko Ursulin Cc: Jon Bloomfield Cc: Daniel Vetter Cc: Jon Bloomfield Cc: Jordan Justen Cc: Kenneth Graunke Cc: Akeem G Abodunrin Cc: mesa-...@lists.freedesktop.org --- Documentation/gpu/rfc/i915_small_b

Re: [PATCH v3] drm/doc: add rfc section for small BAR uapi

2022-05-17 Thread Matthew Auld
On 17/05/2022 09:29, Tvrtko Ursulin wrote: On 16/05/2022 19:11, Matthew Auld wrote: Add an entry for the new uapi needed for small BAR on DG2+. v2:    - Some spelling fixes and other small tweaks. (Akeem & Thomas)    - Rework error capture interactions, including no longer nee

[PATCH v3] drm/doc: add rfc section for small BAR uapi

2022-05-16 Thread Matthew Auld
size. (Lionel) v3: - Drop the vma query for now. - Add unallocated_cpu_visible_size as part of the region query. - Improve the docs some more, including documenting the expected behaviour on older kernels, since this came up in some offline discussion. Signed-off-by: Matthew Auld Cc: Th

Re: Improve TTMs empty object handling

2022-05-13 Thread Matthew Auld
On Fri, 13 May 2022 at 14:03, Christian König wrote: > > Am 13.05.22 um 11:21 schrieb Matthew Auld: > > On Mon, 9 May 2022 at 14:09, Christian König > > wrote: > >> Hi everyone, > >> > >> re-sending this because Daniel was requesting a backgroun

Re: Improve TTMs empty object handling

2022-05-13 Thread Matthew Auld
On Mon, 9 May 2022 at 14:09, Christian König wrote: > > Hi everyone, > > re-sending this because Daniel was requesting a background why this is > useful. > > When TTM creates a buffer this object initially should not have any > backing store and there no resource object associated with it. The

Re: [PATCH] drm/i915: Use i915_gem_object_ggtt_pin_ww for reloc_iomap

2022-05-12 Thread Matthew Auld
On 11/05/2022 19:38, Maarten Lankhorst wrote: Op 11-05-2022 om 20:23 schreef Matthew Auld: On 11/05/2022 12:52, Maarten Lankhorst wrote: Instead of its own path, use the common path when it doesn't result in evicting any vma. This fixes the case where we don't wait for binding. https

Re: [PATCH] drm/i915: Use i915_gem_object_ggtt_pin_ww for reloc_iomap

2022-05-11 Thread Matthew Auld
for the bind doesn't seem to help? Fixes: b5cfe6f7a6e1 ("drm/i915: Remove short-term pins from execbuf, v6.") Cc: Matthew Auld Reported-by: Mateusz Jończyk Tested-by: Hans de Goede Signed-off-by: Maarten Lankhorst --- drivers/gpu/drm/i915/gem/i915_gem_execbuffer.c | 6 ++ 1 file

Re: [PATCH 1/2] drm/i915: Enable THP on Icelake and beyond

2022-05-09 Thread Matthew Auld
is run both in fullscreen and 1/2 screen window). """ Since the only regression is MemBW GPU blend, against many more gains, it sounds it is time to enable THP on Gen11+. Signed-off-by: Tvrtko Ursulin References: https://gitlab.freedesktop.org/drm/intel/-/issues/430 Cc: Joonas Lahti

Re: [Intel-gfx] [PATCH v2] drm/doc: add rfc section for small BAR uapi

2022-05-03 Thread Matthew Auld
On 28/04/2022 12:11, Tvrtko Ursulin wrote: On 28/04/2022 11:25, Matthew Auld wrote: On 28/04/2022 09:55, Tvrtko Ursulin wrote: On 27/04/2022 18:36, Matthew Auld wrote: On 27/04/2022 09:36, Tvrtko Ursulin wrote: On 20/04/2022 18:13, Matthew Auld wrote: Add an entry for the new uapi needed

Re: [PATCH v2] drm/doc: add rfc section for small BAR uapi

2022-05-03 Thread Matthew Auld
On 03/05/2022 11:39, Lionel Landwerlin wrote: On 03/05/2022 13:22, Matthew Auld wrote: On 02/05/2022 09:53, Lionel Landwerlin wrote: On 02/05/2022 10:54, Lionel Landwerlin wrote: On 20/04/2022 20:13, Matthew Auld wrote: Add an entry for the new uapi needed for small BAR on DG2+. v2

Re: [PATCH v2] drm/doc: add rfc section for small BAR uapi

2022-05-03 Thread Matthew Auld
On 02/05/2022 09:53, Lionel Landwerlin wrote: On 02/05/2022 10:54, Lionel Landwerlin wrote: On 20/04/2022 20:13, Matthew Auld wrote: Add an entry for the new uapi needed for small BAR on DG2+. v2:    - Some spelling fixes and other small tweaks. (Akeem & Thomas)    - Rework error cap

Re: [PATCH v2] drm/doc: add rfc section for small BAR uapi

2022-05-03 Thread Matthew Auld
; Bloomfield, Jon ; Daniel Vetter ; Justen, Jordan L ; Kenneth Graunke ; Abodunrin, Akeem G ; mesa-...@lists.freedesktop.org Subject: Re: [PATCH v2] drm/doc: add rfc section for small BAR uapi On 20/04/2022 20:13, Matthew Auld wrote: Add an entry for the new uapi needed for small BAR on DG2+. v2

Re: [PATCH v2] drm/doc: add rfc section for small BAR uapi

2022-05-03 Thread Matthew Auld
On 02/05/2022 08:54, Lionel Landwerlin wrote: On 20/04/2022 20:13, Matthew Auld wrote: Add an entry for the new uapi needed for small BAR on DG2+. v2:    - Some spelling fixes and other small tweaks. (Akeem & Thomas)    - Rework error capture interactions, including no longer nee

Re: [Intel-gfx] [PATCH 3/3] drm/i915/gt: Clear SET_PREDICATE_RESULT prior to executing the ring

2022-04-29 Thread Matthew Auld
t; batch. This allows us to protect the kernel's ring without changing the > uABI. > > Suggested-by: Zbigniew Kempczynski > Signed-off-by: Chris Wilson > Cc: Zbigniew Kempczynski > Cc: Thomas Hellstrom > Signed-off-by: Ramalingam C Reviewed-by: Matthew Auld

Re: [PATCH 2/3] drm/i915/selftests: Skip poisoning SET_PREDICATE_RESULT on dg2

2022-04-29 Thread Matthew Auld
as Lahtinen > Suggested-by: CQ Tang > Signed-off-by: Chris Wilson > Signed-off-by: Ramalingam C Reviewed-by: Matthew Auld

Re: [Intel-gfx] [PATCH 1/3] drm/i915/xehpsdv/dg1/tgl: Fix issue with LRI relative addressing

2022-04-29 Thread Matthew Auld
> mismatch between LRC register layout generated during init and HW > default register offsets. > > Signed-off-by: Akeem G Abodunrin > cc: Prathap Kumar Valsan > Signed-off-by: Ramalingam C Reviewed-by: Matthew Auld

Re: [Intel-gfx] [PATCH v2] drm/doc: add rfc section for small BAR uapi

2022-04-28 Thread Matthew Auld
On 28/04/2022 09:55, Tvrtko Ursulin wrote: On 27/04/2022 18:36, Matthew Auld wrote: On 27/04/2022 09:36, Tvrtko Ursulin wrote: On 20/04/2022 18:13, Matthew Auld wrote: Add an entry for the new uapi needed for small BAR on DG2+. v2:    - Some spelling fixes and other small tweaks. (Akeem

Re: [PATCH v2 1/4] drm/i915/gt: GEM_BUG_ON unexpected NULL at scatterlist walking

2022-04-27 Thread Matthew Auld
o_copy). +*/ + GEM_BUG_ON(!it->sg); It will crash and burn anyway, with the below NULL deref. Not sure if BUG_ON() is really much better, but I guess with the additional comment, Reviewed-by: Matthew Auld it->dma = sg_dma_address(it->sg);

Re: [PATCH v2 2/4] drm/i915/gt: optimize the ccs_sz calculation per chunk

2022-04-27 Thread Matthew Auld
dst_sz; bool ccs_is_src; int err; @@ -770,7 +762,7 @@ intel_context_migrate_copy(struct intel_context *ce, } do { - int len; + int len, ccs_sz; This could be moved into the reduced scope below. Reviewed-by: Matthew Auld

Re: [Intel-gfx] [PATCH v2] drm/doc: add rfc section for small BAR uapi

2022-04-27 Thread Matthew Auld
On 27/04/2022 09:36, Tvrtko Ursulin wrote: On 20/04/2022 18:13, Matthew Auld wrote: Add an entry for the new uapi needed for small BAR on DG2+. v2:    - Some spelling fixes and other small tweaks. (Akeem & Thomas)    - Rework error capture interactions, including no longer nee

Re: [PATCH v2 4/4] uapi/drm/i915: Document memory residency and Flat-CCS capability of obj

2022-04-27 Thread Matthew Auld
cc: Matthew Auld cc: Thomas Hellstrom --- include/uapi/drm/i915_drm.h | 18 ++ 1 file changed, 18 insertions(+) diff --git a/include/uapi/drm/i915_drm.h b/include/uapi/drm/i915_drm.h index 35ca528803fd..ad191ed6547c 100644 --- a/include/uapi/drm/i915_drm.h +++ b/include/uapi/drm

Re: [PATCH v2 3/4] drm/i915/gt: Document the eviction of the Flat-CCS objects

2022-04-27 Thread Matthew Auld
On 25/04/2022 17:24, Ramalingam C wrote: Capture the eviction details for Flat-CCS capable, lmem objects. v2: Fix the Flat-ccs capbility of lmem obj with smem residency possibility [Thomas] Signed-off-by: Ramalingam C cc: Thomas Hellstrom cc: Matthew Auld --- drivers/gpu/drm/i915/gt

Re: [PATCH v2] drm/doc: add rfc section for small BAR uapi

2022-04-27 Thread Matthew Auld
:35, Lionel Landwerlin wrote: Hi Matt, The proposal looks good to me. Looking forward to try it on drm-tip. -Lionel On 20/04/2022 20:13, Matthew Auld wrote: Add an entry for the new uapi needed for small BAR on DG2+. v2:    - Some spelling fixes and other small tweaks. (Akeem & Th

Re: [PATCH v2] drm/doc: add rfc section for small BAR uapi

2022-04-27 Thread Matthew Auld
ss? You made a comment stating this is racy, wouldn't querying on the GEM object prevent this? Thanks, -Lionel On 27/04/2022 09:35, Lionel Landwerlin wrote: Hi Matt, The proposal looks good to me. Looking forward to try it on drm-tip. -Lionel On 20/04/2022 20:13, Matthew Auld wrote: Add an

[CI 2/4] drm/i915/buddy: sanity check the size

2022-04-20 Thread Matthew Auld
-by: Matthew Auld Cc: Thomas Hellström Cc: Nirmoy Das Reviewed-by: Nirmoy Das --- drivers/gpu/drm/i915/i915_ttm_buddy_manager.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/i915/i915_ttm_buddy_manager.c b/drivers/gpu/drm/i915/i915_ttm_buddy_manager.c index 8e4e3f72c1ef

[CI 3/4] drm/i915/selftests: fixup min_alignment usage

2022-04-20 Thread Matthew Auld
Trying to cast the region id into the region type doesn't work too well, since the i915_vm_min_alignment() won't give us the correct value for the stolen-lmem case. Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Nirmoy Das Cc: Ramalingam C --- drivers/gpu/drm/i915/selftests

[CI 4/4] drm/i915/selftests: tweak the misaligned_case

2022-04-20 Thread Matthew Auld
The compact-pt layout restrictions should only apply to the ppGTT. Also make this play nice on platforms that only have the 64K GTT restriction, and not the compact-pt thing. Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Nirmoy Das Cc: Ramalingam C --- drivers/gpu/drm/i915/selftests

[CI 1/4] drm/i915: consider min_page_size when migrating

2022-04-20 Thread Matthew Auld
9] DR3: DR6: fffe0ff0 DR7: 0400 [ 2857.497692] Call Trace: [ 2857.497694] [ 2857.497697] intel_context_migrate_copy+0x1e5/0x4f0 [i915] Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Nirmoy Das Reviewed-by: Nirmoy Das --- drivers/gpu/drm/i9

[PATCH v2] drm/doc: add rfc section for small BAR uapi

2022-04-20 Thread Matthew Auld
size. (Lionel) Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Lionel Landwerlin Cc: Jon Bloomfield Cc: Daniel Vetter Cc: Jordan Justen Cc: Kenneth Graunke Cc: Akeem G Abodunrin Cc: mesa-...@lists.freedesktop.org --- Documentation/gpu/rfc/i915_small_bar.h |

[PATCH v2] drm/ttm: fixup ttm_bo_add_move_fence

2022-04-13 Thread Matthew Auld
moving") Cc: Christian König Cc: Daniel Vetter Signed-off-by: Matthew Auld Reviewed-by: Christian König Reviewed-by: Daniel Vetter --- drivers/gpu/drm/ttm/ttm_bo.c | 8 +++- 1 file changed, 3 insertions(+), 5 deletions(-) diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/tt

[PATCH] drm/ttm: fixup ttm_bo_add_move_fence

2022-04-13 Thread Matthew Auld
l Vetter Signed-off-by: Matthew Auld --- drivers/gpu/drm/ttm/ttm_bo.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/drivers/gpu/drm/ttm/ttm_bo.c b/drivers/gpu/drm/ttm/ttm_bo.c index 015a94f766de..b15b77e10383 100644 --- a/drivers/gpu/drm/ttm/ttm_bo.c +++ b/drivers/gpu/drm/ttm/ttm_bo.c

Re: [PATCH] drm/ttm: stop passing NULL fence in ttm_bo_move_sync_cleanup

2022-04-12 Thread Matthew Auld
On 11/04/2022 13:39, Christian König wrote: Am 11.04.22 um 10:56 schrieb Matthew Auld: If we hit the sync case, like when skipping clearing for kernel internal objects, or when falling back to cpu clearing, like in i915, we end up trying to add a NULL fence, but with some recent changes

Re: [igt-dev] [PATCH i-g-t v2] tests/drm_buddy: Add drm buddy test cases

2022-04-12 Thread Matthew Auld
On Mon, 11 Apr 2022 at 19:51, Arunpravin Paneer Selvam wrote: > > Add a set of drm buddy test cases to validate the > drm/drm_buddy.c memory allocator. > > v2: sorted in alphabetical order > > Signed-off-by: Arunpravin Paneer Selvam > Reviewed-by: Matthew Auld Tests

Re: [PATCH] drm/ttm: fix logic inversion in ttm_eu_reserve_buffers

2022-04-11 Thread Matthew Auld
g a shared slot mandatory v4") Reviewed-by: Matthew Auld --- drivers/gpu/drm/ttm/ttm_execbuf_util.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/drivers/gpu/drm/ttm/ttm_execbuf_util.c b/drivers/gpu/drm/ttm/ttm_execbuf_util.c index 0eb995d25df1..dbee34a058df 1006

Re: [PATCH v3] drm: add a check to verify the size alignment

2022-04-11 Thread Matthew Auld
On 11/04/2022 13:42, Christian König wrote: Am 11.04.22 um 11:47 schrieb Matthew Auld: On 11/04/2022 08:38, Arunpravin Paneer Selvam wrote: Add a simple check to reject any size not aligned to the min_page_size. when size is not aligned to min_page_size, driver module should handle

Re: [PATCH] drm/ttm: stop passing NULL fence in ttm_bo_move_sync_cleanup

2022-04-11 Thread Matthew Auld
On 11/04/2022 10:56, Thomas Hellström wrote: Hi, Matthew On 4/11/22 10:56, Matthew Auld wrote: If we hit the sync case, like when skipping clearing for kernel internal objects, or when falling back to cpu clearing, like in i915, we end up trying to add a NULL fence, but with some recent

Re: [PATCH v3] drm: add a check to verify the size alignment

2022-04-11 Thread Matthew Auld
with min_order = 8, triggers the BUG_ON(order < min_order). v2: add more commit description v3: remove WARN_ON() Signed-off-by: Arunpravin Paneer Selvam Suggested-by: Matthew Auld Reviewed-by: Matthew Auld

Re: [PATCH] tests/drm_buddy: Add drm buddy test cases

2022-04-11 Thread Matthew Auld
0644 --- a/tests/meson.build +++ b/tests/meson.build @@ -10,6 +10,7 @@ test_progs = [ 'device_reset', 'drm_import_export', 'drm_mm', + 'drm_buddy', Nit: Should be kept sorted. No need to resend though. Reviewed-by: Matthew Auld 'drm_read', 'fbdev',

[PATCH] drm/ttm: stop passing NULL fence in ttm_bo_move_sync_cleanup

2022-04-11 Thread Matthew Auld
x3e/0x2b0 <4>[5.467704] intel_alloc_initial_plane_obj.isra.6+0x1a9/0x390 [i915] <4>[5.467833] intel_crtc_initial_plane_config+0x83/0x340 [i915] In the ttm_bo_move_sync_cleanup() case it seems we only really care about calling ttm_bo_wait_free_node(), so let's instead

ttm_bo_move_sync_cleanup() issue

2022-04-08 Thread Matthew Auld
Hi Christian, We seem to be hitting a new issue in ttm_bo_move_sync_cleanup(), due to passing a NULL fence, and I guess with some recent changes this is now blowing up in at least dma_resv_add_fence(). Question is how should we handle this? Should we add a special case in

Re: [PATCH v2] drm/i915: fix i915_gem_object_wait_moving_fence

2022-04-08 Thread Matthew Auld
On 08/04/2022 10:48, Matthew Auld wrote: On 08/04/2022 09:59, Christian König wrote: Am 08.04.22 um 10:42 schrieb Matthew Auld: All of CI is just failing with the following, which prevents loading of the module: i915 :03:00.0: [drm] *ERROR* Scratch setup failed Best guess

Re: [PATCH v2] drm/i915: fix i915_gem_object_wait_moving_fence

2022-04-08 Thread Matthew Auld
On 08/04/2022 09:59, Christian König wrote: Am 08.04.22 um 10:42 schrieb Matthew Auld: All of CI is just failing with the following, which prevents loading of the module: i915 :03:00.0: [drm] *ERROR* Scratch setup failed Best guess is that this comes from the pin_map

[PATCH v2] drm/i915: fix i915_gem_object_wait_moving_fence

2022-04-08 Thread Matthew Auld
calls into dma_resv_wait_timeout() which can return the remaining timeout, leading to the caller thinking this is an error. v2(Lucas): handle ret == 0 Fixes: 1d7f5e6c5240 ("drm/i915: drop bo->moving dependency") Signed-off-by: Matthew Auld Cc: Christian König Cc: Lucas De March

Re: [PATCH 1/2] drm/i915: fix broken build

2022-04-08 Thread Matthew Auld
On 07/04/2022 17:49, Christian König wrote: Am 07.04.22 um 18:45 schrieb Matthew Auld: I guess this was missed in the conversion or something. Fixes: 7bc80a5462c3 ("dma-buf: add enum dma_resv_usage v4") Signed-off-by: Matthew Auld Cc: Christian König Cc: Daniel Vetter My

Re: [Intel-gfx] [PATCH 2/2] drm/i915: fix i915_gem_object_wait_moving_fence

2022-04-08 Thread Matthew Auld
On 08/04/2022 06:00, Lucas De Marchi wrote: On Thu, Apr 07, 2022 at 05:45:32PM +0100, Matthew Auld wrote: All of CI is just failing with the following, which prevents loading of the module:    i915 :03:00.0: [drm] *ERROR* Scratch setup failed Best guess is that this comes from the pin_map

Re: [PATCH 1/2] drm/i915: fix broken build

2022-04-07 Thread Matthew Auld
On 07/04/2022 17:49, Christian König wrote: Am 07.04.22 um 18:45 schrieb Matthew Auld: I guess this was missed in the conversion or something. Fixes: 7bc80a5462c3 ("dma-buf: add enum dma_resv_usage v4") Signed-off-by: Matthew Auld Cc: Christian König Cc: Daniel Vetter My

[PATCH 2/2] drm/i915: fix i915_gem_object_wait_moving_fence

2022-04-07 Thread Matthew Auld
calls into dma_resv_wait_timeout() which can return the remaining timeout, leading to the caller thinking this is an error. Fixes: 1d7f5e6c5240 ("drm/i915: drop bo->moving dependency") Signed-off-by: Matthew Auld Cc: Christian König Cc: Daniel Vetter --- drivers/gpu

[PATCH 1/2] drm/i915: fix broken build

2022-04-07 Thread Matthew Auld
I guess this was missed in the conversion or something. Fixes: 7bc80a5462c3 ("dma-buf: add enum dma_resv_usage v4") Signed-off-by: Matthew Auld Cc: Christian König Cc: Daniel Vetter --- drivers/gpu/drm/i915/i915_deps.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-)

[PATCH 2/2] drm/i915/buddy: sanity check the size

2022-04-07 Thread Matthew Auld
-by: Matthew Auld Cc: Thomas Hellström Cc: Nirmoy Das --- drivers/gpu/drm/i915/i915_ttm_buddy_manager.c | 1 + 1 file changed, 1 insertion(+) diff --git a/drivers/gpu/drm/i915/i915_ttm_buddy_manager.c b/drivers/gpu/drm/i915/i915_ttm_buddy_manager.c index 8e4e3f72c1ef..a5109548abc0 100644

[PATCH 1/2] drm/i915: consider min_page_size when migrating

2022-04-07 Thread Matthew Auld
9] DR3: DR6: fffe0ff0 DR7: 0400 [ 2857.497692] Call Trace: [ 2857.497694] [ 2857.497697] intel_context_migrate_copy+0x1e5/0x4f0 [i915] Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Nirmoy Das Reviewed-by: Nirmoy Das --- drivers/gpu/drm/i9

[PATCH 2/2] drm/i915/selftests: tweak the misaligned_case

2022-04-06 Thread Matthew Auld
The compact-pt layout restrictions should only apply to the ppGTT. Also make this play nice on platforms that only have the 64K GTT restriction, and not the compact-pt thing. Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Nirmoy Das --- drivers/gpu/drm/i915/selftests/i915_gem_gtt.c | 12

[PATCH 1/2] drm/i915/selftests: fixup min_alignment usage

2022-04-06 Thread Matthew Auld
Trying to cast the region id into the region type doesn't work too well, since the i915_vm_min_alignment() won't give us the correct value for the stolen-lmem case. Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Nirmoy Das --- drivers/gpu/drm/i915/selftests/i915_gem_gtt.c | 2 +- 1 file

[PATCH] drm/i915: consider min_page_size when migrating

2022-04-06 Thread Matthew Auld
9] DR3: DR6: fffe0ff0 DR7: 0400 [ 2857.497692] Call Trace: [ 2857.497694] [ 2857.497697] intel_context_migrate_copy+0x1e5/0x4f0 [i915] Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Nirmoy Das --- drivers/gpu/drm/i915/gem/i915_gem_object.c

Re: [PATCH 14/16] drm/i915: drop bo->moving dependency

2022-04-06 Thread Matthew Auld
On Wed, 6 Apr 2022 at 08:52, Christian König wrote: > > That should now be handled by the common dma_resv framework. > > Signed-off-by: Christian König > Reviewed-by: Daniel Vetter > Cc: intel-...@lists.freedesktop.org > --- > drivers/gpu/drm/i915/gem/i915_gem_object.c| 41

Re: [Intel-gfx] Small bar recovery vs compressed content on DG2

2022-03-31 Thread Matthew Auld
On 18/03/2022 18:12, Daniel Vetter wrote: Maybe also good to add dri-devel to these discussions. I'm not sure where exactly we landed with dgpu error capture (maybe I should check the code but it's really w/e here), but I think we can also toss in "you need a non-recoverable context for error

Re: [PATCH v2] drm: add a check to verify the size alignment

2022-03-29 Thread Matthew Auld
the order value which is 0 > >> and when it compares with min_order = 8, triggers the BUG_ON(order > >> < min_order). To avoid this problem, we added a simple check to > >> return -EINVAL if size is not aligned to the min_page_size. > >> > >> v2

[PATCH 2/2] drm/i915/migrate: move the sanity check

2022-03-24 Thread Matthew Auld
Move the sanity check that both src and dst are never both system memory, which should never happen on discrete, and likely means we have a bug. The only exception is on integrated where we trigger this path in the selftests. Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Nirmoy Das

[PATCH 1/2] drm/i915/ttm: limit where we apply TTM_PL_FLAG_CONTIGUOUS

2022-03-24 Thread Matthew Auld
move when not needed, since the current placement is seen as not compatible. Suggested-by: Thomas Hellström Fixes: 2ed38cec5606 ("drm/i915: opportunistically apply ALLOC_CONTIGIOUS") Signed-off-by: Matthew Auld Cc: Nirmoy Das --- drivers/gpu/drm/i915/gem/i915_gem_ttm.c | 3 +++ 1 file c

Re: [PATCH v6 4/7] drm/i915/gt: create per-tile sysfs interface

2022-03-18 Thread Matthew Auld
On 18/03/2022 02:10, Andi Shyti wrote: Now that we have tiles we want each of them to have its own interface. A directory "gt/" is created under "cardN/" that will contain as many diroctories as the tiles. In the coming patches tile related interfaces will be added. For now the sysfs gt

Re: [Intel-gfx] [PATCH 2/2] drm/doc: add rfc section for small BAR uapi

2022-03-18 Thread Matthew Auld
-Lionel On 18/02/2022 13:22, Matthew Auld wrote: Add an entry for the new uapi needed for small BAR on DG2+. Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Jon Bloomfield Cc: Daniel Vetter Cc: Jordan Justen Cc: Kenneth Graunke Cc: mesa-...@lists.freedesktop.org ---   Documentatio

Re: [PATCH v2] drm: Fix a infinite loop condition when order becomes 0

2022-03-16 Thread Matthew Auld
On 16/03/2022 06:34, Arunpravin Paneer Selvam wrote: handle a situation in the condition order-- == min_order, when order = 0 and min_order = 0, leading to order = -1, it now won't exit the loop. To avoid this problem, added a order check in the same condition, (i.e) when order is 0, we return

Re: [PATCH] drm: Fix a infinite loop condition when order becomes 0

2022-03-15 Thread Matthew Auld
On 14/03/2022 19:40, Arunpravin wrote: handle a situation in the condition order-- == min_order, when order = 0, leading to order = -1, it now won't exit the loop. To avoid this problem, added a order check in the same condition, (i.e) when order is 0, we return -ENOSPC Signed-off-by:

Re: [Intel-gfx] [PATCH] drm/i915: round_up the size to the alignment value

2022-03-15 Thread Matthew Auld
On Mon, 14 Mar 2022 at 19:32, Arunpravin wrote: > > handle instances when size is not aligned with the min_page_size. > Unigine Heaven has allocation requests for example required pages > are 161 and alignment request is 128. To allocate the left over > 33 pages, continues the iteration to find

[PATCH v3 0/7] Some more bits for small BAR enabling

2022-03-14 Thread Matthew Auld
The leftover bits around dealing with stolen-local memory + small BAR, plus some related fixes. v2: some tweaks based on feedback from Ville v3: directly probe the PTE to derive the physical offset within lmem -- 2.34.1

[PATCH v3 1/7] drm/i915/lmem: don't treat small BAR as an error

2022-03-14 Thread Matthew Auld
Just pass along the probed io_size. The backend should be able to utilize the entire range here, even if some of it is non-mappable. It does leave open with what to do with stolen local-memory. Signed-off-by: Matthew Auld Cc: Thomas Hellström Reviewed-by: Thomas Hellström Acked-by: Nirmoy Das

[PATCH v3 5/7] drm/i915/ttm: wire up the object offset

2022-03-14 Thread Matthew Auld
For the ttm backend we can use existing placements fpfn and lpfn to force the allocator to place the object at the requested offset, potentially evicting stuff if the spot is currently occupied. Signed-off-by: Matthew Auld Cc: Thomas Hellström Acked-by: Nirmoy Das --- .../gpu/drm/i915/gem

[PATCH v3 2/7] drm/i915/stolen: don't treat small BAR as an error

2022-03-14 Thread Matthew Auld
on platforms like DG2). For simplicity we don't attempt to support partially mappable stolen. Signed-off-by: Akeem G Abodunrin Co-developed-by: Matthew Auld Signed-off-by: Matthew Auld Cc: Thomas Hellström Acked-by: Nirmoy Das --- drivers/gpu/drm/i915/gem/i915_gem_stolen.c | 48

[PATCH v3 4/7] drm/i915: add i915_gem_object_create_region_at()

2022-03-14 Thread Matthew Auld
Add a generic interface for allocating an object at some specific offset, and convert stolen over. Later we will want to hook this up to different backends. Signed-off-by: Matthew Auld Cc: Thomas Hellström Acked-by: Nirmoy Das --- .../drm/i915/display/intel_plane_initial.c| 4 +- drivers

[PATCH v3 3/7] drm/i915/stolen: consider I915_BO_ALLOC_GPU_ONLY

2022-03-14 Thread Matthew Auld
Keep the behaviour consistent with normal lmem, where we assume CPU access if by default required. Signed-off-by: Matthew Auld Cc: Thomas Hellström Acked-by: Nirmoy Das --- drivers/gpu/drm/i915/gem/i915_gem_stolen.c | 8 1 file changed, 8 insertions(+) diff --git a/drivers/gpu/drm

[PATCH v3 7/7] drm/i915: fixup the initial fb base on DGFX

2022-03-14 Thread Matthew Auld
address, before allocating from stolen. - Bail if it's not located in dsm. v3: - Scratch that. There doesn't seem to be any relationship with the base and PTE address, on at least DG1. Let's instead just grab the lmem address from the PTE itself. Signed-off-by: Matthew Auld Cc: Thomas

[PATCH v3 6/7] drm/i915/display: Check mappable aperture when pinning preallocated vma

2022-03-14 Thread Matthew Auld
hna Sripada Cc: Ap Kamal Reviewed-by: Matthew Auld Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Ville Syrjälä Acked-by: Nirmoy Das --- drivers/gpu/drm/i915/display/intel_plane_initial.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/disp

Re: [Intel-gfx] [PATCH v2 6/8] drm/i915/display: Check mappable aperture when pinning preallocated vma

2022-03-11 Thread Matthew Auld
On Thu, 10 Mar 2022 at 12:28, Matthew Auld wrote: > > From: CQ Tang > > When system does not have mappable aperture, ggtt->mappable_end=0. In > this case if we pass PIN_MAPPABLE when pinning vma, the pinning code > will return -ENOSPC. So conditionally set PIN

Re: [PATCH] drm: remove min_order BUG_ON check

2022-03-10 Thread Matthew Auld
On 10/03/2022 14:47, Arunpravin wrote: On 08/03/22 10:31 pm, Matthew Auld wrote: On 08/03/2022 13:59, Arunpravin wrote: On 07/03/22 10:11 pm, Matthew Auld wrote: On 07/03/2022 14:37, Arunpravin wrote: place BUG_ON(order < min_order) outside do..while loop as it fails Unigine Hea

[PATCH v2 7/8] drm/i915: fixup the initial fb base on DG1

2022-03-10 Thread Matthew Auld
be some offset within lmem, but this also happens to be the exact dsm start, on dg1. Therefore we should only need to fudge the physical address, before allocating from stolen. - Bail if it's not located in dsm. Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Ville Syrjälä --- .../drm

[PATCH v2 8/8] drm/i915: fixup the initial fb on DG2

2022-03-10 Thread Matthew Auld
On DG2+ the initial fb shouldn't be placed anywhere close to DSM, and so should just be allocated directly from LMEM. Signed-off-by: Matthew Auld Cc: Thomas Hellström --- .../drm/i915/display/intel_plane_initial.c| 46 +++ 1 file changed, 27 insertions(+), 19 deletions

[PATCH v2 6/8] drm/i915/display: Check mappable aperture when pinning preallocated vma

2022-03-10 Thread Matthew Auld
hna Sripada Cc: Ap Kamal Signed-off-by: Matthew Auld Cc: Thomas Hellström Cc: Ville Syrjälä --- drivers/gpu/drm/i915/display/intel_plane_initial.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/display/intel_plane_initial.c b/drivers/gpu/drm/i

[PATCH v2 4/8] drm/i915: add i915_gem_object_create_region_at()

2022-03-10 Thread Matthew Auld
Add a generic interface for allocating an object at some specific offset, and convert stolen over. Later we will want to hook this up to different backends. Signed-off-by: Matthew Auld Cc: Thomas Hellström --- .../drm/i915/display/intel_plane_initial.c| 4 +- drivers/gpu/drm/i915/gem

[PATCH v2 3/8] drm/i915/stolen: consider I915_BO_ALLOC_GPU_ONLY

2022-03-10 Thread Matthew Auld
Keep the behaviour consistent with normal lmem, where we assume CPU access if by default required. Signed-off-by: Matthew Auld Cc: Thomas Hellström --- drivers/gpu/drm/i915/gem/i915_gem_stolen.c | 8 1 file changed, 8 insertions(+) diff --git a/drivers/gpu/drm/i915/gem

[PATCH v2 5/8] drm/i915/ttm: wire up the object offset

2022-03-10 Thread Matthew Auld
For the ttm backend we can use existing placements fpfn and lpfn to force the allocator to place the object at the requested offset, potentially evicting stuff if the spot is currently occupied. Signed-off-by: Matthew Auld Cc: Thomas Hellström --- .../gpu/drm/i915/gem/i915_gem_object_types.h

[PATCH v2 1/8] drm/i915/lmem: don't treat small BAR as an error

2022-03-10 Thread Matthew Auld
Just pass along the probed io_size. The backend should be able to utilize the entire range here, even if some of it is non-mappable. It does leave open with what to do with stolen local-memory. Signed-off-by: Matthew Auld Cc: Thomas Hellström Reviewed-by: Thomas Hellström --- drivers/gpu/drm

[PATCH v2 2/8] drm/i915/stolen: don't treat small BAR as an error

2022-03-10 Thread Matthew Auld
on platforms like DG2). For simplicity we don't attempt to support partially mappable stolen. Signed-off-by: Akeem G Abodunrin Co-developed-by: Matthew Auld Signed-off-by: Matthew Auld Cc: Thomas Hellström --- drivers/gpu/drm/i915/gem/i915_gem_stolen.c | 48 -- drivers/gpu/drm/i915

[PATCH v2 0/8] Some more bits for small BAR enabling

2022-03-10 Thread Matthew Auld
The leftover bits around dealing with stolen-local memory + small BAR, plus some related fixes. v2: some tweaks based on feedback from Ville -- 2.34.1

Re: [PATCH] drm: remove min_order BUG_ON check

2022-03-08 Thread Matthew Auld
On 08/03/2022 13:59, Arunpravin wrote: On 07/03/22 10:11 pm, Matthew Auld wrote: On 07/03/2022 14:37, Arunpravin wrote: place BUG_ON(order < min_order) outside do..while loop as it fails Unigine Heaven benchmark. Unigine Heaven has buffer allocation requests for example required pa

Re: [PATCH] drm/doc: pull in drm_buddy.c

2022-03-08 Thread Matthew Auld
On 09/02/2022 07:32, Christian König wrote: Am 08.02.22 um 16:12 schrieb Matthew Auld: Make sure we pull in the kernel-doc for this. Reported-by: Daniel Vetter Signed-off-by: Matthew Auld Cc: Arunpravin Cc: Christian König Reviewed-by: Christian König Thanks. Could you also push

Re: [Intel-gfx] [PATCH 7/8] drm/i915: fixup the initial fb base on DG1

2022-03-07 Thread Matthew Auld
On Mon, 7 Mar 2022 at 18:41, Ville Syrjälä wrote: > > On Mon, Mar 07, 2022 at 06:26:32PM +, Matthew Auld wrote: > > On 07/03/2022 17:06, Ville Syrjälä wrote: > > > On Mon, Mar 07, 2022 at 10:32:36AM +, Matthew Auld wrote: > > >> On 04/03/2022 19:33, Vi

Re: [PATCH 7/8] drm/i915: fixup the initial fb base on DG1

2022-03-07 Thread Matthew Auld
On 07/03/2022 17:06, Ville Syrjälä wrote: On Mon, Mar 07, 2022 at 10:32:36AM +, Matthew Auld wrote: On 04/03/2022 19:33, Ville Syrjälä wrote: On Fri, Mar 04, 2022 at 05:23:32PM +, Matthew Auld wrote: The offset we get looks to be the exact start of DSM, but the inital_plane_vma

Re: [PATCH] drm: remove min_order BUG_ON check

2022-03-07 Thread Matthew Auld
On 07/03/2022 14:37, Arunpravin wrote: place BUG_ON(order < min_order) outside do..while loop as it fails Unigine Heaven benchmark. Unigine Heaven has buffer allocation requests for example required pages are 161 and alignment request is 128. To allocate the remaining 33 pages, continues the

Re: [PATCH v3 4/6] drm/i915/gem: Add extra pages in ttm_tt for ccs data

2022-03-07 Thread Matthew Auld
On 07/03/2022 13:40, Ramalingam C wrote: On Xe-HP and later devices, dedicated compression control state (CCS) stored in local memory is used for each surface, to support the 3D and media compression formats. The memory required for the CCS of the entire local memory is 1/256 of the local

Re: [PATCH 7/8] drm/i915: fixup the initial fb base on DG1

2022-03-07 Thread Matthew Auld
On 04/03/2022 19:33, Ville Syrjälä wrote: On Fri, Mar 04, 2022 at 05:23:32PM +, Matthew Auld wrote: The offset we get looks to be the exact start of DSM, but the inital_plane_vma expects the address to be relative. Signed-off-by: Matthew Auld Cc: Thomas Hellström --- .../drm/i915

[PATCH] drm/i915: stop checking for NULL vma->obj

2022-03-04 Thread Matthew Auld
This is no longer possible since e6e1a304d759 ("drm/i915: vma is always backed by an object."). Signed-off-by: Matthew Auld Cc: Thomas Hellström --- drivers/gpu/drm/i915/i915_vma.c | 17 +++-- 1 file changed, 7 insertions(+), 10 deletions(-) diff --git a/drivers/gp

[PATCH 8/8] drm/i915: fixup the initial fb on DG2

2022-03-04 Thread Matthew Auld
On DG2+ the initial fb shouldn't be placed anywhere close to DSM, and so should just be allocated directly from LMEM. Signed-off-by: Matthew Auld Cc: Thomas Hellström --- drivers/gpu/drm/i915/display/intel_plane_initial.c | 10 +++--- 1 file changed, 7 insertions(+), 3 deletions(-) diff

[PATCH 7/8] drm/i915: fixup the initial fb base on DG1

2022-03-04 Thread Matthew Auld
The offset we get looks to be the exact start of DSM, but the inital_plane_vma expects the address to be relative. Signed-off-by: Matthew Auld Cc: Thomas Hellström --- .../drm/i915/display/intel_plane_initial.c| 22 +++ 1 file changed, 18 insertions(+), 4 deletions(-) diff

[PATCH 6/8] drm/i915/display: Check mappable aperture when pinning preallocated vma

2022-03-04 Thread Matthew Auld
hna Sripada Cc: Ap Kamal Signed-off-by: Matthew Auld Cc: Thomas Hellström --- drivers/gpu/drm/i915/display/intel_plane_initial.c | 6 +- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/drivers/gpu/drm/i915/display/intel_plane_initial.c b/drivers/gpu/drm/i915/disp

[PATCH 4/8] drm/i915/buddy: tweak CONTIGUOUS rounding

2022-03-04 Thread Matthew Auld
If this is an actual range allocation, and not some bias thing then the resultant allocation will already be naturally contiguous without needing any power-of-two rounding. Signed-off-by: Matthew Auld Cc: Thomas Hellström --- drivers/gpu/drm/i915/i915_ttm_buddy_manager.c | 3 ++- 1 file

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