ommon path of ttm_device init into a function.
Signed-off-by: Karolina Stolarek
Reviewed-by: Somalapuram, Amaranath
Tested-by: Somalapuram, Amaranath
---
.../gpu/drm/ttm/tests/ttm_bo_validate_test.c | 433 ++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 106 -
drivers/g
Add mock resource manager to test ttm_bo_validate() with non-system
placements. Update KConfig entry to enable DRM Buddy allocator, used
by the mock manager. Update move function to do more than just assign
a resource.
Signed-off-by: Karolina Stolarek
Tested-by: Somalapuram, Amaranath
List improvements for the test suite with some notes.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/TODO | 25 +
1 file changed, 25 insertions(+)
create mode 100644 drivers/gpu/drm/ttm/tests/TODO
diff --git a/drivers/gpu/drm/ttm/tests/TODO b/drivers
Add tests for functions that add and release pages to TTs. Test the
swapin operation. Export ttm_tt_unpopulate, ttm_tt_swapin and
ttm_tt_swapout symbols for testing purposes.
Signed-off-by: Karolina Stolarek
Reviewed-by: Somalapuram, Amaranath
Tested-by: Somalapuram, Amaranath
---
drivers/gpu
Add test cases that check how the state of dma fences in BO's
reservation object influence the ttm_bo_validation() flow. Do similar
tests for resource manager's move fence.
Signed-off-by: Karolina Stolarek
Reviewed-by: Somalapuram, Amaranath
Tested-by: Somalapuram, Amaranath
---
.../gpu/drm
Add tests for ttm_bo_init_reserved() and ttm_bo_validate() that use
sys manager. Define a simple move function in ttm_device_funcs. Expose
destroy callback of the buffer object to make testing of
ttm_bo_init_reserved() behaviour easier.
Signed-off-by: Karolina Stolarek
Reviewed-by: Matthew Auld
Add a new helper function that also initializes the device. Use it in
ttm_tt test suite and delete the local definition.
Signed-off-by: Karolina Stolarek
Reviewed-by: Matthew Auld
Reviewed-by: Somalapuram, Amaranath
---
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 14
t mappings to unblock testing.
Signed-off-by: Karolina Stolarek
Reviewed-by: Nirmoy Das
---
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c
b/drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c
index 5b
: 995279d280d1 ("drm/ttm/tests: Add tests for ttm_bo functions")
Suggested-by: Christian König
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_bo_test.c | 40 +++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 7 +++-
drivers/gpu/drm/ttm/tests/ttm_kunit
DRM KUnit helpers are selected automatically when TTM tests are enabled,
so there's no need to do it directly in the .kunitconfig file.
Signed-off-by: Karolina Stolarek
Reviewed-by: Nirmoy Das
---
drivers/gpu/drm/ttm/tests/.kunitconfig | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers
and should
be checked again
Karolina Stolarek (10):
drm/ttm/tests: Fix a warning in ttm_bo_unreserve_bulk
drm/ttm/tests: Delete unnecessary config option
drm/ttm/tests: Set DMA mask in KUnit device
drm/ttm/tests: Use an init function from the helpers lib
drm/ttm/tests: Test simple BO creati
On 18.04.2024 10:15, Christian König wrote:
Am 17.04.24 um 15:03 schrieb Karolina Stolarek:
BOs in a bulk move have to share the same reservation object. That is
not the case in the ttm_bo_unreserve_bulk subtest. Share bo2's resv
object with bo1 to fix the issue.
Fixes: 995279d280d1 ("dr
Add test cases that check how the state of dma fences in BO's
reservation object influence the ttm_bo_validation() flow. Do similar
tests for resource manager's move fence.
Signed-off-by: Karolina Stolarek
Reviewed-by: Somalapuram, Amaranath
Tested-by: Somalapuram, Amaranath
---
.../gpu/drm
List improvements for the test suite with some notes.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/TODO | 25 +
1 file changed, 25 insertions(+)
create mode 100644 drivers/gpu/drm/ttm/tests/TODO
diff --git a/drivers/gpu/drm/ttm/tests/TODO b/drivers
Add tests for functions that add and release pages to TTs. Test the
swapin operation. Export ttm_tt_unpopulate, ttm_tt_swapin and
ttm_tt_swapout symbols for testing purposes.
Signed-off-by: Karolina Stolarek
Reviewed-by: Somalapuram, Amaranath
Tested-by: Somalapuram, Amaranath
---
drivers/gpu
Add mock resource manager to test ttm_bo_validate() with non-system
placements. Update KConfig entry to enable DRM Buddy allocator, used
by the mock manager. Update move function to do more than just assign
a resource.
Signed-off-by: Karolina Stolarek
Tested-by: Somalapuram, Amaranath
ommon path of ttm_device init into a function.
Signed-off-by: Karolina Stolarek
Reviewed-by: Somalapuram, Amaranath
Tested-by: Somalapuram, Amaranath
---
.../gpu/drm/ttm/tests/ttm_bo_validate_test.c | 433 ++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 106 -
drivers/g
Add tests for ttm_bo_init_reserved() and ttm_bo_validate() that use
sys manager. Define a simple move function in ttm_device_funcs. Expose
destroy callback of the buffer object to make testing of
ttm_bo_init_reserved() behaviour easier.
Signed-off-by: Karolina Stolarek
Reviewed-by: Matthew Auld
DRM KUnit helpers are selected automatically when TTM tests are enabled,
so there's no need to do it directly in the .kunitconfig file.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/.kunitconfig | 1 -
1 file changed, 1 deletion(-)
diff --git a/drivers/gpu/drm/ttm/tests
Add a new helper function that also initializes the device. Use it in
ttm_tt test suite and delete the local definition.
Signed-off-by: Karolina Stolarek
Reviewed-by: Matthew Auld
Reviewed-by: Somalapuram, Amaranath
---
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 14
tialization of spinlock in
ttm_bo_validate_move_fence_signaled(), it not used at all (Andi)
- Just return the error code threaded_fence_signal(), don't save it to a
local variable (Andi)
- Use ttm_bo_unreserve() in tests checking different move fence states (Andi)
Karolina Stolarek (10):
drm/t
t mappings to unblock testing.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c
b/drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c
index 7b7c1fa805fc..cb1cd676f
BOs in a bulk move have to share the same reservation object. That is
not the case in the ttm_bo_unreserve_bulk subtest. Share bo2's resv
object with bo1 to fix the issue.
Fixes: 995279d280d1 ("drm/ttm/tests: Add tests for ttm_bo functions")
Signed-off-by: Karolina Stolarek
---
drive
Hi Amaranath,
Many thanks for your review and comments.
On 15.04.2024 14:10, Somalapuram, Amaranath wrote:
+static void ttm_bo_validate_basic(struct kunit *test)
+{
+ const struct ttm_bo_validate_test_case *params = test->param_value;
+ uint32_t fst_mem = TTM_PL_SYSTEM, snd_mem =
On 10.04.2024 16:24, Matthew Auld wrote:
On 22/03/2024 14:29, Karolina Stolarek wrote:
+static const struct ttm_bo_validate_test_case ttm_mem_type_cases[] = {
+ {
+ .description = "System manager",
+ .mem_type = TTM_PL_SYSTEM,
+ },
+ {
+ .descripti
On 10.04.2024 16:01, Matthew Auld wrote:
On 22/03/2024 14:29, Karolina Stolarek wrote:
+static void ttm_bo_validate_pinned(struct kunit *test)
+{
+ enum ttm_bo_type bo_type = ttm_bo_type_device;
+ uint32_t size = ALIGN(BO_SIZE, PAGE_SIZE);
+ struct ttm_operation_ctx ctx
Hi Amaranath,
Thanks for checking this.
On 2.04.2024 15:35, Somalapuram, Amaranath wrote:
/usr/bin/ld: drivers/gpu/drm/tests/drm_kunit_helpers.o:(.rodata+0xa0):
undefined reference to `drm_atomic_helper_crtc_reset'
/usr/bin/ld: drivers/gpu/drm/tests/drm_kunit_helpers.o:(.rodata+0xf0):
List improvements for the test suite with some notes.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/TODO | 24
1 file changed, 24 insertions(+)
create mode 100644 drivers/gpu/drm/ttm/tests/TODO
diff --git a/drivers/gpu/drm/ttm/tests/TODO b/drivers/gpu
BOs in a bulk move have to share the same reservation object. That is
not the case in the ttm_bo_unreserve_bulk subtest. Share bo2's resv
object with bo1 to fix the issue.
Fixes: 995279d280d1 ("drm/ttm/tests: Add tests for ttm_bo functions")
Signed-off-by: Karolina Stolarek
---
drive
Add tests for functions that add and release pages to TTs. Test the
swapin operation. Export ttm_tt_unpopulate, ttm_tt_swapin and
ttm_tt_swapout symbols for testing purposes.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_tt_test.c | 119
drivers/gpu
Add mock resource manager to test ttm_bo_validate() with non-system
placements. Update KConfig entry to enable DRM Buddy allocator, used
by the mock manager. Update move function to do more than just assign
a resource.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/Kconfig
ommon path of ttm_device init into a function.
Signed-off-by: Karolina Stolarek
---
.../gpu/drm/ttm/tests/ttm_bo_validate_test.c | 425 ++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 107 -
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 7 +
drivers/gpu/drm
Add a new helper function that also initializes the device. Use it in
ttm_tt test suite and delete the local definition.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 14 ++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 1 +
drivers/gpu/drm
Add test cases that check how the state of dma fences in BO's
reservation object influence the ttm_bo_validation() flow. Do similar
tests for resource manager's move fence.
Signed-off-by: Karolina Stolarek
---
.../gpu/drm/ttm/tests/ttm_bo_validate_test.c | 305 ++
1 file
Add tests for ttm_bo_init_reserved() and ttm_bo_validate() that use
sys manager. Define a simple move function in ttm_device_funcs. Expose
destroy callback of the buffer object to make testing of
ttm_bo_init_reserved() behaviour easier.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm
t mappings to unblock testing.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 3 +++
1 file changed, 3 insertions(+)
diff --git a/drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c
b/drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c
index 7b7c1fa805fc..cb1cd676f
clean up an incomplete, orphaned
resource. That's not good, and this could bite us back in the future.
Karolina Stolarek (9):
drm/ttm/tests: Set DMA mask in KUnit device
drm/ttm/tests: Use an init function from the helpers lib
drm/ttm/tests: Test simple BO creation and validation
d
me Ripard
Cc: Maíra Canal
Signed-off-by: Karolina Stolarek
---
Run into this when trying to run TTM KUnit tests. As for now,
TTM KUnit test suite are the only outside user of these helpers,
but I think it makes sense to explicitly select DRM_KMS_HELPER
together with DRM_KUNIT_TEST_HELPE
into the CI.
Thanks,
Christian.
Am 11.01.24 um 11:28 schrieb Karolina Stolarek:
Remove a leftover definition of page order and pass an empty flag value
in ttm_pool_pre_populated().
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
Reviewed-by: Dominik Karol Piątkowski
Acked
List improvements for the test suite with some notes.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/TODO | 24
1 file changed, 24 insertions(+)
create mode 100644 drivers/gpu/drm/ttm/tests/TODO
diff --git a/drivers/gpu/drm/ttm/tests/TODO b/drivers/gpu
Add tests for functions that add and release pages to TTs. Test the
swapin operation. Export ttm_tt_unpopulate, ttm_tt_swapin and
ttm_tt_swapout symbols for testing purposes.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_tt_test.c | 119
drivers/gpu
ommon path of ttm_device init into a function.
Signed-off-by: Karolina Stolarek
---
.../gpu/drm/ttm/tests/ttm_bo_validate_test.c | 426 ++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 113 -
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 7 +
drivers/gpu/drm
Add mock resource manager to test ttm_bo_validate() with non-system
placements. Update KConfig entry to enable DRM Buddy allocator, used
by the mock manager. Update move function to do more than just assign
a resource.
Signed-off-by: Karolina Stolarek
Reviewed-by: Christian König
Tested
Add test cases that check how the state of dma fences in BO's
reservation object influence the ttm_bo_validation() flow. Do similar
tests for resource manager's move fence.
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
---
.../gpu/drm/ttm/tests/ttm_bo_validate_test.c | 305
Add tests for ttm_bo_init_reserved() and ttm_bo_validate() that use
sys manager. Define a simple move function in ttm_device_funcs. Expose
destroy callback of the buffer object to make testing of
ttm_bo_init_reserved() behaviour easier.
Signed-off-by: Karolina Stolarek
Reviewed-by: Christian
Add a new helper function that also initializes the device. Use it in
ttm_tt test suite and delete the local definition.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 14 ++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 1 +
drivers/gpu/drm
Remove a leftover definition of page order and pass an empty flag value
in ttm_pool_pre_populated().
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
Reviewed-by: Dominik Karol Piątkowski
Acked-by: Christian König
---
drivers/gpu/drm/ttm/tests/ttm_pool_test.c | 3 +--
1 file
nctions that are not exported
- Fix ttm_pool_pre_populated(); a wrong flag was passed to
ttm_tt_kunit_init() function
Karolina Stolarek (8):
drm/ttm/tests: Fix argument in ttm_tt_kunit_init()
drm/ttm/tests: Use an init function from the helpers lib
drm/ttm/tests: Test simple BO creation a
ommon path of ttm_device init into a function.
Signed-off-by: Karolina Stolarek
---
.../gpu/drm/ttm/tests/ttm_bo_validate_test.c | 426 ++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 113 -
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 7 +
drivers/gpu/drm
Add mock resource manager to test ttm_bo_validate() with non-system
placements. Update KConfig entry to enable DRM Buddy allocator, used
by the mock manager. Update move function to do more than just assign
a resource.
Signed-off-by: Karolina Stolarek
Reviewed-by: Christian König
Tested
Add tests for functions that add and release pages to TTs. Test the
swapin operation. Export ttm_tt_unpopulate, ttm_tt_swapin and
ttm_tt_swapout symbols for testing purposes.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_tt_test.c | 119
drivers/gpu
List improvements for the test suite with some notes.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/TODO | 24
1 file changed, 24 insertions(+)
create mode 100644 drivers/gpu/drm/ttm/tests/TODO
diff --git a/drivers/gpu/drm/ttm/tests/TODO b/drivers/gpu
Add test cases that check how the state of dma fences in BO's
reservation object influence the ttm_bo_validation() flow. Do similar
tests for resource manager's move fence.
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
---
.../gpu/drm/ttm/tests/ttm_bo_validate_test.c | 305
Add tests for ttm_bo_init_reserved() and ttm_bo_validate() that use
sys manager. Define a simple move function in ttm_device_funcs. Expose
destroy callback of the buffer object to make testing of
ttm_bo_init_reserved() behaviour easier.
Signed-off-by: Karolina Stolarek
Reviewed-by: Christian
Add a new helper function that also initializes the device. Use it in
ttm_tt test suite and delete the local definition.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 14 ++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 1 +
drivers/gpu/drm
Remove a leftover definition of page order and pass an empty flag value
in ttm_pool_pre_populated().
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
Reviewed-by: Dominik Karol Piątkowski
Acked-by: Christian König
---
drivers/gpu/drm/ttm/tests/ttm_pool_test.c | 3 +--
1 file
nctions that are not exported
- Fix ttm_pool_pre_populated(); a wrong flag was passed to
ttm_tt_kunit_init() function
Karolina Stolarek (8):
drm/ttm/tests: Fix argument in ttm_tt_kunit_init()
drm/ttm/tests: Use an init function from the helpers lib
drm/ttm/tests: Test simple BO creation a
On 14.12.2023 11:22, Christian König wrote:
Am 14.12.23 um 09:20 schrieb Karolina Stolarek:
Hi Christian,
On 29.11.2023 13:02, Karolina Stolarek wrote:
Karolina Stolarek (8):
drm/ttm/tests: Add tests for ttm_resource and ttm_sys_man
drm/ttm/tests: Add tests for ttm_tt
drm/ttm
Hi Christian,
On 29.11.2023 13:02, Karolina Stolarek wrote:
Karolina Stolarek (8):
drm/ttm/tests: Add tests for ttm_resource and ttm_sys_man
drm/ttm/tests: Add tests for ttm_tt
drm/ttm/tests: Add tests for ttm_bo functions
>drm/ttm/tests: Fix argument in ttm_tt_kunit_i
Hi Andi,
For next time, I find it difficult to follow all these variables,
it's easier to read
man = ttm_manager_type(priv->ttm_dev, TTM_PL_SYSTEM);
than
mem_type = TTM_PL_SYSTEM;
...
...
...
man = ttm_manager_type(priv->ttm_dev, mem_type);
Hi Andi,
On 5.12.2023 16:39, Andi Shyti wrote:
Hi Karolina and Christian,
Karolina Stolarek (8): drm/ttm/tests: Add tests for ttm_resource
and ttm_sys_man drm/ttm/tests: Add tests for ttm_tt drm/ttm/tests:
Add tests for ttm_bo functions drm/ttm/tests: Fix argument in
ttm_tt_kunit_init
Test reservation and release of TTM buffer objects. Add tests to check
pin and unpin operations.
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
Reviewed-by: Andi Shyti
---
drivers/gpu/drm/ttm/tests/Makefile| 1 +
drivers/gpu/drm/ttm/tests/ttm_bo_test.c
Add mock resource manager to test ttm_bo_validate() with non-system
placements. Update KConfig entry to enable DRM Buddy allocator, used
by the mock manager. Update move function to do more than just assign
a resource.
Signed-off-by: Karolina Stolarek
Reviewed-by: Christian König
Tested
Add a new helper function that also initializes the device. Use it in
ttm_tt test suite and delete the local definition.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 14 ++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 1 +
drivers/gpu/drm
Add test cases that check how the state of dma fences in BO's
reservation object influence the ttm_bo_validation() flow. Do similar
tests for resource manager's move fence.
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
---
.../gpu/drm/ttm/tests/ttm_bo_validate_test.c | 308
Remove a leftover definition of page order and pass an empty flag value
in ttm_pool_pre_populated().
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
Reviewed-by: Dominik Karol Piątkowski
Acked-by: Christian König
---
drivers/gpu/drm/ttm/tests/ttm_pool_test.c | 3 +--
1 file
Add tests for ttm_bo_init_reserved() and ttm_bo_validate() that use
sys manager. Define a simple move function in ttm_device_funcs. Expose
destroy callback of the buffer object to make testing of
ttm_bo_init_reserved() behaviour easier.
Signed-off-by: Karolina Stolarek
Reviewed-by: Christian
Test initialization, creation and destruction of ttm_tt instances.
Export ttm_tt_destroy and ttm_tt_create symbols for testing purposes.
Signed-off-by: Karolina Stolarek
Reviewed-by: Christian König
Tested-by: Amaranath Somalapuram
---
drivers/gpu/drm/ttm/tests/Makefile| 1
purposes only.
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
Reviewed-by: Christian König
---
drivers/gpu/drm/ttm/tests/Makefile| 1 +
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 22 +-
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 3 +
drivers/gpu/drm
nit_init() function
Karolina Stolarek (8):
drm/ttm/tests: Add tests for ttm_resource and ttm_sys_man
drm/ttm/tests: Add tests for ttm_tt
drm/ttm/tests: Add tests for ttm_bo functions
drm/ttm/tests: Fix argument in ttm_tt_kunit_init()
drm/ttm/tests: Use an init function from the helpers lib
On 24.11.2023 16:53, Christian König wrote:
@Karolina do you of hand know a way how we could exercise this in a TTM
unit test? Basically we would need to redirect the alloc_pages_node()
symbol to an unit test internal function and let it return an error (or
something like that).
Do I
On 21.11.2023 15:29, Christian König wrote:
Am 17.11.23 um 09:49 schrieb Karolina Stolarek:
Test reservation and release of TTM buffer objects. Add tests to check
pin and unpin operations.
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
From the TTM side it looks good
Add tests for ttm_bo_init_reserved() and ttm_bo_validate() that use
sys manager. Define a simple move function in ttm_device_funcs. Expose
destroy callback of the buffer object to make testing of
ttm_bo_init_reserved() behaviour easier.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm
Add test cases that check how the state of dma fences in BO's
reservation object influence the ttm_bo_validation() flow. Do similar
tests for resource manager's move fence.
Signed-off-by: Karolina Stolarek
---
.../gpu/drm/ttm/tests/ttm_bo_validate_test.c | 308 ++
1 file
Add mock resource manager to test ttm_bo_validate() with non-system
placements. Update KConfig entry to enable DRM Buddy allocator, used
by the mock manager. Update move function to do more than just assign
a resource.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/Kconfig
Remove a leftover definition of page order and pass an empty flag value
in ttm_pool_pre_populated().
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
---
drivers/gpu/drm/ttm/tests/ttm_pool_test.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu
Add a new helper function that also initializes the device. Use it in
ttm_tt test suite and delete the local definition.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 14 ++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 1 +
drivers/gpu/drm
Test reservation and release of TTM buffer objects. Add tests to check
pin and unpin operations.
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
---
drivers/gpu/drm/ttm/tests/Makefile| 1 +
drivers/gpu/drm/ttm/tests/ttm_bo_test.c | 619
Test initialization, creation and destruction of ttm_tt instances.
Export ttm_tt_destroy and ttm_tt_create symbols for testing purposes.
Signed-off-by: Karolina Stolarek
Reviewed-by: Christian König
Tested-by: Amaranath Somalapuram
---
drivers/gpu/drm/ttm/tests/Makefile| 1
purposes only.
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
---
drivers/gpu/drm/ttm/tests/Makefile| 1 +
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 22 +-
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 3 +
drivers/gpu/drm/ttm/tests/ttm_resource_test.c
t uses functions that are not exported
- Fix ttm_pool_pre_populated(); a wrong flag was passed to
ttm_tt_kunit_init() function
Karolina Stolarek (8):
drm/ttm/tests: Add tests for ttm_resource and ttm_sys_man
drm/ttm/tests: Add tests for ttm_tt
drm/ttm/tests: Add tests for ttm_bo functions
On 8.11.2023 16:01, Christian König wrote:> Well, you have a tendency to
keep us busy :)
...:)
I'll try to get other folks to take a look at this. It's a lot of code
to review
Please keep Amar looped in those patches. I will try to review them when
I have time, but he can give you at
On 8.11.2023 14:56, Karolina Stolarek wrote:
diff --git a/drivers/gpu/drm/ttm/tests/ttm_bo_validate_test.c
b/drivers/gpu/drm/ttm/tests/ttm_bo_validate_test.c
index 38e584798584..f0f0ab992e04 100644
--- a/drivers/gpu/drm/ttm/tests/ttm_bo_validate_test.c
+++ b/drivers/gpu/drm/ttm/tests
Add tests for ttm_bo_init_reserved() and ttm_bo_validate() that use
sys manager. Define a simple move function in ttm_device_funcs. Expose
destroy callback of the buffer object to make testing of
ttm_bo_init_reserved() behaviour easier.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm
Remove a leftover definition of page order and pass an empty flag value
in ttm_pool_pre_populated().
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
---
drivers/gpu/drm/ttm/tests/ttm_pool_test.c | 3 +--
1 file changed, 1 insertion(+), 2 deletions(-)
diff --git a/drivers/gpu
Add test cases that check how the state of dma fences in BO's
reservation object influence the ttm_bo_validation() flow. Do similar
tests for resource manager's move fence.
Signed-off-by: Karolina Stolarek
---
.../gpu/drm/ttm/tests/ttm_bo_validate_test.c | 306 ++
1 file
Add mock resource manager to test ttm_bo_validate() with non-system
placements. Update KConfig entry to enable DRM Buddy allocator, used
by the mock manager. Update move function to do more than just assign
a resource.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/Kconfig
Test initialization, creation and destruction of ttm_tt instances.
Export ttm_tt_destroy and ttm_tt_create symbols for testing purposes.
Signed-off-by: Karolina Stolarek
Reviewed-by: Christian König
Tested-by: Amaranath Somalapuram
---
drivers/gpu/drm/ttm/tests/Makefile| 1
Add a new helper function that also initializes the device. Use it in
ttm_tt test suite and delete the local definition.
Signed-off-by: Karolina Stolarek
---
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 14 ++
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 1 +
drivers/gpu/drm
Test reservation and release of TTM buffer objects. Add tests to check
pin and unpin operations.
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
---
drivers/gpu/drm/ttm/tests/Makefile| 1 +
drivers/gpu/drm/ttm/tests/ttm_bo_test.c | 619
purposes only.
Signed-off-by: Karolina Stolarek
Tested-by: Amaranath Somalapuram
---
drivers/gpu/drm/ttm/tests/Makefile| 1 +
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c | 23 +-
drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.h | 4 +
drivers/gpu/drm/ttm/tests/ttm_resource_test.c
to
ttm_tt_kunit_init() function
Karolina Stolarek (8):
drm/ttm/tests: Add tests for ttm_resource and ttm_sys_man
drm/ttm/tests: Add tests for ttm_tt
drm/ttm/tests: Add tests for ttm_bo functions
drm/ttm/tests: Fix argument in ttm_tt_kunit_init()
drm/ttm/tests: Use an init function from
On 7.11.2023 10:34, Christian König wrote:
Am 16.10.23 um 10:52 schrieb Karolina Stolarek:
diff --git a/drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c
b/drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c
index 81661d8827aa..c605f010ea08 100644
--- a/drivers/gpu/drm/ttm/tests/ttm_kunit_helpers.c
Hi Christian,
On 17.10.2023 14:10, Christian König wrote:
Am 17.10.23 um 14:06 schrieb Karolina Stolarek: >> Oh! Could you at least take
a look at ttm_bo_reserve_deadlock and/or
interrupted subtests? I'm not 100% sure if my solution is right.
Than this will have to wait till next wee
On 26.10.2023 06:43, Soumya Negi wrote:
In accordance to Linux coding style(Documentation/process/4.Coding.rst),
remove unneeded braces from if-else block as all arms of this block
contain single statements.
I'd just keep the description simple, and say that braces are not needed
for single
On 17.10.2023 14:10, Christian König wrote:
Am 17.10.23 um 14:06 schrieb Karolina Stolarek:
On 17.10.2023 13:57, Christian König wrote:
Am 17.10.23 um 13:22 schrieb Somalapuram, Amaranath:
On 10/17/2023 4:35 PM, Karolina Stolarek wrote:
Hi Amaranath,
On 16.10.2023 15:08, Somalapuram
On 17.10.2023 13:57, Christian König wrote:
Am 17.10.23 um 13:22 schrieb Somalapuram, Amaranath:
On 10/17/2023 4:35 PM, Karolina Stolarek wrote:
Hi Amaranath,
On 16.10.2023 15:08, Somalapuram, Amaranath wrote:
On 10/16/2023 2:22 PM, Karolina Stolarek wrote:
Add tests for building blocks
Hi Amaranath,
On 16.10.2023 15:08, Somalapuram, Amaranath wrote:
On 10/16/2023 2:22 PM, Karolina Stolarek wrote:
Add tests for building blocks of the TTM subsystem, such as ttm_resource,
ttm_resource_manager, ttm_tt and ttm_buffer_object. This series covers
basic functions
list and drain its workqueue
before releasing the system domain manager in ttm_device_fini().
Signed-off-by: Karolina Stolarek
---
This is actually a reiteration of a patch sent in [1], but the
solution and commit message changed significantly, so I decided
not to send it as v2.
[1
On 16.10.2023 13:03, Christian König wrote:
Am 13.10.23 um 16:34 schrieb Karolina Stolarek:
In rare cases, a delayed destruction of a BO with a system resource
could stay in the workqueue until drain_workqueue() is called in
ttm_device_fini(). An attempt to free a resource from an already
1 - 100 of 178 matches
Mail list logo