* [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling
@ 2026-02-09 8:30 Arunpravin Paneer Selvam
2026-02-09 8:30 ` [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations Arunpravin Paneer Selvam
` (6 more replies)
0 siblings, 7 replies; 14+ messages in thread
From: Arunpravin Paneer Selvam @ 2026-02-09 8:30 UTC (permalink / raw)
To: matthew.auld, christian.koenig, dri-devel, intel-gfx, intel-xe,
amd-gfx
Cc: alexander.deucher, Arunpravin Paneer Selvam
Large alignment requests previously forced the buddy allocator to search by
alignment order, which often caused higher-order free blocks to be split even
when a suitably aligned smaller region already existed within them. This led
to excessive fragmentation, especially for workloads requesting small sizes
with large alignment constraints.
This change prioritizes the requested allocation size during the search and
uses an augmented RB-tree field (subtree_max_alignment) to efficiently locate
free blocks that satisfy both size and offset-alignment requirements. As a
result, the allocator can directly select an aligned sub-region without
splitting larger blocks unnecessarily.
A practical example is the VKCTS test
dEQP-VK.memory.allocation.basic.size_8KiB.reverse.count_4000, which repeatedly
allocates 8 KiB buffers with a 256 KiB alignment. Previously, such allocations
caused large blocks to be split aggressively, despite smaller aligned regions
being sufficient. With this change, those aligned regions are reused directly,
significantly reducing fragmentation.
This improvement is visible in the amdgpu VRAM buddy allocator state
(/sys/kernel/debug/dri/1/amdgpu_vram_mm). After the change, higher-order blocks
are preserved and the number of low-order fragments is substantially reduced.
Before:
order- 5 free: 1936 MiB, blocks: 15490
order- 4 free: 967 MiB, blocks: 15486
order- 3 free: 483 MiB, blocks: 15485
order- 2 free: 241 MiB, blocks: 15486
order- 1 free: 241 MiB, blocks: 30948
After:
order- 5 free: 493 MiB, blocks: 3941
order- 4 free: 246 MiB, blocks: 3943
order- 3 free: 123 MiB, blocks: 4101
order- 2 free: 61 MiB, blocks: 4101
order- 1 free: 61 MiB, blocks: 8018
By avoiding unnecessary splits, this change improves allocator efficiency and
helps maintain larger contiguous free regions under heavy offset-aligned
allocation workloads.
v2:(Matthew)
- Update augmented information along the path to the inserted node.
v3:
- Move the patch to gpu/buddy.c file.
Signed-off-by: Arunpravin Paneer Selvam <Arunpravin.PaneerSelvam@amd.com>
Suggested-by: Christian König <christian.koenig@amd.com>
---
drivers/gpu/buddy.c | 271 +++++++++++++++++++++++++++++++-------
include/linux/gpu_buddy.h | 2 +
2 files changed, 228 insertions(+), 45 deletions(-)
diff --git a/drivers/gpu/buddy.c b/drivers/gpu/buddy.c
index 603c59a2013a..3a25eed050ba 100644
--- a/drivers/gpu/buddy.c
+++ b/drivers/gpu/buddy.c
@@ -14,6 +14,16 @@
static struct kmem_cache *slab_blocks;
+static unsigned int gpu_buddy_block_offset_alignment(struct gpu_buddy_block *block)
+{
+ return __ffs(gpu_buddy_block_offset(block));
+}
+
+RB_DECLARE_CALLBACKS_MAX(static, gpu_buddy_augment_cb,
+ struct gpu_buddy_block, rb,
+ unsigned int, subtree_max_alignment,
+ gpu_buddy_block_offset_alignment);
+
static struct gpu_buddy_block *gpu_block_alloc(struct gpu_buddy *mm,
struct gpu_buddy_block *parent,
unsigned int order,
@@ -31,6 +41,9 @@ static struct gpu_buddy_block *gpu_block_alloc(struct gpu_buddy *mm,
block->header |= order;
block->parent = parent;
+ block->subtree_max_alignment =
+ gpu_buddy_block_offset_alignment(block);
+
RB_CLEAR_NODE(&block->rb);
BUG_ON(block->header & GPU_BUDDY_HEADER_UNUSED);
@@ -67,26 +80,42 @@ static bool rbtree_is_empty(struct rb_root *root)
return RB_EMPTY_ROOT(root);
}
-static bool gpu_buddy_block_offset_less(const struct gpu_buddy_block *block,
- const struct gpu_buddy_block *node)
-{
- return gpu_buddy_block_offset(block) < gpu_buddy_block_offset(node);
-}
-
-static bool rbtree_block_offset_less(struct rb_node *block,
- const struct rb_node *node)
-{
- return gpu_buddy_block_offset_less(rbtree_get_free_block(block),
- rbtree_get_free_block(node));
-}
-
static void rbtree_insert(struct gpu_buddy *mm,
struct gpu_buddy_block *block,
enum gpu_buddy_free_tree tree)
{
- rb_add(&block->rb,
- &mm->free_trees[tree][gpu_buddy_block_order(block)],
- rbtree_block_offset_less);
+ struct rb_node **link, *parent = NULL;
+ unsigned int block_alignment, order;
+ struct gpu_buddy_block *node;
+ struct rb_root *root;
+
+ order = gpu_buddy_block_order(block);
+ block_alignment = gpu_buddy_block_offset_alignment(block);
+
+ root = &mm->free_trees[tree][order];
+ link = &root->rb_node;
+
+ while (*link) {
+ parent = *link;
+ node = rbtree_get_free_block(parent);
+ /*
+ * Manual augmentation update during insertion traversal. Required
+ * because rb_insert_augmented() only calls rotate callback during
+ * rotations. This ensures all ancestors on the insertion path have
+ * correct subtree_max_alignment values.
+ */
+ if (node->subtree_max_alignment < block_alignment)
+ node->subtree_max_alignment = block_alignment;
+
+ if (gpu_buddy_block_offset(block) < gpu_buddy_block_offset(node))
+ link = &parent->rb_left;
+ else
+ link = &parent->rb_right;
+ }
+
+ block->subtree_max_alignment = block_alignment;
+ rb_link_node(&block->rb, parent, link);
+ rb_insert_augmented(&block->rb, root, &gpu_buddy_augment_cb);
}
static void rbtree_remove(struct gpu_buddy *mm,
@@ -99,7 +128,7 @@ static void rbtree_remove(struct gpu_buddy *mm,
tree = get_block_tree(block);
root = &mm->free_trees[tree][order];
- rb_erase(&block->rb, root);
+ rb_erase_augmented(&block->rb, root, &gpu_buddy_augment_cb);
RB_CLEAR_NODE(&block->rb);
}
@@ -790,6 +819,132 @@ alloc_from_freetree(struct gpu_buddy *mm,
return ERR_PTR(err);
}
+static bool
+gpu_buddy_can_offset_align(u64 size, u64 min_block_size)
+{
+ return size < min_block_size && is_power_of_2(size);
+}
+
+static bool gpu_buddy_subtree_can_satisfy(struct rb_node *node,
+ unsigned int alignment)
+{
+ struct gpu_buddy_block *block;
+
+ if (!node)
+ return false;
+
+ block = rbtree_get_free_block(node);
+ return block->subtree_max_alignment >= alignment;
+}
+
+static struct gpu_buddy_block *
+gpu_buddy_find_block_aligned(struct gpu_buddy *mm,
+ enum gpu_buddy_free_tree tree,
+ unsigned int order,
+ unsigned int tmp,
+ unsigned int alignment,
+ unsigned long flags)
+{
+ struct rb_root *root = &mm->free_trees[tree][tmp];
+ struct rb_node *rb = root->rb_node;
+
+ while (rb) {
+ struct gpu_buddy_block *block = rbtree_get_free_block(rb);
+ struct rb_node *left_node = rb->rb_left, *right_node = rb->rb_right;
+
+ if (right_node) {
+ if (gpu_buddy_subtree_can_satisfy(right_node, alignment)) {
+ rb = right_node;
+ continue;
+ }
+ }
+
+ if (gpu_buddy_block_order(block) >= order &&
+ __ffs(gpu_buddy_block_offset(block)) >= alignment)
+ return block;
+
+ if (left_node) {
+ if (gpu_buddy_subtree_can_satisfy(left_node, alignment)) {
+ rb = left_node;
+ continue;
+ }
+ }
+
+ break;
+ }
+
+ return NULL;
+}
+
+static struct gpu_buddy_block *
+gpu_buddy_offset_aligned_allocation(struct gpu_buddy *mm,
+ u64 size,
+ u64 min_block_size,
+ unsigned long flags)
+{
+ struct gpu_buddy_block *block = NULL;
+ unsigned int order, tmp, alignment;
+ struct gpu_buddy_block *buddy;
+ enum gpu_buddy_free_tree tree;
+ unsigned long pages;
+ int err;
+
+ alignment = ilog2(min_block_size);
+ pages = size >> ilog2(mm->chunk_size);
+ order = fls(pages) - 1;
+
+ tree = (flags & GPU_BUDDY_CLEAR_ALLOCATION) ?
+ GPU_BUDDY_CLEAR_TREE : GPU_BUDDY_DIRTY_TREE;
+
+ for (tmp = order; tmp <= mm->max_order; ++tmp) {
+ block = gpu_buddy_find_block_aligned(mm, tree, order,
+ tmp, alignment, flags);
+ if (!block) {
+ tree = (tree == GPU_BUDDY_CLEAR_TREE) ?
+ GPU_BUDDY_DIRTY_TREE : GPU_BUDDY_CLEAR_TREE;
+ block = gpu_buddy_find_block_aligned(mm, tree, order,
+ tmp, alignment, flags);
+ }
+
+ if (block)
+ break;
+ }
+
+ if (!block)
+ return ERR_PTR(-ENOSPC);
+
+ while (gpu_buddy_block_order(block) > order) {
+ struct gpu_buddy_block *left, *right;
+
+ err = split_block(mm, block);
+ if (unlikely(err))
+ goto err_undo;
+
+ left = block->left;
+ right = block->right;
+
+ if (__ffs(gpu_buddy_block_offset(right)) >= alignment)
+ block = right;
+ else
+ block = left;
+ }
+
+ return block;
+
+err_undo:
+ /*
+ * We really don't want to leave around a bunch of split blocks, since
+ * bigger is better, so make sure we merge everything back before we
+ * free the allocated blocks.
+ */
+ buddy = __get_buddy(block);
+ if (buddy &&
+ (gpu_buddy_block_is_free(block) &&
+ gpu_buddy_block_is_free(buddy)))
+ __gpu_buddy_free(mm, block, false);
+ return ERR_PTR(err);
+}
+
static int __alloc_range(struct gpu_buddy *mm,
struct list_head *dfs,
u64 start, u64 size,
@@ -1059,6 +1214,7 @@ EXPORT_SYMBOL(gpu_buddy_block_trim);
static struct gpu_buddy_block *
__gpu_buddy_alloc_blocks(struct gpu_buddy *mm,
u64 start, u64 end,
+ u64 size, u64 min_block_size,
unsigned int order,
unsigned long flags)
{
@@ -1066,6 +1222,11 @@ __gpu_buddy_alloc_blocks(struct gpu_buddy *mm,
/* Allocate traversing within the range */
return __gpu_buddy_alloc_range_bias(mm, start, end,
order, flags);
+ else if (size < min_block_size)
+ /* Allocate from an offset-aligned region without size rounding */
+ return gpu_buddy_offset_aligned_allocation(mm, size,
+ min_block_size,
+ flags);
else
/* Allocate from freetree */
return alloc_from_freetree(mm, order, flags);
@@ -1137,8 +1298,11 @@ int gpu_buddy_alloc_blocks(struct gpu_buddy *mm,
if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION) {
size = roundup_pow_of_two(size);
min_block_size = size;
- /* Align size value to min_block_size */
- } else if (!IS_ALIGNED(size, min_block_size)) {
+ /*
+ * Normalize the requested size to min_block_size for regular allocations.
+ * Offset-aligned allocations intentionally skip size rounding.
+ */
+ } else if (!gpu_buddy_can_offset_align(size, min_block_size)) {
size = round_up(size, min_block_size);
}
@@ -1158,43 +1322,60 @@ int gpu_buddy_alloc_blocks(struct gpu_buddy *mm,
do {
order = min(order, (unsigned int)fls(pages) - 1);
BUG_ON(order > mm->max_order);
- BUG_ON(order < min_order);
+ /*
+ * Regular allocations must not allocate blocks smaller than min_block_size.
+ * Offset-aligned allocations deliberately bypass this constraint.
+ */
+ BUG_ON(size >= min_block_size && order < min_order);
do {
+ unsigned int fallback_order;
+
block = __gpu_buddy_alloc_blocks(mm, start,
end,
+ size,
+ min_block_size,
order,
flags);
if (!IS_ERR(block))
break;
- if (order-- == min_order) {
- /* Try allocation through force merge method */
- if (mm->clear_avail &&
- !__force_merge(mm, start, end, min_order)) {
- block = __gpu_buddy_alloc_blocks(mm, start,
- end,
- min_order,
- flags);
- if (!IS_ERR(block)) {
- order = min_order;
- break;
- }
- }
+ if (size < min_block_size) {
+ fallback_order = order;
+ } else if (order == min_order) {
+ fallback_order = min_order;
+ } else {
+ order--;
+ continue;
+ }
- /*
- * Try contiguous block allocation through
- * try harder method.
- */
- if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION &&
- !(flags & GPU_BUDDY_RANGE_ALLOCATION))
- return __alloc_contig_try_harder(mm,
- original_size,
- original_min_size,
- blocks);
- err = -ENOSPC;
- goto err_free;
+ /* Try allocation through force merge method */
+ if (mm->clear_avail &&
+ !__force_merge(mm, start, end, fallback_order)) {
+ block = __gpu_buddy_alloc_blocks(mm, start,
+ end,
+ size,
+ min_block_size,
+ fallback_order,
+ flags);
+ if (!IS_ERR(block)) {
+ order = fallback_order;
+ break;
+ }
}
+
+ /*
+ * Try contiguous block allocation through
+ * try harder method.
+ */
+ if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION &&
+ !(flags & GPU_BUDDY_RANGE_ALLOCATION))
+ return __alloc_contig_try_harder(mm,
+ original_size,
+ original_min_size,
+ blocks);
+ err = -ENOSPC;
+ goto err_free;
} while (1);
mark_allocated(mm, block);
diff --git a/include/linux/gpu_buddy.h b/include/linux/gpu_buddy.h
index 07ac65db6d2e..7ad817c69ec6 100644
--- a/include/linux/gpu_buddy.h
+++ b/include/linux/gpu_buddy.h
@@ -11,6 +11,7 @@
#include <linux/slab.h>
#include <linux/sched.h>
#include <linux/rbtree.h>
+#include <linux/rbtree_augmented.h>
#define GPU_BUDDY_RANGE_ALLOCATION BIT(0)
#define GPU_BUDDY_TOPDOWN_ALLOCATION BIT(1)
@@ -58,6 +59,7 @@ struct gpu_buddy_block {
};
struct list_head tmp_link;
+ unsigned int subtree_max_alignment;
};
/* Order-zero must be at least SZ_4K */
base-commit: 9d757669b2b22cd224c334924f798393ffca537c
--
2.34.1
^ permalink raw reply related [flat|nested] 14+ messages in thread* [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations 2026-02-09 8:30 [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling Arunpravin Paneer Selvam @ 2026-02-09 8:30 ` Arunpravin Paneer Selvam 2026-02-09 19:23 ` kernel test robot ` (2 more replies) 2026-02-09 8:37 ` ✗ CI.checkpatch: warning for series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling Patchwork ` (5 subsequent siblings) 6 siblings, 3 replies; 14+ messages in thread From: Arunpravin Paneer Selvam @ 2026-02-09 8:30 UTC (permalink / raw) To: matthew.auld, christian.koenig, dri-devel, intel-gfx, intel-xe, amd-gfx Cc: alexander.deucher, Arunpravin Paneer Selvam Add KUnit test to validate offset-aligned allocations in the DRM buddy allocator. Validate offset-aligned allocation: The test covers allocations with sizes smaller than the alignment constraint and verifies correct size preservation, offset alignment, and behavior across multiple allocation sizes. It also exercises fragmentation by freeing alternating blocks and confirms that allocation fails once all aligned offsets are consumed. Stress subtree_max_alignment propagation: Exercise subtree_max_alignment tracking by allocating blocks with descending alignment constraints and freeing them in reverse order. This verifies that free-tree augmentation correctly propagates the maximum offset alignment present in each subtree at every stage. v2: - Move the patch to gpu/tests/gpu_buddy_test.c file. Signed-off-by: Arunpravin Paneer Selvam <Arunpravin.PaneerSelvam@amd.com> --- drivers/gpu/tests/gpu_buddy_test.c | 166 +++++++++++++++++++++++++++++ 1 file changed, 166 insertions(+) diff --git a/drivers/gpu/tests/gpu_buddy_test.c b/drivers/gpu/tests/gpu_buddy_test.c index 450e71deed90..37f22655b5fb 100644 --- a/drivers/gpu/tests/gpu_buddy_test.c +++ b/drivers/gpu/tests/gpu_buddy_test.c @@ -21,6 +21,170 @@ static inline u64 get_size(int order, u64 chunk_size) return (1 << order) * chunk_size; } +static void gpu_test_buddy_subtree_offset_alignment_stress(struct kunit *test) +{ + struct gpu_buddy_block *block; + struct rb_node *node = NULL; + const u64 mm_size = SZ_2M; + const u64 alignments[] = { + SZ_1M, + SZ_512K, + SZ_256K, + SZ_128K, + SZ_64K, + SZ_32K, + SZ_16K, + SZ_8K, + }; + + struct list_head allocated[ARRAY_SIZE(alignments)]; + unsigned int i, order, max_subtree_align = 0; + struct gpu_buddy mm; + int ret, tree; + + KUNIT_ASSERT_FALSE(test, gpu_buddy_init(&mm, mm_size, SZ_4K), + "buddy_init failed\n"); + + for (i = 0; i < ARRAY_SIZE(allocated); i++) + INIT_LIST_HEAD(&allocated[i]); + + /* + * Exercise subtree_max_alignment tracking by allocating blocks with descending + * alignment constraints and freeing them in reverse order. This verifies that + * free-tree augmentation correctly propagates the maximum offset alignment + * present in each subtree at every stage. + */ + + for (i = 0; i < ARRAY_SIZE(alignments); i++) { + struct gpu_buddy_block *root = NULL; + unsigned int expected; + u64 align; + + align = alignments[i]; + expected = ilog2(align) - 1; + + for (;;) { + ret = gpu_buddy_alloc_blocks(&mm, + 0, mm_size, + SZ_4K, align, + &allocated[i], + 0); + if (ret) + break; + + block = list_last_entry(&allocated[i], + struct gpu_buddy_block, + link); + KUNIT_EXPECT_EQ(test, gpu_buddy_block_offset(block) & (align - 1), 0ULL); + } + + for (order = mm.max_order + 1; order-- > 0 && !root; ) { + for (tree = 0; tree < 2; tree++) { + node = mm.free_trees[tree][order].rb_node; + if (node) { + root = container_of(node, + struct gpu_buddy_block, + rb); + break; + } + } + } + + KUNIT_ASSERT_NOT_NULL(test, root); + KUNIT_EXPECT_EQ(test, root->subtree_max_alignment, expected); + } + + for (i = ARRAY_SIZE(alignments); i-- > 0; ) { + gpu_buddy_free_list(&mm, &allocated[i], 0); + + for (order = 0; order <= mm.max_order; order++) { + for (tree = 0; tree < 2; tree++) { + node = mm.free_trees[tree][order].rb_node; + if (!node) + continue; + + block = container_of(node, struct gpu_buddy_block, rb); + max_subtree_align = max(max_subtree_align, block->subtree_max_alignment); + } + } + + KUNIT_EXPECT_GE(test, max_subtree_align, ilog2(alignments[i])); + } + + gpu_buddy_fini(&mm); +} + +static void gpu_test_buddy_offset_aligned_allocation(struct kunit *test) +{ + struct gpu_buddy_block *block, *tmp; + int num_blocks, i, count = 0; + LIST_HEAD(allocated); + struct gpu_buddy mm; + u64 mm_size = SZ_4M; + LIST_HEAD(freed); + + KUNIT_ASSERT_FALSE_MSG(test, gpu_buddy_init(&mm, mm_size, SZ_4K), + "buddy_init failed\n"); + + num_blocks = mm_size / SZ_256K; + /* + * Allocate multiple sizes under a fixed offset alignment. + * Ensures alignment handling is independent of allocation size and + * exercises subtree max-alignment pruning for small requests. + */ + for (i = 0; i < num_blocks; i++) + KUNIT_ASSERT_FALSE_MSG(test, gpu_buddy_alloc_blocks(&mm, 0, mm_size, SZ_8K, SZ_256K, + &allocated, 0), + "buddy_alloc hit an error size=%u\n", SZ_8K); + + list_for_each_entry(block, &allocated, link) { + /* Ensure the allocated block uses the expected 8 KB size */ + KUNIT_EXPECT_EQ(test, gpu_buddy_block_size(&mm, block), SZ_8K); + /* Ensure the block starts at a 256 KB-aligned offset for proper alignment */ + KUNIT_EXPECT_EQ(test, gpu_buddy_block_offset(block) & (SZ_256K - 1), 0ULL); + } + gpu_buddy_free_list(&mm, &allocated, 0); + + for (i = 0; i < num_blocks; i++) + KUNIT_ASSERT_FALSE_MSG(test, gpu_buddy_alloc_blocks(&mm, 0, mm_size, SZ_16K, SZ_256K, + &allocated, 0), + "buddy_alloc hit an error size=%u\n", SZ_16K); + + list_for_each_entry(block, &allocated, link) { + /* Ensure the allocated block uses the expected 16 KB size */ + KUNIT_EXPECT_EQ(test, gpu_buddy_block_size(&mm, block), SZ_16K); + /* Ensure the block starts at a 256 KB-aligned offset for proper alignment */ + KUNIT_EXPECT_EQ(test, gpu_buddy_block_offset(block) & (SZ_256K - 1), 0ULL); + } + + /* + * Free alternating aligned blocks to introduce fragmentation. + * Ensures offset-aligned allocations remain valid after frees and + * verifies subtree max-alignment metadata is correctly maintained. + */ + list_for_each_entry_safe(block, tmp, &allocated, link) { + if (count % 2 == 0) + list_move_tail(&block->link, &freed); + count++; + } + gpu_buddy_free_list(&mm, &freed, 0); + + for (i = 0; i < num_blocks / 2; i++) + KUNIT_ASSERT_FALSE_MSG(test, gpu_buddy_alloc_blocks(&mm, 0, mm_size, SZ_16K, SZ_256K, + &allocated, 0), + "buddy_alloc hit an error size=%u\n", SZ_16K); + + /* + * Allocate with offset alignment after all slots are used; must fail. + * Confirms that no aligned offsets remain. + */ + KUNIT_ASSERT_TRUE_MSG(test, gpu_buddy_alloc_blocks(&mm, 0, mm_size, SZ_16K, SZ_256K, + &allocated, 0), + "buddy_alloc hit an error size=%u\n", SZ_16K); + gpu_buddy_free_list(&mm, &allocated, 0); + gpu_buddy_fini(&mm); +} + static void gpu_test_buddy_fragmentation_performance(struct kunit *test) { struct gpu_buddy_block *block, *tmp; @@ -912,6 +1076,8 @@ static struct kunit_case gpu_buddy_tests[] = { KUNIT_CASE(gpu_test_buddy_alloc_range_bias), KUNIT_CASE(gpu_test_buddy_fragmentation_performance), KUNIT_CASE(gpu_test_buddy_alloc_exceeds_max_order), + KUNIT_CASE(gpu_test_buddy_offset_aligned_allocation), + KUNIT_CASE(gpu_test_buddy_subtree_offset_alignment_stress), {} }; -- 2.34.1 ^ permalink raw reply related [flat|nested] 14+ messages in thread
* Re: [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations 2026-02-09 8:30 ` [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations Arunpravin Paneer Selvam @ 2026-02-09 19:23 ` kernel test robot 2026-02-09 19:26 ` kernel test robot 2026-02-09 21:20 ` kernel test robot 2 siblings, 0 replies; 14+ messages in thread From: kernel test robot @ 2026-02-09 19:23 UTC (permalink / raw) To: Arunpravin Paneer Selvam, matthew.auld, christian.koenig, dri-devel, intel-gfx, intel-xe, amd-gfx Cc: oe-kbuild-all, alexander.deucher, Arunpravin Paneer Selvam Hi Arunpravin, kernel test robot noticed the following build errors: [auto build test ERROR on 9d757669b2b22cd224c334924f798393ffca537c] url: https://github.com/intel-lab-lkp/linux/commits/Arunpravin-Paneer-Selvam/drm-buddy-Add-KUnit-test-for-offset-aligned-allocations/20260209-163512 base: 9d757669b2b22cd224c334924f798393ffca537c patch link: https://lore.kernel.org/r/20260209083051.13376-2-Arunpravin.PaneerSelvam%40amd.com patch subject: [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations config: m68k-allmodconfig (https://download.01.org/0day-ci/archive/20260210/202602100334.WD4wuI8R-lkp@intel.com/config) compiler: m68k-linux-gcc (GCC) 15.2.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260210/202602100334.WD4wuI8R-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202602100334.WD4wuI8R-lkp@intel.com/ All errors (new ones prefixed by >>): drivers/gpu/tests/gpu_buddy_test.c: In function 'gpu_test_buddy_subtree_offset_alignment_stress': >> drivers/gpu/tests/gpu_buddy_test.c:46:49: error: macro 'KUNIT_ASSERT_FALSE' passed 3 arguments, but takes just 2 46 | "buddy_init failed\n"); | ^ In file included from drivers/gpu/tests/gpu_buddy_test.c:7: include/kunit/test.h:1390:9: note: macro 'KUNIT_ASSERT_FALSE' defined here 1390 | #define KUNIT_ASSERT_FALSE(test, condition) \ | ^~~~~~~~~~~~~~~~~~ >> drivers/gpu/tests/gpu_buddy_test.c:45:9: error: 'KUNIT_ASSERT_FALSE' undeclared (first use in this function); did you mean 'KUNIT_ASSERTION'? 45 | KUNIT_ASSERT_FALSE(test, gpu_buddy_init(&mm, mm_size, SZ_4K), | ^~~~~~~~~~~~~~~~~~ | KUNIT_ASSERTION drivers/gpu/tests/gpu_buddy_test.c:45:9: note: each undeclared identifier is reported only once for each function it appears in vim +/KUNIT_ASSERT_FALSE +46 drivers/gpu/tests/gpu_buddy_test.c 23 24 static void gpu_test_buddy_subtree_offset_alignment_stress(struct kunit *test) 25 { 26 struct gpu_buddy_block *block; 27 struct rb_node *node = NULL; 28 const u64 mm_size = SZ_2M; 29 const u64 alignments[] = { 30 SZ_1M, 31 SZ_512K, 32 SZ_256K, 33 SZ_128K, 34 SZ_64K, 35 SZ_32K, 36 SZ_16K, 37 SZ_8K, 38 }; 39 40 struct list_head allocated[ARRAY_SIZE(alignments)]; 41 unsigned int i, order, max_subtree_align = 0; 42 struct gpu_buddy mm; 43 int ret, tree; 44 > 45 KUNIT_ASSERT_FALSE(test, gpu_buddy_init(&mm, mm_size, SZ_4K), > 46 "buddy_init failed\n"); 47 48 for (i = 0; i < ARRAY_SIZE(allocated); i++) 49 INIT_LIST_HEAD(&allocated[i]); 50 51 /* 52 * Exercise subtree_max_alignment tracking by allocating blocks with descending 53 * alignment constraints and freeing them in reverse order. This verifies that 54 * free-tree augmentation correctly propagates the maximum offset alignment 55 * present in each subtree at every stage. 56 */ 57 58 for (i = 0; i < ARRAY_SIZE(alignments); i++) { 59 struct gpu_buddy_block *root = NULL; 60 unsigned int expected; 61 u64 align; 62 63 align = alignments[i]; 64 expected = ilog2(align) - 1; 65 66 for (;;) { 67 ret = gpu_buddy_alloc_blocks(&mm, 68 0, mm_size, 69 SZ_4K, align, 70 &allocated[i], 71 0); 72 if (ret) 73 break; 74 75 block = list_last_entry(&allocated[i], 76 struct gpu_buddy_block, 77 link); 78 KUNIT_EXPECT_EQ(test, gpu_buddy_block_offset(block) & (align - 1), 0ULL); 79 } 80 81 for (order = mm.max_order + 1; order-- > 0 && !root; ) { 82 for (tree = 0; tree < 2; tree++) { 83 node = mm.free_trees[tree][order].rb_node; 84 if (node) { 85 root = container_of(node, 86 struct gpu_buddy_block, 87 rb); 88 break; 89 } 90 } 91 } 92 93 KUNIT_ASSERT_NOT_NULL(test, root); 94 KUNIT_EXPECT_EQ(test, root->subtree_max_alignment, expected); 95 } 96 97 for (i = ARRAY_SIZE(alignments); i-- > 0; ) { 98 gpu_buddy_free_list(&mm, &allocated[i], 0); 99 100 for (order = 0; order <= mm.max_order; order++) { 101 for (tree = 0; tree < 2; tree++) { 102 node = mm.free_trees[tree][order].rb_node; 103 if (!node) 104 continue; 105 106 block = container_of(node, struct gpu_buddy_block, rb); 107 max_subtree_align = max(max_subtree_align, block->subtree_max_alignment); 108 } 109 } 110 111 KUNIT_EXPECT_GE(test, max_subtree_align, ilog2(alignments[i])); 112 } 113 114 gpu_buddy_fini(&mm); 115 } 116 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations 2026-02-09 8:30 ` [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations Arunpravin Paneer Selvam 2026-02-09 19:23 ` kernel test robot @ 2026-02-09 19:26 ` kernel test robot 2026-02-09 21:20 ` kernel test robot 2 siblings, 0 replies; 14+ messages in thread From: kernel test robot @ 2026-02-09 19:26 UTC (permalink / raw) To: Arunpravin Paneer Selvam, matthew.auld, christian.koenig, dri-devel, intel-gfx, intel-xe, amd-gfx Cc: oe-kbuild-all, alexander.deucher, Arunpravin Paneer Selvam Hi Arunpravin, kernel test robot noticed the following build errors: [auto build test ERROR on 9d757669b2b22cd224c334924f798393ffca537c] url: https://github.com/intel-lab-lkp/linux/commits/Arunpravin-Paneer-Selvam/drm-buddy-Add-KUnit-test-for-offset-aligned-allocations/20260209-163512 base: 9d757669b2b22cd224c334924f798393ffca537c patch link: https://lore.kernel.org/r/20260209083051.13376-2-Arunpravin.PaneerSelvam%40amd.com patch subject: [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations config: x86_64-rhel-9.4-kunit (https://download.01.org/0day-ci/archive/20260209/202602092035.vOm98J4x-lkp@intel.com/config) compiler: gcc-14 (Debian 14.2.0-19) 14.2.0 reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260209/202602092035.vOm98J4x-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202602092035.vOm98J4x-lkp@intel.com/ All errors (new ones prefixed by >>): drivers/gpu/tests/gpu_buddy_test.c: In function 'gpu_test_buddy_subtree_offset_alignment_stress': >> drivers/gpu/tests/gpu_buddy_test.c:46:49: error: macro "KUNIT_ASSERT_FALSE" passed 3 arguments, but takes just 2 46 | "buddy_init failed\n"); | ^ In file included from drivers/gpu/tests/gpu_buddy_test.c:7: include/kunit/test.h:1390:9: note: macro "KUNIT_ASSERT_FALSE" defined here 1390 | #define KUNIT_ASSERT_FALSE(test, condition) \ | ^~~~~~~~~~~~~~~~~~ >> drivers/gpu/tests/gpu_buddy_test.c:45:9: error: 'KUNIT_ASSERT_FALSE' undeclared (first use in this function); did you mean 'KUNIT_ASSERTION'? 45 | KUNIT_ASSERT_FALSE(test, gpu_buddy_init(&mm, mm_size, SZ_4K), | ^~~~~~~~~~~~~~~~~~ | KUNIT_ASSERTION drivers/gpu/tests/gpu_buddy_test.c:45:9: note: each undeclared identifier is reported only once for each function it appears in vim +/KUNIT_ASSERT_FALSE +46 drivers/gpu/tests/gpu_buddy_test.c 23 24 static void gpu_test_buddy_subtree_offset_alignment_stress(struct kunit *test) 25 { 26 struct gpu_buddy_block *block; 27 struct rb_node *node = NULL; 28 const u64 mm_size = SZ_2M; 29 const u64 alignments[] = { 30 SZ_1M, 31 SZ_512K, 32 SZ_256K, 33 SZ_128K, 34 SZ_64K, 35 SZ_32K, 36 SZ_16K, 37 SZ_8K, 38 }; 39 40 struct list_head allocated[ARRAY_SIZE(alignments)]; 41 unsigned int i, order, max_subtree_align = 0; 42 struct gpu_buddy mm; 43 int ret, tree; 44 > 45 KUNIT_ASSERT_FALSE(test, gpu_buddy_init(&mm, mm_size, SZ_4K), > 46 "buddy_init failed\n"); 47 48 for (i = 0; i < ARRAY_SIZE(allocated); i++) 49 INIT_LIST_HEAD(&allocated[i]); 50 51 /* 52 * Exercise subtree_max_alignment tracking by allocating blocks with descending 53 * alignment constraints and freeing them in reverse order. This verifies that 54 * free-tree augmentation correctly propagates the maximum offset alignment 55 * present in each subtree at every stage. 56 */ 57 58 for (i = 0; i < ARRAY_SIZE(alignments); i++) { 59 struct gpu_buddy_block *root = NULL; 60 unsigned int expected; 61 u64 align; 62 63 align = alignments[i]; 64 expected = ilog2(align) - 1; 65 66 for (;;) { 67 ret = gpu_buddy_alloc_blocks(&mm, 68 0, mm_size, 69 SZ_4K, align, 70 &allocated[i], 71 0); 72 if (ret) 73 break; 74 75 block = list_last_entry(&allocated[i], 76 struct gpu_buddy_block, 77 link); 78 KUNIT_EXPECT_EQ(test, gpu_buddy_block_offset(block) & (align - 1), 0ULL); 79 } 80 81 for (order = mm.max_order + 1; order-- > 0 && !root; ) { 82 for (tree = 0; tree < 2; tree++) { 83 node = mm.free_trees[tree][order].rb_node; 84 if (node) { 85 root = container_of(node, 86 struct gpu_buddy_block, 87 rb); 88 break; 89 } 90 } 91 } 92 93 KUNIT_ASSERT_NOT_NULL(test, root); 94 KUNIT_EXPECT_EQ(test, root->subtree_max_alignment, expected); 95 } 96 97 for (i = ARRAY_SIZE(alignments); i-- > 0; ) { 98 gpu_buddy_free_list(&mm, &allocated[i], 0); 99 100 for (order = 0; order <= mm.max_order; order++) { 101 for (tree = 0; tree < 2; tree++) { 102 node = mm.free_trees[tree][order].rb_node; 103 if (!node) 104 continue; 105 106 block = container_of(node, struct gpu_buddy_block, rb); 107 max_subtree_align = max(max_subtree_align, block->subtree_max_alignment); 108 } 109 } 110 111 KUNIT_EXPECT_GE(test, max_subtree_align, ilog2(alignments[i])); 112 } 113 114 gpu_buddy_fini(&mm); 115 } 116 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations 2026-02-09 8:30 ` [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations Arunpravin Paneer Selvam 2026-02-09 19:23 ` kernel test robot 2026-02-09 19:26 ` kernel test robot @ 2026-02-09 21:20 ` kernel test robot 2 siblings, 0 replies; 14+ messages in thread From: kernel test robot @ 2026-02-09 21:20 UTC (permalink / raw) To: Arunpravin Paneer Selvam, matthew.auld, christian.koenig, dri-devel, intel-gfx, intel-xe, amd-gfx Cc: llvm, oe-kbuild-all, alexander.deucher, Arunpravin Paneer Selvam Hi Arunpravin, kernel test robot noticed the following build warnings: [auto build test WARNING on 9d757669b2b22cd224c334924f798393ffca537c] url: https://github.com/intel-lab-lkp/linux/commits/Arunpravin-Paneer-Selvam/drm-buddy-Add-KUnit-test-for-offset-aligned-allocations/20260209-163512 base: 9d757669b2b22cd224c334924f798393ffca537c patch link: https://lore.kernel.org/r/20260209083051.13376-2-Arunpravin.PaneerSelvam%40amd.com patch subject: [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations config: riscv-allyesconfig (https://download.01.org/0day-ci/archive/20260210/202602100509.jUETbEEY-lkp@intel.com/config) compiler: clang version 16.0.6 (https://github.com/llvm/llvm-project 7cbf1a2591520c2491aa35339f227775f4d3adf6) reproduce (this is a W=1 build): (https://download.01.org/0day-ci/archive/20260210/202602100509.jUETbEEY-lkp@intel.com/reproduce) If you fix the issue in a separate patch/commit (i.e. not just a new version of the same patch/commit), kindly add following tags | Reported-by: kernel test robot <lkp@intel.com> | Closes: https://lore.kernel.org/oe-kbuild-all/202602100509.jUETbEEY-lkp@intel.com/ All warnings (new ones prefixed by >>): drivers/gpu/tests/gpu_buddy_test.c:46:7: error: too many arguments provided to function-like macro invocation "buddy_init failed\n"); ^ include/kunit/test.h:1390:9: note: macro 'KUNIT_ASSERT_FALSE' defined here #define KUNIT_ASSERT_FALSE(test, condition) \ ^ drivers/gpu/tests/gpu_buddy_test.c:45:2: error: use of undeclared identifier 'KUNIT_ASSERT_FALSE'; did you mean 'KUNIT_ASSERTION'? KUNIT_ASSERT_FALSE(test, gpu_buddy_init(&mm, mm_size, SZ_4K), ^~~~~~~~~~~~~~~~~~ KUNIT_ASSERTION include/kunit/assert.h:27:2: note: 'KUNIT_ASSERTION' declared here KUNIT_ASSERTION, ^ >> drivers/gpu/tests/gpu_buddy_test.c:45:2: warning: expression result unused [-Wunused-value] KUNIT_ASSERT_FALSE(test, gpu_buddy_init(&mm, mm_size, SZ_4K), ^~~~~~~~~~~~~~~~~~ 1 warning and 2 errors generated. vim +45 drivers/gpu/tests/gpu_buddy_test.c 23 24 static void gpu_test_buddy_subtree_offset_alignment_stress(struct kunit *test) 25 { 26 struct gpu_buddy_block *block; 27 struct rb_node *node = NULL; 28 const u64 mm_size = SZ_2M; 29 const u64 alignments[] = { 30 SZ_1M, 31 SZ_512K, 32 SZ_256K, 33 SZ_128K, 34 SZ_64K, 35 SZ_32K, 36 SZ_16K, 37 SZ_8K, 38 }; 39 40 struct list_head allocated[ARRAY_SIZE(alignments)]; 41 unsigned int i, order, max_subtree_align = 0; 42 struct gpu_buddy mm; 43 int ret, tree; 44 > 45 KUNIT_ASSERT_FALSE(test, gpu_buddy_init(&mm, mm_size, SZ_4K), 46 "buddy_init failed\n"); 47 48 for (i = 0; i < ARRAY_SIZE(allocated); i++) 49 INIT_LIST_HEAD(&allocated[i]); 50 51 /* 52 * Exercise subtree_max_alignment tracking by allocating blocks with descending 53 * alignment constraints and freeing them in reverse order. This verifies that 54 * free-tree augmentation correctly propagates the maximum offset alignment 55 * present in each subtree at every stage. 56 */ 57 58 for (i = 0; i < ARRAY_SIZE(alignments); i++) { 59 struct gpu_buddy_block *root = NULL; 60 unsigned int expected; 61 u64 align; 62 63 align = alignments[i]; 64 expected = ilog2(align) - 1; 65 66 for (;;) { 67 ret = gpu_buddy_alloc_blocks(&mm, 68 0, mm_size, 69 SZ_4K, align, 70 &allocated[i], 71 0); 72 if (ret) 73 break; 74 75 block = list_last_entry(&allocated[i], 76 struct gpu_buddy_block, 77 link); 78 KUNIT_EXPECT_EQ(test, gpu_buddy_block_offset(block) & (align - 1), 0ULL); 79 } 80 81 for (order = mm.max_order + 1; order-- > 0 && !root; ) { 82 for (tree = 0; tree < 2; tree++) { 83 node = mm.free_trees[tree][order].rb_node; 84 if (node) { 85 root = container_of(node, 86 struct gpu_buddy_block, 87 rb); 88 break; 89 } 90 } 91 } 92 93 KUNIT_ASSERT_NOT_NULL(test, root); 94 KUNIT_EXPECT_EQ(test, root->subtree_max_alignment, expected); 95 } 96 97 for (i = ARRAY_SIZE(alignments); i-- > 0; ) { 98 gpu_buddy_free_list(&mm, &allocated[i], 0); 99 100 for (order = 0; order <= mm.max_order; order++) { 101 for (tree = 0; tree < 2; tree++) { 102 node = mm.free_trees[tree][order].rb_node; 103 if (!node) 104 continue; 105 106 block = container_of(node, struct gpu_buddy_block, rb); 107 max_subtree_align = max(max_subtree_align, block->subtree_max_alignment); 108 } 109 } 110 111 KUNIT_EXPECT_GE(test, max_subtree_align, ilog2(alignments[i])); 112 } 113 114 gpu_buddy_fini(&mm); 115 } 116 -- 0-DAY CI Kernel Test Service https://github.com/intel/lkp-tests/wiki ^ permalink raw reply [flat|nested] 14+ messages in thread
* ✗ CI.checkpatch: warning for series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling 2026-02-09 8:30 [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling Arunpravin Paneer Selvam 2026-02-09 8:30 ` [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations Arunpravin Paneer Selvam @ 2026-02-09 8:37 ` Patchwork 2026-02-09 8:39 ` ✓ CI.KUnit: success " Patchwork ` (4 subsequent siblings) 6 siblings, 0 replies; 14+ messages in thread From: Patchwork @ 2026-02-09 8:37 UTC (permalink / raw) To: Arunpravin Paneer Selvam; +Cc: intel-xe == Series Details == Series: series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling URL : https://patchwork.freedesktop.org/series/161338/ State : warning == Summary == + KERNEL=/kernel + git clone https://gitlab.freedesktop.org/drm/maintainer-tools mt Cloning into 'mt'... warning: redirecting to https://gitlab.freedesktop.org/drm/maintainer-tools.git/ + git -C mt rev-list -n1 origin/master 1f57ba1afceae32108bd24770069f764d940a0e4 + cd /kernel + git config --global --add safe.directory /kernel + git log -n1 commit 6653bd74e57113d4998fc010d497b17fce1cc0db Author: Arunpravin Paneer Selvam <Arunpravin.PaneerSelvam@amd.com> Date: Mon Feb 9 14:00:51 2026 +0530 drm/buddy: Add KUnit test for offset-aligned allocations Add KUnit test to validate offset-aligned allocations in the DRM buddy allocator. Validate offset-aligned allocation: The test covers allocations with sizes smaller than the alignment constraint and verifies correct size preservation, offset alignment, and behavior across multiple allocation sizes. It also exercises fragmentation by freeing alternating blocks and confirms that allocation fails once all aligned offsets are consumed. Stress subtree_max_alignment propagation: Exercise subtree_max_alignment tracking by allocating blocks with descending alignment constraints and freeing them in reverse order. This verifies that free-tree augmentation correctly propagates the maximum offset alignment present in each subtree at every stage. v2: - Move the patch to gpu/tests/gpu_buddy_test.c file. Signed-off-by: Arunpravin Paneer Selvam <Arunpravin.PaneerSelvam@amd.com> + /mt/dim checkpatch 9ddce2e2e1c2891bc26ea8648b2ba530b73937fe drm-intel 0ae593f23b79 drm/buddy: Improve offset-aligned allocation handling -:10: WARNING:COMMIT_LOG_LONG_LINE: Prefer a maximum 75 chars per line (possible unwrapped commit description?) #10: alignment order, which often caused higher-order free blocks to be split even -:334: WARNING:AVOID_BUG: Do not crash the kernel unless it is absolutely unavoidable--use WARN_ON_ONCE() plus recovery code (if feasible) instead of BUG() or variants #334: FILE: drivers/gpu/buddy.c:1329: + BUG_ON(size >= min_block_size && order < min_order); total: 0 errors, 2 warnings, 0 checks, 354 lines checked 6653bd74e571 drm/buddy: Add KUnit test for offset-aligned allocations -:10: WARNING:COMMIT_LOG_LONG_LINE: Prefer a maximum 75 chars per line (possible unwrapped commit description?) #10: The test covers allocations with sizes smaller than the alignment constraint -:118: WARNING:LONG_LINE: line length of 105 exceeds 100 columns #118: FILE: drivers/gpu/tests/gpu_buddy_test.c:107: + max_subtree_align = max(max_subtree_align, block->subtree_max_alignment); -:160: WARNING:LONG_LINE: line length of 101 exceeds 100 columns #160: FILE: drivers/gpu/tests/gpu_buddy_test.c:149: + KUNIT_ASSERT_FALSE_MSG(test, gpu_buddy_alloc_blocks(&mm, 0, mm_size, SZ_16K, SZ_256K, -:184: WARNING:LONG_LINE: line length of 101 exceeds 100 columns #184: FILE: drivers/gpu/tests/gpu_buddy_test.c:173: + KUNIT_ASSERT_FALSE_MSG(test, gpu_buddy_alloc_blocks(&mm, 0, mm_size, SZ_16K, SZ_256K, total: 0 errors, 4 warnings, 0 checks, 178 lines checked ^ permalink raw reply [flat|nested] 14+ messages in thread
* ✓ CI.KUnit: success for series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling 2026-02-09 8:30 [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling Arunpravin Paneer Selvam 2026-02-09 8:30 ` [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations Arunpravin Paneer Selvam 2026-02-09 8:37 ` ✗ CI.checkpatch: warning for series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling Patchwork @ 2026-02-09 8:39 ` Patchwork 2026-02-09 8:57 ` ✗ CI.checksparse: warning " Patchwork ` (3 subsequent siblings) 6 siblings, 0 replies; 14+ messages in thread From: Patchwork @ 2026-02-09 8:39 UTC (permalink / raw) To: Arunpravin Paneer Selvam; +Cc: intel-xe == Series Details == Series: series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling URL : https://patchwork.freedesktop.org/series/161338/ State : success == Summary == + trap cleanup EXIT + /kernel/tools/testing/kunit/kunit.py run --kunitconfig /kernel/drivers/gpu/drm/xe/.kunitconfig [08:37:48] Configuring KUnit Kernel ... Generating .config ... Populating config with: $ make ARCH=um O=.kunit olddefconfig [08:37:52] Building KUnit Kernel ... Populating config with: $ make ARCH=um O=.kunit olddefconfig Building with: $ make all compile_commands.json scripts_gdb ARCH=um O=.kunit --jobs=25 [08:38:30] Starting KUnit Kernel (1/1)... [08:38:30] ============================================================ Running tests with: $ .kunit/linux kunit.enable=1 mem=1G console=tty kunit_shutdown=halt [08:38:30] ================== guc_buf (11 subtests) =================== [08:38:30] [PASSED] test_smallest [08:38:30] [PASSED] test_largest [08:38:31] [PASSED] test_granular [08:38:31] [PASSED] test_unique [08:38:31] [PASSED] test_overlap [08:38:31] [PASSED] test_reusable [08:38:31] [PASSED] test_too_big [08:38:31] [PASSED] test_flush [08:38:31] [PASSED] test_lookup [08:38:31] [PASSED] test_data [08:38:31] [PASSED] test_class [08:38:31] ===================== [PASSED] guc_buf ===================== [08:38:31] =================== guc_dbm (7 subtests) =================== [08:38:31] [PASSED] test_empty [08:38:31] [PASSED] test_default [08:38:31] ======================== test_size ======================== [08:38:31] [PASSED] 4 [08:38:31] [PASSED] 8 [08:38:31] [PASSED] 32 [08:38:31] [PASSED] 256 [08:38:31] ==================== [PASSED] test_size ==================== [08:38:31] ======================= test_reuse ======================== [08:38:31] [PASSED] 4 [08:38:31] [PASSED] 8 [08:38:31] [PASSED] 32 [08:38:31] [PASSED] 256 [08:38:31] =================== [PASSED] test_reuse ==================== [08:38:31] =================== test_range_overlap ==================== [08:38:31] [PASSED] 4 [08:38:31] [PASSED] 8 [08:38:31] [PASSED] 32 [08:38:31] [PASSED] 256 [08:38:31] =============== [PASSED] test_range_overlap ================ [08:38:31] =================== test_range_compact ==================== [08:38:31] [PASSED] 4 [08:38:31] [PASSED] 8 [08:38:31] [PASSED] 32 [08:38:31] [PASSED] 256 [08:38:31] =============== [PASSED] test_range_compact ================ [08:38:31] ==================== test_range_spare ===================== [08:38:31] [PASSED] 4 [08:38:31] [PASSED] 8 [08:38:31] [PASSED] 32 [08:38:31] [PASSED] 256 [08:38:31] ================ [PASSED] test_range_spare ================= [08:38:31] ===================== [PASSED] guc_dbm ===================== [08:38:31] =================== guc_idm (6 subtests) =================== [08:38:31] [PASSED] bad_init [08:38:31] [PASSED] no_init [08:38:31] [PASSED] init_fini [08:38:31] [PASSED] check_used [08:38:31] [PASSED] check_quota [08:38:31] [PASSED] check_all [08:38:31] ===================== [PASSED] guc_idm ===================== [08:38:31] ================== no_relay (3 subtests) =================== [08:38:31] [PASSED] xe_drops_guc2pf_if_not_ready [08:38:31] [PASSED] xe_drops_guc2vf_if_not_ready [08:38:31] [PASSED] xe_rejects_send_if_not_ready [08:38:31] ==================== [PASSED] no_relay ===================== [08:38:31] ================== pf_relay (14 subtests) ================== [08:38:31] [PASSED] pf_rejects_guc2pf_too_short [08:38:31] [PASSED] pf_rejects_guc2pf_too_long [08:38:31] [PASSED] pf_rejects_guc2pf_no_payload [08:38:31] [PASSED] pf_fails_no_payload [08:38:31] [PASSED] pf_fails_bad_origin [08:38:31] [PASSED] pf_fails_bad_type [08:38:31] [PASSED] pf_txn_reports_error [08:38:31] [PASSED] pf_txn_sends_pf2guc [08:38:31] [PASSED] pf_sends_pf2guc [08:38:31] [SKIPPED] pf_loopback_nop [08:38:31] [SKIPPED] pf_loopback_echo [08:38:31] [SKIPPED] pf_loopback_fail [08:38:31] [SKIPPED] pf_loopback_busy [08:38:31] [SKIPPED] pf_loopback_retry [08:38:31] ==================== [PASSED] pf_relay ===================== [08:38:31] ================== vf_relay (3 subtests) =================== [08:38:31] [PASSED] vf_rejects_guc2vf_too_short [08:38:31] [PASSED] vf_rejects_guc2vf_too_long [08:38:31] [PASSED] vf_rejects_guc2vf_no_payload [08:38:31] ==================== [PASSED] vf_relay ===================== [08:38:31] ================ pf_gt_config (6 subtests) ================= [08:38:31] [PASSED] fair_contexts_1vf [08:38:31] [PASSED] fair_doorbells_1vf [08:38:31] [PASSED] fair_ggtt_1vf [08:38:31] ====================== fair_contexts ====================== [08:38:31] [PASSED] 1 VF [08:38:31] [PASSED] 2 VFs [08:38:31] [PASSED] 3 VFs [08:38:31] [PASSED] 4 VFs [08:38:31] [PASSED] 5 VFs [08:38:31] [PASSED] 6 VFs [08:38:31] [PASSED] 7 VFs [08:38:31] [PASSED] 8 VFs [08:38:31] [PASSED] 9 VFs [08:38:31] [PASSED] 10 VFs [08:38:31] [PASSED] 11 VFs [08:38:31] [PASSED] 12 VFs [08:38:31] [PASSED] 13 VFs [08:38:31] [PASSED] 14 VFs [08:38:31] [PASSED] 15 VFs [08:38:31] [PASSED] 16 VFs [08:38:31] [PASSED] 17 VFs [08:38:31] [PASSED] 18 VFs [08:38:31] [PASSED] 19 VFs [08:38:31] [PASSED] 20 VFs [08:38:31] [PASSED] 21 VFs [08:38:31] [PASSED] 22 VFs [08:38:31] [PASSED] 23 VFs [08:38:31] [PASSED] 24 VFs [08:38:31] [PASSED] 25 VFs [08:38:31] [PASSED] 26 VFs [08:38:31] [PASSED] 27 VFs [08:38:31] [PASSED] 28 VFs [08:38:31] [PASSED] 29 VFs [08:38:31] [PASSED] 30 VFs [08:38:31] [PASSED] 31 VFs [08:38:31] [PASSED] 32 VFs [08:38:31] [PASSED] 33 VFs [08:38:31] [PASSED] 34 VFs [08:38:31] [PASSED] 35 VFs [08:38:31] [PASSED] 36 VFs [08:38:31] [PASSED] 37 VFs [08:38:31] [PASSED] 38 VFs [08:38:31] [PASSED] 39 VFs [08:38:31] [PASSED] 40 VFs [08:38:31] [PASSED] 41 VFs [08:38:31] [PASSED] 42 VFs [08:38:31] [PASSED] 43 VFs [08:38:31] [PASSED] 44 VFs [08:38:31] [PASSED] 45 VFs [08:38:31] [PASSED] 46 VFs [08:38:31] [PASSED] 47 VFs [08:38:31] [PASSED] 48 VFs [08:38:31] [PASSED] 49 VFs [08:38:31] [PASSED] 50 VFs [08:38:31] [PASSED] 51 VFs [08:38:31] [PASSED] 52 VFs [08:38:31] [PASSED] 53 VFs [08:38:31] [PASSED] 54 VFs [08:38:31] [PASSED] 55 VFs [08:38:31] [PASSED] 56 VFs [08:38:31] [PASSED] 57 VFs [08:38:31] [PASSED] 58 VFs [08:38:31] [PASSED] 59 VFs [08:38:31] [PASSED] 60 VFs [08:38:31] [PASSED] 61 VFs [08:38:31] [PASSED] 62 VFs [08:38:31] [PASSED] 63 VFs [08:38:31] ================== [PASSED] fair_contexts ================== [08:38:31] ===================== fair_doorbells ====================== [08:38:31] [PASSED] 1 VF [08:38:31] [PASSED] 2 VFs [08:38:31] [PASSED] 3 VFs [08:38:31] [PASSED] 4 VFs [08:38:31] [PASSED] 5 VFs [08:38:31] [PASSED] 6 VFs [08:38:31] [PASSED] 7 VFs [08:38:31] [PASSED] 8 VFs [08:38:31] [PASSED] 9 VFs [08:38:31] [PASSED] 10 VFs [08:38:31] [PASSED] 11 VFs [08:38:31] [PASSED] 12 VFs [08:38:31] [PASSED] 13 VFs [08:38:31] [PASSED] 14 VFs [08:38:31] [PASSED] 15 VFs [08:38:31] [PASSED] 16 VFs [08:38:31] [PASSED] 17 VFs [08:38:31] [PASSED] 18 VFs [08:38:31] [PASSED] 19 VFs [08:38:31] [PASSED] 20 VFs [08:38:31] [PASSED] 21 VFs [08:38:31] [PASSED] 22 VFs [08:38:31] [PASSED] 23 VFs [08:38:31] [PASSED] 24 VFs [08:38:31] [PASSED] 25 VFs [08:38:31] [PASSED] 26 VFs [08:38:31] [PASSED] 27 VFs [08:38:31] [PASSED] 28 VFs [08:38:31] [PASSED] 29 VFs [08:38:31] [PASSED] 30 VFs [08:38:31] [PASSED] 31 VFs [08:38:31] [PASSED] 32 VFs [08:38:31] [PASSED] 33 VFs [08:38:31] [PASSED] 34 VFs [08:38:31] [PASSED] 35 VFs [08:38:31] [PASSED] 36 VFs [08:38:31] [PASSED] 37 VFs [08:38:31] [PASSED] 38 VFs [08:38:31] [PASSED] 39 VFs [08:38:31] [PASSED] 40 VFs [08:38:31] [PASSED] 41 VFs [08:38:31] [PASSED] 42 VFs [08:38:31] [PASSED] 43 VFs [08:38:31] [PASSED] 44 VFs [08:38:31] [PASSED] 45 VFs [08:38:31] [PASSED] 46 VFs [08:38:31] [PASSED] 47 VFs [08:38:31] [PASSED] 48 VFs [08:38:31] [PASSED] 49 VFs [08:38:31] [PASSED] 50 VFs [08:38:31] [PASSED] 51 VFs [08:38:31] [PASSED] 52 VFs [08:38:31] [PASSED] 53 VFs [08:38:31] [PASSED] 54 VFs [08:38:31] [PASSED] 55 VFs [08:38:31] [PASSED] 56 VFs [08:38:31] [PASSED] 57 VFs [08:38:31] [PASSED] 58 VFs [08:38:31] [PASSED] 59 VFs [08:38:31] [PASSED] 60 VFs [08:38:31] [PASSED] 61 VFs [08:38:31] [PASSED] 62 VFs [08:38:31] [PASSED] 63 VFs [08:38:31] ================= [PASSED] fair_doorbells ================== [08:38:31] ======================== fair_ggtt ======================== [08:38:31] [PASSED] 1 VF [08:38:31] [PASSED] 2 VFs [08:38:31] [PASSED] 3 VFs [08:38:31] [PASSED] 4 VFs [08:38:31] [PASSED] 5 VFs [08:38:31] [PASSED] 6 VFs [08:38:31] [PASSED] 7 VFs [08:38:31] [PASSED] 8 VFs [08:38:31] [PASSED] 9 VFs [08:38:31] [PASSED] 10 VFs [08:38:31] [PASSED] 11 VFs [08:38:31] [PASSED] 12 VFs [08:38:31] [PASSED] 13 VFs [08:38:31] [PASSED] 14 VFs [08:38:31] [PASSED] 15 VFs [08:38:31] [PASSED] 16 VFs [08:38:31] [PASSED] 17 VFs [08:38:31] [PASSED] 18 VFs [08:38:31] [PASSED] 19 VFs [08:38:31] [PASSED] 20 VFs [08:38:31] [PASSED] 21 VFs [08:38:31] [PASSED] 22 VFs [08:38:31] [PASSED] 23 VFs [08:38:31] [PASSED] 24 VFs [08:38:31] [PASSED] 25 VFs [08:38:31] [PASSED] 26 VFs [08:38:31] [PASSED] 27 VFs [08:38:31] [PASSED] 28 VFs [08:38:31] [PASSED] 29 VFs [08:38:31] [PASSED] 30 VFs [08:38:31] [PASSED] 31 VFs [08:38:31] [PASSED] 32 VFs [08:38:31] [PASSED] 33 VFs [08:38:31] [PASSED] 34 VFs [08:38:31] [PASSED] 35 VFs [08:38:31] [PASSED] 36 VFs [08:38:31] [PASSED] 37 VFs [08:38:31] [PASSED] 38 VFs [08:38:31] [PASSED] 39 VFs [08:38:31] [PASSED] 40 VFs [08:38:31] [PASSED] 41 VFs [08:38:31] [PASSED] 42 VFs [08:38:31] [PASSED] 43 VFs [08:38:31] [PASSED] 44 VFs [08:38:31] [PASSED] 45 VFs [08:38:31] [PASSED] 46 VFs [08:38:31] [PASSED] 47 VFs [08:38:31] [PASSED] 48 VFs [08:38:31] [PASSED] 49 VFs [08:38:31] [PASSED] 50 VFs [08:38:31] [PASSED] 51 VFs [08:38:31] [PASSED] 52 VFs [08:38:31] [PASSED] 53 VFs [08:38:31] [PASSED] 54 VFs [08:38:31] [PASSED] 55 VFs [08:38:31] [PASSED] 56 VFs [08:38:31] [PASSED] 57 VFs [08:38:31] [PASSED] 58 VFs [08:38:31] [PASSED] 59 VFs [08:38:31] [PASSED] 60 VFs [08:38:31] [PASSED] 61 VFs [08:38:31] [PASSED] 62 VFs [08:38:31] [PASSED] 63 VFs [08:38:31] ==================== [PASSED] fair_ggtt ==================== [08:38:31] ================== [PASSED] pf_gt_config =================== [08:38:31] ===================== lmtt (1 subtest) ===================== [08:38:31] ======================== test_ops ========================= [08:38:31] [PASSED] 2-level [08:38:31] [PASSED] multi-level [08:38:31] ==================== [PASSED] test_ops ===================== [08:38:31] ====================== [PASSED] lmtt ======================= [08:38:31] ================= pf_service (11 subtests) ================= [08:38:31] [PASSED] pf_negotiate_any [08:38:31] [PASSED] pf_negotiate_base_match [08:38:31] [PASSED] pf_negotiate_base_newer [08:38:31] [PASSED] pf_negotiate_base_next [08:38:31] [SKIPPED] pf_negotiate_base_older [08:38:31] [PASSED] pf_negotiate_base_prev [08:38:31] [PASSED] pf_negotiate_latest_match [08:38:31] [PASSED] pf_negotiate_latest_newer [08:38:31] [PASSED] pf_negotiate_latest_next [08:38:31] [SKIPPED] pf_negotiate_latest_older [08:38:31] [SKIPPED] pf_negotiate_latest_prev [08:38:31] =================== [PASSED] pf_service ==================== [08:38:31] ================= xe_guc_g2g (2 subtests) ================== [08:38:31] ============== xe_live_guc_g2g_kunit_default ============== [08:38:31] ========= [SKIPPED] xe_live_guc_g2g_kunit_default ========== [08:38:31] ============== xe_live_guc_g2g_kunit_allmem =============== [08:38:31] ========== [SKIPPED] xe_live_guc_g2g_kunit_allmem ========== [08:38:31] =================== [SKIPPED] xe_guc_g2g =================== [08:38:31] =================== xe_mocs (2 subtests) =================== [08:38:31] ================ xe_live_mocs_kernel_kunit ================ [08:38:31] =========== [SKIPPED] xe_live_mocs_kernel_kunit ============ [08:38:31] ================ xe_live_mocs_reset_kunit ================= [08:38:31] ============ [SKIPPED] xe_live_mocs_reset_kunit ============ [08:38:31] ==================== [SKIPPED] xe_mocs ===================== [08:38:31] ================= xe_migrate (2 subtests) ================== [08:38:31] ================= xe_migrate_sanity_kunit ================= [08:38:31] ============ [SKIPPED] xe_migrate_sanity_kunit ============= [08:38:31] ================== xe_validate_ccs_kunit ================== [08:38:31] ============= [SKIPPED] xe_validate_ccs_kunit ============== [08:38:31] =================== [SKIPPED] xe_migrate =================== [08:38:31] ================== xe_dma_buf (1 subtest) ================== [08:38:31] ==================== xe_dma_buf_kunit ===================== [08:38:31] ================ [SKIPPED] xe_dma_buf_kunit ================ [08:38:31] =================== [SKIPPED] xe_dma_buf =================== [08:38:31] ================= xe_bo_shrink (1 subtest) ================= [08:38:31] =================== xe_bo_shrink_kunit ==================== [08:38:31] =============== [SKIPPED] xe_bo_shrink_kunit =============== [08:38:31] ================== [SKIPPED] xe_bo_shrink ================== [08:38:31] ==================== xe_bo (2 subtests) ==================== [08:38:31] ================== xe_ccs_migrate_kunit =================== [08:38:31] ============== [SKIPPED] xe_ccs_migrate_kunit ============== [08:38:31] ==================== xe_bo_evict_kunit ==================== [08:38:31] =============== [SKIPPED] xe_bo_evict_kunit ================ [08:38:31] ===================== [SKIPPED] xe_bo ====================== [08:38:31] ==================== args (13 subtests) ==================== [08:38:31] [PASSED] count_args_test [08:38:31] [PASSED] call_args_example [08:38:31] [PASSED] call_args_test [08:38:31] [PASSED] drop_first_arg_example [08:38:31] [PASSED] drop_first_arg_test [08:38:31] [PASSED] first_arg_example [08:38:31] [PASSED] first_arg_test [08:38:31] [PASSED] last_arg_example [08:38:31] [PASSED] last_arg_test [08:38:31] [PASSED] pick_arg_example [08:38:31] [PASSED] if_args_example [08:38:31] [PASSED] if_args_test [08:38:31] [PASSED] sep_comma_example [08:38:31] ====================== [PASSED] args ======================= [08:38:31] =================== xe_pci (3 subtests) ==================== [08:38:31] ==================== check_graphics_ip ==================== [08:38:31] [PASSED] 12.00 Xe_LP [08:38:31] [PASSED] 12.10 Xe_LP+ [08:38:31] [PASSED] 12.55 Xe_HPG [08:38:31] [PASSED] 12.60 Xe_HPC [08:38:31] [PASSED] 12.70 Xe_LPG [08:38:31] [PASSED] 12.71 Xe_LPG [08:38:31] [PASSED] 12.74 Xe_LPG+ [08:38:31] [PASSED] 20.01 Xe2_HPG [08:38:31] [PASSED] 20.02 Xe2_HPG [08:38:31] [PASSED] 20.04 Xe2_LPG [08:38:31] [PASSED] 30.00 Xe3_LPG [08:38:31] [PASSED] 30.01 Xe3_LPG [08:38:31] [PASSED] 30.03 Xe3_LPG [08:38:31] [PASSED] 30.04 Xe3_LPG [08:38:31] [PASSED] 30.05 Xe3_LPG [08:38:31] [PASSED] 35.11 Xe3p_XPC [08:38:31] ================ [PASSED] check_graphics_ip ================ [08:38:31] ===================== check_media_ip ====================== [08:38:31] [PASSED] 12.00 Xe_M [08:38:31] [PASSED] 12.55 Xe_HPM [08:38:31] [PASSED] 13.00 Xe_LPM+ [08:38:31] [PASSED] 13.01 Xe2_HPM [08:38:31] [PASSED] 20.00 Xe2_LPM [08:38:31] [PASSED] 30.00 Xe3_LPM [08:38:31] [PASSED] 30.02 Xe3_LPM [08:38:31] [PASSED] 35.00 Xe3p_LPM [08:38:31] [PASSED] 35.03 Xe3p_HPM [08:38:31] ================= [PASSED] check_media_ip ================== [08:38:31] =================== check_platform_desc =================== [08:38:31] [PASSED] 0x9A60 (TIGERLAKE) [08:38:31] [PASSED] 0x9A68 (TIGERLAKE) [08:38:31] [PASSED] 0x9A70 (TIGERLAKE) [08:38:31] [PASSED] 0x9A40 (TIGERLAKE) [08:38:31] [PASSED] 0x9A49 (TIGERLAKE) [08:38:31] [PASSED] 0x9A59 (TIGERLAKE) [08:38:31] [PASSED] 0x9A78 (TIGERLAKE) [08:38:31] [PASSED] 0x9AC0 (TIGERLAKE) [08:38:31] [PASSED] 0x9AC9 (TIGERLAKE) [08:38:31] [PASSED] 0x9AD9 (TIGERLAKE) [08:38:31] [PASSED] 0x9AF8 (TIGERLAKE) [08:38:31] [PASSED] 0x4C80 (ROCKETLAKE) [08:38:31] [PASSED] 0x4C8A (ROCKETLAKE) [08:38:31] [PASSED] 0x4C8B (ROCKETLAKE) [08:38:31] [PASSED] 0x4C8C (ROCKETLAKE) [08:38:31] [PASSED] 0x4C90 (ROCKETLAKE) [08:38:31] [PASSED] 0x4C9A (ROCKETLAKE) [08:38:31] [PASSED] 0x4680 (ALDERLAKE_S) [08:38:31] [PASSED] 0x4682 (ALDERLAKE_S) [08:38:31] [PASSED] 0x4688 (ALDERLAKE_S) [08:38:31] [PASSED] 0x468A (ALDERLAKE_S) [08:38:31] [PASSED] 0x468B (ALDERLAKE_S) [08:38:31] [PASSED] 0x4690 (ALDERLAKE_S) [08:38:31] [PASSED] 0x4692 (ALDERLAKE_S) [08:38:31] [PASSED] 0x4693 (ALDERLAKE_S) [08:38:31] [PASSED] 0x46A0 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46A1 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46A2 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46A3 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46A6 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46A8 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46AA (ALDERLAKE_P) [08:38:31] [PASSED] 0x462A (ALDERLAKE_P) [08:38:31] [PASSED] 0x4626 (ALDERLAKE_P) [08:38:31] [PASSED] 0x4628 (ALDERLAKE_P) stty: 'standard input': Inappropriate ioctl for device [08:38:31] [PASSED] 0x46B0 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46B1 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46B2 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46B3 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46C0 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46C1 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46C2 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46C3 (ALDERLAKE_P) [08:38:31] [PASSED] 0x46D0 (ALDERLAKE_N) [08:38:31] [PASSED] 0x46D1 (ALDERLAKE_N) [08:38:31] [PASSED] 0x46D2 (ALDERLAKE_N) [08:38:31] [PASSED] 0x46D3 (ALDERLAKE_N) [08:38:31] [PASSED] 0x46D4 (ALDERLAKE_N) [08:38:31] [PASSED] 0xA721 (ALDERLAKE_P) [08:38:31] [PASSED] 0xA7A1 (ALDERLAKE_P) [08:38:31] [PASSED] 0xA7A9 (ALDERLAKE_P) [08:38:31] [PASSED] 0xA7AC (ALDERLAKE_P) [08:38:31] [PASSED] 0xA7AD (ALDERLAKE_P) [08:38:31] [PASSED] 0xA720 (ALDERLAKE_P) [08:38:31] [PASSED] 0xA7A0 (ALDERLAKE_P) [08:38:31] [PASSED] 0xA7A8 (ALDERLAKE_P) [08:38:31] [PASSED] 0xA7AA (ALDERLAKE_P) [08:38:31] [PASSED] 0xA7AB (ALDERLAKE_P) [08:38:31] [PASSED] 0xA780 (ALDERLAKE_S) [08:38:31] [PASSED] 0xA781 (ALDERLAKE_S) [08:38:31] [PASSED] 0xA782 (ALDERLAKE_S) [08:38:31] [PASSED] 0xA783 (ALDERLAKE_S) [08:38:31] [PASSED] 0xA788 (ALDERLAKE_S) [08:38:31] [PASSED] 0xA789 (ALDERLAKE_S) [08:38:31] [PASSED] 0xA78A (ALDERLAKE_S) [08:38:31] [PASSED] 0xA78B (ALDERLAKE_S) [08:38:31] [PASSED] 0x4905 (DG1) [08:38:31] [PASSED] 0x4906 (DG1) [08:38:31] [PASSED] 0x4907 (DG1) [08:38:31] [PASSED] 0x4908 (DG1) [08:38:31] [PASSED] 0x4909 (DG1) [08:38:31] [PASSED] 0x56C0 (DG2) [08:38:31] [PASSED] 0x56C2 (DG2) [08:38:31] [PASSED] 0x56C1 (DG2) [08:38:31] [PASSED] 0x7D51 (METEORLAKE) [08:38:31] [PASSED] 0x7DD1 (METEORLAKE) [08:38:31] [PASSED] 0x7D41 (METEORLAKE) [08:38:31] [PASSED] 0x7D67 (METEORLAKE) [08:38:31] [PASSED] 0xB640 (METEORLAKE) [08:38:31] [PASSED] 0x56A0 (DG2) [08:38:31] [PASSED] 0x56A1 (DG2) [08:38:31] [PASSED] 0x56A2 (DG2) [08:38:31] [PASSED] 0x56BE (DG2) [08:38:31] [PASSED] 0x56BF (DG2) [08:38:31] [PASSED] 0x5690 (DG2) [08:38:31] [PASSED] 0x5691 (DG2) [08:38:31] [PASSED] 0x5692 (DG2) [08:38:31] [PASSED] 0x56A5 (DG2) [08:38:31] [PASSED] 0x56A6 (DG2) [08:38:31] [PASSED] 0x56B0 (DG2) [08:38:31] [PASSED] 0x56B1 (DG2) [08:38:31] [PASSED] 0x56BA (DG2) [08:38:31] [PASSED] 0x56BB (DG2) [08:38:31] [PASSED] 0x56BC (DG2) [08:38:31] [PASSED] 0x56BD (DG2) [08:38:31] [PASSED] 0x5693 (DG2) [08:38:31] [PASSED] 0x5694 (DG2) [08:38:31] [PASSED] 0x5695 (DG2) [08:38:31] [PASSED] 0x56A3 (DG2) [08:38:31] [PASSED] 0x56A4 (DG2) [08:38:31] [PASSED] 0x56B2 (DG2) [08:38:31] [PASSED] 0x56B3 (DG2) [08:38:31] [PASSED] 0x5696 (DG2) [08:38:31] [PASSED] 0x5697 (DG2) [08:38:31] [PASSED] 0xB69 (PVC) [08:38:31] [PASSED] 0xB6E (PVC) [08:38:31] [PASSED] 0xBD4 (PVC) [08:38:31] [PASSED] 0xBD5 (PVC) [08:38:31] [PASSED] 0xBD6 (PVC) [08:38:31] [PASSED] 0xBD7 (PVC) [08:38:31] [PASSED] 0xBD8 (PVC) [08:38:31] [PASSED] 0xBD9 (PVC) [08:38:31] [PASSED] 0xBDA (PVC) [08:38:31] [PASSED] 0xBDB (PVC) [08:38:31] [PASSED] 0xBE0 (PVC) [08:38:31] [PASSED] 0xBE1 (PVC) [08:38:31] [PASSED] 0xBE5 (PVC) [08:38:31] [PASSED] 0x7D40 (METEORLAKE) [08:38:31] [PASSED] 0x7D45 (METEORLAKE) [08:38:31] [PASSED] 0x7D55 (METEORLAKE) [08:38:31] [PASSED] 0x7D60 (METEORLAKE) [08:38:31] [PASSED] 0x7DD5 (METEORLAKE) [08:38:31] [PASSED] 0x6420 (LUNARLAKE) [08:38:31] [PASSED] 0x64A0 (LUNARLAKE) [08:38:31] [PASSED] 0x64B0 (LUNARLAKE) [08:38:31] [PASSED] 0xE202 (BATTLEMAGE) [08:38:31] [PASSED] 0xE209 (BATTLEMAGE) [08:38:31] [PASSED] 0xE20B (BATTLEMAGE) [08:38:31] [PASSED] 0xE20C (BATTLEMAGE) [08:38:31] [PASSED] 0xE20D (BATTLEMAGE) [08:38:31] [PASSED] 0xE210 (BATTLEMAGE) [08:38:31] [PASSED] 0xE211 (BATTLEMAGE) [08:38:31] [PASSED] 0xE212 (BATTLEMAGE) [08:38:31] [PASSED] 0xE216 (BATTLEMAGE) [08:38:31] [PASSED] 0xE220 (BATTLEMAGE) [08:38:31] [PASSED] 0xE221 (BATTLEMAGE) [08:38:31] [PASSED] 0xE222 (BATTLEMAGE) [08:38:31] [PASSED] 0xE223 (BATTLEMAGE) [08:38:31] [PASSED] 0xB080 (PANTHERLAKE) [08:38:31] [PASSED] 0xB081 (PANTHERLAKE) [08:38:31] [PASSED] 0xB082 (PANTHERLAKE) [08:38:31] [PASSED] 0xB083 (PANTHERLAKE) [08:38:31] [PASSED] 0xB084 (PANTHERLAKE) [08:38:31] [PASSED] 0xB085 (PANTHERLAKE) [08:38:31] [PASSED] 0xB086 (PANTHERLAKE) [08:38:31] [PASSED] 0xB087 (PANTHERLAKE) [08:38:31] [PASSED] 0xB08F (PANTHERLAKE) [08:38:31] [PASSED] 0xB090 (PANTHERLAKE) [08:38:31] [PASSED] 0xB0A0 (PANTHERLAKE) [08:38:31] [PASSED] 0xB0B0 (PANTHERLAKE) [08:38:31] [PASSED] 0xFD80 (PANTHERLAKE) [08:38:31] [PASSED] 0xFD81 (PANTHERLAKE) [08:38:31] [PASSED] 0xD740 (NOVALAKE_S) [08:38:31] [PASSED] 0xD741 (NOVALAKE_S) [08:38:31] [PASSED] 0xD742 (NOVALAKE_S) [08:38:31] [PASSED] 0xD743 (NOVALAKE_S) [08:38:31] [PASSED] 0xD744 (NOVALAKE_S) [08:38:31] [PASSED] 0xD745 (NOVALAKE_S) [08:38:31] [PASSED] 0x674C (CRESCENTISLAND) [08:38:31] =============== [PASSED] check_platform_desc =============== [08:38:31] ===================== [PASSED] xe_pci ====================== [08:38:31] =================== xe_rtp (2 subtests) ==================== [08:38:31] =============== xe_rtp_process_to_sr_tests ================ [08:38:31] [PASSED] coalesce-same-reg [08:38:31] [PASSED] no-match-no-add [08:38:31] [PASSED] match-or [08:38:31] [PASSED] match-or-xfail [08:38:31] [PASSED] no-match-no-add-multiple-rules [08:38:31] [PASSED] two-regs-two-entries [08:38:31] [PASSED] clr-one-set-other [08:38:31] [PASSED] set-field [08:38:31] [PASSED] conflict-duplicate [08:38:31] [PASSED] conflict-not-disjoint [08:38:31] [PASSED] conflict-reg-type [08:38:31] =========== [PASSED] xe_rtp_process_to_sr_tests ============ [08:38:31] ================== xe_rtp_process_tests =================== [08:38:31] [PASSED] active1 [08:38:31] [PASSED] active2 [08:38:31] [PASSED] active-inactive [08:38:31] [PASSED] inactive-active [08:38:31] [PASSED] inactive-1st_or_active-inactive [08:38:31] [PASSED] inactive-2nd_or_active-inactive [08:38:31] [PASSED] inactive-last_or_active-inactive [08:38:31] [PASSED] inactive-no_or_active-inactive [08:38:31] ============== [PASSED] xe_rtp_process_tests =============== [08:38:31] ===================== [PASSED] xe_rtp ====================== [08:38:31] ==================== xe_wa (1 subtest) ===================== [08:38:31] ======================== xe_wa_gt ========================= [08:38:31] [PASSED] TIGERLAKE B0 [08:38:31] [PASSED] DG1 A0 [08:38:31] [PASSED] DG1 B0 [08:38:31] [PASSED] ALDERLAKE_S A0 [08:38:31] [PASSED] ALDERLAKE_S B0 [08:38:31] [PASSED] ALDERLAKE_S C0 [08:38:31] [PASSED] ALDERLAKE_S D0 [08:38:31] [PASSED] ALDERLAKE_P A0 [08:38:31] [PASSED] ALDERLAKE_P B0 [08:38:31] [PASSED] ALDERLAKE_P C0 [08:38:31] [PASSED] ALDERLAKE_S RPLS D0 [08:38:31] [PASSED] ALDERLAKE_P RPLU E0 [08:38:31] [PASSED] DG2 G10 C0 [08:38:31] [PASSED] DG2 G11 B1 [08:38:31] [PASSED] DG2 G12 A1 [08:38:31] [PASSED] METEORLAKE 12.70(Xe_LPG) A0 13.00(Xe_LPM+) A0 [08:38:31] [PASSED] METEORLAKE 12.71(Xe_LPG) A0 13.00(Xe_LPM+) A0 [08:38:31] [PASSED] METEORLAKE 12.74(Xe_LPG+) A0 13.00(Xe_LPM+) A0 [08:38:31] [PASSED] LUNARLAKE 20.04(Xe2_LPG) A0 20.00(Xe2_LPM) A0 [08:38:31] [PASSED] LUNARLAKE 20.04(Xe2_LPG) B0 20.00(Xe2_LPM) A0 [08:38:31] [PASSED] BATTLEMAGE 20.01(Xe2_HPG) A0 13.01(Xe2_HPM) A1 [08:38:31] [PASSED] PANTHERLAKE 30.00(Xe3_LPG) A0 30.00(Xe3_LPM) A0 [08:38:31] ==================== [PASSED] xe_wa_gt ===================== [08:38:31] ====================== [PASSED] xe_wa ====================== [08:38:31] ============================================================ [08:38:31] Testing complete. Ran 512 tests: passed: 494, skipped: 18 [08:38:31] Elapsed time: 43.275s total, 4.241s configuring, 38.566s building, 0.447s running + /kernel/tools/testing/kunit/kunit.py run --kunitconfig /kernel/drivers/gpu/drm/tests/.kunitconfig [08:38:31] Configuring KUnit Kernel ... Regenerating .config ... Populating config with: $ make ARCH=um O=.kunit olddefconfig [08:38:32] Building KUnit Kernel ... Populating config with: $ make ARCH=um O=.kunit olddefconfig Building with: $ make all compile_commands.json scripts_gdb ARCH=um O=.kunit --jobs=25 [08:39:03] Starting KUnit Kernel (1/1)... [08:39:03] ============================================================ Running tests with: $ .kunit/linux kunit.enable=1 mem=1G console=tty kunit_shutdown=halt [08:39:03] ============ drm_test_pick_cmdline (2 subtests) ============ [08:39:03] [PASSED] drm_test_pick_cmdline_res_1920_1080_60 [08:39:03] =============== drm_test_pick_cmdline_named =============== [08:39:03] [PASSED] NTSC [08:39:03] [PASSED] NTSC-J [08:39:03] [PASSED] PAL [08:39:03] [PASSED] PAL-M [08:39:03] =========== [PASSED] drm_test_pick_cmdline_named =========== [08:39:03] ============== [PASSED] drm_test_pick_cmdline ============== [08:39:03] == drm_test_atomic_get_connector_for_encoder (1 subtest) === [08:39:03] [PASSED] drm_test_drm_atomic_get_connector_for_encoder [08:39:03] ==== [PASSED] drm_test_atomic_get_connector_for_encoder ==== [08:39:03] =========== drm_validate_clone_mode (2 subtests) =========== [08:39:03] ============== drm_test_check_in_clone_mode =============== [08:39:03] [PASSED] in_clone_mode [08:39:03] [PASSED] not_in_clone_mode [08:39:03] ========== [PASSED] drm_test_check_in_clone_mode =========== [08:39:03] =============== drm_test_check_valid_clones =============== [08:39:03] [PASSED] not_in_clone_mode [08:39:03] [PASSED] valid_clone [08:39:03] [PASSED] invalid_clone [08:39:03] =========== [PASSED] drm_test_check_valid_clones =========== [08:39:03] ============= [PASSED] drm_validate_clone_mode ============= [08:39:03] ============= drm_validate_modeset (1 subtest) ============= [08:39:03] [PASSED] drm_test_check_connector_changed_modeset [08:39:03] ============== [PASSED] drm_validate_modeset =============== [08:39:03] ====== drm_test_bridge_get_current_state (2 subtests) ====== [08:39:03] [PASSED] drm_test_drm_bridge_get_current_state_atomic [08:39:03] [PASSED] drm_test_drm_bridge_get_current_state_legacy [08:39:03] ======== [PASSED] drm_test_bridge_get_current_state ======== [08:39:03] ====== drm_test_bridge_helper_reset_crtc (3 subtests) ====== [08:39:03] [PASSED] drm_test_drm_bridge_helper_reset_crtc_atomic [08:39:03] [PASSED] drm_test_drm_bridge_helper_reset_crtc_atomic_disabled [08:39:03] [PASSED] drm_test_drm_bridge_helper_reset_crtc_legacy [08:39:03] ======== [PASSED] drm_test_bridge_helper_reset_crtc ======== [08:39:03] ============== drm_bridge_alloc (2 subtests) =============== [08:39:03] [PASSED] drm_test_drm_bridge_alloc_basic [08:39:03] [PASSED] drm_test_drm_bridge_alloc_get_put [08:39:03] ================ [PASSED] drm_bridge_alloc ================= [08:39:03] ============= drm_cmdline_parser (40 subtests) ============= [08:39:03] [PASSED] drm_test_cmdline_force_d_only [08:39:03] [PASSED] drm_test_cmdline_force_D_only_dvi [08:39:03] [PASSED] drm_test_cmdline_force_D_only_hdmi [08:39:03] [PASSED] drm_test_cmdline_force_D_only_not_digital [08:39:03] [PASSED] drm_test_cmdline_force_e_only [08:39:03] [PASSED] drm_test_cmdline_res [08:39:03] [PASSED] drm_test_cmdline_res_vesa [08:39:03] [PASSED] drm_test_cmdline_res_vesa_rblank [08:39:03] [PASSED] drm_test_cmdline_res_rblank [08:39:03] [PASSED] drm_test_cmdline_res_bpp [08:39:03] [PASSED] drm_test_cmdline_res_refresh [08:39:03] [PASSED] drm_test_cmdline_res_bpp_refresh [08:39:03] [PASSED] drm_test_cmdline_res_bpp_refresh_interlaced [08:39:03] [PASSED] drm_test_cmdline_res_bpp_refresh_margins [08:39:03] [PASSED] drm_test_cmdline_res_bpp_refresh_force_off [08:39:03] [PASSED] drm_test_cmdline_res_bpp_refresh_force_on [08:39:03] [PASSED] drm_test_cmdline_res_bpp_refresh_force_on_analog [08:39:03] [PASSED] drm_test_cmdline_res_bpp_refresh_force_on_digital [08:39:03] [PASSED] drm_test_cmdline_res_bpp_refresh_interlaced_margins_force_on [08:39:03] [PASSED] drm_test_cmdline_res_margins_force_on [08:39:03] [PASSED] drm_test_cmdline_res_vesa_margins [08:39:03] [PASSED] drm_test_cmdline_name [08:39:03] [PASSED] drm_test_cmdline_name_bpp [08:39:03] [PASSED] drm_test_cmdline_name_option [08:39:03] [PASSED] drm_test_cmdline_name_bpp_option [08:39:03] [PASSED] drm_test_cmdline_rotate_0 [08:39:03] [PASSED] drm_test_cmdline_rotate_90 [08:39:03] [PASSED] drm_test_cmdline_rotate_180 [08:39:03] [PASSED] drm_test_cmdline_rotate_270 [08:39:03] [PASSED] drm_test_cmdline_hmirror [08:39:03] [PASSED] drm_test_cmdline_vmirror [08:39:03] [PASSED] drm_test_cmdline_margin_options [08:39:03] [PASSED] drm_test_cmdline_multiple_options [08:39:03] [PASSED] drm_test_cmdline_bpp_extra_and_option [08:39:03] [PASSED] drm_test_cmdline_extra_and_option [08:39:03] [PASSED] drm_test_cmdline_freestanding_options [08:39:03] [PASSED] drm_test_cmdline_freestanding_force_e_and_options [08:39:03] [PASSED] drm_test_cmdline_panel_orientation [08:39:03] ================ drm_test_cmdline_invalid ================= [08:39:03] [PASSED] margin_only [08:39:03] [PASSED] interlace_only [08:39:03] [PASSED] res_missing_x [08:39:03] [PASSED] res_missing_y [08:39:03] [PASSED] res_bad_y [08:39:03] [PASSED] res_missing_y_bpp [08:39:03] [PASSED] res_bad_bpp [08:39:03] [PASSED] res_bad_refresh [08:39:03] [PASSED] res_bpp_refresh_force_on_off [08:39:03] [PASSED] res_invalid_mode [08:39:03] [PASSED] res_bpp_wrong_place_mode [08:39:03] [PASSED] name_bpp_refresh [08:39:03] [PASSED] name_refresh [08:39:03] [PASSED] name_refresh_wrong_mode [08:39:03] [PASSED] name_refresh_invalid_mode [08:39:03] [PASSED] rotate_multiple [08:39:03] [PASSED] rotate_invalid_val [08:39:03] [PASSED] rotate_truncated [08:39:03] [PASSED] invalid_option [08:39:03] [PASSED] invalid_tv_option [08:39:03] [PASSED] truncated_tv_option [08:39:03] ============ [PASSED] drm_test_cmdline_invalid ============= [08:39:03] =============== drm_test_cmdline_tv_options =============== [08:39:03] [PASSED] NTSC [08:39:03] [PASSED] NTSC_443 [08:39:03] [PASSED] NTSC_J [08:39:03] [PASSED] PAL [08:39:03] [PASSED] PAL_M [08:39:03] [PASSED] PAL_N [08:39:03] [PASSED] SECAM [08:39:03] [PASSED] MONO_525 [08:39:03] [PASSED] MONO_625 [08:39:03] =========== [PASSED] drm_test_cmdline_tv_options =========== [08:39:03] =============== [PASSED] drm_cmdline_parser ================ [08:39:03] ========== drmm_connector_hdmi_init (20 subtests) ========== [08:39:03] [PASSED] drm_test_connector_hdmi_init_valid [08:39:03] [PASSED] drm_test_connector_hdmi_init_bpc_8 [08:39:03] [PASSED] drm_test_connector_hdmi_init_bpc_10 [08:39:03] [PASSED] drm_test_connector_hdmi_init_bpc_12 [08:39:03] [PASSED] drm_test_connector_hdmi_init_bpc_invalid [08:39:03] [PASSED] drm_test_connector_hdmi_init_bpc_null [08:39:03] [PASSED] drm_test_connector_hdmi_init_formats_empty [08:39:03] [PASSED] drm_test_connector_hdmi_init_formats_no_rgb [08:39:03] === drm_test_connector_hdmi_init_formats_yuv420_allowed === [08:39:03] [PASSED] supported_formats=0x9 yuv420_allowed=1 [08:39:03] [PASSED] supported_formats=0x9 yuv420_allowed=0 [08:39:03] [PASSED] supported_formats=0x3 yuv420_allowed=1 [08:39:03] [PASSED] supported_formats=0x3 yuv420_allowed=0 [08:39:03] === [PASSED] drm_test_connector_hdmi_init_formats_yuv420_allowed === [08:39:03] [PASSED] drm_test_connector_hdmi_init_null_ddc [08:39:03] [PASSED] drm_test_connector_hdmi_init_null_product [08:39:03] [PASSED] drm_test_connector_hdmi_init_null_vendor [08:39:03] [PASSED] drm_test_connector_hdmi_init_product_length_exact [08:39:03] [PASSED] drm_test_connector_hdmi_init_product_length_too_long [08:39:03] [PASSED] drm_test_connector_hdmi_init_product_valid [08:39:03] [PASSED] drm_test_connector_hdmi_init_vendor_length_exact [08:39:03] [PASSED] drm_test_connector_hdmi_init_vendor_length_too_long [08:39:03] [PASSED] drm_test_connector_hdmi_init_vendor_valid [08:39:03] ========= drm_test_connector_hdmi_init_type_valid ========= [08:39:03] [PASSED] HDMI-A [08:39:03] [PASSED] HDMI-B [08:39:03] ===== [PASSED] drm_test_connector_hdmi_init_type_valid ===== [08:39:03] ======== drm_test_connector_hdmi_init_type_invalid ======== [08:39:03] [PASSED] Unknown [08:39:03] [PASSED] VGA [08:39:03] [PASSED] DVI-I [08:39:03] [PASSED] DVI-D [08:39:03] [PASSED] DVI-A [08:39:03] [PASSED] Composite [08:39:03] [PASSED] SVIDEO [08:39:03] [PASSED] LVDS [08:39:03] [PASSED] Component [08:39:03] [PASSED] DIN [08:39:03] [PASSED] DP [08:39:03] [PASSED] TV [08:39:03] [PASSED] eDP [08:39:03] [PASSED] Virtual [08:39:03] [PASSED] DSI [08:39:03] [PASSED] DPI [08:39:03] [PASSED] Writeback [08:39:03] [PASSED] SPI [08:39:03] [PASSED] USB [08:39:03] ==== [PASSED] drm_test_connector_hdmi_init_type_invalid ==== [08:39:03] ============ [PASSED] drmm_connector_hdmi_init ============= [08:39:03] ============= drmm_connector_init (3 subtests) ============= [08:39:03] [PASSED] drm_test_drmm_connector_init [08:39:03] [PASSED] drm_test_drmm_connector_init_null_ddc [08:39:03] ========= drm_test_drmm_connector_init_type_valid ========= [08:39:03] [PASSED] Unknown [08:39:03] [PASSED] VGA [08:39:03] [PASSED] DVI-I [08:39:03] [PASSED] DVI-D [08:39:03] [PASSED] DVI-A [08:39:03] [PASSED] Composite [08:39:03] [PASSED] SVIDEO [08:39:03] [PASSED] LVDS [08:39:03] [PASSED] Component [08:39:03] [PASSED] DIN [08:39:03] [PASSED] DP [08:39:03] [PASSED] HDMI-A [08:39:03] [PASSED] HDMI-B [08:39:03] [PASSED] TV [08:39:03] [PASSED] eDP [08:39:03] [PASSED] Virtual [08:39:03] [PASSED] DSI [08:39:03] [PASSED] DPI [08:39:03] [PASSED] Writeback [08:39:03] [PASSED] SPI [08:39:03] [PASSED] USB [08:39:03] ===== [PASSED] drm_test_drmm_connector_init_type_valid ===== [08:39:03] =============== [PASSED] drmm_connector_init =============== [08:39:03] ========= drm_connector_dynamic_init (6 subtests) ========== [08:39:03] [PASSED] drm_test_drm_connector_dynamic_init [08:39:03] [PASSED] drm_test_drm_connector_dynamic_init_null_ddc [08:39:03] [PASSED] drm_test_drm_connector_dynamic_init_not_added [08:39:03] [PASSED] drm_test_drm_connector_dynamic_init_properties [08:39:03] ===== drm_test_drm_connector_dynamic_init_type_valid ====== [08:39:03] [PASSED] Unknown [08:39:03] [PASSED] VGA [08:39:03] [PASSED] DVI-I [08:39:03] [PASSED] DVI-D [08:39:03] [PASSED] DVI-A [08:39:03] [PASSED] Composite [08:39:03] [PASSED] SVIDEO [08:39:03] [PASSED] LVDS [08:39:03] [PASSED] Component [08:39:03] [PASSED] DIN [08:39:03] [PASSED] DP [08:39:03] [PASSED] HDMI-A [08:39:03] [PASSED] HDMI-B [08:39:03] [PASSED] TV [08:39:03] [PASSED] eDP [08:39:03] [PASSED] Virtual [08:39:03] [PASSED] DSI [08:39:03] [PASSED] DPI [08:39:03] [PASSED] Writeback [08:39:03] [PASSED] SPI [08:39:03] [PASSED] USB [08:39:03] = [PASSED] drm_test_drm_connector_dynamic_init_type_valid == [08:39:03] ======== drm_test_drm_connector_dynamic_init_name ========= [08:39:03] [PASSED] Unknown [08:39:03] [PASSED] VGA [08:39:03] [PASSED] DVI-I [08:39:03] [PASSED] DVI-D [08:39:03] [PASSED] DVI-A [08:39:03] [PASSED] Composite [08:39:03] [PASSED] SVIDEO [08:39:03] [PASSED] LVDS [08:39:03] [PASSED] Component [08:39:03] [PASSED] DIN [08:39:03] [PASSED] DP [08:39:03] [PASSED] HDMI-A [08:39:03] [PASSED] HDMI-B [08:39:03] [PASSED] TV [08:39:03] [PASSED] eDP [08:39:03] [PASSED] Virtual [08:39:03] [PASSED] DSI [08:39:03] [PASSED] DPI [08:39:03] [PASSED] Writeback [08:39:03] [PASSED] SPI [08:39:03] [PASSED] USB [08:39:03] ==== [PASSED] drm_test_drm_connector_dynamic_init_name ===== [08:39:03] =========== [PASSED] drm_connector_dynamic_init ============ [08:39:03] ==== drm_connector_dynamic_register_early (4 subtests) ===== [08:39:03] [PASSED] drm_test_drm_connector_dynamic_register_early_on_list [08:39:03] [PASSED] drm_test_drm_connector_dynamic_register_early_defer [08:39:03] [PASSED] drm_test_drm_connector_dynamic_register_early_no_init [08:39:03] [PASSED] drm_test_drm_connector_dynamic_register_early_no_mode_object [08:39:03] ====== [PASSED] drm_connector_dynamic_register_early ======= [08:39:03] ======= drm_connector_dynamic_register (7 subtests) ======== [08:39:03] [PASSED] drm_test_drm_connector_dynamic_register_on_list [08:39:03] [PASSED] drm_test_drm_connector_dynamic_register_no_defer [08:39:03] [PASSED] drm_test_drm_connector_dynamic_register_no_init [08:39:03] [PASSED] drm_test_drm_connector_dynamic_register_mode_object [08:39:03] [PASSED] drm_test_drm_connector_dynamic_register_sysfs [08:39:03] [PASSED] drm_test_drm_connector_dynamic_register_sysfs_name [08:39:03] [PASSED] drm_test_drm_connector_dynamic_register_debugfs [08:39:03] ========= [PASSED] drm_connector_dynamic_register ========== [08:39:03] = drm_connector_attach_broadcast_rgb_property (2 subtests) = [08:39:03] [PASSED] drm_test_drm_connector_attach_broadcast_rgb_property [08:39:03] [PASSED] drm_test_drm_connector_attach_broadcast_rgb_property_hdmi_connector [08:39:03] === [PASSED] drm_connector_attach_broadcast_rgb_property === [08:39:03] ========== drm_get_tv_mode_from_name (2 subtests) ========== [08:39:03] ========== drm_test_get_tv_mode_from_name_valid =========== [08:39:03] [PASSED] NTSC [08:39:03] [PASSED] NTSC-443 [08:39:03] [PASSED] NTSC-J [08:39:03] [PASSED] PAL [08:39:03] [PASSED] PAL-M [08:39:03] [PASSED] PAL-N [08:39:03] [PASSED] SECAM [08:39:03] [PASSED] Mono [08:39:03] ====== [PASSED] drm_test_get_tv_mode_from_name_valid ======= [08:39:03] [PASSED] drm_test_get_tv_mode_from_name_truncated [08:39:03] ============ [PASSED] drm_get_tv_mode_from_name ============ [08:39:03] = drm_test_connector_hdmi_compute_mode_clock (12 subtests) = [08:39:03] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb [08:39:03] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb_10bpc [08:39:03] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb_10bpc_vic_1 [08:39:03] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb_12bpc [08:39:03] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb_12bpc_vic_1 [08:39:03] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb_double [08:39:03] = drm_test_connector_hdmi_compute_mode_clock_yuv420_valid = [08:39:03] [PASSED] VIC 96 [08:39:03] [PASSED] VIC 97 [08:39:03] [PASSED] VIC 101 [08:39:03] [PASSED] VIC 102 [08:39:03] [PASSED] VIC 106 [08:39:03] [PASSED] VIC 107 [08:39:03] === [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv420_valid === [08:39:03] [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv420_10_bpc [08:39:03] [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv420_12_bpc [08:39:03] [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv422_8_bpc [08:39:03] [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv422_10_bpc [08:39:03] [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv422_12_bpc [08:39:03] === [PASSED] drm_test_connector_hdmi_compute_mode_clock ==== [08:39:03] == drm_hdmi_connector_get_broadcast_rgb_name (2 subtests) == [08:39:03] === drm_test_drm_hdmi_connector_get_broadcast_rgb_name ==== [08:39:03] [PASSED] Automatic [08:39:03] [PASSED] Full [08:39:03] [PASSED] Limited 16:235 [08:39:03] === [PASSED] drm_test_drm_hdmi_connector_get_broadcast_rgb_name === [08:39:03] [PASSED] drm_test_drm_hdmi_connector_get_broadcast_rgb_name_invalid [08:39:03] ==== [PASSED] drm_hdmi_connector_get_broadcast_rgb_name ==== [08:39:03] == drm_hdmi_connector_get_output_format_name (2 subtests) == [08:39:03] === drm_test_drm_hdmi_connector_get_output_format_name ==== [08:39:03] [PASSED] RGB [08:39:03] [PASSED] YUV 4:2:0 [08:39:03] [PASSED] YUV 4:2:2 [08:39:03] [PASSED] YUV 4:4:4 [08:39:03] === [PASSED] drm_test_drm_hdmi_connector_get_output_format_name === [08:39:03] [PASSED] drm_test_drm_hdmi_connector_get_output_format_name_invalid [08:39:03] ==== [PASSED] drm_hdmi_connector_get_output_format_name ==== [08:39:03] ============= drm_damage_helper (21 subtests) ============== [08:39:03] [PASSED] drm_test_damage_iter_no_damage [08:39:03] [PASSED] drm_test_damage_iter_no_damage_fractional_src [08:39:03] [PASSED] drm_test_damage_iter_no_damage_src_moved [08:39:03] [PASSED] drm_test_damage_iter_no_damage_fractional_src_moved [08:39:03] [PASSED] drm_test_damage_iter_no_damage_not_visible [08:39:03] [PASSED] drm_test_damage_iter_no_damage_no_crtc [08:39:03] [PASSED] drm_test_damage_iter_no_damage_no_fb [08:39:03] [PASSED] drm_test_damage_iter_simple_damage [08:39:03] [PASSED] drm_test_damage_iter_single_damage [08:39:03] [PASSED] drm_test_damage_iter_single_damage_intersect_src [08:39:03] [PASSED] drm_test_damage_iter_single_damage_outside_src [08:39:03] [PASSED] drm_test_damage_iter_single_damage_fractional_src [08:39:03] [PASSED] drm_test_damage_iter_single_damage_intersect_fractional_src [08:39:03] [PASSED] drm_test_damage_iter_single_damage_outside_fractional_src [08:39:03] [PASSED] drm_test_damage_iter_single_damage_src_moved [08:39:03] [PASSED] drm_test_damage_iter_single_damage_fractional_src_moved [08:39:03] [PASSED] drm_test_damage_iter_damage [08:39:03] [PASSED] drm_test_damage_iter_damage_one_intersect [08:39:03] [PASSED] drm_test_damage_iter_damage_one_outside [08:39:03] [PASSED] drm_test_damage_iter_damage_src_moved [08:39:03] [PASSED] drm_test_damage_iter_damage_not_visible [08:39:03] ================ [PASSED] drm_damage_helper ================ [08:39:03] ============== drm_dp_mst_helper (3 subtests) ============== [08:39:03] ============== drm_test_dp_mst_calc_pbn_mode ============== [08:39:03] [PASSED] Clock 154000 BPP 30 DSC disabled [08:39:03] [PASSED] Clock 234000 BPP 30 DSC disabled [08:39:03] [PASSED] Clock 297000 BPP 24 DSC disabled [08:39:03] [PASSED] Clock 332880 BPP 24 DSC enabled [08:39:03] [PASSED] Clock 324540 BPP 24 DSC enabled [08:39:03] ========== [PASSED] drm_test_dp_mst_calc_pbn_mode ========== [08:39:03] ============== drm_test_dp_mst_calc_pbn_div =============== [08:39:03] [PASSED] Link rate 2000000 lane count 4 [08:39:03] [PASSED] Link rate 2000000 lane count 2 [08:39:03] [PASSED] Link rate 2000000 lane count 1 [08:39:03] [PASSED] Link rate 1350000 lane count 4 [08:39:03] [PASSED] Link rate 1350000 lane count 2 [08:39:03] [PASSED] Link rate 1350000 lane count 1 [08:39:03] [PASSED] Link rate 1000000 lane count 4 [08:39:03] [PASSED] Link rate 1000000 lane count 2 [08:39:03] [PASSED] Link rate 1000000 lane count 1 [08:39:03] [PASSED] Link rate 810000 lane count 4 [08:39:03] [PASSED] Link rate 810000 lane count 2 [08:39:03] [PASSED] Link rate 810000 lane count 1 [08:39:03] [PASSED] Link rate 540000 lane count 4 [08:39:03] [PASSED] Link rate 540000 lane count 2 [08:39:03] [PASSED] Link rate 540000 lane count 1 [08:39:03] [PASSED] Link rate 270000 lane count 4 [08:39:03] [PASSED] Link rate 270000 lane count 2 [08:39:03] [PASSED] Link rate 270000 lane count 1 [08:39:03] [PASSED] Link rate 162000 lane count 4 [08:39:03] [PASSED] Link rate 162000 lane count 2 [08:39:03] [PASSED] Link rate 162000 lane count 1 [08:39:03] ========== [PASSED] drm_test_dp_mst_calc_pbn_div =========== [08:39:03] ========= drm_test_dp_mst_sideband_msg_req_decode ========= [08:39:03] [PASSED] DP_ENUM_PATH_RESOURCES with port number [08:39:03] [PASSED] DP_POWER_UP_PHY with port number [08:39:03] [PASSED] DP_POWER_DOWN_PHY with port number [08:39:03] [PASSED] DP_ALLOCATE_PAYLOAD with SDP stream sinks [08:39:03] [PASSED] DP_ALLOCATE_PAYLOAD with port number [08:39:03] [PASSED] DP_ALLOCATE_PAYLOAD with VCPI [08:39:03] [PASSED] DP_ALLOCATE_PAYLOAD with PBN [08:39:03] [PASSED] DP_QUERY_PAYLOAD with port number [08:39:03] [PASSED] DP_QUERY_PAYLOAD with VCPI [08:39:03] [PASSED] DP_REMOTE_DPCD_READ with port number [08:39:03] [PASSED] DP_REMOTE_DPCD_READ with DPCD address [08:39:03] [PASSED] DP_REMOTE_DPCD_READ with max number of bytes [08:39:03] [PASSED] DP_REMOTE_DPCD_WRITE with port number [08:39:03] [PASSED] DP_REMOTE_DPCD_WRITE with DPCD address [08:39:03] [PASSED] DP_REMOTE_DPCD_WRITE with data array [08:39:03] [PASSED] DP_REMOTE_I2C_READ with port number [08:39:03] [PASSED] DP_REMOTE_I2C_READ with I2C device ID [08:39:03] [PASSED] DP_REMOTE_I2C_READ with transactions array [08:39:03] [PASSED] DP_REMOTE_I2C_WRITE with port number [08:39:03] [PASSED] DP_REMOTE_I2C_WRITE with I2C device ID [08:39:03] [PASSED] DP_REMOTE_I2C_WRITE with data array [08:39:03] [PASSED] DP_QUERY_STREAM_ENC_STATUS with stream ID [08:39:03] [PASSED] DP_QUERY_STREAM_ENC_STATUS with client ID [08:39:03] [PASSED] DP_QUERY_STREAM_ENC_STATUS with stream event [08:39:03] [PASSED] DP_QUERY_STREAM_ENC_STATUS with valid stream event [08:39:03] [PASSED] DP_QUERY_STREAM_ENC_STATUS with stream behavior [08:39:03] [PASSED] DP_QUERY_STREAM_ENC_STATUS with a valid stream behavior [08:39:03] ===== [PASSED] drm_test_dp_mst_sideband_msg_req_decode ===== [08:39:03] ================ [PASSED] drm_dp_mst_helper ================ [08:39:03] ================== drm_exec (7 subtests) =================== [08:39:03] [PASSED] sanitycheck [08:39:03] [PASSED] test_lock [08:39:03] [PASSED] test_lock_unlock [08:39:03] [PASSED] test_duplicates [08:39:03] [PASSED] test_prepare [08:39:03] [PASSED] test_prepare_array [08:39:03] [PASSED] test_multiple_loops [08:39:03] ==================== [PASSED] drm_exec ===================== [08:39:03] =========== drm_format_helper_test (17 subtests) =========== [08:39:03] ============== drm_test_fb_xrgb8888_to_gray8 ============== [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ========== [PASSED] drm_test_fb_xrgb8888_to_gray8 ========== [08:39:03] ============= drm_test_fb_xrgb8888_to_rgb332 ============== [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ========= [PASSED] drm_test_fb_xrgb8888_to_rgb332 ========== [08:39:03] ============= drm_test_fb_xrgb8888_to_rgb565 ============== [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ========= [PASSED] drm_test_fb_xrgb8888_to_rgb565 ========== [08:39:03] ============ drm_test_fb_xrgb8888_to_xrgb1555 ============= [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ======== [PASSED] drm_test_fb_xrgb8888_to_xrgb1555 ========= [08:39:03] ============ drm_test_fb_xrgb8888_to_argb1555 ============= [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ======== [PASSED] drm_test_fb_xrgb8888_to_argb1555 ========= [08:39:03] ============ drm_test_fb_xrgb8888_to_rgba5551 ============= [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ======== [PASSED] drm_test_fb_xrgb8888_to_rgba5551 ========= [08:39:03] ============= drm_test_fb_xrgb8888_to_rgb888 ============== [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ========= [PASSED] drm_test_fb_xrgb8888_to_rgb888 ========== [08:39:03] ============= drm_test_fb_xrgb8888_to_bgr888 ============== [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ========= [PASSED] drm_test_fb_xrgb8888_to_bgr888 ========== [08:39:03] ============ drm_test_fb_xrgb8888_to_argb8888 ============= [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ======== [PASSED] drm_test_fb_xrgb8888_to_argb8888 ========= [08:39:03] =========== drm_test_fb_xrgb8888_to_xrgb2101010 =========== [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ======= [PASSED] drm_test_fb_xrgb8888_to_xrgb2101010 ======= [08:39:03] =========== drm_test_fb_xrgb8888_to_argb2101010 =========== [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ======= [PASSED] drm_test_fb_xrgb8888_to_argb2101010 ======= [08:39:03] ============== drm_test_fb_xrgb8888_to_mono =============== [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ========== [PASSED] drm_test_fb_xrgb8888_to_mono =========== [08:39:03] ==================== drm_test_fb_swab ===================== [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ================ [PASSED] drm_test_fb_swab ================= [08:39:03] ============ drm_test_fb_xrgb8888_to_xbgr8888 ============= [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ======== [PASSED] drm_test_fb_xrgb8888_to_xbgr8888 ========= [08:39:03] ============ drm_test_fb_xrgb8888_to_abgr8888 ============= [08:39:03] [PASSED] single_pixel_source_buffer [08:39:03] [PASSED] single_pixel_clip_rectangle [08:39:03] [PASSED] well_known_colors [08:39:03] [PASSED] destination_pitch [08:39:03] ======== [PASSED] drm_test_fb_xrgb8888_to_abgr8888 ========= [08:39:03] ================= drm_test_fb_clip_offset ================= [08:39:03] [PASSED] pass through [08:39:03] [PASSED] horizontal offset [08:39:03] [PASSED] vertical offset [08:39:03] [PASSED] horizontal and vertical offset [08:39:03] [PASSED] horizontal offset (custom pitch) [08:39:03] [PASSED] vertical offset (custom pitch) [08:39:03] [PASSED] horizontal and vertical offset (custom pitch) [08:39:03] ============= [PASSED] drm_test_fb_clip_offset ============= [08:39:03] =================== drm_test_fb_memcpy ==================== [08:39:03] [PASSED] single_pixel_source_buffer: XR24 little-endian (0x34325258) [08:39:03] [PASSED] single_pixel_source_buffer: XRA8 little-endian (0x38415258) [08:39:03] [PASSED] single_pixel_source_buffer: YU24 little-endian (0x34325559) [08:39:03] [PASSED] single_pixel_clip_rectangle: XB24 little-endian (0x34324258) [08:39:03] [PASSED] single_pixel_clip_rectangle: XRA8 little-endian (0x38415258) [08:39:03] [PASSED] single_pixel_clip_rectangle: YU24 little-endian (0x34325559) [08:39:03] [PASSED] well_known_colors: XB24 little-endian (0x34324258) [08:39:03] [PASSED] well_known_colors: XRA8 little-endian (0x38415258) [08:39:03] [PASSED] well_known_colors: YU24 little-endian (0x34325559) [08:39:03] [PASSED] destination_pitch: XB24 little-endian (0x34324258) [08:39:03] [PASSED] destination_pitch: XRA8 little-endian (0x38415258) [08:39:03] [PASSED] destination_pitch: YU24 little-endian (0x34325559) [08:39:03] =============== [PASSED] drm_test_fb_memcpy ================ [08:39:03] ============= [PASSED] drm_format_helper_test ============== [08:39:03] ================= drm_format (18 subtests) ================= [08:39:03] [PASSED] drm_test_format_block_width_invalid [08:39:03] [PASSED] drm_test_format_block_width_one_plane [08:39:03] [PASSED] drm_test_format_block_width_two_plane [08:39:03] [PASSED] drm_test_format_block_width_three_plane [08:39:03] [PASSED] drm_test_format_block_width_tiled [08:39:03] [PASSED] drm_test_format_block_height_invalid [08:39:03] [PASSED] drm_test_format_block_height_one_plane [08:39:03] [PASSED] drm_test_format_block_height_two_plane [08:39:03] [PASSED] drm_test_format_block_height_three_plane [08:39:03] [PASSED] drm_test_format_block_height_tiled [08:39:03] [PASSED] drm_test_format_min_pitch_invalid [08:39:03] [PASSED] drm_test_format_min_pitch_one_plane_8bpp [08:39:03] [PASSED] drm_test_format_min_pitch_one_plane_16bpp [08:39:03] [PASSED] drm_test_format_min_pitch_one_plane_24bpp [08:39:03] [PASSED] drm_test_format_min_pitch_one_plane_32bpp [08:39:03] [PASSED] drm_test_format_min_pitch_two_plane [08:39:03] [PASSED] drm_test_format_min_pitch_three_plane_8bpp [08:39:03] [PASSED] drm_test_format_min_pitch_tiled [08:39:03] =================== [PASSED] drm_format ==================== [08:39:03] ============== drm_framebuffer (10 subtests) =============== [08:39:03] ========== drm_test_framebuffer_check_src_coords ========== [08:39:03] [PASSED] Success: source fits into fb [08:39:03] [PASSED] Fail: overflowing fb with x-axis coordinate [08:39:03] [PASSED] Fail: overflowing fb with y-axis coordinate [08:39:03] [PASSED] Fail: overflowing fb with source width [08:39:03] [PASSED] Fail: overflowing fb with source height [08:39:03] ====== [PASSED] drm_test_framebuffer_check_src_coords ====== [08:39:03] [PASSED] drm_test_framebuffer_cleanup [08:39:03] =============== drm_test_framebuffer_create =============== [08:39:03] [PASSED] ABGR8888 normal sizes [08:39:03] [PASSED] ABGR8888 max sizes [08:39:03] [PASSED] ABGR8888 pitch greater than min required [08:39:03] [PASSED] ABGR8888 pitch less than min required [08:39:03] [PASSED] ABGR8888 Invalid width [08:39:03] [PASSED] ABGR8888 Invalid buffer handle [08:39:03] [PASSED] No pixel format [08:39:03] [PASSED] ABGR8888 Width 0 [08:39:03] [PASSED] ABGR8888 Height 0 [08:39:03] [PASSED] ABGR8888 Out of bound height * pitch combination [08:39:03] [PASSED] ABGR8888 Large buffer offset [08:39:03] [PASSED] ABGR8888 Buffer offset for inexistent plane [08:39:03] [PASSED] ABGR8888 Invalid flag [08:39:03] [PASSED] ABGR8888 Set DRM_MODE_FB_MODIFIERS without modifiers [08:39:03] [PASSED] ABGR8888 Valid buffer modifier [08:39:03] [PASSED] ABGR8888 Invalid buffer modifier(DRM_FORMAT_MOD_SAMSUNG_64_32_TILE) [08:39:03] [PASSED] ABGR8888 Extra pitches without DRM_MODE_FB_MODIFIERS [08:39:03] [PASSED] ABGR8888 Extra pitches with DRM_MODE_FB_MODIFIERS [08:39:03] [PASSED] NV12 Normal sizes [08:39:03] [PASSED] NV12 Max sizes [08:39:03] [PASSED] NV12 Invalid pitch [08:39:03] [PASSED] NV12 Invalid modifier/missing DRM_MODE_FB_MODIFIERS flag [08:39:03] [PASSED] NV12 different modifier per-plane [08:39:03] [PASSED] NV12 with DRM_FORMAT_MOD_SAMSUNG_64_32_TILE [08:39:03] [PASSED] NV12 Valid modifiers without DRM_MODE_FB_MODIFIERS [08:39:03] [PASSED] NV12 Modifier for inexistent plane [08:39:03] [PASSED] NV12 Handle for inexistent plane [08:39:03] [PASSED] NV12 Handle for inexistent plane without DRM_MODE_FB_MODIFIERS [08:39:03] [PASSED] YVU420 DRM_MODE_FB_MODIFIERS set without modifier [08:39:03] [PASSED] YVU420 Normal sizes [08:39:03] [PASSED] YVU420 Max sizes [08:39:03] [PASSED] YVU420 Invalid pitch [08:39:03] [PASSED] YVU420 Different pitches [08:39:03] [PASSED] YVU420 Different buffer offsets/pitches [08:39:03] [PASSED] YVU420 Modifier set just for plane 0, without DRM_MODE_FB_MODIFIERS [08:39:03] [PASSED] YVU420 Modifier set just for planes 0, 1, without DRM_MODE_FB_MODIFIERS [08:39:03] [PASSED] YVU420 Modifier set just for plane 0, 1, with DRM_MODE_FB_MODIFIERS [08:39:03] [PASSED] YVU420 Valid modifier [08:39:03] [PASSED] YVU420 Different modifiers per plane [08:39:03] [PASSED] YVU420 Modifier for inexistent plane [08:39:03] [PASSED] YUV420_10BIT Invalid modifier(DRM_FORMAT_MOD_LINEAR) [08:39:03] [PASSED] X0L2 Normal sizes [08:39:03] [PASSED] X0L2 Max sizes [08:39:03] [PASSED] X0L2 Invalid pitch [08:39:03] [PASSED] X0L2 Pitch greater than minimum required [08:39:03] [PASSED] X0L2 Handle for inexistent plane [08:39:03] [PASSED] X0L2 Offset for inexistent plane, without DRM_MODE_FB_MODIFIERS set [08:39:03] [PASSED] X0L2 Modifier without DRM_MODE_FB_MODIFIERS set [08:39:03] [PASSED] X0L2 Valid modifier [08:39:03] [PASSED] X0L2 Modifier for inexistent plane [08:39:03] =========== [PASSED] drm_test_framebuffer_create =========== [08:39:03] [PASSED] drm_test_framebuffer_free [08:39:03] [PASSED] drm_test_framebuffer_init [08:39:03] [PASSED] drm_test_framebuffer_init_bad_format [08:39:03] [PASSED] drm_test_framebuffer_init_dev_mismatch [08:39:03] [PASSED] drm_test_framebuffer_lookup [08:39:03] [PASSED] drm_test_framebuffer_lookup_inexistent [08:39:03] [PASSED] drm_test_framebuffer_modifiers_not_supported [08:39:03] ================= [PASSED] drm_framebuffer ================= [08:39:03] ================ drm_gem_shmem (8 subtests) ================ [08:39:03] [PASSED] drm_gem_shmem_test_obj_create [08:39:03] [PASSED] drm_gem_shmem_test_obj_create_private [08:39:03] [PASSED] drm_gem_shmem_test_pin_pages [08:39:03] [PASSED] drm_gem_shmem_test_vmap [08:39:03] [PASSED] drm_gem_shmem_test_get_sg_table [08:39:03] [PASSED] drm_gem_shmem_test_get_pages_sgt [08:39:03] [PASSED] drm_gem_shmem_test_madvise [08:39:03] [PASSED] drm_gem_shmem_test_purge [08:39:03] ================== [PASSED] drm_gem_shmem ================== [08:39:03] === drm_atomic_helper_connector_hdmi_check (27 subtests) === [08:39:03] [PASSED] drm_test_check_broadcast_rgb_auto_cea_mode [08:39:03] [PASSED] drm_test_check_broadcast_rgb_auto_cea_mode_vic_1 [08:39:03] [PASSED] drm_test_check_broadcast_rgb_full_cea_mode [08:39:03] [PASSED] drm_test_check_broadcast_rgb_full_cea_mode_vic_1 [08:39:03] [PASSED] drm_test_check_broadcast_rgb_limited_cea_mode [08:39:03] [PASSED] drm_test_check_broadcast_rgb_limited_cea_mode_vic_1 [08:39:03] ====== drm_test_check_broadcast_rgb_cea_mode_yuv420 ======= [08:39:03] [PASSED] Automatic [08:39:03] [PASSED] Full [08:39:03] [PASSED] Limited 16:235 [08:39:03] == [PASSED] drm_test_check_broadcast_rgb_cea_mode_yuv420 === [08:39:03] [PASSED] drm_test_check_broadcast_rgb_crtc_mode_changed [08:39:03] [PASSED] drm_test_check_broadcast_rgb_crtc_mode_not_changed [08:39:03] [PASSED] drm_test_check_disable_connector [08:39:03] [PASSED] drm_test_check_hdmi_funcs_reject_rate [08:39:03] [PASSED] drm_test_check_max_tmds_rate_bpc_fallback_rgb [08:39:03] [PASSED] drm_test_check_max_tmds_rate_bpc_fallback_yuv420 [08:39:03] [PASSED] drm_test_check_max_tmds_rate_bpc_fallback_ignore_yuv422 [08:39:03] [PASSED] drm_test_check_max_tmds_rate_bpc_fallback_ignore_yuv420 [08:39:03] [PASSED] drm_test_check_driver_unsupported_fallback_yuv420 [08:39:03] [PASSED] drm_test_check_output_bpc_crtc_mode_changed [08:39:03] [PASSED] drm_test_check_output_bpc_crtc_mode_not_changed [08:39:03] [PASSED] drm_test_check_output_bpc_dvi [08:39:03] [PASSED] drm_test_check_output_bpc_format_vic_1 [08:39:03] [PASSED] drm_test_check_output_bpc_format_display_8bpc_only [08:39:03] [PASSED] drm_test_check_output_bpc_format_display_rgb_only [08:39:03] [PASSED] drm_test_check_output_bpc_format_driver_8bpc_only [08:39:03] [PASSED] drm_test_check_output_bpc_format_driver_rgb_only [08:39:03] [PASSED] drm_test_check_tmds_char_rate_rgb_8bpc [08:39:03] [PASSED] drm_test_check_tmds_char_rate_rgb_10bpc [08:39:03] [PASSED] drm_test_check_tmds_char_rate_rgb_12bpc [08:39:03] ===== [PASSED] drm_atomic_helper_connector_hdmi_check ====== [08:39:03] === drm_atomic_helper_connector_hdmi_reset (6 subtests) ==== [08:39:03] [PASSED] drm_test_check_broadcast_rgb_value [08:39:03] [PASSED] drm_test_check_bpc_8_value [08:39:03] [PASSED] drm_test_check_bpc_10_value [08:39:03] [PASSED] drm_test_check_bpc_12_value [08:39:03] [PASSED] drm_test_check_format_value [08:39:03] [PASSED] drm_test_check_tmds_char_value [08:39:03] ===== [PASSED] drm_atomic_helper_connector_hdmi_reset ====== [08:39:03] = drm_atomic_helper_connector_hdmi_mode_valid (4 subtests) = [08:39:03] [PASSED] drm_test_check_mode_valid [08:39:03] [PASSED] drm_test_check_mode_valid_reject [08:39:03] [PASSED] drm_test_check_mode_valid_reject_rate [08:39:03] [PASSED] drm_test_check_mode_valid_reject_max_clock [08:39:03] === [PASSED] drm_atomic_helper_connector_hdmi_mode_valid === [08:39:03] = drm_atomic_helper_connector_hdmi_infoframes (5 subtests) = [08:39:03] [PASSED] drm_test_check_infoframes [08:39:03] [PASSED] drm_test_check_reject_avi_infoframe [08:39:03] [PASSED] drm_test_check_reject_hdr_infoframe_bpc_8 [08:39:03] [PASSED] drm_test_check_reject_hdr_infoframe_bpc_10 [08:39:03] [PASSED] drm_test_check_reject_audio_infoframe [08:39:03] === [PASSED] drm_atomic_helper_connector_hdmi_infoframes === [08:39:03] ================= drm_managed (2 subtests) ================= [08:39:03] [PASSED] drm_test_managed_release_action [08:39:03] [PASSED] drm_test_managed_run_action [08:39:03] =================== [PASSED] drm_managed =================== [08:39:03] =================== drm_mm (6 subtests) ==================== [08:39:03] [PASSED] drm_test_mm_init [08:39:03] [PASSED] drm_test_mm_debug [08:39:03] [PASSED] drm_test_mm_align32 [08:39:03] [PASSED] drm_test_mm_align64 [08:39:03] [PASSED] drm_test_mm_lowest [08:39:03] [PASSED] drm_test_mm_highest [08:39:03] ===================== [PASSED] drm_mm ====================== [08:39:03] ============= drm_modes_analog_tv (5 subtests) ============= [08:39:03] [PASSED] drm_test_modes_analog_tv_mono_576i [08:39:03] [PASSED] drm_test_modes_analog_tv_ntsc_480i [08:39:03] [PASSED] drm_test_modes_analog_tv_ntsc_480i_inlined [08:39:03] [PASSED] drm_test_modes_analog_tv_pal_576i [08:39:03] [PASSED] drm_test_modes_analog_tv_pal_576i_inlined [08:39:03] =============== [PASSED] drm_modes_analog_tv =============== [08:39:03] ============== drm_plane_helper (2 subtests) =============== [08:39:03] =============== drm_test_check_plane_state ================ [08:39:03] [PASSED] clipping_simple [08:39:03] [PASSED] clipping_rotate_reflect [08:39:03] [PASSED] positioning_simple [08:39:03] [PASSED] upscaling [08:39:03] [PASSED] downscaling [08:39:03] [PASSED] rounding1 [08:39:03] [PASSED] rounding2 [08:39:03] [PASSED] rounding3 [08:39:03] [PASSED] rounding4 [08:39:03] =========== [PASSED] drm_test_check_plane_state ============ [08:39:03] =========== drm_test_check_invalid_plane_state ============ [08:39:03] [PASSED] positioning_invalid [08:39:03] [PASSED] upscaling_invalid [08:39:03] [PASSED] downscaling_invalid [08:39:03] ======= [PASSED] drm_test_check_invalid_plane_state ======== [08:39:03] ================ [PASSED] drm_plane_helper ================= [08:39:03] ====== drm_connector_helper_tv_get_modes (1 subtest) ======= [08:39:03] ====== drm_test_connector_helper_tv_get_modes_check ======= [08:39:03] [PASSED] None [08:39:03] [PASSED] PAL [08:39:03] [PASSED] NTSC [08:39:03] [PASSED] Both, NTSC Default [08:39:03] [PASSED] Both, PAL Default [08:39:03] [PASSED] Both, NTSC Default, with PAL on command-line [08:39:03] [PASSED] Both, PAL Default, with NTSC on command-line [08:39:03] == [PASSED] drm_test_connector_helper_tv_get_modes_check === [08:39:03] ======== [PASSED] drm_connector_helper_tv_get_modes ======== [08:39:03] ================== drm_rect (9 subtests) =================== [08:39:03] [PASSED] drm_test_rect_clip_scaled_div_by_zero [08:39:03] [PASSED] drm_test_rect_clip_scaled_not_clipped [08:39:03] [PASSED] drm_test_rect_clip_scaled_clipped [08:39:03] [PASSED] drm_test_rect_clip_scaled_signed_vs_unsigned [08:39:03] ================= drm_test_rect_intersect ================= [08:39:03] [PASSED] top-left x bottom-right: 2x2+1+1 x 2x2+0+0 [08:39:03] [PASSED] top-right x bottom-left: 2x2+0+0 x 2x2+1-1 [08:39:03] [PASSED] bottom-left x top-right: 2x2+1-1 x 2x2+0+0 [08:39:03] [PASSED] bottom-right x top-left: 2x2+0+0 x 2x2+1+1 [08:39:03] [PASSED] right x left: 2x1+0+0 x 3x1+1+0 [08:39:03] [PASSED] left x right: 3x1+1+0 x 2x1+0+0 [08:39:03] [PASSED] up x bottom: 1x2+0+0 x 1x3+0-1 [08:39:03] [PASSED] bottom x up: 1x3+0-1 x 1x2+0+0 [08:39:03] [PASSED] touching corner: 1x1+0+0 x 2x2+1+1 [08:39:03] [PASSED] touching side: 1x1+0+0 x 1x1+1+0 [08:39:03] [PASSED] equal rects: 2x2+0+0 x 2x2+0+0 [08:39:03] [PASSED] inside another: 2x2+0+0 x 1x1+1+1 [08:39:03] [PASSED] far away: 1x1+0+0 x 1x1+3+6 [08:39:03] [PASSED] points intersecting: 0x0+5+10 x 0x0+5+10 [08:39:03] [PASSED] points not intersecting: 0x0+0+0 x 0x0+5+10 [08:39:03] ============= [PASSED] drm_test_rect_intersect ============= [08:39:03] ================ drm_test_rect_calc_hscale ================ [08:39:03] [PASSED] normal use [08:39:03] [PASSED] out of max range [08:39:03] [PASSED] out of min range [08:39:03] [PASSED] zero dst [08:39:03] [PASSED] negative src [08:39:03] [PASSED] negative dst [08:39:03] ============ [PASSED] drm_test_rect_calc_hscale ============ [08:39:03] ================ drm_test_rect_calc_vscale ================ [08:39:03] [PASSED] normal use [08:39:03] [PASSED] out of max range [08:39:03] [PASSED] out of min range [08:39:03] [PASSED] zero dst [08:39:03] [PASSED] negative src [08:39:03] [PASSED] negative dst stty: 'standard input': Inappropriate ioctl for device [08:39:03] ============ [PASSED] drm_test_rect_calc_vscale ============ [08:39:03] ================== drm_test_rect_rotate =================== [08:39:03] [PASSED] reflect-x [08:39:03] [PASSED] reflect-y [08:39:03] [PASSED] rotate-0 [08:39:03] [PASSED] rotate-90 [08:39:03] [PASSED] rotate-180 [08:39:03] [PASSED] rotate-270 [08:39:03] ============== [PASSED] drm_test_rect_rotate =============== [08:39:03] ================ drm_test_rect_rotate_inv ================= [08:39:03] [PASSED] reflect-x [08:39:03] [PASSED] reflect-y [08:39:03] [PASSED] rotate-0 [08:39:03] [PASSED] rotate-90 [08:39:03] [PASSED] rotate-180 [08:39:03] [PASSED] rotate-270 [08:39:03] ============ [PASSED] drm_test_rect_rotate_inv ============= [08:39:03] ==================== [PASSED] drm_rect ===================== [08:39:03] ============ drm_sysfb_modeset_test (1 subtest) ============ [08:39:03] ============ drm_test_sysfb_build_fourcc_list ============= [08:39:03] [PASSED] no native formats [08:39:03] [PASSED] XRGB8888 as native format [08:39:03] [PASSED] remove duplicates [08:39:03] [PASSED] convert alpha formats [08:39:03] [PASSED] random formats [08:39:03] ======== [PASSED] drm_test_sysfb_build_fourcc_list ========= [08:39:03] ============= [PASSED] drm_sysfb_modeset_test ============== [08:39:03] ================== drm_fixp (2 subtests) =================== [08:39:03] [PASSED] drm_test_int2fixp [08:39:03] [PASSED] drm_test_sm2fixp [08:39:03] ==================== [PASSED] drm_fixp ===================== [08:39:03] ============================================================ [08:39:03] Testing complete. Ran 621 tests: passed: 621 [08:39:03] Elapsed time: 31.848s total, 1.598s configuring, 30.033s building, 0.179s running + /kernel/tools/testing/kunit/kunit.py run --kunitconfig /kernel/drivers/gpu/drm/ttm/tests/.kunitconfig [08:39:03] Configuring KUnit Kernel ... Regenerating .config ... Populating config with: $ make ARCH=um O=.kunit olddefconfig [08:39:04] Building KUnit Kernel ... Populating config with: $ make ARCH=um O=.kunit olddefconfig Building with: $ make all compile_commands.json scripts_gdb ARCH=um O=.kunit --jobs=25 [08:39:14] Starting KUnit Kernel (1/1)... [08:39:14] ============================================================ Running tests with: $ .kunit/linux kunit.enable=1 mem=1G console=tty kunit_shutdown=halt [08:39:14] ================= ttm_device (5 subtests) ================== [08:39:14] [PASSED] ttm_device_init_basic [08:39:14] [PASSED] ttm_device_init_multiple [08:39:14] [PASSED] ttm_device_fini_basic [08:39:14] [PASSED] ttm_device_init_no_vma_man [08:39:14] ================== ttm_device_init_pools ================== [08:39:14] [PASSED] No DMA allocations, no DMA32 required [08:39:14] [PASSED] DMA allocations, DMA32 required [08:39:14] [PASSED] No DMA allocations, DMA32 required [08:39:14] [PASSED] DMA allocations, no DMA32 required [08:39:14] ============== [PASSED] ttm_device_init_pools ============== [08:39:14] =================== [PASSED] ttm_device ==================== [08:39:14] ================== ttm_pool (8 subtests) =================== [08:39:14] ================== ttm_pool_alloc_basic =================== [08:39:14] [PASSED] One page [08:39:14] [PASSED] More than one page [08:39:14] [PASSED] Above the allocation limit [08:39:14] [PASSED] One page, with coherent DMA mappings enabled [08:39:14] [PASSED] Above the allocation limit, with coherent DMA mappings enabled [08:39:14] ============== [PASSED] ttm_pool_alloc_basic =============== [08:39:14] ============== ttm_pool_alloc_basic_dma_addr ============== [08:39:14] [PASSED] One page [08:39:14] [PASSED] More than one page [08:39:14] [PASSED] Above the allocation limit [08:39:14] [PASSED] One page, with coherent DMA mappings enabled [08:39:14] [PASSED] Above the allocation limit, with coherent DMA mappings enabled [08:39:14] ========== [PASSED] ttm_pool_alloc_basic_dma_addr ========== [08:39:14] [PASSED] ttm_pool_alloc_order_caching_match [08:39:14] [PASSED] ttm_pool_alloc_caching_mismatch [08:39:14] [PASSED] ttm_pool_alloc_order_mismatch [08:39:14] [PASSED] ttm_pool_free_dma_alloc [08:39:14] [PASSED] ttm_pool_free_no_dma_alloc [08:39:14] [PASSED] ttm_pool_fini_basic [08:39:14] ==================== [PASSED] ttm_pool ===================== [08:39:14] ================ ttm_resource (8 subtests) ================= [08:39:14] ================= ttm_resource_init_basic ================= [08:39:14] [PASSED] Init resource in TTM_PL_SYSTEM [08:39:14] [PASSED] Init resource in TTM_PL_VRAM [08:39:14] [PASSED] Init resource in a private placement [08:39:14] [PASSED] Init resource in TTM_PL_SYSTEM, set placement flags [08:39:14] ============= [PASSED] ttm_resource_init_basic ============= [08:39:14] [PASSED] ttm_resource_init_pinned [08:39:14] [PASSED] ttm_resource_fini_basic [08:39:14] [PASSED] ttm_resource_manager_init_basic [08:39:14] [PASSED] ttm_resource_manager_usage_basic [08:39:14] [PASSED] ttm_resource_manager_set_used_basic [08:39:14] [PASSED] ttm_sys_man_alloc_basic [08:39:14] [PASSED] ttm_sys_man_free_basic [08:39:14] ================== [PASSED] ttm_resource =================== [08:39:14] =================== ttm_tt (15 subtests) =================== [08:39:14] ==================== ttm_tt_init_basic ==================== [08:39:14] [PASSED] Page-aligned size [08:39:14] [PASSED] Extra pages requested [08:39:14] ================ [PASSED] ttm_tt_init_basic ================ [08:39:14] [PASSED] ttm_tt_init_misaligned [08:39:14] [PASSED] ttm_tt_fini_basic [08:39:14] [PASSED] ttm_tt_fini_sg [08:39:14] [PASSED] ttm_tt_fini_shmem [08:39:14] [PASSED] ttm_tt_create_basic [08:39:14] [PASSED] ttm_tt_create_invalid_bo_type [08:39:14] [PASSED] ttm_tt_create_ttm_exists [08:39:14] [PASSED] ttm_tt_create_failed [08:39:14] [PASSED] ttm_tt_destroy_basic [08:39:14] [PASSED] ttm_tt_populate_null_ttm [08:39:14] [PASSED] ttm_tt_populate_populated_ttm [08:39:14] [PASSED] ttm_tt_unpopulate_basic [08:39:14] [PASSED] ttm_tt_unpopulate_empty_ttm [08:39:14] [PASSED] ttm_tt_swapin_basic [08:39:14] ===================== [PASSED] ttm_tt ====================== [08:39:14] =================== ttm_bo (14 subtests) =================== [08:39:14] =========== ttm_bo_reserve_optimistic_no_ticket =========== [08:39:14] [PASSED] Cannot be interrupted and sleeps [08:39:14] [PASSED] Cannot be interrupted, locks straight away [08:39:14] [PASSED] Can be interrupted, sleeps [08:39:14] ======= [PASSED] ttm_bo_reserve_optimistic_no_ticket ======= [08:39:14] [PASSED] ttm_bo_reserve_locked_no_sleep [08:39:14] [PASSED] ttm_bo_reserve_no_wait_ticket [08:39:14] [PASSED] ttm_bo_reserve_double_resv [08:39:14] [PASSED] ttm_bo_reserve_interrupted [08:39:14] [PASSED] ttm_bo_reserve_deadlock [08:39:14] [PASSED] ttm_bo_unreserve_basic [08:39:14] [PASSED] ttm_bo_unreserve_pinned [08:39:14] [PASSED] ttm_bo_unreserve_bulk [08:39:14] [PASSED] ttm_bo_fini_basic [08:39:14] [PASSED] ttm_bo_fini_shared_resv [08:39:14] [PASSED] ttm_bo_pin_basic [08:39:14] [PASSED] ttm_bo_pin_unpin_resource [08:39:14] [PASSED] ttm_bo_multiple_pin_one_unpin [08:39:14] ===================== [PASSED] ttm_bo ====================== [08:39:14] ============== ttm_bo_validate (21 subtests) =============== [08:39:14] ============== ttm_bo_init_reserved_sys_man =============== [08:39:14] [PASSED] Buffer object for userspace [08:39:14] [PASSED] Kernel buffer object [08:39:14] [PASSED] Shared buffer object [08:39:14] ========== [PASSED] ttm_bo_init_reserved_sys_man =========== [08:39:14] ============== ttm_bo_init_reserved_mock_man ============== [08:39:14] [PASSED] Buffer object for userspace [08:39:14] [PASSED] Kernel buffer object [08:39:14] [PASSED] Shared buffer object [08:39:14] ========== [PASSED] ttm_bo_init_reserved_mock_man ========== [08:39:14] [PASSED] ttm_bo_init_reserved_resv [08:39:14] ================== ttm_bo_validate_basic ================== [08:39:14] [PASSED] Buffer object for userspace [08:39:14] [PASSED] Kernel buffer object [08:39:14] [PASSED] Shared buffer object [08:39:14] ============== [PASSED] ttm_bo_validate_basic ============== [08:39:14] [PASSED] ttm_bo_validate_invalid_placement [08:39:14] ============= ttm_bo_validate_same_placement ============== [08:39:14] [PASSED] System manager [08:39:14] [PASSED] VRAM manager [08:39:14] ========= [PASSED] ttm_bo_validate_same_placement ========== [08:39:14] [PASSED] ttm_bo_validate_failed_alloc [08:39:14] [PASSED] ttm_bo_validate_pinned [08:39:14] [PASSED] ttm_bo_validate_busy_placement [08:39:14] ================ ttm_bo_validate_multihop ================= [08:39:14] [PASSED] Buffer object for userspace [08:39:14] [PASSED] Kernel buffer object [08:39:14] [PASSED] Shared buffer object [08:39:14] ============ [PASSED] ttm_bo_validate_multihop ============= [08:39:14] ========== ttm_bo_validate_no_placement_signaled ========== [08:39:14] [PASSED] Buffer object in system domain, no page vector [08:39:14] [PASSED] Buffer object in system domain with an existing page vector [08:39:14] ====== [PASSED] ttm_bo_validate_no_placement_signaled ====== [08:39:14] ======== ttm_bo_validate_no_placement_not_signaled ======== [08:39:14] [PASSED] Buffer object for userspace [08:39:14] [PASSED] Kernel buffer object [08:39:14] [PASSED] Shared buffer object [08:39:14] ==== [PASSED] ttm_bo_validate_no_placement_not_signaled ==== [08:39:14] [PASSED] ttm_bo_validate_move_fence_signaled [08:39:14] ========= ttm_bo_validate_move_fence_not_signaled ========= [08:39:14] [PASSED] Waits for GPU [08:39:14] [PASSED] Tries to lock straight away [08:39:14] ===== [PASSED] ttm_bo_validate_move_fence_not_signaled ===== [08:39:14] [PASSED] ttm_bo_validate_happy_evict [08:39:14] [PASSED] ttm_bo_validate_all_pinned_evict [08:39:14] [PASSED] ttm_bo_validate_allowed_only_evict [08:39:14] [PASSED] ttm_bo_validate_deleted_evict [08:39:14] [PASSED] ttm_bo_validate_busy_domain_evict [08:39:14] [PASSED] ttm_bo_validate_evict_gutting [08:39:14] [PASSED] ttm_bo_validate_recrusive_evict stty: 'standard input': Inappropriate ioctl for device [08:39:14] ================= [PASSED] ttm_bo_validate ================= [08:39:14] ============================================================ [08:39:14] Testing complete. Ran 101 tests: passed: 101 [08:39:14] Elapsed time: 11.047s total, 1.587s configuring, 9.193s building, 0.223s running + cleanup ++ stat -c %u:%g /kernel + chown -R 1003:1003 /kernel ^ permalink raw reply [flat|nested] 14+ messages in thread
* ✗ CI.checksparse: warning for series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling 2026-02-09 8:30 [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling Arunpravin Paneer Selvam ` (2 preceding siblings ...) 2026-02-09 8:39 ` ✓ CI.KUnit: success " Patchwork @ 2026-02-09 8:57 ` Patchwork 2026-02-09 9:16 ` ✓ Xe.CI.BAT: success " Patchwork ` (2 subsequent siblings) 6 siblings, 0 replies; 14+ messages in thread From: Patchwork @ 2026-02-09 8:57 UTC (permalink / raw) To: Arunpravin Paneer Selvam; +Cc: intel-xe == Series Details == Series: series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling URL : https://patchwork.freedesktop.org/series/161338/ State : warning == Summary == + trap cleanup EXIT + KERNEL=/kernel + MT=/root/linux/maintainer-tools + git clone https://gitlab.freedesktop.org/drm/maintainer-tools /root/linux/maintainer-tools Cloning into '/root/linux/maintainer-tools'... warning: redirecting to https://gitlab.freedesktop.org/drm/maintainer-tools.git/ + make -C /root/linux/maintainer-tools make: Entering directory '/root/linux/maintainer-tools' cc -O2 -g -Wextra -o remap-log remap-log.c make: Leaving directory '/root/linux/maintainer-tools' + cd /kernel + git config --global --add safe.directory /kernel + /root/linux/maintainer-tools/dim sparse --fast 9ddce2e2e1c2891bc26ea8648b2ba530b73937fe Sparse version: 0.6.4 (Ubuntu: 0.6.4-4ubuntu3) Fast mode used, each commit won't be checked separately. - +drivers/gpu/drm/drm_buddy.c:76:1: error: bad constant expression +drivers/gpu/drm/drm_buddy.c:77:1: error: bad constant expression +drivers/gpu/drm/drm_buddy.c:77:1: error: bad constant expression + cleanup ++ stat -c %u:%g /kernel + chown -R 1003:1003 /kernel ^ permalink raw reply [flat|nested] 14+ messages in thread
* ✓ Xe.CI.BAT: success for series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling 2026-02-09 8:30 [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling Arunpravin Paneer Selvam ` (3 preceding siblings ...) 2026-02-09 8:57 ` ✗ CI.checksparse: warning " Patchwork @ 2026-02-09 9:16 ` Patchwork 2026-02-09 10:21 ` ✓ Xe.CI.FULL: " Patchwork 2026-02-10 16:26 ` [PATCH v3 1/2] " Matthew Auld 6 siblings, 0 replies; 14+ messages in thread From: Patchwork @ 2026-02-09 9:16 UTC (permalink / raw) To: Arunpravin Paneer Selvam; +Cc: intel-xe [-- Attachment #1: Type: text/plain, Size: 906 bytes --] == Series Details == Series: series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling URL : https://patchwork.freedesktop.org/series/161338/ State : success == Summary == CI Bug Log - changes from xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36_BAT -> xe-pw-161338v1_BAT ==================================================== Summary ------- **SUCCESS** No regressions found. Participating hosts (12 -> 12) ------------------------------ No changes in participating hosts Changes ------- No changes found Build changes ------------- * Linux: xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36 -> xe-pw-161338v1 IGT_8744: 8744 xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36: 1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36 xe-pw-161338v1: 161338v1 == Logs == For more details see: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/index.html [-- Attachment #2: Type: text/html, Size: 1454 bytes --] ^ permalink raw reply [flat|nested] 14+ messages in thread
* ✓ Xe.CI.FULL: success for series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling 2026-02-09 8:30 [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling Arunpravin Paneer Selvam ` (4 preceding siblings ...) 2026-02-09 9:16 ` ✓ Xe.CI.BAT: success " Patchwork @ 2026-02-09 10:21 ` Patchwork 2026-02-10 16:26 ` [PATCH v3 1/2] " Matthew Auld 6 siblings, 0 replies; 14+ messages in thread From: Patchwork @ 2026-02-09 10:21 UTC (permalink / raw) To: Arunpravin Paneer Selvam; +Cc: intel-xe [-- Attachment #1: Type: text/plain, Size: 29764 bytes --] == Series Details == Series: series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling URL : https://patchwork.freedesktop.org/series/161338/ State : success == Summary == CI Bug Log - changes from xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36_FULL -> xe-pw-161338v1_FULL ==================================================== Summary ------- **SUCCESS** No regressions found. Participating hosts (2 -> 2) ------------------------------ No changes in participating hosts Known issues ------------ Here are the changes found in xe-pw-161338v1_FULL that come from known issues: ### IGT changes ### #### Issues hit #### * igt@kms_big_fb@y-tiled-64bpp-rotate-0: - shard-bmg: NOTRUN -> [SKIP][1] ([Intel XE#1124]) +1 other test skip [1]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@kms_big_fb@y-tiled-64bpp-rotate-0.html * igt@kms_bw@connected-linear-tiling-2-displays-1920x1080p: - shard-bmg: [PASS][2] -> [SKIP][3] ([Intel XE#2314] / [Intel XE#2894]) +1 other test skip [2]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-8/igt@kms_bw@connected-linear-tiling-2-displays-1920x1080p.html [3]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-6/igt@kms_bw@connected-linear-tiling-2-displays-1920x1080p.html * igt@kms_ccs@bad-rotation-90-4-tiled-lnl-ccs@pipe-c-dp-2: - shard-bmg: NOTRUN -> [SKIP][4] ([Intel XE#2652] / [Intel XE#787]) +7 other tests skip [4]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-10/igt@kms_ccs@bad-rotation-90-4-tiled-lnl-ccs@pipe-c-dp-2.html * igt@kms_ccs@crc-primary-suspend-4-tiled-dg2-rc-ccs-cc: - shard-bmg: NOTRUN -> [SKIP][5] ([Intel XE#3432]) [5]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@kms_ccs@crc-primary-suspend-4-tiled-dg2-rc-ccs-cc.html * igt@kms_chamelium_edid@dp-edid-resolution-list: - shard-bmg: NOTRUN -> [SKIP][6] ([Intel XE#2252]) [6]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_chamelium_edid@dp-edid-resolution-list.html * igt@kms_content_protection@dp-mst-type-0-suspend-resume: - shard-bmg: NOTRUN -> [SKIP][7] ([Intel XE#6974]) [7]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_content_protection@dp-mst-type-0-suspend-resume.html * igt@kms_content_protection@dp-mst-type-1: - shard-bmg: NOTRUN -> [SKIP][8] ([Intel XE#2390] / [Intel XE#6974]) [8]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@kms_content_protection@dp-mst-type-1.html * igt@kms_content_protection@lic-type-0-hdcp14@pipe-a-dp-2: - shard-bmg: NOTRUN -> [FAIL][9] ([Intel XE#3304]) [9]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@kms_content_protection@lic-type-0-hdcp14@pipe-a-dp-2.html * igt@kms_content_protection@lic-type-0@pipe-a-dp-2: - shard-bmg: NOTRUN -> [FAIL][10] ([Intel XE#1178] / [Intel XE#3304]) [10]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-7/igt@kms_content_protection@lic-type-0@pipe-a-dp-2.html * igt@kms_content_protection@uevent-hdcp14@pipe-a-dp-2: - shard-bmg: NOTRUN -> [FAIL][11] ([Intel XE#6707]) +1 other test fail [11]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-1/igt@kms_content_protection@uevent-hdcp14@pipe-a-dp-2.html * igt@kms_cursor_crc@cursor-offscreen-512x512: - shard-bmg: NOTRUN -> [SKIP][12] ([Intel XE#2321]) [12]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_cursor_crc@cursor-offscreen-512x512.html * igt@kms_cursor_legacy@cursorb-vs-flipb-legacy: - shard-bmg: [PASS][13] -> [SKIP][14] ([Intel XE#2291]) +5 other tests skip [13]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-10/igt@kms_cursor_legacy@cursorb-vs-flipb-legacy.html [14]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-5/igt@kms_cursor_legacy@cursorb-vs-flipb-legacy.html * igt@kms_cursor_legacy@flip-vs-cursor-atomic: - shard-bmg: [PASS][15] -> [FAIL][16] ([Intel XE#6715]) [15]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-7/igt@kms_cursor_legacy@flip-vs-cursor-atomic.html [16]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-8/igt@kms_cursor_legacy@flip-vs-cursor-atomic.html * igt@kms_cursor_legacy@flip-vs-cursor-atomic-transitions: - shard-bmg: [PASS][17] -> [FAIL][18] ([Intel XE#5299]) [17]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-8/igt@kms_cursor_legacy@flip-vs-cursor-atomic-transitions.html [18]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_cursor_legacy@flip-vs-cursor-atomic-transitions.html * igt@kms_feature_discovery@display-2x: - shard-bmg: [PASS][19] -> [SKIP][20] ([Intel XE#2373]) [19]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-10/igt@kms_feature_discovery@display-2x.html [20]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-5/igt@kms_feature_discovery@display-2x.html * igt@kms_flip@2x-absolute-wf_vblank-interruptible: - shard-bmg: [PASS][21] -> [FAIL][22] ([Intel XE#5352]) +1 other test fail [21]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-2/igt@kms_flip@2x-absolute-wf_vblank-interruptible.html [22]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_flip@2x-absolute-wf_vblank-interruptible.html * igt@kms_flip@2x-plain-flip-fb-recreate: - shard-bmg: [PASS][23] -> [SKIP][24] ([Intel XE#2316]) +9 other tests skip [23]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-1/igt@kms_flip@2x-plain-flip-fb-recreate.html [24]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-6/igt@kms_flip@2x-plain-flip-fb-recreate.html * igt@kms_frontbuffer_tracking@drrs-2p-primscrn-pri-shrfb-draw-mmap-wc: - shard-bmg: NOTRUN -> [SKIP][25] ([Intel XE#2311]) +1 other test skip [25]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_frontbuffer_tracking@drrs-2p-primscrn-pri-shrfb-draw-mmap-wc.html * igt@kms_frontbuffer_tracking@fbc-abgr161616f-draw-render: - shard-bmg: NOTRUN -> [SKIP][26] ([Intel XE#7061]) +2 other tests skip [26]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@kms_frontbuffer_tracking@fbc-abgr161616f-draw-render.html * igt@kms_frontbuffer_tracking@fbcpsr-2p-scndscrn-shrfb-pgflip-blt: - shard-bmg: NOTRUN -> [SKIP][27] ([Intel XE#2313]) +2 other tests skip [27]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@kms_frontbuffer_tracking@fbcpsr-2p-scndscrn-shrfb-pgflip-blt.html * igt@kms_hdr@static-toggle-dpms: - shard-bmg: [PASS][28] -> [SKIP][29] ([Intel XE#1503]) [28]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-9/igt@kms_hdr@static-toggle-dpms.html [29]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-5/igt@kms_hdr@static-toggle-dpms.html * igt@kms_joiner@invalid-modeset-force-big-joiner: - shard-bmg: [PASS][30] -> [SKIP][31] ([Intel XE#7086]) +1 other test skip [30]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-9/igt@kms_joiner@invalid-modeset-force-big-joiner.html [31]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-5/igt@kms_joiner@invalid-modeset-force-big-joiner.html * igt@kms_plane@pixel-format-4-tiled-dg2-rc-ccs-cc-modifier@pipe-a-plane-5: - shard-bmg: NOTRUN -> [SKIP][32] ([Intel XE#7130]) +4 other tests skip [32]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_plane@pixel-format-4-tiled-dg2-rc-ccs-cc-modifier@pipe-a-plane-5.html * igt@kms_plane@pixel-format-4-tiled-dg2-rc-ccs-cc-modifier@pipe-b-plane-5: - shard-bmg: NOTRUN -> [SKIP][33] ([Intel XE#7111] / [Intel XE#7130]) +1 other test skip [33]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_plane@pixel-format-4-tiled-dg2-rc-ccs-cc-modifier@pipe-b-plane-5.html * igt@kms_plane_multiple@2x-tiling-4: - shard-bmg: [PASS][34] -> [SKIP][35] ([Intel XE#4596]) [34]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-10/igt@kms_plane_multiple@2x-tiling-4.html [35]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-5/igt@kms_plane_multiple@2x-tiling-4.html * igt@kms_pm_backlight@brightness-with-dpms: - shard-bmg: NOTRUN -> [SKIP][36] ([Intel XE#2938]) [36]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_pm_backlight@brightness-with-dpms.html * igt@kms_pm_dc@dc5-retention-flops: - shard-bmg: NOTRUN -> [SKIP][37] ([Intel XE#3309]) [37]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@kms_pm_dc@dc5-retention-flops.html * igt@kms_psr2_sf@fbc-pr-primary-plane-update-sf-dmg-area: - shard-bmg: NOTRUN -> [SKIP][38] ([Intel XE#1406] / [Intel XE#1489]) +1 other test skip [38]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@kms_psr2_sf@fbc-pr-primary-plane-update-sf-dmg-area.html * igt@kms_psr@psr-basic: - shard-bmg: NOTRUN -> [SKIP][39] ([Intel XE#1406] / [Intel XE#2234] / [Intel XE#2850]) [39]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_psr@psr-basic.html * igt@kms_setmode@clone-exclusive-crtc: - shard-bmg: [PASS][40] -> [SKIP][41] ([Intel XE#1435]) [40]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-7/igt@kms_setmode@clone-exclusive-crtc.html [41]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-5/igt@kms_setmode@clone-exclusive-crtc.html * igt@xe_eudebug@attach-debug-metadata: - shard-bmg: NOTRUN -> [SKIP][42] ([Intel XE#4837]) [42]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@xe_eudebug@attach-debug-metadata.html * igt@xe_eudebug_online@pagefault-one-of-many: - shard-bmg: NOTRUN -> [SKIP][43] ([Intel XE#6665]) [43]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@xe_eudebug_online@pagefault-one-of-many.html * igt@xe_evict@evict-mixed-threads-small-multi-queue: - shard-bmg: NOTRUN -> [SKIP][44] ([Intel XE#7140]) [44]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@xe_evict@evict-mixed-threads-small-multi-queue.html * igt@xe_exec_basic@multigpu-once-basic-defer-bind: - shard-bmg: NOTRUN -> [SKIP][45] ([Intel XE#2322]) [45]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@xe_exec_basic@multigpu-once-basic-defer-bind.html * igt@xe_exec_multi_queue@max-queues-preempt-mode-basic: - shard-bmg: NOTRUN -> [SKIP][46] ([Intel XE#6874]) +3 other tests skip [46]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@xe_exec_multi_queue@max-queues-preempt-mode-basic.html * igt@xe_exec_system_allocator@threads-shared-vm-many-large-execqueues-mmap-free-huge-nomemset: - shard-bmg: NOTRUN -> [SKIP][47] ([Intel XE#4943]) +3 other tests skip [47]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@xe_exec_system_allocator@threads-shared-vm-many-large-execqueues-mmap-free-huge-nomemset.html * igt@xe_multigpu_svm@mgpu-migration-basic: - shard-bmg: NOTRUN -> [SKIP][48] ([Intel XE#6964]) +1 other test skip [48]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@xe_multigpu_svm@mgpu-migration-basic.html * igt@xe_oa@oa-tlb-invalidate: - shard-bmg: NOTRUN -> [SKIP][49] ([Intel XE#2248]) [49]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@xe_oa@oa-tlb-invalidate.html * igt@xe_pxp@pxp-stale-queue-post-suspend: - shard-bmg: NOTRUN -> [SKIP][50] ([Intel XE#4733]) [50]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@xe_pxp@pxp-stale-queue-post-suspend.html #### Possible fixes #### * igt@kms_async_flips@async-flip-with-page-flip-events-linear-atomic@pipe-c-edp-1: - shard-lnl: [FAIL][51] ([Intel XE#6054]) -> [PASS][52] +3 other tests pass [51]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-lnl-2/igt@kms_async_flips@async-flip-with-page-flip-events-linear-atomic@pipe-c-edp-1.html [52]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-lnl-4/igt@kms_async_flips@async-flip-with-page-flip-events-linear-atomic@pipe-c-edp-1.html * igt@kms_atomic_transition@plane-all-transition-fencing: - shard-bmg: [INCOMPLETE][53] -> [PASS][54] [53]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-2/igt@kms_atomic_transition@plane-all-transition-fencing.html [54]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_atomic_transition@plane-all-transition-fencing.html * igt@kms_atomic_transition@plane-all-transition-fencing@pipe-b-hdmi-a-3: - shard-bmg: [DMESG-FAIL][55] ([Intel XE#1727]) -> [PASS][56] [55]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-2/igt@kms_atomic_transition@plane-all-transition-fencing@pipe-b-hdmi-a-3.html [56]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@kms_atomic_transition@plane-all-transition-fencing@pipe-b-hdmi-a-3.html * igt@kms_bw@connected-linear-tiling-2-displays-2560x1440p: - shard-bmg: [SKIP][57] ([Intel XE#2314] / [Intel XE#2894]) -> [PASS][58] [57]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-6/igt@kms_bw@connected-linear-tiling-2-displays-2560x1440p.html [58]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-7/igt@kms_bw@connected-linear-tiling-2-displays-2560x1440p.html * igt@kms_cursor_legacy@2x-cursor-vs-flip-atomic: - shard-bmg: [SKIP][59] ([Intel XE#2291]) -> [PASS][60] +4 other tests pass [59]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-6/igt@kms_cursor_legacy@2x-cursor-vs-flip-atomic.html [60]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-7/igt@kms_cursor_legacy@2x-cursor-vs-flip-atomic.html * igt@kms_dither@fb-8bpc-vs-panel-6bpc: - shard-bmg: [SKIP][61] ([Intel XE#1340]) -> [PASS][62] [61]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-5/igt@kms_dither@fb-8bpc-vs-panel-6bpc.html [62]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-10/igt@kms_dither@fb-8bpc-vs-panel-6bpc.html * igt@kms_flip@2x-flip-vs-wf_vblank-interruptible: - shard-bmg: [SKIP][63] ([Intel XE#2316]) -> [PASS][64] +8 other tests pass [63]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-6/igt@kms_flip@2x-flip-vs-wf_vblank-interruptible.html [64]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-9/igt@kms_flip@2x-flip-vs-wf_vblank-interruptible.html * igt@kms_flip@wf_vblank-ts-check-interruptible: - shard-lnl: [FAIL][65] ([Intel XE#5416] / [Intel XE#6266]) -> [PASS][66] +1 other test pass [65]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-lnl-8/igt@kms_flip@wf_vblank-ts-check-interruptible.html [66]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-lnl-2/igt@kms_flip@wf_vblank-ts-check-interruptible.html - shard-bmg: [FAIL][67] ([Intel XE#3098]) -> [PASS][68] +1 other test pass [67]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-9/igt@kms_flip@wf_vblank-ts-check-interruptible.html [68]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-7/igt@kms_flip@wf_vblank-ts-check-interruptible.html * igt@kms_hdr@static-toggle-suspend: - shard-bmg: [SKIP][69] ([Intel XE#1503]) -> [PASS][70] [69]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-5/igt@kms_hdr@static-toggle-suspend.html [70]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-1/igt@kms_hdr@static-toggle-suspend.html * igt@kms_vrr@flipline: - shard-lnl: [FAIL][71] ([Intel XE#4227]) -> [PASS][72] +1 other test pass [71]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-lnl-2/igt@kms_vrr@flipline.html [72]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-lnl-4/igt@kms_vrr@flipline.html * igt@xe_evict@evict-mixed-many-threads-small: - shard-bmg: [INCOMPLETE][73] ([Intel XE#6321]) -> [PASS][74] [73]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-8/igt@xe_evict@evict-mixed-many-threads-small.html [74]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-3/igt@xe_evict@evict-mixed-many-threads-small.html #### Warnings #### * igt@kms_content_protection@atomic-dpms: - shard-bmg: [FAIL][75] ([Intel XE#1178] / [Intel XE#3304]) -> [SKIP][76] ([Intel XE#2341]) [75]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-10/igt@kms_content_protection@atomic-dpms.html [76]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-6/igt@kms_content_protection@atomic-dpms.html * igt@kms_content_protection@legacy-hdcp14: - shard-bmg: [FAIL][77] ([Intel XE#3304]) -> [SKIP][78] ([Intel XE#7194]) +1 other test skip [77]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-7/igt@kms_content_protection@legacy-hdcp14.html [78]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-5/igt@kms_content_protection@legacy-hdcp14.html * igt@kms_content_protection@lic-type-0: - shard-bmg: [SKIP][79] ([Intel XE#2341]) -> [FAIL][80] ([Intel XE#1178] / [Intel XE#3304]) [79]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-6/igt@kms_content_protection@lic-type-0.html [80]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-7/igt@kms_content_protection@lic-type-0.html * igt@kms_content_protection@lic-type-0-hdcp14: - shard-bmg: [SKIP][81] ([Intel XE#7194]) -> [FAIL][82] ([Intel XE#3304]) [81]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-6/igt@kms_content_protection@lic-type-0-hdcp14.html [82]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@kms_content_protection@lic-type-0-hdcp14.html * igt@kms_content_protection@uevent: - shard-bmg: [SKIP][83] ([Intel XE#2341]) -> [FAIL][84] ([Intel XE#6707]) [83]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-5/igt@kms_content_protection@uevent.html [84]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-10/igt@kms_content_protection@uevent.html * igt@kms_content_protection@uevent-hdcp14: - shard-bmg: [SKIP][85] ([Intel XE#7194]) -> [FAIL][86] ([Intel XE#6707]) [85]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-5/igt@kms_content_protection@uevent-hdcp14.html [86]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-1/igt@kms_content_protection@uevent-hdcp14.html * igt@kms_frontbuffer_tracking@fbc-2p-primscrn-spr-indfb-fullscreen: - shard-bmg: [SKIP][87] ([Intel XE#2312]) -> [SKIP][88] ([Intel XE#4141]) +7 other tests skip [87]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-5/igt@kms_frontbuffer_tracking@fbc-2p-primscrn-spr-indfb-fullscreen.html [88]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-10/igt@kms_frontbuffer_tracking@fbc-2p-primscrn-spr-indfb-fullscreen.html * igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-shrfb-pgflip-blt: - shard-bmg: [SKIP][89] ([Intel XE#4141]) -> [SKIP][90] ([Intel XE#2312]) +11 other tests skip [89]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-7/igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-shrfb-pgflip-blt.html [90]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-5/igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-shrfb-pgflip-blt.html * igt@kms_frontbuffer_tracking@fbcdrrs-2p-primscrn-shrfb-plflip-blt: - shard-bmg: [SKIP][91] ([Intel XE#2312]) -> [SKIP][92] ([Intel XE#2311]) +15 other tests skip [91]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-5/igt@kms_frontbuffer_tracking@fbcdrrs-2p-primscrn-shrfb-plflip-blt.html [92]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-1/igt@kms_frontbuffer_tracking@fbcdrrs-2p-primscrn-shrfb-plflip-blt.html * igt@kms_frontbuffer_tracking@fbcdrrs-2p-scndscrn-cur-indfb-draw-mmap-wc: - shard-bmg: [SKIP][93] ([Intel XE#2311]) -> [SKIP][94] ([Intel XE#2312]) +26 other tests skip [93]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-1/igt@kms_frontbuffer_tracking@fbcdrrs-2p-scndscrn-cur-indfb-draw-mmap-wc.html [94]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-6/igt@kms_frontbuffer_tracking@fbcdrrs-2p-scndscrn-cur-indfb-draw-mmap-wc.html * igt@kms_frontbuffer_tracking@psr-2p-primscrn-indfb-plflip-blt: - shard-bmg: [SKIP][95] ([Intel XE#2313]) -> [SKIP][96] ([Intel XE#2312]) +23 other tests skip [95]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-1/igt@kms_frontbuffer_tracking@psr-2p-primscrn-indfb-plflip-blt.html [96]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-6/igt@kms_frontbuffer_tracking@psr-2p-primscrn-indfb-plflip-blt.html * igt@kms_frontbuffer_tracking@psr-2p-primscrn-spr-indfb-fullscreen: - shard-bmg: [SKIP][97] ([Intel XE#2312]) -> [SKIP][98] ([Intel XE#2313]) +18 other tests skip [97]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-5/igt@kms_frontbuffer_tracking@psr-2p-primscrn-spr-indfb-fullscreen.html [98]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-10/igt@kms_frontbuffer_tracking@psr-2p-primscrn-spr-indfb-fullscreen.html * igt@kms_plane_multiple@2x-tiling-yf: - shard-bmg: [SKIP][99] ([Intel XE#4596]) -> [SKIP][100] ([Intel XE#5021]) +1 other test skip [99]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-6/igt@kms_plane_multiple@2x-tiling-yf.html [100]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-9/igt@kms_plane_multiple@2x-tiling-yf.html * igt@kms_tiled_display@basic-test-pattern-with-chamelium: - shard-bmg: [SKIP][101] ([Intel XE#2509]) -> [SKIP][102] ([Intel XE#2426]) [101]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-10/igt@kms_tiled_display@basic-test-pattern-with-chamelium.html [102]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-5/igt@kms_tiled_display@basic-test-pattern-with-chamelium.html * igt@xe_exec_system_allocator@threads-shared-vm-many-large-execqueues-mmap-new-huge-nomemset: - shard-bmg: [ABORT][103] -> [SKIP][104] ([Intel XE#4943]) [103]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36/shard-bmg-9/igt@xe_exec_system_allocator@threads-shared-vm-many-large-execqueues-mmap-new-huge-nomemset.html [104]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/shard-bmg-4/igt@xe_exec_system_allocator@threads-shared-vm-many-large-execqueues-mmap-new-huge-nomemset.html [Intel XE#1124]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1124 [Intel XE#1178]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1178 [Intel XE#1340]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1340 [Intel XE#1406]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1406 [Intel XE#1435]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1435 [Intel XE#1489]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1489 [Intel XE#1503]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1503 [Intel XE#1727]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1727 [Intel XE#2234]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2234 [Intel XE#2248]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2248 [Intel XE#2252]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2252 [Intel XE#2291]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2291 [Intel XE#2311]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2311 [Intel XE#2312]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2312 [Intel XE#2313]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2313 [Intel XE#2314]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2314 [Intel XE#2316]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2316 [Intel XE#2321]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2321 [Intel XE#2322]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2322 [Intel XE#2341]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2341 [Intel XE#2373]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2373 [Intel XE#2390]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2390 [Intel XE#2426]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2426 [Intel XE#2509]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2509 [Intel XE#2652]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2652 [Intel XE#2850]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2850 [Intel XE#2894]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2894 [Intel XE#2938]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2938 [Intel XE#3098]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3098 [Intel XE#3304]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3304 [Intel XE#3309]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3309 [Intel XE#3432]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3432 [Intel XE#4141]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4141 [Intel XE#4227]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4227 [Intel XE#4596]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4596 [Intel XE#4733]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4733 [Intel XE#4837]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4837 [Intel XE#4943]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4943 [Intel XE#5021]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/5021 [Intel XE#5299]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/5299 [Intel XE#5352]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/5352 [Intel XE#5416]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/5416 [Intel XE#6054]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/6054 [Intel XE#6266]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/6266 [Intel XE#6321]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/6321 [Intel XE#6665]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/6665 [Intel XE#6707]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/6707 [Intel XE#6715]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/6715 [Intel XE#6874]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/6874 [Intel XE#6964]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/6964 [Intel XE#6974]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/6974 [Intel XE#7061]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/7061 [Intel XE#7086]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/7086 [Intel XE#7111]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/7111 [Intel XE#7130]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/7130 [Intel XE#7140]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/7140 [Intel XE#7194]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/7194 [Intel XE#787]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/787 Build changes ------------- * Linux: xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36 -> xe-pw-161338v1 IGT_8744: 8744 xe-4524-1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36: 1d8de8bfed023d4f1e11f6978a0fcdbddc0f9b36 xe-pw-161338v1: 161338v1 == Logs == For more details see: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-161338v1/index.html [-- Attachment #2: Type: text/html, Size: 34057 bytes --] ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling 2026-02-09 8:30 [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling Arunpravin Paneer Selvam ` (5 preceding siblings ...) 2026-02-09 10:21 ` ✓ Xe.CI.FULL: " Patchwork @ 2026-02-10 16:26 ` Matthew Auld 2026-02-17 6:03 ` Arunpravin Paneer Selvam 6 siblings, 1 reply; 14+ messages in thread From: Matthew Auld @ 2026-02-10 16:26 UTC (permalink / raw) To: Arunpravin Paneer Selvam, christian.koenig, dri-devel, intel-gfx, intel-xe, amd-gfx Cc: alexander.deucher On 09/02/2026 08:30, Arunpravin Paneer Selvam wrote: > Large alignment requests previously forced the buddy allocator to search by > alignment order, which often caused higher-order free blocks to be split even > when a suitably aligned smaller region already existed within them. This led > to excessive fragmentation, especially for workloads requesting small sizes > with large alignment constraints. > > This change prioritizes the requested allocation size during the search and > uses an augmented RB-tree field (subtree_max_alignment) to efficiently locate > free blocks that satisfy both size and offset-alignment requirements. As a > result, the allocator can directly select an aligned sub-region without > splitting larger blocks unnecessarily. > > A practical example is the VKCTS test > dEQP-VK.memory.allocation.basic.size_8KiB.reverse.count_4000, which repeatedly > allocates 8 KiB buffers with a 256 KiB alignment. Previously, such allocations > caused large blocks to be split aggressively, despite smaller aligned regions > being sufficient. With this change, those aligned regions are reused directly, > significantly reducing fragmentation. > > This improvement is visible in the amdgpu VRAM buddy allocator state > (/sys/kernel/debug/dri/1/amdgpu_vram_mm). After the change, higher-order blocks > are preserved and the number of low-order fragments is substantially reduced. > > Before: > order- 5 free: 1936 MiB, blocks: 15490 > order- 4 free: 967 MiB, blocks: 15486 > order- 3 free: 483 MiB, blocks: 15485 > order- 2 free: 241 MiB, blocks: 15486 > order- 1 free: 241 MiB, blocks: 30948 > > After: > order- 5 free: 493 MiB, blocks: 3941 > order- 4 free: 246 MiB, blocks: 3943 > order- 3 free: 123 MiB, blocks: 4101 > order- 2 free: 61 MiB, blocks: 4101 > order- 1 free: 61 MiB, blocks: 8018 > > By avoiding unnecessary splits, this change improves allocator efficiency and > helps maintain larger contiguous free regions under heavy offset-aligned > allocation workloads. > > v2:(Matthew) > - Update augmented information along the path to the inserted node. > > v3: > - Move the patch to gpu/buddy.c file. > > Signed-off-by: Arunpravin Paneer Selvam <Arunpravin.PaneerSelvam@amd.com> > Suggested-by: Christian König <christian.koenig@amd.com> > --- > drivers/gpu/buddy.c | 271 +++++++++++++++++++++++++++++++------- > include/linux/gpu_buddy.h | 2 + > 2 files changed, 228 insertions(+), 45 deletions(-) > > diff --git a/drivers/gpu/buddy.c b/drivers/gpu/buddy.c > index 603c59a2013a..3a25eed050ba 100644 > --- a/drivers/gpu/buddy.c > +++ b/drivers/gpu/buddy.c > @@ -14,6 +14,16 @@ > > static struct kmem_cache *slab_blocks; > > +static unsigned int gpu_buddy_block_offset_alignment(struct gpu_buddy_block *block) > +{ > + return __ffs(gpu_buddy_block_offset(block)); __ffs() will be undefined for offset zero it seems, so might blow up in some strange way. I guess just return the max possible alignment here if offset is zero? Also are we meant to use __ffs64() here? > +} > + > +RB_DECLARE_CALLBACKS_MAX(static, gpu_buddy_augment_cb, > + struct gpu_buddy_block, rb, > + unsigned int, subtree_max_alignment, > + gpu_buddy_block_offset_alignment); > + > static struct gpu_buddy_block *gpu_block_alloc(struct gpu_buddy *mm, > struct gpu_buddy_block *parent, > unsigned int order, > @@ -31,6 +41,9 @@ static struct gpu_buddy_block *gpu_block_alloc(struct gpu_buddy *mm, > block->header |= order; > block->parent = parent; > > + block->subtree_max_alignment = > + gpu_buddy_block_offset_alignment(block); > + > RB_CLEAR_NODE(&block->rb); > > BUG_ON(block->header & GPU_BUDDY_HEADER_UNUSED); > @@ -67,26 +80,42 @@ static bool rbtree_is_empty(struct rb_root *root) > return RB_EMPTY_ROOT(root); > } > > -static bool gpu_buddy_block_offset_less(const struct gpu_buddy_block *block, > - const struct gpu_buddy_block *node) > -{ > - return gpu_buddy_block_offset(block) < gpu_buddy_block_offset(node); > -} > - > -static bool rbtree_block_offset_less(struct rb_node *block, > - const struct rb_node *node) > -{ > - return gpu_buddy_block_offset_less(rbtree_get_free_block(block), > - rbtree_get_free_block(node)); > -} > - > static void rbtree_insert(struct gpu_buddy *mm, > struct gpu_buddy_block *block, > enum gpu_buddy_free_tree tree) > { > - rb_add(&block->rb, > - &mm->free_trees[tree][gpu_buddy_block_order(block)], > - rbtree_block_offset_less); > + struct rb_node **link, *parent = NULL; > + unsigned int block_alignment, order; > + struct gpu_buddy_block *node; > + struct rb_root *root; > + > + order = gpu_buddy_block_order(block); > + block_alignment = gpu_buddy_block_offset_alignment(block); > + > + root = &mm->free_trees[tree][order]; > + link = &root->rb_node; > + > + while (*link) { > + parent = *link; > + node = rbtree_get_free_block(parent); > + /* > + * Manual augmentation update during insertion traversal. Required > + * because rb_insert_augmented() only calls rotate callback during > + * rotations. This ensures all ancestors on the insertion path have > + * correct subtree_max_alignment values. > + */ > + if (node->subtree_max_alignment < block_alignment) > + node->subtree_max_alignment = block_alignment; > + > + if (gpu_buddy_block_offset(block) < gpu_buddy_block_offset(node)) > + link = &parent->rb_left; > + else > + link = &parent->rb_right; > + } > + > + block->subtree_max_alignment = block_alignment; > + rb_link_node(&block->rb, parent, link); > + rb_insert_augmented(&block->rb, root, &gpu_buddy_augment_cb); > } > > static void rbtree_remove(struct gpu_buddy *mm, > @@ -99,7 +128,7 @@ static void rbtree_remove(struct gpu_buddy *mm, > tree = get_block_tree(block); > root = &mm->free_trees[tree][order]; > > - rb_erase(&block->rb, root); > + rb_erase_augmented(&block->rb, root, &gpu_buddy_augment_cb); > RB_CLEAR_NODE(&block->rb); > } > > @@ -790,6 +819,132 @@ alloc_from_freetree(struct gpu_buddy *mm, > return ERR_PTR(err); > } > > +static bool > +gpu_buddy_can_offset_align(u64 size, u64 min_block_size) > +{ > + return size < min_block_size && is_power_of_2(size); > +} > + > +static bool gpu_buddy_subtree_can_satisfy(struct rb_node *node, > + unsigned int alignment) > +{ > + struct gpu_buddy_block *block; > + > + if (!node) > + return false; All callers seem to handle null case already, so could potentially drop this? > + > + block = rbtree_get_free_block(node); > + return block->subtree_max_alignment >= alignment; > +} > + > +static struct gpu_buddy_block * > +gpu_buddy_find_block_aligned(struct gpu_buddy *mm, > + enum gpu_buddy_free_tree tree, > + unsigned int order, > + unsigned int tmp, > + unsigned int alignment, > + unsigned long flags) > +{ > + struct rb_root *root = &mm->free_trees[tree][tmp]; > + struct rb_node *rb = root->rb_node; > + > + while (rb) { > + struct gpu_buddy_block *block = rbtree_get_free_block(rb); > + struct rb_node *left_node = rb->rb_left, *right_node = rb->rb_right; > + > + if (right_node) { > + if (gpu_buddy_subtree_can_satisfy(right_node, alignment)) { > + rb = right_node; > + continue; > + } > + } > + > + if (gpu_buddy_block_order(block) >= order && Is this not always true? With that we can drop order, or better yet s/tmp/order/ ? > + __ffs(gpu_buddy_block_offset(block)) >= alignment) Same here with undefined offset zero case. I guess also use the helper. > + return block; > + > + if (left_node) { > + if (gpu_buddy_subtree_can_satisfy(left_node, alignment)) { > + rb = left_node; > + continue; > + } > + } > + > + break; > + } > + > + return NULL; > +} > + > +static struct gpu_buddy_block * > +gpu_buddy_offset_aligned_allocation(struct gpu_buddy *mm, > + u64 size, > + u64 min_block_size, > + unsigned long flags) > +{ > + struct gpu_buddy_block *block = NULL; > + unsigned int order, tmp, alignment; > + struct gpu_buddy_block *buddy; > + enum gpu_buddy_free_tree tree; > + unsigned long pages; > + int err; > + > + alignment = ilog2(min_block_size); > + pages = size >> ilog2(mm->chunk_size); > + order = fls(pages) - 1; > + > + tree = (flags & GPU_BUDDY_CLEAR_ALLOCATION) ? > + GPU_BUDDY_CLEAR_TREE : GPU_BUDDY_DIRTY_TREE; > + > + for (tmp = order; tmp <= mm->max_order; ++tmp) { > + block = gpu_buddy_find_block_aligned(mm, tree, order, > + tmp, alignment, flags); > + if (!block) { > + tree = (tree == GPU_BUDDY_CLEAR_TREE) ? > + GPU_BUDDY_DIRTY_TREE : GPU_BUDDY_CLEAR_TREE; > + block = gpu_buddy_find_block_aligned(mm, tree, order, > + tmp, alignment, flags); > + } > + > + if (block) > + break; > + } > + > + if (!block) > + return ERR_PTR(-ENOSPC); > + > + while (gpu_buddy_block_order(block) > order) { > + struct gpu_buddy_block *left, *right; > + > + err = split_block(mm, block); > + if (unlikely(err)) > + goto err_undo; > + > + left = block->left; > + right = block->right; > + > + if (__ffs(gpu_buddy_block_offset(right)) >= alignment) Might be better to use the helper for this? > + block = right; > + else > + block = left; > + } > + > + return block; > + > +err_undo: > + /* > + * We really don't want to leave around a bunch of split blocks, since > + * bigger is better, so make sure we merge everything back before we > + * free the allocated blocks. > + */ > + buddy = __get_buddy(block); > + if (buddy && > + (gpu_buddy_block_is_free(block) && > + gpu_buddy_block_is_free(buddy))) > + __gpu_buddy_free(mm, block, false); > + return ERR_PTR(err); > +} > + > static int __alloc_range(struct gpu_buddy *mm, > struct list_head *dfs, > u64 start, u64 size, > @@ -1059,6 +1214,7 @@ EXPORT_SYMBOL(gpu_buddy_block_trim); > static struct gpu_buddy_block * > __gpu_buddy_alloc_blocks(struct gpu_buddy *mm, > u64 start, u64 end, > + u64 size, u64 min_block_size, > unsigned int order, > unsigned long flags) > { > @@ -1066,6 +1222,11 @@ __gpu_buddy_alloc_blocks(struct gpu_buddy *mm, > /* Allocate traversing within the range */ > return __gpu_buddy_alloc_range_bias(mm, start, end, > order, flags); > + else if (size < min_block_size) > + /* Allocate from an offset-aligned region without size rounding */ > + return gpu_buddy_offset_aligned_allocation(mm, size, > + min_block_size, > + flags); > else > /* Allocate from freetree */ > return alloc_from_freetree(mm, order, flags); > @@ -1137,8 +1298,11 @@ int gpu_buddy_alloc_blocks(struct gpu_buddy *mm, > if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION) { > size = roundup_pow_of_two(size); > min_block_size = size; > - /* Align size value to min_block_size */ > - } else if (!IS_ALIGNED(size, min_block_size)) { > + /* > + * Normalize the requested size to min_block_size for regular allocations. > + * Offset-aligned allocations intentionally skip size rounding. > + */ > + } else if (!gpu_buddy_can_offset_align(size, min_block_size)) { > size = round_up(size, min_block_size); > } > > @@ -1158,43 +1322,60 @@ int gpu_buddy_alloc_blocks(struct gpu_buddy *mm, > do { > order = min(order, (unsigned int)fls(pages) - 1); > BUG_ON(order > mm->max_order); > - BUG_ON(order < min_order); > + /* > + * Regular allocations must not allocate blocks smaller than min_block_size. > + * Offset-aligned allocations deliberately bypass this constraint. > + */ > + BUG_ON(size >= min_block_size && order < min_order); > > do { > + unsigned int fallback_order; > + > block = __gpu_buddy_alloc_blocks(mm, start, > end, > + size, > + min_block_size, > order, > flags); > if (!IS_ERR(block)) > break; > > - if (order-- == min_order) { > - /* Try allocation through force merge method */ > - if (mm->clear_avail && > - !__force_merge(mm, start, end, min_order)) { > - block = __gpu_buddy_alloc_blocks(mm, start, > - end, > - min_order, > - flags); > - if (!IS_ERR(block)) { > - order = min_order; > - break; > - } > - } > + if (size < min_block_size) { > + fallback_order = order; > + } else if (order == min_order) { > + fallback_order = min_order; > + } else { > + order--; > + continue; > + } > > - /* > - * Try contiguous block allocation through > - * try harder method. > - */ > - if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION && > - !(flags & GPU_BUDDY_RANGE_ALLOCATION)) > - return __alloc_contig_try_harder(mm, > - original_size, > - original_min_size, > - blocks); > - err = -ENOSPC; > - goto err_free; > + /* Try allocation through force merge method */ > + if (mm->clear_avail && > + !__force_merge(mm, start, end, fallback_order)) { > + block = __gpu_buddy_alloc_blocks(mm, start, > + end, > + size, > + min_block_size, > + fallback_order, > + flags); > + if (!IS_ERR(block)) { > + order = fallback_order; > + break; > + } > } > + > + /* > + * Try contiguous block allocation through > + * try harder method. > + */ > + if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION && > + !(flags & GPU_BUDDY_RANGE_ALLOCATION)) > + return __alloc_contig_try_harder(mm, > + original_size, > + original_min_size, > + blocks); > + err = -ENOSPC; > + goto err_free; > } while (1); > > mark_allocated(mm, block); > diff --git a/include/linux/gpu_buddy.h b/include/linux/gpu_buddy.h > index 07ac65db6d2e..7ad817c69ec6 100644 > --- a/include/linux/gpu_buddy.h > +++ b/include/linux/gpu_buddy.h > @@ -11,6 +11,7 @@ > #include <linux/slab.h> > #include <linux/sched.h> > #include <linux/rbtree.h> > +#include <linux/rbtree_augmented.h> > > #define GPU_BUDDY_RANGE_ALLOCATION BIT(0) > #define GPU_BUDDY_TOPDOWN_ALLOCATION BIT(1) > @@ -58,6 +59,7 @@ struct gpu_buddy_block { > }; > > struct list_head tmp_link; > + unsigned int subtree_max_alignment; > }; > > /* Order-zero must be at least SZ_4K */ > > base-commit: 9d757669b2b22cd224c334924f798393ffca537c ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling 2026-02-10 16:26 ` [PATCH v3 1/2] " Matthew Auld @ 2026-02-17 6:03 ` Arunpravin Paneer Selvam 2026-02-17 10:01 ` Matthew Auld 0 siblings, 1 reply; 14+ messages in thread From: Arunpravin Paneer Selvam @ 2026-02-17 6:03 UTC (permalink / raw) To: Matthew Auld, christian.koenig, dri-devel, intel-gfx, intel-xe, amd-gfx Cc: alexander.deucher Hi Matthew, On 2/10/2026 9:56 PM, Matthew Auld wrote: > On 09/02/2026 08:30, Arunpravin Paneer Selvam wrote: >> Large alignment requests previously forced the buddy allocator to >> search by >> alignment order, which often caused higher-order free blocks to be >> split even >> when a suitably aligned smaller region already existed within them. >> This led >> to excessive fragmentation, especially for workloads requesting small >> sizes >> with large alignment constraints. >> >> This change prioritizes the requested allocation size during the >> search and >> uses an augmented RB-tree field (subtree_max_alignment) to >> efficiently locate >> free blocks that satisfy both size and offset-alignment requirements. >> As a >> result, the allocator can directly select an aligned sub-region without >> splitting larger blocks unnecessarily. >> >> A practical example is the VKCTS test >> dEQP-VK.memory.allocation.basic.size_8KiB.reverse.count_4000, which >> repeatedly >> allocates 8 KiB buffers with a 256 KiB alignment. Previously, such >> allocations >> caused large blocks to be split aggressively, despite smaller aligned >> regions >> being sufficient. With this change, those aligned regions are reused >> directly, >> significantly reducing fragmentation. >> >> This improvement is visible in the amdgpu VRAM buddy allocator state >> (/sys/kernel/debug/dri/1/amdgpu_vram_mm). After the change, >> higher-order blocks >> are preserved and the number of low-order fragments is substantially >> reduced. >> >> Before: >> order- 5 free: 1936 MiB, blocks: 15490 >> order- 4 free: 967 MiB, blocks: 15486 >> order- 3 free: 483 MiB, blocks: 15485 >> order- 2 free: 241 MiB, blocks: 15486 >> order- 1 free: 241 MiB, blocks: 30948 >> >> After: >> order- 5 free: 493 MiB, blocks: 3941 >> order- 4 free: 246 MiB, blocks: 3943 >> order- 3 free: 123 MiB, blocks: 4101 >> order- 2 free: 61 MiB, blocks: 4101 >> order- 1 free: 61 MiB, blocks: 8018 >> >> By avoiding unnecessary splits, this change improves allocator >> efficiency and >> helps maintain larger contiguous free regions under heavy offset-aligned >> allocation workloads. >> >> v2:(Matthew) >> - Update augmented information along the path to the inserted node. >> >> v3: >> - Move the patch to gpu/buddy.c file. >> >> Signed-off-by: Arunpravin Paneer Selvam >> <Arunpravin.PaneerSelvam@amd.com> >> Suggested-by: Christian König <christian.koenig@amd.com> >> --- >> drivers/gpu/buddy.c | 271 +++++++++++++++++++++++++++++++------- >> include/linux/gpu_buddy.h | 2 + >> 2 files changed, 228 insertions(+), 45 deletions(-) >> >> diff --git a/drivers/gpu/buddy.c b/drivers/gpu/buddy.c >> index 603c59a2013a..3a25eed050ba 100644 >> --- a/drivers/gpu/buddy.c >> +++ b/drivers/gpu/buddy.c >> @@ -14,6 +14,16 @@ >> static struct kmem_cache *slab_blocks; >> +static unsigned int gpu_buddy_block_offset_alignment(struct >> gpu_buddy_block *block) >> +{ >> + return __ffs(gpu_buddy_block_offset(block)); > > __ffs() will be undefined for offset zero it seems, so might blow up > in some strange way. I guess just return the max possible alignment > here if offset is zero? Also are we meant to use __ffs64() here? Yes, I had the same concern about __ffs() being undefined when the offset is zero. My initial thought was to derive the maximum possible alignment from the allocator size using ilog2(mm->size) and return that value for the zero-offset case. But, RB_DECLARE_CALLBACKS_MAX() requires the compute callback (gpu_buddy_block_offset_alignment()) to accept only a single struct gpu_buddy_block * argument. It does not provide a mechanism to pass additional context such as the associated struct gpu_buddy *mm. As a result, deriving the alignment from allocator state (e.g., via ilog2(mm->size)) is not directly feasible within this callback. When I tested the zero-offset case locally, __ffs() returned 64, which effectively corresponds to the maximum alignment for a u64 offset. Based on that observation, I initially left the __ffs() call unchanged for the zero case as well. One possible alternative would be to store a pointer to struct gpu_buddy inside each gpu_buddy_block. All other review comments have been addressed, and I will send a v4 once this point is clarified. Regards, Arun. > >> +} >> + >> +RB_DECLARE_CALLBACKS_MAX(static, gpu_buddy_augment_cb, >> + struct gpu_buddy_block, rb, >> + unsigned int, subtree_max_alignment, >> + gpu_buddy_block_offset_alignment); >> + >> static struct gpu_buddy_block *gpu_block_alloc(struct gpu_buddy *mm, >> struct gpu_buddy_block *parent, >> unsigned int order, >> @@ -31,6 +41,9 @@ static struct gpu_buddy_block >> *gpu_block_alloc(struct gpu_buddy *mm, >> block->header |= order; >> block->parent = parent; >> + block->subtree_max_alignment = >> + gpu_buddy_block_offset_alignment(block); >> + >> RB_CLEAR_NODE(&block->rb); >> BUG_ON(block->header & GPU_BUDDY_HEADER_UNUSED); >> @@ -67,26 +80,42 @@ static bool rbtree_is_empty(struct rb_root *root) >> return RB_EMPTY_ROOT(root); >> } >> -static bool gpu_buddy_block_offset_less(const struct >> gpu_buddy_block *block, >> - const struct gpu_buddy_block *node) >> -{ >> - return gpu_buddy_block_offset(block) < >> gpu_buddy_block_offset(node); >> -} >> - >> -static bool rbtree_block_offset_less(struct rb_node *block, >> - const struct rb_node *node) >> -{ >> - return gpu_buddy_block_offset_less(rbtree_get_free_block(block), >> - rbtree_get_free_block(node)); >> -} >> - >> static void rbtree_insert(struct gpu_buddy *mm, >> struct gpu_buddy_block *block, >> enum gpu_buddy_free_tree tree) >> { >> - rb_add(&block->rb, >> - &mm->free_trees[tree][gpu_buddy_block_order(block)], >> - rbtree_block_offset_less); >> + struct rb_node **link, *parent = NULL; >> + unsigned int block_alignment, order; >> + struct gpu_buddy_block *node; >> + struct rb_root *root; >> + >> + order = gpu_buddy_block_order(block); >> + block_alignment = gpu_buddy_block_offset_alignment(block); >> + >> + root = &mm->free_trees[tree][order]; >> + link = &root->rb_node; >> + >> + while (*link) { >> + parent = *link; >> + node = rbtree_get_free_block(parent); >> + /* >> + * Manual augmentation update during insertion traversal. >> Required >> + * because rb_insert_augmented() only calls rotate callback >> during >> + * rotations. This ensures all ancestors on the insertion >> path have >> + * correct subtree_max_alignment values. >> + */ >> + if (node->subtree_max_alignment < block_alignment) >> + node->subtree_max_alignment = block_alignment; >> + >> + if (gpu_buddy_block_offset(block) < >> gpu_buddy_block_offset(node)) >> + link = &parent->rb_left; >> + else >> + link = &parent->rb_right; >> + } >> + >> + block->subtree_max_alignment = block_alignment; >> + rb_link_node(&block->rb, parent, link); >> + rb_insert_augmented(&block->rb, root, &gpu_buddy_augment_cb); >> } >> static void rbtree_remove(struct gpu_buddy *mm, >> @@ -99,7 +128,7 @@ static void rbtree_remove(struct gpu_buddy *mm, >> tree = get_block_tree(block); >> root = &mm->free_trees[tree][order]; >> - rb_erase(&block->rb, root); >> + rb_erase_augmented(&block->rb, root, &gpu_buddy_augment_cb); >> RB_CLEAR_NODE(&block->rb); >> } >> @@ -790,6 +819,132 @@ alloc_from_freetree(struct gpu_buddy *mm, >> return ERR_PTR(err); >> } >> +static bool >> +gpu_buddy_can_offset_align(u64 size, u64 min_block_size) >> +{ >> + return size < min_block_size && is_power_of_2(size); >> +} >> + >> +static bool gpu_buddy_subtree_can_satisfy(struct rb_node *node, >> + unsigned int alignment) >> +{ >> + struct gpu_buddy_block *block; >> + >> + if (!node) >> + return false; > > All callers seem to handle null case already, so could potentially > drop this? > >> + >> + block = rbtree_get_free_block(node); >> + return block->subtree_max_alignment >= alignment; >> +} >> + >> +static struct gpu_buddy_block * >> +gpu_buddy_find_block_aligned(struct gpu_buddy *mm, >> + enum gpu_buddy_free_tree tree, >> + unsigned int order, >> + unsigned int tmp, >> + unsigned int alignment, >> + unsigned long flags) >> +{ >> + struct rb_root *root = &mm->free_trees[tree][tmp]; >> + struct rb_node *rb = root->rb_node; >> + >> + while (rb) { >> + struct gpu_buddy_block *block = rbtree_get_free_block(rb); >> + struct rb_node *left_node = rb->rb_left, *right_node = >> rb->rb_right; >> + >> + if (right_node) { >> + if (gpu_buddy_subtree_can_satisfy(right_node, alignment)) { >> + rb = right_node; >> + continue; >> + } >> + } >> + >> + if (gpu_buddy_block_order(block) >= order && > > Is this not always true? With that we can drop order, or better yet > s/tmp/order/ ? > >> + __ffs(gpu_buddy_block_offset(block)) >= alignment) > > Same here with undefined offset zero case. I guess also use the helper. > >> + return block; >> + >> + if (left_node) { >> + if (gpu_buddy_subtree_can_satisfy(left_node, alignment)) { >> + rb = left_node; >> + continue; >> + } >> + } >> + >> + break; >> + } >> + >> + return NULL; >> +} >> + >> +static struct gpu_buddy_block * >> +gpu_buddy_offset_aligned_allocation(struct gpu_buddy *mm, >> + u64 size, >> + u64 min_block_size, >> + unsigned long flags) >> +{ >> + struct gpu_buddy_block *block = NULL; >> + unsigned int order, tmp, alignment; >> + struct gpu_buddy_block *buddy; >> + enum gpu_buddy_free_tree tree; >> + unsigned long pages; >> + int err; >> + >> + alignment = ilog2(min_block_size); >> + pages = size >> ilog2(mm->chunk_size); >> + order = fls(pages) - 1; >> + >> + tree = (flags & GPU_BUDDY_CLEAR_ALLOCATION) ? >> + GPU_BUDDY_CLEAR_TREE : GPU_BUDDY_DIRTY_TREE; >> + >> + for (tmp = order; tmp <= mm->max_order; ++tmp) { >> + block = gpu_buddy_find_block_aligned(mm, tree, order, >> + tmp, alignment, flags); >> + if (!block) { >> + tree = (tree == GPU_BUDDY_CLEAR_TREE) ? >> + GPU_BUDDY_DIRTY_TREE : GPU_BUDDY_CLEAR_TREE; >> + block = gpu_buddy_find_block_aligned(mm, tree, order, >> + tmp, alignment, flags); >> + } >> + >> + if (block) >> + break; >> + } >> + >> + if (!block) >> + return ERR_PTR(-ENOSPC); >> + >> + while (gpu_buddy_block_order(block) > order) { >> + struct gpu_buddy_block *left, *right; >> + >> + err = split_block(mm, block); >> + if (unlikely(err)) >> + goto err_undo; >> + >> + left = block->left; >> + right = block->right; >> + >> + if (__ffs(gpu_buddy_block_offset(right)) >= alignment) > > Might be better to use the helper for this? > >> + block = right; >> + else >> + block = left; >> + } >> + >> + return block; >> + >> +err_undo: >> + /* >> + * We really don't want to leave around a bunch of split blocks, >> since >> + * bigger is better, so make sure we merge everything back >> before we >> + * free the allocated blocks. >> + */ >> + buddy = __get_buddy(block); >> + if (buddy && >> + (gpu_buddy_block_is_free(block) && >> + gpu_buddy_block_is_free(buddy))) >> + __gpu_buddy_free(mm, block, false); >> + return ERR_PTR(err); >> +} >> + >> static int __alloc_range(struct gpu_buddy *mm, >> struct list_head *dfs, >> u64 start, u64 size, >> @@ -1059,6 +1214,7 @@ EXPORT_SYMBOL(gpu_buddy_block_trim); >> static struct gpu_buddy_block * >> __gpu_buddy_alloc_blocks(struct gpu_buddy *mm, >> u64 start, u64 end, >> + u64 size, u64 min_block_size, >> unsigned int order, >> unsigned long flags) >> { >> @@ -1066,6 +1222,11 @@ __gpu_buddy_alloc_blocks(struct gpu_buddy *mm, >> /* Allocate traversing within the range */ >> return __gpu_buddy_alloc_range_bias(mm, start, end, >> order, flags); >> + else if (size < min_block_size) >> + /* Allocate from an offset-aligned region without size >> rounding */ >> + return gpu_buddy_offset_aligned_allocation(mm, size, >> + min_block_size, >> + flags); >> else >> /* Allocate from freetree */ >> return alloc_from_freetree(mm, order, flags); >> @@ -1137,8 +1298,11 @@ int gpu_buddy_alloc_blocks(struct gpu_buddy *mm, >> if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION) { >> size = roundup_pow_of_two(size); >> min_block_size = size; >> - /* Align size value to min_block_size */ >> - } else if (!IS_ALIGNED(size, min_block_size)) { >> + /* >> + * Normalize the requested size to min_block_size for >> regular allocations. >> + * Offset-aligned allocations intentionally skip size rounding. >> + */ >> + } else if (!gpu_buddy_can_offset_align(size, min_block_size)) { >> size = round_up(size, min_block_size); >> } >> @@ -1158,43 +1322,60 @@ int gpu_buddy_alloc_blocks(struct gpu_buddy >> *mm, >> do { >> order = min(order, (unsigned int)fls(pages) - 1); >> BUG_ON(order > mm->max_order); >> - BUG_ON(order < min_order); >> + /* >> + * Regular allocations must not allocate blocks smaller than >> min_block_size. >> + * Offset-aligned allocations deliberately bypass this >> constraint. >> + */ >> + BUG_ON(size >= min_block_size && order < min_order); >> do { >> + unsigned int fallback_order; >> + >> block = __gpu_buddy_alloc_blocks(mm, start, >> end, >> + size, >> + min_block_size, >> order, >> flags); >> if (!IS_ERR(block)) >> break; >> - if (order-- == min_order) { >> - /* Try allocation through force merge method */ >> - if (mm->clear_avail && >> - !__force_merge(mm, start, end, min_order)) { >> - block = __gpu_buddy_alloc_blocks(mm, start, >> - end, >> - min_order, >> - flags); >> - if (!IS_ERR(block)) { >> - order = min_order; >> - break; >> - } >> - } >> + if (size < min_block_size) { >> + fallback_order = order; >> + } else if (order == min_order) { >> + fallback_order = min_order; >> + } else { >> + order--; >> + continue; >> + } >> - /* >> - * Try contiguous block allocation through >> - * try harder method. >> - */ >> - if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION && >> - !(flags & GPU_BUDDY_RANGE_ALLOCATION)) >> - return __alloc_contig_try_harder(mm, >> - original_size, >> - original_min_size, >> - blocks); >> - err = -ENOSPC; >> - goto err_free; >> + /* Try allocation through force merge method */ >> + if (mm->clear_avail && >> + !__force_merge(mm, start, end, fallback_order)) { >> + block = __gpu_buddy_alloc_blocks(mm, start, >> + end, >> + size, >> + min_block_size, >> + fallback_order, >> + flags); >> + if (!IS_ERR(block)) { >> + order = fallback_order; >> + break; >> + } >> } >> + >> + /* >> + * Try contiguous block allocation through >> + * try harder method. >> + */ >> + if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION && >> + !(flags & GPU_BUDDY_RANGE_ALLOCATION)) >> + return __alloc_contig_try_harder(mm, >> + original_size, >> + original_min_size, >> + blocks); >> + err = -ENOSPC; >> + goto err_free; >> } while (1); >> mark_allocated(mm, block); >> diff --git a/include/linux/gpu_buddy.h b/include/linux/gpu_buddy.h >> index 07ac65db6d2e..7ad817c69ec6 100644 >> --- a/include/linux/gpu_buddy.h >> +++ b/include/linux/gpu_buddy.h >> @@ -11,6 +11,7 @@ >> #include <linux/slab.h> >> #include <linux/sched.h> >> #include <linux/rbtree.h> >> +#include <linux/rbtree_augmented.h> >> #define GPU_BUDDY_RANGE_ALLOCATION BIT(0) >> #define GPU_BUDDY_TOPDOWN_ALLOCATION BIT(1) >> @@ -58,6 +59,7 @@ struct gpu_buddy_block { >> }; >> struct list_head tmp_link; >> + unsigned int subtree_max_alignment; >> }; >> /* Order-zero must be at least SZ_4K */ >> >> base-commit: 9d757669b2b22cd224c334924f798393ffca537c > ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling 2026-02-17 6:03 ` Arunpravin Paneer Selvam @ 2026-02-17 10:01 ` Matthew Auld 2026-02-17 10:16 ` Arunpravin Paneer Selvam 0 siblings, 1 reply; 14+ messages in thread From: Matthew Auld @ 2026-02-17 10:01 UTC (permalink / raw) To: Arunpravin Paneer Selvam, christian.koenig, dri-devel, intel-gfx, intel-xe, amd-gfx Cc: alexander.deucher On 17/02/2026 06:03, Arunpravin Paneer Selvam wrote: > Hi Matthew, > > On 2/10/2026 9:56 PM, Matthew Auld wrote: >> On 09/02/2026 08:30, Arunpravin Paneer Selvam wrote: >>> Large alignment requests previously forced the buddy allocator to >>> search by >>> alignment order, which often caused higher-order free blocks to be >>> split even >>> when a suitably aligned smaller region already existed within them. >>> This led >>> to excessive fragmentation, especially for workloads requesting small >>> sizes >>> with large alignment constraints. >>> >>> This change prioritizes the requested allocation size during the >>> search and >>> uses an augmented RB-tree field (subtree_max_alignment) to >>> efficiently locate >>> free blocks that satisfy both size and offset-alignment requirements. >>> As a >>> result, the allocator can directly select an aligned sub-region without >>> splitting larger blocks unnecessarily. >>> >>> A practical example is the VKCTS test >>> dEQP-VK.memory.allocation.basic.size_8KiB.reverse.count_4000, which >>> repeatedly >>> allocates 8 KiB buffers with a 256 KiB alignment. Previously, such >>> allocations >>> caused large blocks to be split aggressively, despite smaller aligned >>> regions >>> being sufficient. With this change, those aligned regions are reused >>> directly, >>> significantly reducing fragmentation. >>> >>> This improvement is visible in the amdgpu VRAM buddy allocator state >>> (/sys/kernel/debug/dri/1/amdgpu_vram_mm). After the change, higher- >>> order blocks >>> are preserved and the number of low-order fragments is substantially >>> reduced. >>> >>> Before: >>> order- 5 free: 1936 MiB, blocks: 15490 >>> order- 4 free: 967 MiB, blocks: 15486 >>> order- 3 free: 483 MiB, blocks: 15485 >>> order- 2 free: 241 MiB, blocks: 15486 >>> order- 1 free: 241 MiB, blocks: 30948 >>> >>> After: >>> order- 5 free: 493 MiB, blocks: 3941 >>> order- 4 free: 246 MiB, blocks: 3943 >>> order- 3 free: 123 MiB, blocks: 4101 >>> order- 2 free: 61 MiB, blocks: 4101 >>> order- 1 free: 61 MiB, blocks: 8018 >>> >>> By avoiding unnecessary splits, this change improves allocator >>> efficiency and >>> helps maintain larger contiguous free regions under heavy offset-aligned >>> allocation workloads. >>> >>> v2:(Matthew) >>> - Update augmented information along the path to the inserted node. >>> >>> v3: >>> - Move the patch to gpu/buddy.c file. >>> >>> Signed-off-by: Arunpravin Paneer Selvam >>> <Arunpravin.PaneerSelvam@amd.com> >>> Suggested-by: Christian König <christian.koenig@amd.com> >>> --- >>> drivers/gpu/buddy.c | 271 +++++++++++++++++++++++++++++++------- >>> include/linux/gpu_buddy.h | 2 + >>> 2 files changed, 228 insertions(+), 45 deletions(-) >>> >>> diff --git a/drivers/gpu/buddy.c b/drivers/gpu/buddy.c >>> index 603c59a2013a..3a25eed050ba 100644 >>> --- a/drivers/gpu/buddy.c >>> +++ b/drivers/gpu/buddy.c >>> @@ -14,6 +14,16 @@ >>> static struct kmem_cache *slab_blocks; >>> +static unsigned int gpu_buddy_block_offset_alignment(struct >>> gpu_buddy_block *block) >>> +{ >>> + return __ffs(gpu_buddy_block_offset(block)); >> >> __ffs() will be undefined for offset zero it seems, so might blow up >> in some strange way. I guess just return the max possible alignment >> here if offset is zero? Also are we meant to use __ffs64() here? > Yes, I had the same concern about __ffs() being undefined when the > offset is zero. My initial thought was to derive the maximum possible > alignment from the allocator size using ilog2(mm->size) and return that > value for the zero-offset case. > > But, RB_DECLARE_CALLBACKS_MAX() requires the compute callback > (gpu_buddy_block_offset_alignment()) to accept only a single struct > gpu_buddy_block * argument. It does not provide a mechanism to pass > additional context such as the associated struct gpu_buddy *mm. As a > result, deriving the alignment from allocator state (e.g., via ilog2(mm- > >size)) is not directly feasible within this callback. When I tested > the zero-offset case locally, __ffs() returned 64, which effectively > corresponds to the maximum alignment for a u64 offset. Based on that > observation, I initially left the __ffs() call unchanged for the zero > case as well. > > One possible alternative would be to store a pointer to struct gpu_buddy > inside each gpu_buddy_block. > > All other review comments have been addressed, and I will send a v4 once > this point is clarified. Yeah, I was thinking we just return the max theoretical value, so 64, or perhaps 64+1. It just needs to be a value that will be larger than any other possible alignment, since zero is special. It shouldn't matter if that is larger than the actual real max for the region, I think. if (!offset) return 64 + 1; return __ffs64(offset); ? > > Regards, > Arun. >> >>> +} >>> + >>> +RB_DECLARE_CALLBACKS_MAX(static, gpu_buddy_augment_cb, >>> + struct gpu_buddy_block, rb, >>> + unsigned int, subtree_max_alignment, >>> + gpu_buddy_block_offset_alignment); >>> + >>> static struct gpu_buddy_block *gpu_block_alloc(struct gpu_buddy *mm, >>> struct gpu_buddy_block *parent, >>> unsigned int order, >>> @@ -31,6 +41,9 @@ static struct gpu_buddy_block >>> *gpu_block_alloc(struct gpu_buddy *mm, >>> block->header |= order; >>> block->parent = parent; >>> + block->subtree_max_alignment = >>> + gpu_buddy_block_offset_alignment(block); >>> + >>> RB_CLEAR_NODE(&block->rb); >>> BUG_ON(block->header & GPU_BUDDY_HEADER_UNUSED); >>> @@ -67,26 +80,42 @@ static bool rbtree_is_empty(struct rb_root *root) >>> return RB_EMPTY_ROOT(root); >>> } >>> -static bool gpu_buddy_block_offset_less(const struct >>> gpu_buddy_block *block, >>> - const struct gpu_buddy_block *node) >>> -{ >>> - return gpu_buddy_block_offset(block) < >>> gpu_buddy_block_offset(node); >>> -} >>> - >>> -static bool rbtree_block_offset_less(struct rb_node *block, >>> - const struct rb_node *node) >>> -{ >>> - return gpu_buddy_block_offset_less(rbtree_get_free_block(block), >>> - rbtree_get_free_block(node)); >>> -} >>> - >>> static void rbtree_insert(struct gpu_buddy *mm, >>> struct gpu_buddy_block *block, >>> enum gpu_buddy_free_tree tree) >>> { >>> - rb_add(&block->rb, >>> - &mm->free_trees[tree][gpu_buddy_block_order(block)], >>> - rbtree_block_offset_less); >>> + struct rb_node **link, *parent = NULL; >>> + unsigned int block_alignment, order; >>> + struct gpu_buddy_block *node; >>> + struct rb_root *root; >>> + >>> + order = gpu_buddy_block_order(block); >>> + block_alignment = gpu_buddy_block_offset_alignment(block); >>> + >>> + root = &mm->free_trees[tree][order]; >>> + link = &root->rb_node; >>> + >>> + while (*link) { >>> + parent = *link; >>> + node = rbtree_get_free_block(parent); >>> + /* >>> + * Manual augmentation update during insertion traversal. >>> Required >>> + * because rb_insert_augmented() only calls rotate callback >>> during >>> + * rotations. This ensures all ancestors on the insertion >>> path have >>> + * correct subtree_max_alignment values. >>> + */ >>> + if (node->subtree_max_alignment < block_alignment) >>> + node->subtree_max_alignment = block_alignment; >>> + >>> + if (gpu_buddy_block_offset(block) < >>> gpu_buddy_block_offset(node)) >>> + link = &parent->rb_left; >>> + else >>> + link = &parent->rb_right; >>> + } >>> + >>> + block->subtree_max_alignment = block_alignment; >>> + rb_link_node(&block->rb, parent, link); >>> + rb_insert_augmented(&block->rb, root, &gpu_buddy_augment_cb); >>> } >>> static void rbtree_remove(struct gpu_buddy *mm, >>> @@ -99,7 +128,7 @@ static void rbtree_remove(struct gpu_buddy *mm, >>> tree = get_block_tree(block); >>> root = &mm->free_trees[tree][order]; >>> - rb_erase(&block->rb, root); >>> + rb_erase_augmented(&block->rb, root, &gpu_buddy_augment_cb); >>> RB_CLEAR_NODE(&block->rb); >>> } >>> @@ -790,6 +819,132 @@ alloc_from_freetree(struct gpu_buddy *mm, >>> return ERR_PTR(err); >>> } >>> +static bool >>> +gpu_buddy_can_offset_align(u64 size, u64 min_block_size) >>> +{ >>> + return size < min_block_size && is_power_of_2(size); >>> +} >>> + >>> +static bool gpu_buddy_subtree_can_satisfy(struct rb_node *node, >>> + unsigned int alignment) >>> +{ >>> + struct gpu_buddy_block *block; >>> + >>> + if (!node) >>> + return false; >> >> All callers seem to handle null case already, so could potentially >> drop this? >> >>> + >>> + block = rbtree_get_free_block(node); >>> + return block->subtree_max_alignment >= alignment; >>> +} >>> + >>> +static struct gpu_buddy_block * >>> +gpu_buddy_find_block_aligned(struct gpu_buddy *mm, >>> + enum gpu_buddy_free_tree tree, >>> + unsigned int order, >>> + unsigned int tmp, >>> + unsigned int alignment, >>> + unsigned long flags) >>> +{ >>> + struct rb_root *root = &mm->free_trees[tree][tmp]; >>> + struct rb_node *rb = root->rb_node; >>> + >>> + while (rb) { >>> + struct gpu_buddy_block *block = rbtree_get_free_block(rb); >>> + struct rb_node *left_node = rb->rb_left, *right_node = rb- >>> >rb_right; >>> + >>> + if (right_node) { >>> + if (gpu_buddy_subtree_can_satisfy(right_node, alignment)) { >>> + rb = right_node; >>> + continue; >>> + } >>> + } >>> + >>> + if (gpu_buddy_block_order(block) >= order && >> >> Is this not always true? With that we can drop order, or better yet s/ >> tmp/order/ ? >> >>> + __ffs(gpu_buddy_block_offset(block)) >= alignment) >> >> Same here with undefined offset zero case. I guess also use the helper. >> >>> + return block; >>> + >>> + if (left_node) { >>> + if (gpu_buddy_subtree_can_satisfy(left_node, alignment)) { >>> + rb = left_node; >>> + continue; >>> + } >>> + } >>> + >>> + break; >>> + } >>> + >>> + return NULL; >>> +} >>> + >>> +static struct gpu_buddy_block * >>> +gpu_buddy_offset_aligned_allocation(struct gpu_buddy *mm, >>> + u64 size, >>> + u64 min_block_size, >>> + unsigned long flags) >>> +{ >>> + struct gpu_buddy_block *block = NULL; >>> + unsigned int order, tmp, alignment; >>> + struct gpu_buddy_block *buddy; >>> + enum gpu_buddy_free_tree tree; >>> + unsigned long pages; >>> + int err; >>> + >>> + alignment = ilog2(min_block_size); >>> + pages = size >> ilog2(mm->chunk_size); >>> + order = fls(pages) - 1; >>> + >>> + tree = (flags & GPU_BUDDY_CLEAR_ALLOCATION) ? >>> + GPU_BUDDY_CLEAR_TREE : GPU_BUDDY_DIRTY_TREE; >>> + >>> + for (tmp = order; tmp <= mm->max_order; ++tmp) { >>> + block = gpu_buddy_find_block_aligned(mm, tree, order, >>> + tmp, alignment, flags); >>> + if (!block) { >>> + tree = (tree == GPU_BUDDY_CLEAR_TREE) ? >>> + GPU_BUDDY_DIRTY_TREE : GPU_BUDDY_CLEAR_TREE; >>> + block = gpu_buddy_find_block_aligned(mm, tree, order, >>> + tmp, alignment, flags); >>> + } >>> + >>> + if (block) >>> + break; >>> + } >>> + >>> + if (!block) >>> + return ERR_PTR(-ENOSPC); >>> + >>> + while (gpu_buddy_block_order(block) > order) { >>> + struct gpu_buddy_block *left, *right; >>> + >>> + err = split_block(mm, block); >>> + if (unlikely(err)) >>> + goto err_undo; >>> + >>> + left = block->left; >>> + right = block->right; >>> + >>> + if (__ffs(gpu_buddy_block_offset(right)) >= alignment) >> >> Might be better to use the helper for this? >> >>> + block = right; >>> + else >>> + block = left; >>> + } >>> + >>> + return block; >>> + >>> +err_undo: >>> + /* >>> + * We really don't want to leave around a bunch of split blocks, >>> since >>> + * bigger is better, so make sure we merge everything back >>> before we >>> + * free the allocated blocks. >>> + */ >>> + buddy = __get_buddy(block); >>> + if (buddy && >>> + (gpu_buddy_block_is_free(block) && >>> + gpu_buddy_block_is_free(buddy))) >>> + __gpu_buddy_free(mm, block, false); >>> + return ERR_PTR(err); >>> +} >>> + >>> static int __alloc_range(struct gpu_buddy *mm, >>> struct list_head *dfs, >>> u64 start, u64 size, >>> @@ -1059,6 +1214,7 @@ EXPORT_SYMBOL(gpu_buddy_block_trim); >>> static struct gpu_buddy_block * >>> __gpu_buddy_alloc_blocks(struct gpu_buddy *mm, >>> u64 start, u64 end, >>> + u64 size, u64 min_block_size, >>> unsigned int order, >>> unsigned long flags) >>> { >>> @@ -1066,6 +1222,11 @@ __gpu_buddy_alloc_blocks(struct gpu_buddy *mm, >>> /* Allocate traversing within the range */ >>> return __gpu_buddy_alloc_range_bias(mm, start, end, >>> order, flags); >>> + else if (size < min_block_size) >>> + /* Allocate from an offset-aligned region without size >>> rounding */ >>> + return gpu_buddy_offset_aligned_allocation(mm, size, >>> + min_block_size, >>> + flags); >>> else >>> /* Allocate from freetree */ >>> return alloc_from_freetree(mm, order, flags); >>> @@ -1137,8 +1298,11 @@ int gpu_buddy_alloc_blocks(struct gpu_buddy *mm, >>> if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION) { >>> size = roundup_pow_of_two(size); >>> min_block_size = size; >>> - /* Align size value to min_block_size */ >>> - } else if (!IS_ALIGNED(size, min_block_size)) { >>> + /* >>> + * Normalize the requested size to min_block_size for >>> regular allocations. >>> + * Offset-aligned allocations intentionally skip size rounding. >>> + */ >>> + } else if (!gpu_buddy_can_offset_align(size, min_block_size)) { >>> size = round_up(size, min_block_size); >>> } >>> @@ -1158,43 +1322,60 @@ int gpu_buddy_alloc_blocks(struct gpu_buddy >>> *mm, >>> do { >>> order = min(order, (unsigned int)fls(pages) - 1); >>> BUG_ON(order > mm->max_order); >>> - BUG_ON(order < min_order); >>> + /* >>> + * Regular allocations must not allocate blocks smaller than >>> min_block_size. >>> + * Offset-aligned allocations deliberately bypass this >>> constraint. >>> + */ >>> + BUG_ON(size >= min_block_size && order < min_order); >>> do { >>> + unsigned int fallback_order; >>> + >>> block = __gpu_buddy_alloc_blocks(mm, start, >>> end, >>> + size, >>> + min_block_size, >>> order, >>> flags); >>> if (!IS_ERR(block)) >>> break; >>> - if (order-- == min_order) { >>> - /* Try allocation through force merge method */ >>> - if (mm->clear_avail && >>> - !__force_merge(mm, start, end, min_order)) { >>> - block = __gpu_buddy_alloc_blocks(mm, start, >>> - end, >>> - min_order, >>> - flags); >>> - if (!IS_ERR(block)) { >>> - order = min_order; >>> - break; >>> - } >>> - } >>> + if (size < min_block_size) { >>> + fallback_order = order; >>> + } else if (order == min_order) { >>> + fallback_order = min_order; >>> + } else { >>> + order--; >>> + continue; >>> + } >>> - /* >>> - * Try contiguous block allocation through >>> - * try harder method. >>> - */ >>> - if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION && >>> - !(flags & GPU_BUDDY_RANGE_ALLOCATION)) >>> - return __alloc_contig_try_harder(mm, >>> - original_size, >>> - original_min_size, >>> - blocks); >>> - err = -ENOSPC; >>> - goto err_free; >>> + /* Try allocation through force merge method */ >>> + if (mm->clear_avail && >>> + !__force_merge(mm, start, end, fallback_order)) { >>> + block = __gpu_buddy_alloc_blocks(mm, start, >>> + end, >>> + size, >>> + min_block_size, >>> + fallback_order, >>> + flags); >>> + if (!IS_ERR(block)) { >>> + order = fallback_order; >>> + break; >>> + } >>> } >>> + >>> + /* >>> + * Try contiguous block allocation through >>> + * try harder method. >>> + */ >>> + if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION && >>> + !(flags & GPU_BUDDY_RANGE_ALLOCATION)) >>> + return __alloc_contig_try_harder(mm, >>> + original_size, >>> + original_min_size, >>> + blocks); >>> + err = -ENOSPC; >>> + goto err_free; >>> } while (1); >>> mark_allocated(mm, block); >>> diff --git a/include/linux/gpu_buddy.h b/include/linux/gpu_buddy.h >>> index 07ac65db6d2e..7ad817c69ec6 100644 >>> --- a/include/linux/gpu_buddy.h >>> +++ b/include/linux/gpu_buddy.h >>> @@ -11,6 +11,7 @@ >>> #include <linux/slab.h> >>> #include <linux/sched.h> >>> #include <linux/rbtree.h> >>> +#include <linux/rbtree_augmented.h> >>> #define GPU_BUDDY_RANGE_ALLOCATION BIT(0) >>> #define GPU_BUDDY_TOPDOWN_ALLOCATION BIT(1) >>> @@ -58,6 +59,7 @@ struct gpu_buddy_block { >>> }; >>> struct list_head tmp_link; >>> + unsigned int subtree_max_alignment; >>> }; >>> /* Order-zero must be at least SZ_4K */ >>> >>> base-commit: 9d757669b2b22cd224c334924f798393ffca537c >> > ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling 2026-02-17 10:01 ` Matthew Auld @ 2026-02-17 10:16 ` Arunpravin Paneer Selvam 0 siblings, 0 replies; 14+ messages in thread From: Arunpravin Paneer Selvam @ 2026-02-17 10:16 UTC (permalink / raw) To: Matthew Auld, christian.koenig, dri-devel, intel-gfx, intel-xe, amd-gfx Cc: alexander.deucher On 2/17/2026 3:31 PM, Matthew Auld wrote: > On 17/02/2026 06:03, Arunpravin Paneer Selvam wrote: >> Hi Matthew, >> >> On 2/10/2026 9:56 PM, Matthew Auld wrote: >>> On 09/02/2026 08:30, Arunpravin Paneer Selvam wrote: >>>> Large alignment requests previously forced the buddy allocator to >>>> search by >>>> alignment order, which often caused higher-order free blocks to be >>>> split even >>>> when a suitably aligned smaller region already existed within them. >>>> This led >>>> to excessive fragmentation, especially for workloads requesting >>>> small sizes >>>> with large alignment constraints. >>>> >>>> This change prioritizes the requested allocation size during the >>>> search and >>>> uses an augmented RB-tree field (subtree_max_alignment) to >>>> efficiently locate >>>> free blocks that satisfy both size and offset-alignment >>>> requirements. As a >>>> result, the allocator can directly select an aligned sub-region >>>> without >>>> splitting larger blocks unnecessarily. >>>> >>>> A practical example is the VKCTS test >>>> dEQP-VK.memory.allocation.basic.size_8KiB.reverse.count_4000, which >>>> repeatedly >>>> allocates 8 KiB buffers with a 256 KiB alignment. Previously, such >>>> allocations >>>> caused large blocks to be split aggressively, despite smaller >>>> aligned regions >>>> being sufficient. With this change, those aligned regions are >>>> reused directly, >>>> significantly reducing fragmentation. >>>> >>>> This improvement is visible in the amdgpu VRAM buddy allocator state >>>> (/sys/kernel/debug/dri/1/amdgpu_vram_mm). After the change, higher- >>>> order blocks >>>> are preserved and the number of low-order fragments is >>>> substantially reduced. >>>> >>>> Before: >>>> order- 5 free: 1936 MiB, blocks: 15490 >>>> order- 4 free: 967 MiB, blocks: 15486 >>>> order- 3 free: 483 MiB, blocks: 15485 >>>> order- 2 free: 241 MiB, blocks: 15486 >>>> order- 1 free: 241 MiB, blocks: 30948 >>>> >>>> After: >>>> order- 5 free: 493 MiB, blocks: 3941 >>>> order- 4 free: 246 MiB, blocks: 3943 >>>> order- 3 free: 123 MiB, blocks: 4101 >>>> order- 2 free: 61 MiB, blocks: 4101 >>>> order- 1 free: 61 MiB, blocks: 8018 >>>> >>>> By avoiding unnecessary splits, this change improves allocator >>>> efficiency and >>>> helps maintain larger contiguous free regions under heavy >>>> offset-aligned >>>> allocation workloads. >>>> >>>> v2:(Matthew) >>>> - Update augmented information along the path to the inserted node. >>>> >>>> v3: >>>> - Move the patch to gpu/buddy.c file. >>>> >>>> Signed-off-by: Arunpravin Paneer Selvam >>>> <Arunpravin.PaneerSelvam@amd.com> >>>> Suggested-by: Christian König <christian.koenig@amd.com> >>>> --- >>>> drivers/gpu/buddy.c | 271 >>>> +++++++++++++++++++++++++++++++------- >>>> include/linux/gpu_buddy.h | 2 + >>>> 2 files changed, 228 insertions(+), 45 deletions(-) >>>> >>>> diff --git a/drivers/gpu/buddy.c b/drivers/gpu/buddy.c >>>> index 603c59a2013a..3a25eed050ba 100644 >>>> --- a/drivers/gpu/buddy.c >>>> +++ b/drivers/gpu/buddy.c >>>> @@ -14,6 +14,16 @@ >>>> static struct kmem_cache *slab_blocks; >>>> +static unsigned int gpu_buddy_block_offset_alignment(struct >>>> gpu_buddy_block *block) >>>> +{ >>>> + return __ffs(gpu_buddy_block_offset(block)); >>> >>> __ffs() will be undefined for offset zero it seems, so might blow up >>> in some strange way. I guess just return the max possible alignment >>> here if offset is zero? Also are we meant to use __ffs64() here? >> Yes, I had the same concern about __ffs() being undefined when the >> offset is zero. My initial thought was to derive the maximum possible >> alignment from the allocator size using ilog2(mm->size) and return >> that value for the zero-offset case. >> >> But, RB_DECLARE_CALLBACKS_MAX() requires the compute callback >> (gpu_buddy_block_offset_alignment()) to accept only a single struct >> gpu_buddy_block * argument. It does not provide a mechanism to pass >> additional context such as the associated struct gpu_buddy *mm. As a >> result, deriving the alignment from allocator state (e.g., via >> ilog2(mm- >size)) is not directly feasible within this callback. >> When I tested the zero-offset case locally, __ffs() returned 64, >> which effectively corresponds to the maximum alignment for a u64 >> offset. Based on that observation, I initially left the __ffs() call >> unchanged for the zero case as well. >> >> One possible alternative would be to store a pointer to struct >> gpu_buddy inside each gpu_buddy_block. >> >> All other review comments have been addressed, and I will send a v4 >> once this point is clarified. > > Yeah, I was thinking we just return the max theoretical value, so 64, > or perhaps 64+1. It just needs to be a value that will be larger than > any other possible alignment, since zero is special. It shouldn't > matter if that is larger than the actual real max for the region, I > think. > > if (!offset) > return 64 + 1; > > return __ffs64(offset); > > ? Yes, that should work. I will update the helper accordingly in v4. Regards, Arun. > >> >> Regards, >> Arun. >>> >>>> +} >>>> + >>>> +RB_DECLARE_CALLBACKS_MAX(static, gpu_buddy_augment_cb, >>>> + struct gpu_buddy_block, rb, >>>> + unsigned int, subtree_max_alignment, >>>> + gpu_buddy_block_offset_alignment); >>>> + >>>> static struct gpu_buddy_block *gpu_block_alloc(struct gpu_buddy *mm, >>>> struct gpu_buddy_block *parent, >>>> unsigned int order, >>>> @@ -31,6 +41,9 @@ static struct gpu_buddy_block >>>> *gpu_block_alloc(struct gpu_buddy *mm, >>>> block->header |= order; >>>> block->parent = parent; >>>> + block->subtree_max_alignment = >>>> + gpu_buddy_block_offset_alignment(block); >>>> + >>>> RB_CLEAR_NODE(&block->rb); >>>> BUG_ON(block->header & GPU_BUDDY_HEADER_UNUSED); >>>> @@ -67,26 +80,42 @@ static bool rbtree_is_empty(struct rb_root *root) >>>> return RB_EMPTY_ROOT(root); >>>> } >>>> -static bool gpu_buddy_block_offset_less(const struct >>>> gpu_buddy_block *block, >>>> - const struct gpu_buddy_block *node) >>>> -{ >>>> - return gpu_buddy_block_offset(block) < >>>> gpu_buddy_block_offset(node); >>>> -} >>>> - >>>> -static bool rbtree_block_offset_less(struct rb_node *block, >>>> - const struct rb_node *node) >>>> -{ >>>> - return gpu_buddy_block_offset_less(rbtree_get_free_block(block), >>>> - rbtree_get_free_block(node)); >>>> -} >>>> - >>>> static void rbtree_insert(struct gpu_buddy *mm, >>>> struct gpu_buddy_block *block, >>>> enum gpu_buddy_free_tree tree) >>>> { >>>> - rb_add(&block->rb, >>>> - &mm->free_trees[tree][gpu_buddy_block_order(block)], >>>> - rbtree_block_offset_less); >>>> + struct rb_node **link, *parent = NULL; >>>> + unsigned int block_alignment, order; >>>> + struct gpu_buddy_block *node; >>>> + struct rb_root *root; >>>> + >>>> + order = gpu_buddy_block_order(block); >>>> + block_alignment = gpu_buddy_block_offset_alignment(block); >>>> + >>>> + root = &mm->free_trees[tree][order]; >>>> + link = &root->rb_node; >>>> + >>>> + while (*link) { >>>> + parent = *link; >>>> + node = rbtree_get_free_block(parent); >>>> + /* >>>> + * Manual augmentation update during insertion traversal. >>>> Required >>>> + * because rb_insert_augmented() only calls rotate >>>> callback during >>>> + * rotations. This ensures all ancestors on the insertion >>>> path have >>>> + * correct subtree_max_alignment values. >>>> + */ >>>> + if (node->subtree_max_alignment < block_alignment) >>>> + node->subtree_max_alignment = block_alignment; >>>> + >>>> + if (gpu_buddy_block_offset(block) < >>>> gpu_buddy_block_offset(node)) >>>> + link = &parent->rb_left; >>>> + else >>>> + link = &parent->rb_right; >>>> + } >>>> + >>>> + block->subtree_max_alignment = block_alignment; >>>> + rb_link_node(&block->rb, parent, link); >>>> + rb_insert_augmented(&block->rb, root, &gpu_buddy_augment_cb); >>>> } >>>> static void rbtree_remove(struct gpu_buddy *mm, >>>> @@ -99,7 +128,7 @@ static void rbtree_remove(struct gpu_buddy *mm, >>>> tree = get_block_tree(block); >>>> root = &mm->free_trees[tree][order]; >>>> - rb_erase(&block->rb, root); >>>> + rb_erase_augmented(&block->rb, root, &gpu_buddy_augment_cb); >>>> RB_CLEAR_NODE(&block->rb); >>>> } >>>> @@ -790,6 +819,132 @@ alloc_from_freetree(struct gpu_buddy *mm, >>>> return ERR_PTR(err); >>>> } >>>> +static bool >>>> +gpu_buddy_can_offset_align(u64 size, u64 min_block_size) >>>> +{ >>>> + return size < min_block_size && is_power_of_2(size); >>>> +} >>>> + >>>> +static bool gpu_buddy_subtree_can_satisfy(struct rb_node *node, >>>> + unsigned int alignment) >>>> +{ >>>> + struct gpu_buddy_block *block; >>>> + >>>> + if (!node) >>>> + return false; >>> >>> All callers seem to handle null case already, so could potentially >>> drop this? >>> >>>> + >>>> + block = rbtree_get_free_block(node); >>>> + return block->subtree_max_alignment >= alignment; >>>> +} >>>> + >>>> +static struct gpu_buddy_block * >>>> +gpu_buddy_find_block_aligned(struct gpu_buddy *mm, >>>> + enum gpu_buddy_free_tree tree, >>>> + unsigned int order, >>>> + unsigned int tmp, >>>> + unsigned int alignment, >>>> + unsigned long flags) >>>> +{ >>>> + struct rb_root *root = &mm->free_trees[tree][tmp]; >>>> + struct rb_node *rb = root->rb_node; >>>> + >>>> + while (rb) { >>>> + struct gpu_buddy_block *block = rbtree_get_free_block(rb); >>>> + struct rb_node *left_node = rb->rb_left, *right_node = rb- >>>> >rb_right; >>>> + >>>> + if (right_node) { >>>> + if (gpu_buddy_subtree_can_satisfy(right_node, >>>> alignment)) { >>>> + rb = right_node; >>>> + continue; >>>> + } >>>> + } >>>> + >>>> + if (gpu_buddy_block_order(block) >= order && >>> >>> Is this not always true? With that we can drop order, or better yet >>> s/ tmp/order/ ? >>> >>>> + __ffs(gpu_buddy_block_offset(block)) >= alignment) >>> >>> Same here with undefined offset zero case. I guess also use the helper. >>> >>>> + return block; >>>> + >>>> + if (left_node) { >>>> + if (gpu_buddy_subtree_can_satisfy(left_node, >>>> alignment)) { >>>> + rb = left_node; >>>> + continue; >>>> + } >>>> + } >>>> + >>>> + break; >>>> + } >>>> + >>>> + return NULL; >>>> +} >>>> + >>>> +static struct gpu_buddy_block * >>>> +gpu_buddy_offset_aligned_allocation(struct gpu_buddy *mm, >>>> + u64 size, >>>> + u64 min_block_size, >>>> + unsigned long flags) >>>> +{ >>>> + struct gpu_buddy_block *block = NULL; >>>> + unsigned int order, tmp, alignment; >>>> + struct gpu_buddy_block *buddy; >>>> + enum gpu_buddy_free_tree tree; >>>> + unsigned long pages; >>>> + int err; >>>> + >>>> + alignment = ilog2(min_block_size); >>>> + pages = size >> ilog2(mm->chunk_size); >>>> + order = fls(pages) - 1; >>>> + >>>> + tree = (flags & GPU_BUDDY_CLEAR_ALLOCATION) ? >>>> + GPU_BUDDY_CLEAR_TREE : GPU_BUDDY_DIRTY_TREE; >>>> + >>>> + for (tmp = order; tmp <= mm->max_order; ++tmp) { >>>> + block = gpu_buddy_find_block_aligned(mm, tree, order, >>>> + tmp, alignment, flags); >>>> + if (!block) { >>>> + tree = (tree == GPU_BUDDY_CLEAR_TREE) ? >>>> + GPU_BUDDY_DIRTY_TREE : GPU_BUDDY_CLEAR_TREE; >>>> + block = gpu_buddy_find_block_aligned(mm, tree, order, >>>> + tmp, alignment, flags); >>>> + } >>>> + >>>> + if (block) >>>> + break; >>>> + } >>>> + >>>> + if (!block) >>>> + return ERR_PTR(-ENOSPC); >>>> + >>>> + while (gpu_buddy_block_order(block) > order) { >>>> + struct gpu_buddy_block *left, *right; >>>> + >>>> + err = split_block(mm, block); >>>> + if (unlikely(err)) >>>> + goto err_undo; >>>> + >>>> + left = block->left; >>>> + right = block->right; >>>> + >>>> + if (__ffs(gpu_buddy_block_offset(right)) >= alignment) >>> >>> Might be better to use the helper for this? >>> >>>> + block = right; >>>> + else >>>> + block = left; >>>> + } >>>> + >>>> + return block; >>>> + >>>> +err_undo: >>>> + /* >>>> + * We really don't want to leave around a bunch of split >>>> blocks, since >>>> + * bigger is better, so make sure we merge everything back >>>> before we >>>> + * free the allocated blocks. >>>> + */ >>>> + buddy = __get_buddy(block); >>>> + if (buddy && >>>> + (gpu_buddy_block_is_free(block) && >>>> + gpu_buddy_block_is_free(buddy))) >>>> + __gpu_buddy_free(mm, block, false); >>>> + return ERR_PTR(err); >>>> +} >>>> + >>>> static int __alloc_range(struct gpu_buddy *mm, >>>> struct list_head *dfs, >>>> u64 start, u64 size, >>>> @@ -1059,6 +1214,7 @@ EXPORT_SYMBOL(gpu_buddy_block_trim); >>>> static struct gpu_buddy_block * >>>> __gpu_buddy_alloc_blocks(struct gpu_buddy *mm, >>>> u64 start, u64 end, >>>> + u64 size, u64 min_block_size, >>>> unsigned int order, >>>> unsigned long flags) >>>> { >>>> @@ -1066,6 +1222,11 @@ __gpu_buddy_alloc_blocks(struct gpu_buddy *mm, >>>> /* Allocate traversing within the range */ >>>> return __gpu_buddy_alloc_range_bias(mm, start, end, >>>> order, flags); >>>> + else if (size < min_block_size) >>>> + /* Allocate from an offset-aligned region without size >>>> rounding */ >>>> + return gpu_buddy_offset_aligned_allocation(mm, size, >>>> + min_block_size, >>>> + flags); >>>> else >>>> /* Allocate from freetree */ >>>> return alloc_from_freetree(mm, order, flags); >>>> @@ -1137,8 +1298,11 @@ int gpu_buddy_alloc_blocks(struct gpu_buddy >>>> *mm, >>>> if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION) { >>>> size = roundup_pow_of_two(size); >>>> min_block_size = size; >>>> - /* Align size value to min_block_size */ >>>> - } else if (!IS_ALIGNED(size, min_block_size)) { >>>> + /* >>>> + * Normalize the requested size to min_block_size for >>>> regular allocations. >>>> + * Offset-aligned allocations intentionally skip size >>>> rounding. >>>> + */ >>>> + } else if (!gpu_buddy_can_offset_align(size, min_block_size)) { >>>> size = round_up(size, min_block_size); >>>> } >>>> @@ -1158,43 +1322,60 @@ int gpu_buddy_alloc_blocks(struct >>>> gpu_buddy *mm, >>>> do { >>>> order = min(order, (unsigned int)fls(pages) - 1); >>>> BUG_ON(order > mm->max_order); >>>> - BUG_ON(order < min_order); >>>> + /* >>>> + * Regular allocations must not allocate blocks smaller >>>> than min_block_size. >>>> + * Offset-aligned allocations deliberately bypass this >>>> constraint. >>>> + */ >>>> + BUG_ON(size >= min_block_size && order < min_order); >>>> do { >>>> + unsigned int fallback_order; >>>> + >>>> block = __gpu_buddy_alloc_blocks(mm, start, >>>> end, >>>> + size, >>>> + min_block_size, >>>> order, >>>> flags); >>>> if (!IS_ERR(block)) >>>> break; >>>> - if (order-- == min_order) { >>>> - /* Try allocation through force merge method */ >>>> - if (mm->clear_avail && >>>> - !__force_merge(mm, start, end, min_order)) { >>>> - block = __gpu_buddy_alloc_blocks(mm, start, >>>> - end, >>>> - min_order, >>>> - flags); >>>> - if (!IS_ERR(block)) { >>>> - order = min_order; >>>> - break; >>>> - } >>>> - } >>>> + if (size < min_block_size) { >>>> + fallback_order = order; >>>> + } else if (order == min_order) { >>>> + fallback_order = min_order; >>>> + } else { >>>> + order--; >>>> + continue; >>>> + } >>>> - /* >>>> - * Try contiguous block allocation through >>>> - * try harder method. >>>> - */ >>>> - if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION && >>>> - !(flags & GPU_BUDDY_RANGE_ALLOCATION)) >>>> - return __alloc_contig_try_harder(mm, >>>> - original_size, >>>> - original_min_size, >>>> - blocks); >>>> - err = -ENOSPC; >>>> - goto err_free; >>>> + /* Try allocation through force merge method */ >>>> + if (mm->clear_avail && >>>> + !__force_merge(mm, start, end, fallback_order)) { >>>> + block = __gpu_buddy_alloc_blocks(mm, start, >>>> + end, >>>> + size, >>>> + min_block_size, >>>> + fallback_order, >>>> + flags); >>>> + if (!IS_ERR(block)) { >>>> + order = fallback_order; >>>> + break; >>>> + } >>>> } >>>> + >>>> + /* >>>> + * Try contiguous block allocation through >>>> + * try harder method. >>>> + */ >>>> + if (flags & GPU_BUDDY_CONTIGUOUS_ALLOCATION && >>>> + !(flags & GPU_BUDDY_RANGE_ALLOCATION)) >>>> + return __alloc_contig_try_harder(mm, >>>> + original_size, >>>> + original_min_size, >>>> + blocks); >>>> + err = -ENOSPC; >>>> + goto err_free; >>>> } while (1); >>>> mark_allocated(mm, block); >>>> diff --git a/include/linux/gpu_buddy.h b/include/linux/gpu_buddy.h >>>> index 07ac65db6d2e..7ad817c69ec6 100644 >>>> --- a/include/linux/gpu_buddy.h >>>> +++ b/include/linux/gpu_buddy.h >>>> @@ -11,6 +11,7 @@ >>>> #include <linux/slab.h> >>>> #include <linux/sched.h> >>>> #include <linux/rbtree.h> >>>> +#include <linux/rbtree_augmented.h> >>>> #define GPU_BUDDY_RANGE_ALLOCATION BIT(0) >>>> #define GPU_BUDDY_TOPDOWN_ALLOCATION BIT(1) >>>> @@ -58,6 +59,7 @@ struct gpu_buddy_block { >>>> }; >>>> struct list_head tmp_link; >>>> + unsigned int subtree_max_alignment; >>>> }; >>>> /* Order-zero must be at least SZ_4K */ >>>> >>>> base-commit: 9d757669b2b22cd224c334924f798393ffca537c >>> >> > ^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2026-02-17 10:16 UTC | newest] Thread overview: 14+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2026-02-09 8:30 [PATCH v3 1/2] drm/buddy: Improve offset-aligned allocation handling Arunpravin Paneer Selvam 2026-02-09 8:30 ` [PATCH v3 2/2] drm/buddy: Add KUnit test for offset-aligned allocations Arunpravin Paneer Selvam 2026-02-09 19:23 ` kernel test robot 2026-02-09 19:26 ` kernel test robot 2026-02-09 21:20 ` kernel test robot 2026-02-09 8:37 ` ✗ CI.checkpatch: warning for series starting with [v3,1/2] drm/buddy: Improve offset-aligned allocation handling Patchwork 2026-02-09 8:39 ` ✓ CI.KUnit: success " Patchwork 2026-02-09 8:57 ` ✗ CI.checksparse: warning " Patchwork 2026-02-09 9:16 ` ✓ Xe.CI.BAT: success " Patchwork 2026-02-09 10:21 ` ✓ Xe.CI.FULL: " Patchwork 2026-02-10 16:26 ` [PATCH v3 1/2] " Matthew Auld 2026-02-17 6:03 ` Arunpravin Paneer Selvam 2026-02-17 10:01 ` Matthew Auld 2026-02-17 10:16 ` Arunpravin Paneer Selvam
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox