ab65b0cf | 15-Apr-2024 |
Christian König <ckoenig.leichtzumerken@gmail.com> |
drm/ttm: stop pooling cached NUMA pages v2
[ Upstream commit b6976f323a8687cc0d55bc92c2086fd934324ed5 ]
We only pool write combined and uncached allocations because they require extra overhead on a
drm/ttm: stop pooling cached NUMA pages v2
[ Upstream commit b6976f323a8687cc0d55bc92c2086fd934324ed5 ]
We only pool write combined and uncached allocations because they require extra overhead on allocation and release.
If we also pool cached NUMA it not only means some extra unnecessary overhead, but also that under memory pressure it can happen that pages from the wrong NUMA node enters the pool and are re-used over and over again.
This can lead to performance reduction after running into memory pressure.
v2: restructure and cleanup the code a bit from the internal hack to test this.
Signed-off-by: Christian König <christian.koenig@amd.com> Fixes: 4482d3c94d7f ("drm/ttm: add NUMA node id to the pool") CC: stable@vger.kernel.org Reviewed-by: Felix Kuehling <felix.kuehling@amd.com> Link: https://patchwork.freedesktop.org/patch/msgid/20240415134821.1919-1-christian.koenig@amd.com Signed-off-by: Sasha Levin <sashal@kernel.org>
show more ...
|
20404204 | 08-Aug-2023 |
Karolina Stolarek <karolina.stolarek@intel.com> |
drm/ttm/tests: Add tests for ttm_pool
Add KUnit tests that exercise page allocation using page pools and freeing pages, either by returning them to the pool or freeing them. Add a basic test for ttm
drm/ttm/tests: Add tests for ttm_pool
Add KUnit tests that exercise page allocation using page pools and freeing pages, either by returning them to the pool or freeing them. Add a basic test for ttm_pool cleanup. Introduce helpers to create a dummy ttm_buffer_object.
Signed-off-by: Karolina Stolarek <karolina.stolarek@intel.com> Reviewed-by: Christian König <christian.koenig@amd.com> Link: https://patchwork.freedesktop.org/patch/msgid/427ea373357d0b6cb376c9d7ebc33c930bf1d28a.1691487006.git.karolina.stolarek@intel.com Signed-off-by: Christian König <christian.koenig@amd.com>
show more ...
|
24ac009e | 08-Aug-2023 |
Karolina Stolarek <karolina.stolarek@intel.com> |
drm/ttm/tests: Add tests for ttm_device
Test initialization and cleanup of the ttm_device struct, including some error paths. Verify the creation of page pools if use_dma_alloc param is true.
Signe
drm/ttm/tests: Add tests for ttm_device
Test initialization and cleanup of the ttm_device struct, including some error paths. Verify the creation of page pools if use_dma_alloc param is true.
Signed-off-by: Karolina Stolarek <karolina.stolarek@intel.com> Reviewed-by: Christian König <christian.koenig@amd.com> Link: https://patchwork.freedesktop.org/patch/msgid/2abb0e53e7d56b0a24d0255f9075e2123b991278.1691487006.git.karolina.stolarek@intel.com Signed-off-by: Christian König <christian.koenig@amd.com>
show more ...
|
a2848d08 | 07-Jul-2023 |
Christian König <christian.koenig@amd.com> |
drm/ttm: never consider pinned BOs for eviction&swap
There is a small window where we have already incremented the pin count but not yet moved the bo from the lru to the pinned list.
Signed-off-by:
drm/ttm: never consider pinned BOs for eviction&swap
There is a small window where we have already incremented the pin count but not yet moved the bo from the lru to the pinned list.
Signed-off-by: Christian König <christian.koenig@amd.com> Reported-by: Pelloux-Prayer, Pierre-Eric <Pierre-eric.Pelloux-prayer@amd.com> Tested-by: Pelloux-Prayer, Pierre-Eric <Pierre-eric.Pelloux-prayer@amd.com> Acked-by: Alex Deucher <alexander.deucher@amd.com> Cc: stable@vger.kernel.org Link: https://patchwork.freedesktop.org/patch/msgid/20230707120826.3701-1-christian.koenig@amd.com
show more ...
|
a590f03d | 26-Jun-2023 |
Thomas Hellström <thomas.hellstrom@linux.intel.com> |
drm/ttm: Don't leak a resource on swapout move error
If moving the bo to system for swapout failed, we were leaking a resource. Fix.
Fixes: bfa3357ef9ab ("drm/ttm: allocate resource object instead
drm/ttm: Don't leak a resource on swapout move error
If moving the bo to system for swapout failed, we were leaking a resource. Fix.
Fixes: bfa3357ef9ab ("drm/ttm: allocate resource object instead of embedding it v2") Cc: Christian König <christian.koenig@amd.com> Cc: "Christian König" <ckoenig.leichtzumerken@gmail.com> Cc: dri-devel@lists.freedesktop.org Cc: <stable@vger.kernel.org> # v5.14+ Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com> Reviewed-by: Nirmoy Das <nirmoy.das@intel.com> Reviewed-by: Andi Shyti <andi.shyti@linux.intel.com> Reviewed-by: Christian König <christian.koenig@amd.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230626091450.14757-5-thomas.hellstrom@linux.intel.com
show more ...
|
0c3855ba | 23-Jun-2023 |
Christian König <christian.koenig@amd.com> |
drm/ttm: fix warning that we shouldn't mix && and ||
Trivial warning fix.
Signed-off-by: Christian König <christian.koenig@amd.com> Fixes: 4481913607e5 ("drm/ttm: fix bulk_move corruption when addi
drm/ttm: fix warning that we shouldn't mix && and ||
Trivial warning fix.
Signed-off-by: Christian König <christian.koenig@amd.com> Fixes: 4481913607e5 ("drm/ttm: fix bulk_move corruption when adding a entry") Reviewed-by: Alex Deucher <alexander.deucher@amd.com> Link: https://patchwork.freedesktop.org/patch/msgid/20230623070935.65102-1-christian.koenig@amd.com
show more ...
|