* [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf
@ 2025-09-16 11:53 Thomas Hellström
2025-09-16 12:10 ` ✓ CI.KUnit: success for " Patchwork
` (4 more replies)
0 siblings, 5 replies; 14+ messages in thread
From: Thomas Hellström @ 2025-09-16 11:53 UTC (permalink / raw)
To: intel-xe
Cc: Thomas Hellström, Dave Airlie, Simona Vetter,
Joonas Lahtinen, Maarten Lankhorst, Matthew Brost, Rodrigo Vivi,
Lucas De Marchi
RDMA NICs typically requires the VRAM dma-bufs to be pinned in
VRAM for pcie-p2p communication, since they don't fully support
the move_notify() scheme. We would like to support that.
However allowing unaccounted pinning of VRAM creates a DOS vector
so up until now we haven't allowed it.
However with cgroups support in TTM, the amount of VRAM allocated
to a cgroup can be limited, and since also the pinned memory is
accounted as allocated VRAM we should be safe.
An analogy with system memory can be made if we observe the
similarity with kernel system memory that is allocated as the
result of user-space action and that is accounted using __GFP_ACCOUNT.
Ideally, to be more flexible, we would add a "pinned_memory",
or possibly "kernel_memory" limit to the dmem cgroups controller,
that would additionally limit the memory that is pinned in this way.
If we let that limit default to the dmem::max limit we can
introduce that without needing to care about regressions.
Considering that we already pin VRAM in this way for at least
page-table memory and LRC memory, and the above path to greater
flexibility, allow this also for dma-bufs.
Cc: Dave Airlie <airlied@gmail.com>
Cc: Simona Vetter <simona.vetter@ffwll.ch>
Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com>
Cc: Maarten Lankhorst <maarten.lankhorst@intel.com>
Cc: Matthew Brost <matthew.brost@intel.com>
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
Cc: Lucas De Marchi <lucas.demarchi@intel.com>
Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
---
drivers/gpu/drm/xe/tests/xe_dma_buf.c | 13 +++++++++
drivers/gpu/drm/xe/xe_dma_buf.c | 41 +++++++++++++++++----------
2 files changed, 39 insertions(+), 15 deletions(-)
diff --git a/drivers/gpu/drm/xe/tests/xe_dma_buf.c b/drivers/gpu/drm/xe/tests/xe_dma_buf.c
index a7e548a2bdfb..1f88ca71820c 100644
--- a/drivers/gpu/drm/xe/tests/xe_dma_buf.c
+++ b/drivers/gpu/drm/xe/tests/xe_dma_buf.c
@@ -31,6 +31,7 @@ static void check_residency(struct kunit *test, struct xe_bo *exported,
struct drm_exec *exec)
{
struct dma_buf_test_params *params = to_dma_buf_test_params(test->priv);
+ struct dma_buf_attachment *attach;
u32 mem_type;
int ret;
@@ -88,6 +89,18 @@ static void check_residency(struct kunit *test, struct xe_bo *exported,
KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, mem_type));
+ /* Check that we can pin without migrating. */
+ attach = list_first_entry_or_null(&dmabuf->attachments, typeof(*attach), node);
+ if (attach) {
+ int err = dma_buf_pin(attach);
+
+ if (!err) {
+ KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, mem_type));
+ dma_buf_unpin(attach);
+ }
+ KUNIT_EXPECT_EQ(test, err, 0);
+ }
+
if (params->force_different_devices)
KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(imported, XE_PL_TT));
else
diff --git a/drivers/gpu/drm/xe/xe_dma_buf.c b/drivers/gpu/drm/xe/xe_dma_buf.c
index a7d67725c3ee..54e42960daad 100644
--- a/drivers/gpu/drm/xe/xe_dma_buf.c
+++ b/drivers/gpu/drm/xe/xe_dma_buf.c
@@ -48,32 +48,43 @@ static void xe_dma_buf_detach(struct dma_buf *dmabuf,
static int xe_dma_buf_pin(struct dma_buf_attachment *attach)
{
- struct drm_gem_object *obj = attach->dmabuf->priv;
+ struct dma_buf *dmabuf = attach->dmabuf;
+ struct drm_gem_object *obj = dmabuf->priv;
struct xe_bo *bo = gem_to_xe_bo(obj);
struct xe_device *xe = xe_bo_device(bo);
struct drm_exec *exec = XE_VALIDATION_UNSUPPORTED;
+ bool allow_vram = true;
int ret;
- /*
- * For now only support pinning in TT memory, for two reasons:
- * 1) Avoid pinning in a placement not accessible to some importers.
- * 2) Pinning in VRAM requires PIN accounting which is a to-do.
- */
- if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, XE_PL_TT)) {
+ if (!IS_ENABLED(CONFIG_DMABUF_MOVE_NOTIFY)) {
+ allow_vram = false;
+ } else {
+ list_for_each_entry(attach, &dmabuf->attachments, node) {
+ if (!attach->peer2peer) {
+ allow_vram = false;
+ break;
+ }
+ }
+ }
+
+ if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, XE_PL_TT) &&
+ !(xe_bo_is_vram(bo) && allow_vram)) {
drm_dbg(&xe->drm, "Can't migrate pinned bo for dma-buf pin.\n");
return -EINVAL;
}
- ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec);
- if (ret) {
- if (ret != -EINTR && ret != -ERESTARTSYS)
- drm_dbg(&xe->drm,
- "Failed migrating dma-buf to TT memory: %pe\n",
- ERR_PTR(ret));
- return ret;
+ if (!allow_vram) {
+ ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec);
+ if (ret) {
+ if (ret != -EINTR && ret != -ERESTARTSYS)
+ drm_dbg(&xe->drm,
+ "Failed migrating dma-buf to TT memory: %pe\n",
+ ERR_PTR(ret));
+ return ret;
+ }
}
- ret = xe_bo_pin_external(bo, true, exec);
+ ret = xe_bo_pin_external(bo, !allow_vram, exec);
xe_assert(xe, !ret);
return 0;
--
2.51.0
^ permalink raw reply related [flat|nested] 14+ messages in thread* ✓ CI.KUnit: success for drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 11:53 [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf Thomas Hellström @ 2025-09-16 12:10 ` Patchwork 2025-09-16 12:43 ` ✓ Xe.CI.BAT: " Patchwork ` (3 subsequent siblings) 4 siblings, 0 replies; 14+ messages in thread From: Patchwork @ 2025-09-16 12:10 UTC (permalink / raw) To: Thomas Hellström; +Cc: intel-xe == Series Details == Series: drm/xe/dma-buf: Allow pinning of p2p dma-buf URL : https://patchwork.freedesktop.org/series/154593/ State : success == Summary == + trap cleanup EXIT + /kernel/tools/testing/kunit/kunit.py run --kunitconfig /kernel/drivers/gpu/drm/xe/.kunitconfig [12:09:02] Configuring KUnit Kernel ... Generating .config ... Populating config with: $ make ARCH=um O=.kunit olddefconfig [12:09:07] 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=48 [12:09:35] Starting KUnit Kernel (1/1)... [12:09:35] ============================================================ Running tests with: $ .kunit/linux kunit.enable=1 mem=1G console=tty kunit_shutdown=halt [12:09:36] ================== guc_buf (11 subtests) =================== [12:09:36] [PASSED] test_smallest [12:09:36] [PASSED] test_largest [12:09:36] [PASSED] test_granular [12:09:36] [PASSED] test_unique [12:09:36] [PASSED] test_overlap [12:09:36] [PASSED] test_reusable [12:09:36] [PASSED] test_too_big [12:09:36] [PASSED] test_flush [12:09:36] [PASSED] test_lookup [12:09:36] [PASSED] test_data [12:09:36] [PASSED] test_class [12:09:36] ===================== [PASSED] guc_buf ===================== [12:09:36] =================== guc_dbm (7 subtests) =================== [12:09:36] [PASSED] test_empty [12:09:36] [PASSED] test_default [12:09:36] ======================== test_size ======================== [12:09:36] [PASSED] 4 [12:09:36] [PASSED] 8 [12:09:36] [PASSED] 32 [12:09:36] [PASSED] 256 [12:09:36] ==================== [PASSED] test_size ==================== [12:09:36] ======================= test_reuse ======================== [12:09:36] [PASSED] 4 [12:09:36] [PASSED] 8 [12:09:36] [PASSED] 32 [12:09:36] [PASSED] 256 [12:09:36] =================== [PASSED] test_reuse ==================== [12:09:36] =================== test_range_overlap ==================== [12:09:36] [PASSED] 4 [12:09:36] [PASSED] 8 [12:09:36] [PASSED] 32 [12:09:36] [PASSED] 256 [12:09:36] =============== [PASSED] test_range_overlap ================ [12:09:36] =================== test_range_compact ==================== [12:09:36] [PASSED] 4 [12:09:36] [PASSED] 8 [12:09:36] [PASSED] 32 [12:09:36] [PASSED] 256 [12:09:36] =============== [PASSED] test_range_compact ================ [12:09:36] ==================== test_range_spare ===================== [12:09:36] [PASSED] 4 [12:09:36] [PASSED] 8 [12:09:36] [PASSED] 32 [12:09:36] [PASSED] 256 [12:09:36] ================ [PASSED] test_range_spare ================= [12:09:36] ===================== [PASSED] guc_dbm ===================== [12:09:36] =================== guc_idm (6 subtests) =================== [12:09:36] [PASSED] bad_init [12:09:36] [PASSED] no_init [12:09:36] [PASSED] init_fini [12:09:36] [PASSED] check_used [12:09:36] [PASSED] check_quota [12:09:36] [PASSED] check_all [12:09:36] ===================== [PASSED] guc_idm ===================== [12:09:36] ================== no_relay (3 subtests) =================== [12:09:36] [PASSED] xe_drops_guc2pf_if_not_ready [12:09:36] [PASSED] xe_drops_guc2vf_if_not_ready [12:09:36] [PASSED] xe_rejects_send_if_not_ready [12:09:36] ==================== [PASSED] no_relay ===================== [12:09:36] ================== pf_relay (14 subtests) ================== [12:09:36] [PASSED] pf_rejects_guc2pf_too_short [12:09:36] [PASSED] pf_rejects_guc2pf_too_long [12:09:36] [PASSED] pf_rejects_guc2pf_no_payload [12:09:36] [PASSED] pf_fails_no_payload [12:09:36] [PASSED] pf_fails_bad_origin [12:09:36] [PASSED] pf_fails_bad_type [12:09:36] [PASSED] pf_txn_reports_error [12:09:36] [PASSED] pf_txn_sends_pf2guc [12:09:36] [PASSED] pf_sends_pf2guc [12:09:36] [SKIPPED] pf_loopback_nop [12:09:36] [SKIPPED] pf_loopback_echo [12:09:36] [SKIPPED] pf_loopback_fail [12:09:36] [SKIPPED] pf_loopback_busy [12:09:36] [SKIPPED] pf_loopback_retry [12:09:36] ==================== [PASSED] pf_relay ===================== [12:09:36] ================== vf_relay (3 subtests) =================== [12:09:36] [PASSED] vf_rejects_guc2vf_too_short [12:09:36] [PASSED] vf_rejects_guc2vf_too_long [12:09:36] [PASSED] vf_rejects_guc2vf_no_payload [12:09:36] ==================== [PASSED] vf_relay ===================== [12:09:36] ===================== lmtt (1 subtest) ===================== [12:09:36] ======================== test_ops ========================= [12:09:36] [PASSED] 2-level [12:09:36] [PASSED] multi-level [12:09:36] ==================== [PASSED] test_ops ===================== [12:09:36] ====================== [PASSED] lmtt ======================= [12:09:36] ================= pf_service (11 subtests) ================= [12:09:36] [PASSED] pf_negotiate_any [12:09:36] [PASSED] pf_negotiate_base_match [12:09:36] [PASSED] pf_negotiate_base_newer [12:09:36] [PASSED] pf_negotiate_base_next [12:09:36] [SKIPPED] pf_negotiate_base_older [12:09:36] [PASSED] pf_negotiate_base_prev [12:09:36] [PASSED] pf_negotiate_latest_match [12:09:36] [PASSED] pf_negotiate_latest_newer [12:09:36] [PASSED] pf_negotiate_latest_next [12:09:36] [SKIPPED] pf_negotiate_latest_older [12:09:36] [SKIPPED] pf_negotiate_latest_prev [12:09:36] =================== [PASSED] pf_service ==================== [12:09:36] ================= xe_guc_g2g (2 subtests) ================== [12:09:36] ============== xe_live_guc_g2g_kunit_default ============== [12:09:36] ========= [SKIPPED] xe_live_guc_g2g_kunit_default ========== [12:09:36] ============== xe_live_guc_g2g_kunit_allmem =============== [12:09:36] ========== [SKIPPED] xe_live_guc_g2g_kunit_allmem ========== [12:09:36] =================== [SKIPPED] xe_guc_g2g =================== [12:09:36] =================== xe_mocs (2 subtests) =================== [12:09:36] ================ xe_live_mocs_kernel_kunit ================ [12:09:36] =========== [SKIPPED] xe_live_mocs_kernel_kunit ============ [12:09:36] ================ xe_live_mocs_reset_kunit ================= [12:09:36] ============ [SKIPPED] xe_live_mocs_reset_kunit ============ [12:09:36] ==================== [SKIPPED] xe_mocs ===================== [12:09:36] ================= xe_migrate (2 subtests) ================== [12:09:36] ================= xe_migrate_sanity_kunit ================= [12:09:36] ============ [SKIPPED] xe_migrate_sanity_kunit ============= [12:09:36] ================== xe_validate_ccs_kunit ================== [12:09:36] ============= [SKIPPED] xe_validate_ccs_kunit ============== [12:09:36] =================== [SKIPPED] xe_migrate =================== [12:09:36] ================== xe_dma_buf (1 subtest) ================== [12:09:36] ==================== xe_dma_buf_kunit ===================== [12:09:36] ================ [SKIPPED] xe_dma_buf_kunit ================ [12:09:36] =================== [SKIPPED] xe_dma_buf =================== [12:09:36] ================= xe_bo_shrink (1 subtest) ================= [12:09:36] =================== xe_bo_shrink_kunit ==================== [12:09:36] =============== [SKIPPED] xe_bo_shrink_kunit =============== [12:09:36] ================== [SKIPPED] xe_bo_shrink ================== [12:09:36] ==================== xe_bo (2 subtests) ==================== [12:09:36] ================== xe_ccs_migrate_kunit =================== [12:09:36] ============== [SKIPPED] xe_ccs_migrate_kunit ============== [12:09:36] ==================== xe_bo_evict_kunit ==================== [12:09:36] =============== [SKIPPED] xe_bo_evict_kunit ================ [12:09:36] ===================== [SKIPPED] xe_bo ====================== [12:09:36] ==================== args (11 subtests) ==================== [12:09:36] [PASSED] count_args_test [12:09:36] [PASSED] call_args_example [12:09:36] [PASSED] call_args_test [12:09:36] [PASSED] drop_first_arg_example [12:09:36] [PASSED] drop_first_arg_test [12:09:36] [PASSED] first_arg_example [12:09:36] [PASSED] first_arg_test [12:09:36] [PASSED] last_arg_example [12:09:36] [PASSED] last_arg_test [12:09:36] [PASSED] pick_arg_example [12:09:36] [PASSED] sep_comma_example [12:09:36] ====================== [PASSED] args ======================= [12:09:36] =================== xe_pci (3 subtests) ==================== [12:09:36] ==================== check_graphics_ip ==================== [12:09:36] [PASSED] 12.70 Xe_LPG [12:09:36] [PASSED] 12.71 Xe_LPG [12:09:36] [PASSED] 12.74 Xe_LPG+ [12:09:36] [PASSED] 20.01 Xe2_HPG [12:09:36] [PASSED] 20.02 Xe2_HPG [12:09:36] [PASSED] 20.04 Xe2_LPG [12:09:36] [PASSED] 30.00 Xe3_LPG [12:09:36] [PASSED] 30.01 Xe3_LPG [12:09:36] [PASSED] 30.03 Xe3_LPG [12:09:36] ================ [PASSED] check_graphics_ip ================ [12:09:36] ===================== check_media_ip ====================== [12:09:36] [PASSED] 13.00 Xe_LPM+ [12:09:36] [PASSED] 13.01 Xe2_HPM [12:09:36] [PASSED] 20.00 Xe2_LPM [12:09:36] [PASSED] 30.00 Xe3_LPM [12:09:36] [PASSED] 30.02 Xe3_LPM [12:09:36] ================= [PASSED] check_media_ip ================== [12:09:36] ================= check_platform_gt_count ================= [12:09:36] [PASSED] 0x9A60 (TIGERLAKE) [12:09:36] [PASSED] 0x9A68 (TIGERLAKE) [12:09:36] [PASSED] 0x9A70 (TIGERLAKE) [12:09:36] [PASSED] 0x9A40 (TIGERLAKE) [12:09:36] [PASSED] 0x9A49 (TIGERLAKE) [12:09:36] [PASSED] 0x9A59 (TIGERLAKE) [12:09:36] [PASSED] 0x9A78 (TIGERLAKE) [12:09:36] [PASSED] 0x9AC0 (TIGERLAKE) [12:09:36] [PASSED] 0x9AC9 (TIGERLAKE) [12:09:36] [PASSED] 0x9AD9 (TIGERLAKE) [12:09:36] [PASSED] 0x9AF8 (TIGERLAKE) [12:09:36] [PASSED] 0x4C80 (ROCKETLAKE) [12:09:36] [PASSED] 0x4C8A (ROCKETLAKE) [12:09:36] [PASSED] 0x4C8B (ROCKETLAKE) [12:09:36] [PASSED] 0x4C8C (ROCKETLAKE) [12:09:36] [PASSED] 0x4C90 (ROCKETLAKE) [12:09:36] [PASSED] 0x4C9A (ROCKETLAKE) [12:09:36] [PASSED] 0x4680 (ALDERLAKE_S) [12:09:36] [PASSED] 0x4682 (ALDERLAKE_S) [12:09:36] [PASSED] 0x4688 (ALDERLAKE_S) [12:09:36] [PASSED] 0x468A (ALDERLAKE_S) [12:09:36] [PASSED] 0x468B (ALDERLAKE_S) [12:09:36] [PASSED] 0x4690 (ALDERLAKE_S) [12:09:36] [PASSED] 0x4692 (ALDERLAKE_S) [12:09:36] [PASSED] 0x4693 (ALDERLAKE_S) [12:09:36] [PASSED] 0x46A0 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46A1 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46A2 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46A3 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46A6 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46A8 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46AA (ALDERLAKE_P) [12:09:36] [PASSED] 0x462A (ALDERLAKE_P) [12:09:36] [PASSED] 0x4626 (ALDERLAKE_P) [12:09:36] [PASSED] 0x4628 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46B0 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46B1 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46B2 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46B3 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46C0 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46C1 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46C2 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46C3 (ALDERLAKE_P) [12:09:36] [PASSED] 0x46D0 (ALDERLAKE_N) [12:09:36] [PASSED] 0x46D1 (ALDERLAKE_N) [12:09:36] [PASSED] 0x46D2 (ALDERLAKE_N) [12:09:36] [PASSED] 0x46D3 (ALDERLAKE_N) [12:09:36] [PASSED] 0x46D4 (ALDERLAKE_N) [12:09:36] [PASSED] 0xA721 (ALDERLAKE_P) [12:09:36] [PASSED] 0xA7A1 (ALDERLAKE_P) [12:09:36] [PASSED] 0xA7A9 (ALDERLAKE_P) [12:09:36] [PASSED] 0xA7AC (ALDERLAKE_P) [12:09:36] [PASSED] 0xA7AD (ALDERLAKE_P) [12:09:36] [PASSED] 0xA720 (ALDERLAKE_P) [12:09:36] [PASSED] 0xA7A0 (ALDERLAKE_P) [12:09:36] [PASSED] 0xA7A8 (ALDERLAKE_P) [12:09:36] [PASSED] 0xA7AA (ALDERLAKE_P) [12:09:36] [PASSED] 0xA7AB (ALDERLAKE_P) [12:09:36] [PASSED] 0xA780 (ALDERLAKE_S) [12:09:36] [PASSED] 0xA781 (ALDERLAKE_S) [12:09:36] [PASSED] 0xA782 (ALDERLAKE_S) [12:09:36] [PASSED] 0xA783 (ALDERLAKE_S) [12:09:36] [PASSED] 0xA788 (ALDERLAKE_S) [12:09:36] [PASSED] 0xA789 (ALDERLAKE_S) [12:09:36] [PASSED] 0xA78A (ALDERLAKE_S) [12:09:36] [PASSED] 0xA78B (ALDERLAKE_S) [12:09:36] [PASSED] 0x4905 (DG1) [12:09:36] [PASSED] 0x4906 (DG1) [12:09:36] [PASSED] 0x4907 (DG1) [12:09:36] [PASSED] 0x4908 (DG1) [12:09:36] [PASSED] 0x4909 (DG1) [12:09:36] [PASSED] 0x56C0 (DG2) [12:09:36] [PASSED] 0x56C2 (DG2) [12:09:36] [PASSED] 0x56C1 (DG2) [12:09:36] [PASSED] 0x7D51 (METEORLAKE) [12:09:36] [PASSED] 0x7DD1 (METEORLAKE) [12:09:36] [PASSED] 0x7D41 (METEORLAKE) [12:09:36] [PASSED] 0x7D67 (METEORLAKE) [12:09:36] [PASSED] 0xB640 (METEORLAKE) [12:09:36] [PASSED] 0x56A0 (DG2) [12:09:36] [PASSED] 0x56A1 (DG2) [12:09:36] [PASSED] 0x56A2 (DG2) [12:09:36] [PASSED] 0x56BE (DG2) [12:09:36] [PASSED] 0x56BF (DG2) [12:09:36] [PASSED] 0x5690 (DG2) [12:09:36] [PASSED] 0x5691 (DG2) [12:09:36] [PASSED] 0x5692 (DG2) [12:09:36] [PASSED] 0x56A5 (DG2) [12:09:36] [PASSED] 0x56A6 (DG2) [12:09:36] [PASSED] 0x56B0 (DG2) [12:09:36] [PASSED] 0x56B1 (DG2) [12:09:36] [PASSED] 0x56BA (DG2) [12:09:36] [PASSED] 0x56BB (DG2) [12:09:36] [PASSED] 0x56BC (DG2) [12:09:36] [PASSED] 0x56BD (DG2) [12:09:36] [PASSED] 0x5693 (DG2) [12:09:36] [PASSED] 0x5694 (DG2) [12:09:36] [PASSED] 0x5695 (DG2) [12:09:36] [PASSED] 0x56A3 (DG2) [12:09:36] [PASSED] 0x56A4 (DG2) [12:09:36] [PASSED] 0x56B2 (DG2) [12:09:36] [PASSED] 0x56B3 (DG2) [12:09:36] [PASSED] 0x5696 (DG2) [12:09:36] [PASSED] 0x5697 (DG2) [12:09:36] [PASSED] 0xB69 (PVC) [12:09:36] [PASSED] 0xB6E (PVC) [12:09:36] [PASSED] 0xBD4 (PVC) [12:09:36] [PASSED] 0xBD5 (PVC) [12:09:36] [PASSED] 0xBD6 (PVC) [12:09:36] [PASSED] 0xBD7 (PVC) [12:09:36] [PASSED] 0xBD8 (PVC) [12:09:36] [PASSED] 0xBD9 (PVC) [12:09:36] [PASSED] 0xBDA (PVC) [12:09:36] [PASSED] 0xBDB (PVC) [12:09:36] [PASSED] 0xBE0 (PVC) [12:09:36] [PASSED] 0xBE1 (PVC) [12:09:36] [PASSED] 0xBE5 (PVC) [12:09:36] [PASSED] 0x7D40 (METEORLAKE) [12:09:36] [PASSED] 0x7D45 (METEORLAKE) [12:09:36] [PASSED] 0x7D55 (METEORLAKE) [12:09:36] [PASSED] 0x7D60 (METEORLAKE) [12:09:36] [PASSED] 0x7DD5 (METEORLAKE) [12:09:36] [PASSED] 0x6420 (LUNARLAKE) [12:09:36] [PASSED] 0x64A0 (LUNARLAKE) [12:09:36] [PASSED] 0x64B0 (LUNARLAKE) [12:09:36] [PASSED] 0xE202 (BATTLEMAGE) [12:09:36] [PASSED] 0xE209 (BATTLEMAGE) [12:09:36] [PASSED] 0xE20B (BATTLEMAGE) [12:09:36] [PASSED] 0xE20C (BATTLEMAGE) [12:09:36] [PASSED] 0xE20D (BATTLEMAGE) [12:09:36] [PASSED] 0xE210 (BATTLEMAGE) [12:09:36] [PASSED] 0xE211 (BATTLEMAGE) [12:09:36] [PASSED] 0xE212 (BATTLEMAGE) [12:09:36] [PASSED] 0xE216 (BATTLEMAGE) [12:09:36] [PASSED] 0xE220 (BATTLEMAGE) [12:09:36] [PASSED] 0xE221 (BATTLEMAGE) [12:09:36] [PASSED] 0xE222 (BATTLEMAGE) [12:09:36] [PASSED] 0xE223 (BATTLEMAGE) [12:09:36] [PASSED] 0xB080 (PANTHERLAKE) [12:09:36] [PASSED] 0xB081 (PANTHERLAKE) [12:09:36] [PASSED] 0xB082 (PANTHERLAKE) [12:09:36] [PASSED] 0xB083 (PANTHERLAKE) [12:09:36] [PASSED] 0xB084 (PANTHERLAKE) [12:09:36] [PASSED] 0xB085 (PANTHERLAKE) [12:09:36] [PASSED] 0xB086 (PANTHERLAKE) [12:09:36] [PASSED] 0xB087 (PANTHERLAKE) [12:09:36] [PASSED] 0xB08F (PANTHERLAKE) [12:09:36] [PASSED] 0xB090 (PANTHERLAKE) [12:09:36] [PASSED] 0xB0A0 (PANTHERLAKE) [12:09:36] [PASSED] 0xB0B0 (PANTHERLAKE) [12:09:36] [PASSED] 0xFD80 (PANTHERLAKE) [12:09:36] [PASSED] 0xFD81 (PANTHERLAKE) [12:09:36] ============= [PASSED] check_platform_gt_count ============= [12:09:36] ===================== [PASSED] xe_pci ====================== [12:09:36] =================== xe_rtp (2 subtests) ==================== [12:09:36] =============== xe_rtp_process_to_sr_tests ================ [12:09:36] [PASSED] coalesce-same-reg [12:09:36] [PASSED] no-match-no-add [12:09:36] [PASSED] match-or [12:09:36] [PASSED] match-or-xfail [12:09:36] [PASSED] no-match-no-add-multiple-rules [12:09:36] [PASSED] two-regs-two-entries [12:09:36] [PASSED] clr-one-set-other [12:09:36] [PASSED] set-field [12:09:36] [PASSED] conflict-duplicate [12:09:36] [PASSED] conflict-not-disjoint [12:09:36] [PASSED] conflict-reg-type [12:09:36] =========== [PASSED] xe_rtp_process_to_sr_tests ============ [12:09:36] ================== xe_rtp_process_tests =================== [12:09:36] [PASSED] active1 [12:09:36] [PASSED] active2 [12:09:36] [PASSED] active-inactive [12:09:36] [PASSED] inactive-active [12:09:36] [PASSED] inactive-1st_or_active-inactive [12:09:36] [PASSED] inactive-2nd_or_active-inactive [12:09:36] [PASSED] inactive-last_or_active-inactive [12:09:36] [PASSED] inactive-no_or_active-inactive [12:09:36] ============== [PASSED] xe_rtp_process_tests =============== [12:09:36] ===================== [PASSED] xe_rtp ====================== [12:09:36] ==================== xe_wa (1 subtest) ===================== [12:09:36] ======================== xe_wa_gt ========================= [12:09:36] [PASSED] TIGERLAKE B0 [12:09:36] [PASSED] DG1 A0 [12:09:36] [PASSED] DG1 B0 [12:09:36] [PASSED] ALDERLAKE_S A0 [12:09:36] [PASSED] ALDERLAKE_S B0 [12:09:36] [PASSED] ALDERLAKE_S C0 [12:09:36] [PASSED] ALDERLAKE_S D0 [12:09:36] [PASSED] ALDERLAKE_P A0 [12:09:36] [PASSED] ALDERLAKE_P B0 [12:09:36] [PASSED] ALDERLAKE_P C0stty: 'standard input': Inappropriate ioctl for device [12:09:36] [PASSED] ALDERLAKE_S RPLS D0 [12:09:36] [PASSED] ALDERLAKE_P RPLU E0 [12:09:36] [PASSED] DG2 G10 C0 [12:09:36] [PASSED] DG2 G11 B1 [12:09:36] [PASSED] DG2 G12 A1 [12:09:36] [PASSED] METEORLAKE 12.70(Xe_LPG) A0 13.00(Xe_LPM+) A0 [12:09:36] [PASSED] METEORLAKE 12.71(Xe_LPG) A0 13.00(Xe_LPM+) A0 [12:09:36] [PASSED] METEORLAKE 12.74(Xe_LPG+) A0 13.00(Xe_LPM+) A0 [12:09:36] [PASSED] LUNARLAKE 20.04(Xe2_LPG) A0 20.00(Xe2_LPM) A0 [12:09:36] [PASSED] LUNARLAKE 20.04(Xe2_LPG) B0 20.00(Xe2_LPM) A0 [12:09:36] [PASSED] BATTLEMAGE 20.01(Xe2_HPG) A0 13.01(Xe2_HPM) A1 [12:09:36] [PASSED] PANTHERLAKE 30.00(Xe3_LPG) A0 30.00(Xe3_LPM) A0 [12:09:36] ==================== [PASSED] xe_wa_gt ===================== [12:09:36] ====================== [PASSED] xe_wa ====================== [12:09:36] ============================================================ [12:09:36] Testing complete. Ran 300 tests: passed: 282, skipped: 18 [12:09:36] Elapsed time: 33.572s total, 4.288s configuring, 28.917s building, 0.317s running + /kernel/tools/testing/kunit/kunit.py run --kunitconfig /kernel/drivers/gpu/drm/tests/.kunitconfig [12:09:36] Configuring KUnit Kernel ... Regenerating .config ... Populating config with: $ make ARCH=um O=.kunit olddefconfig [12:09:38] 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=48 [12:10:01] Starting KUnit Kernel (1/1)... [12:10:01] ============================================================ Running tests with: $ .kunit/linux kunit.enable=1 mem=1G console=tty kunit_shutdown=halt [12:10:01] == drm_test_atomic_get_connector_for_encoder (1 subtest) === [12:10:01] [PASSED] drm_test_drm_atomic_get_connector_for_encoder [12:10:01] ==== [PASSED] drm_test_atomic_get_connector_for_encoder ==== [12:10:01] =========== drm_validate_clone_mode (2 subtests) =========== [12:10:01] ============== drm_test_check_in_clone_mode =============== [12:10:01] [PASSED] in_clone_mode [12:10:01] [PASSED] not_in_clone_mode [12:10:01] ========== [PASSED] drm_test_check_in_clone_mode =========== [12:10:01] =============== drm_test_check_valid_clones =============== [12:10:01] [PASSED] not_in_clone_mode [12:10:01] [PASSED] valid_clone [12:10:01] [PASSED] invalid_clone [12:10:01] =========== [PASSED] drm_test_check_valid_clones =========== [12:10:01] ============= [PASSED] drm_validate_clone_mode ============= [12:10:01] ============= drm_validate_modeset (1 subtest) ============= [12:10:01] [PASSED] drm_test_check_connector_changed_modeset [12:10:01] ============== [PASSED] drm_validate_modeset =============== [12:10:01] ====== drm_test_bridge_get_current_state (2 subtests) ====== [12:10:01] [PASSED] drm_test_drm_bridge_get_current_state_atomic [12:10:01] [PASSED] drm_test_drm_bridge_get_current_state_legacy [12:10:01] ======== [PASSED] drm_test_bridge_get_current_state ======== [12:10:01] ====== drm_test_bridge_helper_reset_crtc (3 subtests) ====== [12:10:01] [PASSED] drm_test_drm_bridge_helper_reset_crtc_atomic [12:10:01] [PASSED] drm_test_drm_bridge_helper_reset_crtc_atomic_disabled [12:10:01] [PASSED] drm_test_drm_bridge_helper_reset_crtc_legacy [12:10:01] ======== [PASSED] drm_test_bridge_helper_reset_crtc ======== [12:10:01] ============== drm_bridge_alloc (2 subtests) =============== [12:10:01] [PASSED] drm_test_drm_bridge_alloc_basic [12:10:01] [PASSED] drm_test_drm_bridge_alloc_get_put [12:10:01] ================ [PASSED] drm_bridge_alloc ================= [12:10:01] ================== drm_buddy (7 subtests) ================== [12:10:01] [PASSED] drm_test_buddy_alloc_limit [12:10:01] [PASSED] drm_test_buddy_alloc_optimistic [12:10:01] [PASSED] drm_test_buddy_alloc_pessimistic [12:10:01] [PASSED] drm_test_buddy_alloc_pathological [12:10:01] [PASSED] drm_test_buddy_alloc_contiguous [12:10:01] [PASSED] drm_test_buddy_alloc_clear [12:10:01] [PASSED] drm_test_buddy_alloc_range_bias [12:10:01] ==================== [PASSED] drm_buddy ==================== [12:10:01] ============= drm_cmdline_parser (40 subtests) ============= [12:10:01] [PASSED] drm_test_cmdline_force_d_only [12:10:01] [PASSED] drm_test_cmdline_force_D_only_dvi [12:10:01] [PASSED] drm_test_cmdline_force_D_only_hdmi [12:10:01] [PASSED] drm_test_cmdline_force_D_only_not_digital [12:10:01] [PASSED] drm_test_cmdline_force_e_only [12:10:01] [PASSED] drm_test_cmdline_res [12:10:01] [PASSED] drm_test_cmdline_res_vesa [12:10:01] [PASSED] drm_test_cmdline_res_vesa_rblank [12:10:01] [PASSED] drm_test_cmdline_res_rblank [12:10:01] [PASSED] drm_test_cmdline_res_bpp [12:10:01] [PASSED] drm_test_cmdline_res_refresh [12:10:01] [PASSED] drm_test_cmdline_res_bpp_refresh [12:10:01] [PASSED] drm_test_cmdline_res_bpp_refresh_interlaced [12:10:01] [PASSED] drm_test_cmdline_res_bpp_refresh_margins [12:10:01] [PASSED] drm_test_cmdline_res_bpp_refresh_force_off [12:10:01] [PASSED] drm_test_cmdline_res_bpp_refresh_force_on [12:10:01] [PASSED] drm_test_cmdline_res_bpp_refresh_force_on_analog [12:10:01] [PASSED] drm_test_cmdline_res_bpp_refresh_force_on_digital [12:10:01] [PASSED] drm_test_cmdline_res_bpp_refresh_interlaced_margins_force_on [12:10:01] [PASSED] drm_test_cmdline_res_margins_force_on [12:10:01] [PASSED] drm_test_cmdline_res_vesa_margins [12:10:01] [PASSED] drm_test_cmdline_name [12:10:01] [PASSED] drm_test_cmdline_name_bpp [12:10:01] [PASSED] drm_test_cmdline_name_option [12:10:01] [PASSED] drm_test_cmdline_name_bpp_option [12:10:01] [PASSED] drm_test_cmdline_rotate_0 [12:10:01] [PASSED] drm_test_cmdline_rotate_90 [12:10:01] [PASSED] drm_test_cmdline_rotate_180 [12:10:01] [PASSED] drm_test_cmdline_rotate_270 [12:10:01] [PASSED] drm_test_cmdline_hmirror [12:10:01] [PASSED] drm_test_cmdline_vmirror [12:10:01] [PASSED] drm_test_cmdline_margin_options [12:10:01] [PASSED] drm_test_cmdline_multiple_options [12:10:01] [PASSED] drm_test_cmdline_bpp_extra_and_option [12:10:01] [PASSED] drm_test_cmdline_extra_and_option [12:10:01] [PASSED] drm_test_cmdline_freestanding_options [12:10:01] [PASSED] drm_test_cmdline_freestanding_force_e_and_options [12:10:01] [PASSED] drm_test_cmdline_panel_orientation [12:10:01] ================ drm_test_cmdline_invalid ================= [12:10:01] [PASSED] margin_only [12:10:01] [PASSED] interlace_only [12:10:01] [PASSED] res_missing_x [12:10:01] [PASSED] res_missing_y [12:10:01] [PASSED] res_bad_y [12:10:01] [PASSED] res_missing_y_bpp [12:10:01] [PASSED] res_bad_bpp [12:10:01] [PASSED] res_bad_refresh [12:10:01] [PASSED] res_bpp_refresh_force_on_off [12:10:01] [PASSED] res_invalid_mode [12:10:01] [PASSED] res_bpp_wrong_place_mode [12:10:01] [PASSED] name_bpp_refresh [12:10:01] [PASSED] name_refresh [12:10:01] [PASSED] name_refresh_wrong_mode [12:10:01] [PASSED] name_refresh_invalid_mode [12:10:01] [PASSED] rotate_multiple [12:10:01] [PASSED] rotate_invalid_val [12:10:01] [PASSED] rotate_truncated [12:10:01] [PASSED] invalid_option [12:10:01] [PASSED] invalid_tv_option [12:10:01] [PASSED] truncated_tv_option [12:10:01] ============ [PASSED] drm_test_cmdline_invalid ============= [12:10:01] =============== drm_test_cmdline_tv_options =============== [12:10:01] [PASSED] NTSC [12:10:01] [PASSED] NTSC_443 [12:10:01] [PASSED] NTSC_J [12:10:01] [PASSED] PAL [12:10:01] [PASSED] PAL_M [12:10:01] [PASSED] PAL_N [12:10:01] [PASSED] SECAM [12:10:01] [PASSED] MONO_525 [12:10:01] [PASSED] MONO_625 [12:10:01] =========== [PASSED] drm_test_cmdline_tv_options =========== [12:10:01] =============== [PASSED] drm_cmdline_parser ================ [12:10:01] ========== drmm_connector_hdmi_init (20 subtests) ========== [12:10:01] [PASSED] drm_test_connector_hdmi_init_valid [12:10:01] [PASSED] drm_test_connector_hdmi_init_bpc_8 [12:10:01] [PASSED] drm_test_connector_hdmi_init_bpc_10 [12:10:01] [PASSED] drm_test_connector_hdmi_init_bpc_12 [12:10:01] [PASSED] drm_test_connector_hdmi_init_bpc_invalid [12:10:01] [PASSED] drm_test_connector_hdmi_init_bpc_null [12:10:01] [PASSED] drm_test_connector_hdmi_init_formats_empty [12:10:01] [PASSED] drm_test_connector_hdmi_init_formats_no_rgb [12:10:01] === drm_test_connector_hdmi_init_formats_yuv420_allowed === [12:10:01] [PASSED] supported_formats=0x9 yuv420_allowed=1 [12:10:01] [PASSED] supported_formats=0x9 yuv420_allowed=0 [12:10:01] [PASSED] supported_formats=0x3 yuv420_allowed=1 [12:10:01] [PASSED] supported_formats=0x3 yuv420_allowed=0 [12:10:01] === [PASSED] drm_test_connector_hdmi_init_formats_yuv420_allowed === [12:10:01] [PASSED] drm_test_connector_hdmi_init_null_ddc [12:10:01] [PASSED] drm_test_connector_hdmi_init_null_product [12:10:01] [PASSED] drm_test_connector_hdmi_init_null_vendor [12:10:01] [PASSED] drm_test_connector_hdmi_init_product_length_exact [12:10:01] [PASSED] drm_test_connector_hdmi_init_product_length_too_long [12:10:01] [PASSED] drm_test_connector_hdmi_init_product_valid [12:10:01] [PASSED] drm_test_connector_hdmi_init_vendor_length_exact [12:10:01] [PASSED] drm_test_connector_hdmi_init_vendor_length_too_long [12:10:01] [PASSED] drm_test_connector_hdmi_init_vendor_valid [12:10:01] ========= drm_test_connector_hdmi_init_type_valid ========= [12:10:01] [PASSED] HDMI-A [12:10:01] [PASSED] HDMI-B [12:10:01] ===== [PASSED] drm_test_connector_hdmi_init_type_valid ===== [12:10:01] ======== drm_test_connector_hdmi_init_type_invalid ======== [12:10:01] [PASSED] Unknown [12:10:01] [PASSED] VGA [12:10:01] [PASSED] DVI-I [12:10:01] [PASSED] DVI-D [12:10:01] [PASSED] DVI-A [12:10:01] [PASSED] Composite [12:10:01] [PASSED] SVIDEO [12:10:01] [PASSED] LVDS [12:10:01] [PASSED] Component [12:10:01] [PASSED] DIN [12:10:01] [PASSED] DP [12:10:01] [PASSED] TV [12:10:01] [PASSED] eDP [12:10:01] [PASSED] Virtual [12:10:01] [PASSED] DSI [12:10:01] [PASSED] DPI [12:10:01] [PASSED] Writeback [12:10:01] [PASSED] SPI [12:10:01] [PASSED] USB [12:10:01] ==== [PASSED] drm_test_connector_hdmi_init_type_invalid ==== [12:10:01] ============ [PASSED] drmm_connector_hdmi_init ============= [12:10:01] ============= drmm_connector_init (3 subtests) ============= [12:10:01] [PASSED] drm_test_drmm_connector_init [12:10:01] [PASSED] drm_test_drmm_connector_init_null_ddc [12:10:01] ========= drm_test_drmm_connector_init_type_valid ========= [12:10:01] [PASSED] Unknown [12:10:01] [PASSED] VGA [12:10:01] [PASSED] DVI-I [12:10:01] [PASSED] DVI-D [12:10:01] [PASSED] DVI-A [12:10:01] [PASSED] Composite [12:10:01] [PASSED] SVIDEO [12:10:01] [PASSED] LVDS [12:10:01] [PASSED] Component [12:10:01] [PASSED] DIN [12:10:01] [PASSED] DP [12:10:01] [PASSED] HDMI-A [12:10:01] [PASSED] HDMI-B [12:10:01] [PASSED] TV [12:10:01] [PASSED] eDP [12:10:01] [PASSED] Virtual [12:10:01] [PASSED] DSI [12:10:01] [PASSED] DPI [12:10:01] [PASSED] Writeback [12:10:01] [PASSED] SPI [12:10:01] [PASSED] USB [12:10:01] ===== [PASSED] drm_test_drmm_connector_init_type_valid ===== [12:10:01] =============== [PASSED] drmm_connector_init =============== [12:10:01] ========= drm_connector_dynamic_init (6 subtests) ========== [12:10:01] [PASSED] drm_test_drm_connector_dynamic_init [12:10:01] [PASSED] drm_test_drm_connector_dynamic_init_null_ddc [12:10:01] [PASSED] drm_test_drm_connector_dynamic_init_not_added [12:10:01] [PASSED] drm_test_drm_connector_dynamic_init_properties [12:10:01] ===== drm_test_drm_connector_dynamic_init_type_valid ====== [12:10:01] [PASSED] Unknown [12:10:01] [PASSED] VGA [12:10:01] [PASSED] DVI-I [12:10:01] [PASSED] DVI-D [12:10:01] [PASSED] DVI-A [12:10:01] [PASSED] Composite [12:10:01] [PASSED] SVIDEO [12:10:01] [PASSED] LVDS [12:10:01] [PASSED] Component [12:10:01] [PASSED] DIN [12:10:01] [PASSED] DP [12:10:01] [PASSED] HDMI-A [12:10:01] [PASSED] HDMI-B [12:10:01] [PASSED] TV [12:10:01] [PASSED] eDP [12:10:01] [PASSED] Virtual [12:10:01] [PASSED] DSI [12:10:01] [PASSED] DPI [12:10:01] [PASSED] Writeback [12:10:01] [PASSED] SPI [12:10:01] [PASSED] USB [12:10:01] = [PASSED] drm_test_drm_connector_dynamic_init_type_valid == [12:10:01] ======== drm_test_drm_connector_dynamic_init_name ========= [12:10:01] [PASSED] Unknown [12:10:01] [PASSED] VGA [12:10:01] [PASSED] DVI-I [12:10:01] [PASSED] DVI-D [12:10:01] [PASSED] DVI-A [12:10:01] [PASSED] Composite [12:10:01] [PASSED] SVIDEO [12:10:01] [PASSED] LVDS [12:10:01] [PASSED] Component [12:10:01] [PASSED] DIN [12:10:01] [PASSED] DP [12:10:01] [PASSED] HDMI-A [12:10:01] [PASSED] HDMI-B [12:10:01] [PASSED] TV [12:10:01] [PASSED] eDP [12:10:01] [PASSED] Virtual [12:10:01] [PASSED] DSI [12:10:01] [PASSED] DPI [12:10:01] [PASSED] Writeback [12:10:01] [PASSED] SPI [12:10:01] [PASSED] USB [12:10:01] ==== [PASSED] drm_test_drm_connector_dynamic_init_name ===== [12:10:01] =========== [PASSED] drm_connector_dynamic_init ============ [12:10:01] ==== drm_connector_dynamic_register_early (4 subtests) ===== [12:10:01] [PASSED] drm_test_drm_connector_dynamic_register_early_on_list [12:10:01] [PASSED] drm_test_drm_connector_dynamic_register_early_defer [12:10:01] [PASSED] drm_test_drm_connector_dynamic_register_early_no_init [12:10:01] [PASSED] drm_test_drm_connector_dynamic_register_early_no_mode_object [12:10:01] ====== [PASSED] drm_connector_dynamic_register_early ======= [12:10:01] ======= drm_connector_dynamic_register (7 subtests) ======== [12:10:01] [PASSED] drm_test_drm_connector_dynamic_register_on_list [12:10:01] [PASSED] drm_test_drm_connector_dynamic_register_no_defer [12:10:01] [PASSED] drm_test_drm_connector_dynamic_register_no_init [12:10:01] [PASSED] drm_test_drm_connector_dynamic_register_mode_object [12:10:01] [PASSED] drm_test_drm_connector_dynamic_register_sysfs [12:10:01] [PASSED] drm_test_drm_connector_dynamic_register_sysfs_name [12:10:01] [PASSED] drm_test_drm_connector_dynamic_register_debugfs [12:10:01] ========= [PASSED] drm_connector_dynamic_register ========== [12:10:01] = drm_connector_attach_broadcast_rgb_property (2 subtests) = [12:10:01] [PASSED] drm_test_drm_connector_attach_broadcast_rgb_property [12:10:01] [PASSED] drm_test_drm_connector_attach_broadcast_rgb_property_hdmi_connector [12:10:01] === [PASSED] drm_connector_attach_broadcast_rgb_property === [12:10:01] ========== drm_get_tv_mode_from_name (2 subtests) ========== [12:10:01] ========== drm_test_get_tv_mode_from_name_valid =========== [12:10:01] [PASSED] NTSC [12:10:01] [PASSED] NTSC-443 [12:10:01] [PASSED] NTSC-J [12:10:01] [PASSED] PAL [12:10:01] [PASSED] PAL-M [12:10:01] [PASSED] PAL-N [12:10:01] [PASSED] SECAM [12:10:01] [PASSED] Mono [12:10:01] ====== [PASSED] drm_test_get_tv_mode_from_name_valid ======= [12:10:01] [PASSED] drm_test_get_tv_mode_from_name_truncated [12:10:01] ============ [PASSED] drm_get_tv_mode_from_name ============ [12:10:01] = drm_test_connector_hdmi_compute_mode_clock (12 subtests) = [12:10:01] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb [12:10:01] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb_10bpc [12:10:01] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb_10bpc_vic_1 [12:10:01] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb_12bpc [12:10:01] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb_12bpc_vic_1 [12:10:01] [PASSED] drm_test_drm_hdmi_compute_mode_clock_rgb_double [12:10:01] = drm_test_connector_hdmi_compute_mode_clock_yuv420_valid = [12:10:01] [PASSED] VIC 96 [12:10:01] [PASSED] VIC 97 [12:10:01] [PASSED] VIC 101 [12:10:01] [PASSED] VIC 102 [12:10:01] [PASSED] VIC 106 [12:10:01] [PASSED] VIC 107 [12:10:01] === [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv420_valid === [12:10:01] [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv420_10_bpc [12:10:01] [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv420_12_bpc [12:10:01] [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv422_8_bpc [12:10:01] [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv422_10_bpc [12:10:01] [PASSED] drm_test_connector_hdmi_compute_mode_clock_yuv422_12_bpc [12:10:01] === [PASSED] drm_test_connector_hdmi_compute_mode_clock ==== [12:10:01] == drm_hdmi_connector_get_broadcast_rgb_name (2 subtests) == [12:10:01] === drm_test_drm_hdmi_connector_get_broadcast_rgb_name ==== [12:10:01] [PASSED] Automatic [12:10:01] [PASSED] Full [12:10:01] [PASSED] Limited 16:235 [12:10:01] === [PASSED] drm_test_drm_hdmi_connector_get_broadcast_rgb_name === [12:10:01] [PASSED] drm_test_drm_hdmi_connector_get_broadcast_rgb_name_invalid [12:10:01] ==== [PASSED] drm_hdmi_connector_get_broadcast_rgb_name ==== [12:10:01] == drm_hdmi_connector_get_output_format_name (2 subtests) == [12:10:01] === drm_test_drm_hdmi_connector_get_output_format_name ==== [12:10:01] [PASSED] RGB [12:10:01] [PASSED] YUV 4:2:0 [12:10:01] [PASSED] YUV 4:2:2 [12:10:01] [PASSED] YUV 4:4:4 [12:10:01] === [PASSED] drm_test_drm_hdmi_connector_get_output_format_name === [12:10:01] [PASSED] drm_test_drm_hdmi_connector_get_output_format_name_invalid [12:10:01] ==== [PASSED] drm_hdmi_connector_get_output_format_name ==== [12:10:01] ============= drm_damage_helper (21 subtests) ============== [12:10:01] [PASSED] drm_test_damage_iter_no_damage [12:10:01] [PASSED] drm_test_damage_iter_no_damage_fractional_src [12:10:01] [PASSED] drm_test_damage_iter_no_damage_src_moved [12:10:01] [PASSED] drm_test_damage_iter_no_damage_fractional_src_moved [12:10:01] [PASSED] drm_test_damage_iter_no_damage_not_visible [12:10:01] [PASSED] drm_test_damage_iter_no_damage_no_crtc [12:10:01] [PASSED] drm_test_damage_iter_no_damage_no_fb [12:10:01] [PASSED] drm_test_damage_iter_simple_damage [12:10:01] [PASSED] drm_test_damage_iter_single_damage [12:10:01] [PASSED] drm_test_damage_iter_single_damage_intersect_src [12:10:01] [PASSED] drm_test_damage_iter_single_damage_outside_src [12:10:01] [PASSED] drm_test_damage_iter_single_damage_fractional_src [12:10:01] [PASSED] drm_test_damage_iter_single_damage_intersect_fractional_src [12:10:01] [PASSED] drm_test_damage_iter_single_damage_outside_fractional_src [12:10:01] [PASSED] drm_test_damage_iter_single_damage_src_moved [12:10:01] [PASSED] drm_test_damage_iter_single_damage_fractional_src_moved [12:10:01] [PASSED] drm_test_damage_iter_damage [12:10:01] [PASSED] drm_test_damage_iter_damage_one_intersect [12:10:01] [PASSED] drm_test_damage_iter_damage_one_outside [12:10:01] [PASSED] drm_test_damage_iter_damage_src_moved [12:10:01] [PASSED] drm_test_damage_iter_damage_not_visible [12:10:01] ================ [PASSED] drm_damage_helper ================ [12:10:01] ============== drm_dp_mst_helper (3 subtests) ============== [12:10:01] ============== drm_test_dp_mst_calc_pbn_mode ============== [12:10:01] [PASSED] Clock 154000 BPP 30 DSC disabled [12:10:01] [PASSED] Clock 234000 BPP 30 DSC disabled [12:10:01] [PASSED] Clock 297000 BPP 24 DSC disabled [12:10:01] [PASSED] Clock 332880 BPP 24 DSC enabled [12:10:01] [PASSED] Clock 324540 BPP 24 DSC enabled [12:10:01] ========== [PASSED] drm_test_dp_mst_calc_pbn_mode ========== [12:10:01] ============== drm_test_dp_mst_calc_pbn_div =============== [12:10:01] [PASSED] Link rate 2000000 lane count 4 [12:10:01] [PASSED] Link rate 2000000 lane count 2 [12:10:01] [PASSED] Link rate 2000000 lane count 1 [12:10:01] [PASSED] Link rate 1350000 lane count 4 [12:10:01] [PASSED] Link rate 1350000 lane count 2 [12:10:01] [PASSED] Link rate 1350000 lane count 1 [12:10:01] [PASSED] Link rate 1000000 lane count 4 [12:10:01] [PASSED] Link rate 1000000 lane count 2 [12:10:01] [PASSED] Link rate 1000000 lane count 1 [12:10:01] [PASSED] Link rate 810000 lane count 4 [12:10:01] [PASSED] Link rate 810000 lane count 2 [12:10:01] [PASSED] Link rate 810000 lane count 1 [12:10:01] [PASSED] Link rate 540000 lane count 4 [12:10:01] [PASSED] Link rate 540000 lane count 2 [12:10:01] [PASSED] Link rate 540000 lane count 1 [12:10:01] [PASSED] Link rate 270000 lane count 4 [12:10:01] [PASSED] Link rate 270000 lane count 2 [12:10:01] [PASSED] Link rate 270000 lane count 1 [12:10:01] [PASSED] Link rate 162000 lane count 4 [12:10:01] [PASSED] Link rate 162000 lane count 2 [12:10:01] [PASSED] Link rate 162000 lane count 1 [12:10:01] ========== [PASSED] drm_test_dp_mst_calc_pbn_div =========== [12:10:01] ========= drm_test_dp_mst_sideband_msg_req_decode ========= [12:10:01] [PASSED] DP_ENUM_PATH_RESOURCES with port number [12:10:01] [PASSED] DP_POWER_UP_PHY with port number [12:10:01] [PASSED] DP_POWER_DOWN_PHY with port number [12:10:01] [PASSED] DP_ALLOCATE_PAYLOAD with SDP stream sinks [12:10:01] [PASSED] DP_ALLOCATE_PAYLOAD with port number [12:10:01] [PASSED] DP_ALLOCATE_PAYLOAD with VCPI [12:10:01] [PASSED] DP_ALLOCATE_PAYLOAD with PBN [12:10:01] [PASSED] DP_QUERY_PAYLOAD with port number [12:10:01] [PASSED] DP_QUERY_PAYLOAD with VCPI [12:10:01] [PASSED] DP_REMOTE_DPCD_READ with port number [12:10:01] [PASSED] DP_REMOTE_DPCD_READ with DPCD address [12:10:01] [PASSED] DP_REMOTE_DPCD_READ with max number of bytes [12:10:01] [PASSED] DP_REMOTE_DPCD_WRITE with port number [12:10:01] [PASSED] DP_REMOTE_DPCD_WRITE with DPCD address [12:10:01] [PASSED] DP_REMOTE_DPCD_WRITE with data array [12:10:01] [PASSED] DP_REMOTE_I2C_READ with port number [12:10:01] [PASSED] DP_REMOTE_I2C_READ with I2C device ID [12:10:01] [PASSED] DP_REMOTE_I2C_READ with transactions array [12:10:01] [PASSED] DP_REMOTE_I2C_WRITE with port number [12:10:01] [PASSED] DP_REMOTE_I2C_WRITE with I2C device ID [12:10:01] [PASSED] DP_REMOTE_I2C_WRITE with data array [12:10:01] [PASSED] DP_QUERY_STREAM_ENC_STATUS with stream ID [12:10:01] [PASSED] DP_QUERY_STREAM_ENC_STATUS with client ID [12:10:01] [PASSED] DP_QUERY_STREAM_ENC_STATUS with stream event [12:10:01] [PASSED] DP_QUERY_STREAM_ENC_STATUS with valid stream event [12:10:01] [PASSED] DP_QUERY_STREAM_ENC_STATUS with stream behavior [12:10:01] [PASSED] DP_QUERY_STREAM_ENC_STATUS with a valid stream behavior [12:10:01] ===== [PASSED] drm_test_dp_mst_sideband_msg_req_decode ===== [12:10:01] ================ [PASSED] drm_dp_mst_helper ================ [12:10:01] ================== drm_exec (7 subtests) =================== [12:10:01] [PASSED] sanitycheck [12:10:01] [PASSED] test_lock [12:10:01] [PASSED] test_lock_unlock [12:10:01] [PASSED] test_duplicates [12:10:01] [PASSED] test_prepare [12:10:01] [PASSED] test_prepare_array [12:10:01] [PASSED] test_multiple_loops [12:10:01] ==================== [PASSED] drm_exec ===================== [12:10:01] =========== drm_format_helper_test (17 subtests) =========== [12:10:01] ============== drm_test_fb_xrgb8888_to_gray8 ============== [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ========== [PASSED] drm_test_fb_xrgb8888_to_gray8 ========== [12:10:01] ============= drm_test_fb_xrgb8888_to_rgb332 ============== [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ========= [PASSED] drm_test_fb_xrgb8888_to_rgb332 ========== [12:10:01] ============= drm_test_fb_xrgb8888_to_rgb565 ============== [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ========= [PASSED] drm_test_fb_xrgb8888_to_rgb565 ========== [12:10:01] ============ drm_test_fb_xrgb8888_to_xrgb1555 ============= [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ======== [PASSED] drm_test_fb_xrgb8888_to_xrgb1555 ========= [12:10:01] ============ drm_test_fb_xrgb8888_to_argb1555 ============= [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ======== [PASSED] drm_test_fb_xrgb8888_to_argb1555 ========= [12:10:01] ============ drm_test_fb_xrgb8888_to_rgba5551 ============= [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ======== [PASSED] drm_test_fb_xrgb8888_to_rgba5551 ========= [12:10:01] ============= drm_test_fb_xrgb8888_to_rgb888 ============== [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ========= [PASSED] drm_test_fb_xrgb8888_to_rgb888 ========== [12:10:01] ============= drm_test_fb_xrgb8888_to_bgr888 ============== [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ========= [PASSED] drm_test_fb_xrgb8888_to_bgr888 ========== [12:10:01] ============ drm_test_fb_xrgb8888_to_argb8888 ============= [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ======== [PASSED] drm_test_fb_xrgb8888_to_argb8888 ========= [12:10:01] =========== drm_test_fb_xrgb8888_to_xrgb2101010 =========== [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ======= [PASSED] drm_test_fb_xrgb8888_to_xrgb2101010 ======= [12:10:01] =========== drm_test_fb_xrgb8888_to_argb2101010 =========== [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ======= [PASSED] drm_test_fb_xrgb8888_to_argb2101010 ======= [12:10:01] ============== drm_test_fb_xrgb8888_to_mono =============== [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ========== [PASSED] drm_test_fb_xrgb8888_to_mono =========== [12:10:01] ==================== drm_test_fb_swab ===================== [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ================ [PASSED] drm_test_fb_swab ================= [12:10:01] ============ drm_test_fb_xrgb8888_to_xbgr8888 ============= [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ======== [PASSED] drm_test_fb_xrgb8888_to_xbgr8888 ========= [12:10:01] ============ drm_test_fb_xrgb8888_to_abgr8888 ============= [12:10:01] [PASSED] single_pixel_source_buffer [12:10:01] [PASSED] single_pixel_clip_rectangle [12:10:01] [PASSED] well_known_colors [12:10:01] [PASSED] destination_pitch [12:10:01] ======== [PASSED] drm_test_fb_xrgb8888_to_abgr8888 ========= [12:10:01] ================= drm_test_fb_clip_offset ================= [12:10:01] [PASSED] pass through [12:10:01] [PASSED] horizontal offset [12:10:01] [PASSED] vertical offset [12:10:01] [PASSED] horizontal and vertical offset [12:10:01] [PASSED] horizontal offset (custom pitch) [12:10:01] [PASSED] vertical offset (custom pitch) [12:10:01] [PASSED] horizontal and vertical offset (custom pitch) [12:10:01] ============= [PASSED] drm_test_fb_clip_offset ============= [12:10:01] =================== drm_test_fb_memcpy ==================== [12:10:01] [PASSED] single_pixel_source_buffer: XR24 little-endian (0x34325258) [12:10:01] [PASSED] single_pixel_source_buffer: XRA8 little-endian (0x38415258) [12:10:01] [PASSED] single_pixel_source_buffer: YU24 little-endian (0x34325559) [12:10:01] [PASSED] single_pixel_clip_rectangle: XB24 little-endian (0x34324258) [12:10:01] [PASSED] single_pixel_clip_rectangle: XRA8 little-endian (0x38415258) [12:10:01] [PASSED] single_pixel_clip_rectangle: YU24 little-endian (0x34325559) [12:10:01] [PASSED] well_known_colors: XB24 little-endian (0x34324258) [12:10:01] [PASSED] well_known_colors: XRA8 little-endian (0x38415258) [12:10:01] [PASSED] well_known_colors: YU24 little-endian (0x34325559) [12:10:01] [PASSED] destination_pitch: XB24 little-endian (0x34324258) [12:10:01] [PASSED] destination_pitch: XRA8 little-endian (0x38415258) [12:10:01] [PASSED] destination_pitch: YU24 little-endian (0x34325559) [12:10:01] =============== [PASSED] drm_test_fb_memcpy ================ [12:10:01] ============= [PASSED] drm_format_helper_test ============== [12:10:01] ================= drm_format (18 subtests) ================= [12:10:01] [PASSED] drm_test_format_block_width_invalid [12:10:01] [PASSED] drm_test_format_block_width_one_plane [12:10:01] [PASSED] drm_test_format_block_width_two_plane [12:10:01] [PASSED] drm_test_format_block_width_three_plane [12:10:01] [PASSED] drm_test_format_block_width_tiled [12:10:01] [PASSED] drm_test_format_block_height_invalid [12:10:01] [PASSED] drm_test_format_block_height_one_plane [12:10:01] [PASSED] drm_test_format_block_height_two_plane [12:10:01] [PASSED] drm_test_format_block_height_three_plane [12:10:01] [PASSED] drm_test_format_block_height_tiled [12:10:01] [PASSED] drm_test_format_min_pitch_invalid [12:10:01] [PASSED] drm_test_format_min_pitch_one_plane_8bpp [12:10:01] [PASSED] drm_test_format_min_pitch_one_plane_16bpp [12:10:01] [PASSED] drm_test_format_min_pitch_one_plane_24bpp [12:10:01] [PASSED] drm_test_format_min_pitch_one_plane_32bpp [12:10:01] [PASSED] drm_test_format_min_pitch_two_plane [12:10:01] [PASSED] drm_test_format_min_pitch_three_plane_8bpp [12:10:01] [PASSED] drm_test_format_min_pitch_tiled [12:10:01] =================== [PASSED] drm_format ==================== [12:10:01] ============== drm_framebuffer (10 subtests) =============== [12:10:01] ========== drm_test_framebuffer_check_src_coords ========== [12:10:01] [PASSED] Success: source fits into fb [12:10:01] [PASSED] Fail: overflowing fb with x-axis coordinate [12:10:01] [PASSED] Fail: overflowing fb with y-axis coordinate [12:10:01] [PASSED] Fail: overflowing fb with source width [12:10:01] [PASSED] Fail: overflowing fb with source height [12:10:01] ====== [PASSED] drm_test_framebuffer_check_src_coords ====== [12:10:01] [PASSED] drm_test_framebuffer_cleanup [12:10:01] =============== drm_test_framebuffer_create =============== [12:10:01] [PASSED] ABGR8888 normal sizes [12:10:01] [PASSED] ABGR8888 max sizes [12:10:01] [PASSED] ABGR8888 pitch greater than min required [12:10:01] [PASSED] ABGR8888 pitch less than min required [12:10:01] [PASSED] ABGR8888 Invalid width [12:10:01] [PASSED] ABGR8888 Invalid buffer handle [12:10:01] [PASSED] No pixel format [12:10:01] [PASSED] ABGR8888 Width 0 [12:10:01] [PASSED] ABGR8888 Height 0 [12:10:01] [PASSED] ABGR8888 Out of bound height * pitch combination [12:10:01] [PASSED] ABGR8888 Large buffer offset [12:10:01] [PASSED] ABGR8888 Buffer offset for inexistent plane [12:10:01] [PASSED] ABGR8888 Invalid flag [12:10:01] [PASSED] ABGR8888 Set DRM_MODE_FB_MODIFIERS without modifiers [12:10:01] [PASSED] ABGR8888 Valid buffer modifier [12:10:01] [PASSED] ABGR8888 Invalid buffer modifier(DRM_FORMAT_MOD_SAMSUNG_64_32_TILE) [12:10:01] [PASSED] ABGR8888 Extra pitches without DRM_MODE_FB_MODIFIERS [12:10:01] [PASSED] ABGR8888 Extra pitches with DRM_MODE_FB_MODIFIERS [12:10:01] [PASSED] NV12 Normal sizes [12:10:01] [PASSED] NV12 Max sizes [12:10:01] [PASSED] NV12 Invalid pitch [12:10:01] [PASSED] NV12 Invalid modifier/missing DRM_MODE_FB_MODIFIERS flag [12:10:01] [PASSED] NV12 different modifier per-plane [12:10:01] [PASSED] NV12 with DRM_FORMAT_MOD_SAMSUNG_64_32_TILE [12:10:01] [PASSED] NV12 Valid modifiers without DRM_MODE_FB_MODIFIERS [12:10:01] [PASSED] NV12 Modifier for inexistent plane [12:10:01] [PASSED] NV12 Handle for inexistent plane [12:10:01] [PASSED] NV12 Handle for inexistent plane without DRM_MODE_FB_MODIFIERS [12:10:01] [PASSED] YVU420 DRM_MODE_FB_MODIFIERS set without modifier [12:10:01] [PASSED] YVU420 Normal sizes [12:10:01] [PASSED] YVU420 Max sizes [12:10:01] [PASSED] YVU420 Invalid pitch [12:10:01] [PASSED] YVU420 Different pitches [12:10:01] [PASSED] YVU420 Different buffer offsets/pitches [12:10:01] [PASSED] YVU420 Modifier set just for plane 0, without DRM_MODE_FB_MODIFIERS [12:10:01] [PASSED] YVU420 Modifier set just for planes 0, 1, without DRM_MODE_FB_MODIFIERS [12:10:01] [PASSED] YVU420 Modifier set just for plane 0, 1, with DRM_MODE_FB_MODIFIERS [12:10:01] [PASSED] YVU420 Valid modifier [12:10:01] [PASSED] YVU420 Different modifiers per plane [12:10:01] [PASSED] YVU420 Modifier for inexistent plane [12:10:01] [PASSED] YUV420_10BIT Invalid modifier(DRM_FORMAT_MOD_LINEAR) [12:10:01] [PASSED] X0L2 Normal sizes [12:10:01] [PASSED] X0L2 Max sizes [12:10:01] [PASSED] X0L2 Invalid pitch [12:10:01] [PASSED] X0L2 Pitch greater than minimum required [12:10:01] [PASSED] X0L2 Handle for inexistent plane [12:10:01] [PASSED] X0L2 Offset for inexistent plane, without DRM_MODE_FB_MODIFIERS set [12:10:01] [PASSED] X0L2 Modifier without DRM_MODE_FB_MODIFIERS set [12:10:01] [PASSED] X0L2 Valid modifier [12:10:01] [PASSED] X0L2 Modifier for inexistent plane [12:10:01] =========== [PASSED] drm_test_framebuffer_create =========== [12:10:01] [PASSED] drm_test_framebuffer_free [12:10:01] [PASSED] drm_test_framebuffer_init [12:10:01] [PASSED] drm_test_framebuffer_init_bad_format [12:10:01] [PASSED] drm_test_framebuffer_init_dev_mismatch [12:10:01] [PASSED] drm_test_framebuffer_lookup [12:10:01] [PASSED] drm_test_framebuffer_lookup_inexistent [12:10:01] [PASSED] drm_test_framebuffer_modifiers_not_supported [12:10:01] ================= [PASSED] drm_framebuffer ================= [12:10:01] ================ drm_gem_shmem (8 subtests) ================ [12:10:01] [PASSED] drm_gem_shmem_test_obj_create [12:10:01] [PASSED] drm_gem_shmem_test_obj_create_private [12:10:01] [PASSED] drm_gem_shmem_test_pin_pages [12:10:01] [PASSED] drm_gem_shmem_test_vmap [12:10:01] [PASSED] drm_gem_shmem_test_get_pages_sgt [12:10:01] [PASSED] drm_gem_shmem_test_get_sg_table [12:10:01] [PASSED] drm_gem_shmem_test_madvise [12:10:01] [PASSED] drm_gem_shmem_test_purge [12:10:01] ================== [PASSED] drm_gem_shmem ================== [12:10:01] === drm_atomic_helper_connector_hdmi_check (27 subtests) === [12:10:01] [PASSED] drm_test_check_broadcast_rgb_auto_cea_mode [12:10:01] [PASSED] drm_test_check_broadcast_rgb_auto_cea_mode_vic_1 [12:10:01] [PASSED] drm_test_check_broadcast_rgb_full_cea_mode [12:10:01] [PASSED] drm_test_check_broadcast_rgb_full_cea_mode_vic_1 [12:10:01] [PASSED] drm_test_check_broadcast_rgb_limited_cea_mode [12:10:01] [PASSED] drm_test_check_broadcast_rgb_limited_cea_mode_vic_1 [12:10:01] ====== drm_test_check_broadcast_rgb_cea_mode_yuv420 ======= [12:10:01] [PASSED] Automatic [12:10:01] [PASSED] Full [12:10:01] [PASSED] Limited 16:235 [12:10:01] == [PASSED] drm_test_check_broadcast_rgb_cea_mode_yuv420 === [12:10:01] [PASSED] drm_test_check_broadcast_rgb_crtc_mode_changed [12:10:01] [PASSED] drm_test_check_broadcast_rgb_crtc_mode_not_changed [12:10:01] [PASSED] drm_test_check_disable_connector [12:10:01] [PASSED] drm_test_check_hdmi_funcs_reject_rate [12:10:01] [PASSED] drm_test_check_max_tmds_rate_bpc_fallback_rgb [12:10:01] [PASSED] drm_test_check_max_tmds_rate_bpc_fallback_yuv420 [12:10:01] [PASSED] drm_test_check_max_tmds_rate_bpc_fallback_ignore_yuv422 [12:10:01] [PASSED] drm_test_check_max_tmds_rate_bpc_fallback_ignore_yuv420 [12:10:01] [PASSED] drm_test_check_driver_unsupported_fallback_yuv420 [12:10:01] [PASSED] drm_test_check_output_bpc_crtc_mode_changed [12:10:01] [PASSED] drm_test_check_output_bpc_crtc_mode_not_changed [12:10:01] [PASSED] drm_test_check_output_bpc_dvi [12:10:01] [PASSED] drm_test_check_output_bpc_format_vic_1 [12:10:01] [PASSED] drm_test_check_output_bpc_format_display_8bpc_only [12:10:01] [PASSED] drm_test_check_output_bpc_format_display_rgb_only [12:10:01] [PASSED] drm_test_check_output_bpc_format_driver_8bpc_only [12:10:01] [PASSED] drm_test_check_output_bpc_format_driver_rgb_only [12:10:01] [PASSED] drm_test_check_tmds_char_rate_rgb_8bpc [12:10:01] [PASSED] drm_test_check_tmds_char_rate_rgb_10bpc [12:10:01] [PASSED] drm_test_check_tmds_char_rate_rgb_12bpc [12:10:01] ===== [PASSED] drm_atomic_helper_connector_hdmi_check ====== [12:10:01] === drm_atomic_helper_connector_hdmi_reset (6 subtests) ==== [12:10:01] [PASSED] drm_test_check_broadcast_rgb_value [12:10:01] [PASSED] drm_test_check_bpc_8_value [12:10:01] [PASSED] drm_test_check_bpc_10_value [12:10:01] [PASSED] drm_test_check_bpc_12_value [12:10:01] [PASSED] drm_test_check_format_value [12:10:01] [PASSED] drm_test_check_tmds_char_value [12:10:01] ===== [PASSED] drm_atomic_helper_connector_hdmi_reset ====== [12:10:01] = drm_atomic_helper_connector_hdmi_mode_valid (4 subtests) = [12:10:01] [PASSED] drm_test_check_mode_valid [12:10:01] [PASSED] drm_test_check_mode_valid_reject [12:10:01] [PASSED] drm_test_check_mode_valid_reject_rate [12:10:01] [PASSED] drm_test_check_mode_valid_reject_max_clock [12:10:01] === [PASSED] drm_atomic_helper_connector_hdmi_mode_valid === [12:10:01] ================= drm_managed (2 subtests) ================= [12:10:01] [PASSED] drm_test_managed_release_action [12:10:01] [PASSED] drm_test_managed_run_action [12:10:01] =================== [PASSED] drm_managed =================== [12:10:01] =================== drm_mm (6 subtests) ==================== [12:10:01] [PASSED] drm_test_mm_init [12:10:01] [PASSED] drm_test_mm_debug [12:10:01] [PASSED] drm_test_mm_align32 [12:10:01] [PASSED] drm_test_mm_align64 [12:10:01] [PASSED] drm_test_mm_lowest [12:10:01] [PASSED] drm_test_mm_highest [12:10:01] ===================== [PASSED] drm_mm ====================== [12:10:01] ============= drm_modes_analog_tv (5 subtests) ============= [12:10:01] [PASSED] drm_test_modes_analog_tv_mono_576i [12:10:01] [PASSED] drm_test_modes_analog_tv_ntsc_480i [12:10:01] [PASSED] drm_test_modes_analog_tv_ntsc_480i_inlined [12:10:01] [PASSED] drm_test_modes_analog_tv_pal_576i [12:10:01] [PASSED] drm_test_modes_analog_tv_pal_576i_inlined [12:10:01] =============== [PASSED] drm_modes_analog_tv =============== [12:10:01] ============== drm_plane_helper (2 subtests) =============== [12:10:01] =============== drm_test_check_plane_state ================ [12:10:01] [PASSED] clipping_simple [12:10:01] [PASSED] clipping_rotate_reflect [12:10:01] [PASSED] positioning_simple [12:10:01] [PASSED] upscaling [12:10:01] [PASSED] downscaling [12:10:01] [PASSED] rounding1 [12:10:01] [PASSED] rounding2 [12:10:01] [PASSED] rounding3 [12:10:01] [PASSED] rounding4 [12:10:01] =========== [PASSED] drm_test_check_plane_state ============ [12:10:01] =========== drm_test_check_invalid_plane_state ============ [12:10:01] [PASSED] positioning_invalid [12:10:01] [PASSED] upscaling_invalid [12:10:01] [PASSED] downscaling_invalid [12:10:01] ======= [PASSED] drm_test_check_invalid_plane_state ======== [12:10:01] ================ [PASSED] drm_plane_helper ================= [12:10:01] ====== drm_connector_helper_tv_get_modes (1 subtest) ======= [12:10:01] ====== drm_test_connector_helper_tv_get_modes_check ======= [12:10:01] [PASSED] None [12:10:01] [PASSED] PAL [12:10:01] [PASSED] NTSC [12:10:01] [PASSED] Both, NTSC Default [12:10:01] [PASSED] Both, PAL Default [12:10:01] [PASSED] Both, NTSC Default, with PAL on command-line [12:10:01] [PASSED] Both, PAL Default, with NTSC on command-line [12:10:01] == [PASSED] drm_test_connector_helper_tv_get_modes_check === [12:10:01] ======== [PASSED] drm_connector_helper_tv_get_modes ======== [12:10:01] ================== drm_rect (9 subtests) =================== [12:10:01] [PASSED] drm_test_rect_clip_scaled_div_by_zero [12:10:01] [PASSED] drm_test_rect_clip_scaled_not_clipped [12:10:01] [PASSED] drm_test_rect_clip_scaled_clipped [12:10:01] [PASSED] drm_test_rect_clip_scaled_signed_vs_unsigned [12:10:01] ================= drm_test_rect_intersect ================= [12:10:01] [PASSED] top-left x bottom-right: 2x2+1+1 x 2x2+0+0 [12:10:01] [PASSED] top-right x bottom-left: 2x2+0+0 x 2x2+1-1 [12:10:01] [PASSED] bottom-left x top-right: 2x2+1-1 x 2x2+0+0 [12:10:01] [PASSED] bottom-right x top-left: 2x2+0+0 x 2x2+1+1 [12:10:01] [PASSED] right x left: 2x1+0+0 x 3x1+1+0 [12:10:01] [PASSED] left x right: 3x1+1+0 x 2x1+0+0 [12:10:01] [PASSED] up x bottom: 1x2+0+0 x 1x3+0-1 [12:10:01] [PASSED] bottom x up: 1x3+0-1 x 1x2+0+0 [12:10:01] [PASSED] touching corner: 1x1+0+0 x 2x2+1+1 [12:10:01] [PASSED] touching side: 1x1+0+0 x 1x1+1+0 [12:10:01] [PASSED] equal rects: 2x2+0+0 x 2x2+0+0 [12:10:01] [PASSED] inside another: 2x2+0+0 x 1x1+1+1 [12:10:01] [PASSED] far away: 1x1+0+0 x 1x1+3+6 [12:10:01] [PASSED] points intersecting: 0x0+5+10 x 0x0+5+10 [12:10:01] [PASSED] points not intersecting: 0x0+0+0 x 0x0+5+10 [12:10:01] ============= [PASSED] drm_test_rect_intersect ============= [12:10:01] ================ drm_test_rect_calc_hscale ================ [12:10:01] [PASSED] normal use [12:10:01] [PASSED] out of max range [12:10:01] [PASSED] out of min range [12:10:01] [PASSED] zero dst [12:10:01] [PASSED] negative src [12:10:01] [PASSED] negative dst [12:10:01] ============ [PASSED] drm_test_rect_calc_hscale ============ [12:10:01] ================ drm_test_rect_calc_vscale ================ [12:10:01] [PASSED] normal use [12:10:01] [PASSED] out of max range [12:10:01] [PASSED] out of min range [12:10:01] [PASSED] zero dst [12:10:01] [PASSED] negative src [12:10:01] [PASSED] negative dst [12:10:01] ============ [PASSED] drm_test_rect_calc_vscale ============ [12:10:01] ================== drm_test_rect_rotate =================== [12:10:01] [PASSED] reflect-x [12:10:01] [PASSED] reflect-y [12:10:01] [PASSED] rotate-0 [12:10:01] [PASSED] rotate-90 [12:10:01] [PASSED] rotate-180 [12:10:01] [PASSED] rotate-270 stty: 'standard input': Inappropriate ioctl for device [12:10:01] ============== [PASSED] drm_test_rect_rotate =============== [12:10:01] ================ drm_test_rect_rotate_inv ================= [12:10:01] [PASSED] reflect-x [12:10:01] [PASSED] reflect-y [12:10:01] [PASSED] rotate-0 [12:10:01] [PASSED] rotate-90 [12:10:01] [PASSED] rotate-180 [12:10:01] [PASSED] rotate-270 [12:10:01] ============ [PASSED] drm_test_rect_rotate_inv ============= [12:10:01] ==================== [PASSED] drm_rect ===================== [12:10:01] ============ drm_sysfb_modeset_test (1 subtest) ============ [12:10:01] ============ drm_test_sysfb_build_fourcc_list ============= [12:10:01] [PASSED] no native formats [12:10:01] [PASSED] XRGB8888 as native format [12:10:01] [PASSED] remove duplicates [12:10:01] [PASSED] convert alpha formats [12:10:01] [PASSED] random formats [12:10:01] ======== [PASSED] drm_test_sysfb_build_fourcc_list ========= [12:10:01] ============= [PASSED] drm_sysfb_modeset_test ============== [12:10:01] ============================================================ [12:10:01] Testing complete. Ran 616 tests: passed: 616 [12:10:01] Elapsed time: 24.932s total, 1.775s configuring, 22.990s building, 0.138s running + /kernel/tools/testing/kunit/kunit.py run --kunitconfig /kernel/drivers/gpu/drm/ttm/tests/.kunitconfig [12:10:01] Configuring KUnit Kernel ... Regenerating .config ... Populating config with: $ make ARCH=um O=.kunit olddefconfig [12:10:03] 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=48 [12:10:11] Starting KUnit Kernel (1/1)... [12:10:11] ============================================================ Running tests with: $ .kunit/linux kunit.enable=1 mem=1G console=tty kunit_shutdown=halt [12:10:11] ================= ttm_device (5 subtests) ================== [12:10:11] [PASSED] ttm_device_init_basic [12:10:11] [PASSED] ttm_device_init_multiple [12:10:11] [PASSED] ttm_device_fini_basic [12:10:11] [PASSED] ttm_device_init_no_vma_man [12:10:11] ================== ttm_device_init_pools ================== [12:10:11] [PASSED] No DMA allocations, no DMA32 required [12:10:11] [PASSED] DMA allocations, DMA32 required [12:10:11] [PASSED] No DMA allocations, DMA32 required [12:10:11] [PASSED] DMA allocations, no DMA32 required [12:10:11] ============== [PASSED] ttm_device_init_pools ============== [12:10:11] =================== [PASSED] ttm_device ==================== [12:10:11] ================== ttm_pool (8 subtests) =================== [12:10:11] ================== ttm_pool_alloc_basic =================== [12:10:11] [PASSED] One page [12:10:11] [PASSED] More than one page [12:10:11] [PASSED] Above the allocation limit [12:10:11] [PASSED] One page, with coherent DMA mappings enabled [12:10:11] [PASSED] Above the allocation limit, with coherent DMA mappings enabled [12:10:11] ============== [PASSED] ttm_pool_alloc_basic =============== [12:10:11] ============== ttm_pool_alloc_basic_dma_addr ============== [12:10:11] [PASSED] One page [12:10:11] [PASSED] More than one page [12:10:11] [PASSED] Above the allocation limit [12:10:11] [PASSED] One page, with coherent DMA mappings enabled [12:10:11] [PASSED] Above the allocation limit, with coherent DMA mappings enabled [12:10:11] ========== [PASSED] ttm_pool_alloc_basic_dma_addr ========== [12:10:11] [PASSED] ttm_pool_alloc_order_caching_match [12:10:11] [PASSED] ttm_pool_alloc_caching_mismatch [12:10:11] [PASSED] ttm_pool_alloc_order_mismatch [12:10:11] [PASSED] ttm_pool_free_dma_alloc [12:10:11] [PASSED] ttm_pool_free_no_dma_alloc [12:10:11] [PASSED] ttm_pool_fini_basic [12:10:11] ==================== [PASSED] ttm_pool ===================== [12:10:11] ================ ttm_resource (8 subtests) ================= [12:10:11] ================= ttm_resource_init_basic ================= [12:10:11] [PASSED] Init resource in TTM_PL_SYSTEM [12:10:11] [PASSED] Init resource in TTM_PL_VRAM [12:10:11] [PASSED] Init resource in a private placement [12:10:11] [PASSED] Init resource in TTM_PL_SYSTEM, set placement flags [12:10:11] ============= [PASSED] ttm_resource_init_basic ============= [12:10:11] [PASSED] ttm_resource_init_pinned [12:10:11] [PASSED] ttm_resource_fini_basic [12:10:11] [PASSED] ttm_resource_manager_init_basic [12:10:11] [PASSED] ttm_resource_manager_usage_basic [12:10:11] [PASSED] ttm_resource_manager_set_used_basic [12:10:11] [PASSED] ttm_sys_man_alloc_basic [12:10:11] [PASSED] ttm_sys_man_free_basic [12:10:11] ================== [PASSED] ttm_resource =================== [12:10:11] =================== ttm_tt (15 subtests) =================== [12:10:11] ==================== ttm_tt_init_basic ==================== [12:10:11] [PASSED] Page-aligned size [12:10:11] [PASSED] Extra pages requested [12:10:11] ================ [PASSED] ttm_tt_init_basic ================ [12:10:11] [PASSED] ttm_tt_init_misaligned [12:10:11] [PASSED] ttm_tt_fini_basic [12:10:11] [PASSED] ttm_tt_fini_sg [12:10:11] [PASSED] ttm_tt_fini_shmem [12:10:11] [PASSED] ttm_tt_create_basic [12:10:11] [PASSED] ttm_tt_create_invalid_bo_type [12:10:11] [PASSED] ttm_tt_create_ttm_exists [12:10:11] [PASSED] ttm_tt_create_failed [12:10:11] [PASSED] ttm_tt_destroy_basic [12:10:11] [PASSED] ttm_tt_populate_null_ttm [12:10:11] [PASSED] ttm_tt_populate_populated_ttm [12:10:11] [PASSED] ttm_tt_unpopulate_basic [12:10:11] [PASSED] ttm_tt_unpopulate_empty_ttm [12:10:11] [PASSED] ttm_tt_swapin_basic [12:10:11] ===================== [PASSED] ttm_tt ====================== [12:10:11] =================== ttm_bo (14 subtests) =================== [12:10:11] =========== ttm_bo_reserve_optimistic_no_ticket =========== [12:10:11] [PASSED] Cannot be interrupted and sleeps [12:10:11] [PASSED] Cannot be interrupted, locks straight away [12:10:11] [PASSED] Can be interrupted, sleeps [12:10:11] ======= [PASSED] ttm_bo_reserve_optimistic_no_ticket ======= [12:10:11] [PASSED] ttm_bo_reserve_locked_no_sleep [12:10:11] [PASSED] ttm_bo_reserve_no_wait_ticket [12:10:11] [PASSED] ttm_bo_reserve_double_resv [12:10:11] [PASSED] ttm_bo_reserve_interrupted [12:10:11] [PASSED] ttm_bo_reserve_deadlock [12:10:11] [PASSED] ttm_bo_unreserve_basic [12:10:11] [PASSED] ttm_bo_unreserve_pinned [12:10:11] [PASSED] ttm_bo_unreserve_bulk [12:10:11] [PASSED] ttm_bo_put_basic [12:10:11] [PASSED] ttm_bo_put_shared_resv [12:10:11] [PASSED] ttm_bo_pin_basic [12:10:11] [PASSED] ttm_bo_pin_unpin_resource [12:10:11] [PASSED] ttm_bo_multiple_pin_one_unpin [12:10:11] ===================== [PASSED] ttm_bo ====================== [12:10:11] ============== ttm_bo_validate (21 subtests) =============== [12:10:11] ============== ttm_bo_init_reserved_sys_man =============== [12:10:11] [PASSED] Buffer object for userspace [12:10:11] [PASSED] Kernel buffer object [12:10:11] [PASSED] Shared buffer object [12:10:11] ========== [PASSED] ttm_bo_init_reserved_sys_man =========== [12:10:11] ============== ttm_bo_init_reserved_mock_man ============== [12:10:11] [PASSED] Buffer object for userspace [12:10:11] [PASSED] Kernel buffer object [12:10:11] [PASSED] Shared buffer object [12:10:11] ========== [PASSED] ttm_bo_init_reserved_mock_man ========== [12:10:11] [PASSED] ttm_bo_init_reserved_resv [12:10:11] ================== ttm_bo_validate_basic ================== [12:10:11] [PASSED] Buffer object for userspace [12:10:11] [PASSED] Kernel buffer object [12:10:11] [PASSED] Shared buffer object [12:10:11] ============== [PASSED] ttm_bo_validate_basic ============== [12:10:11] [PASSED] ttm_bo_validate_invalid_placement [12:10:11] ============= ttm_bo_validate_same_placement ============== [12:10:11] [PASSED] System manager [12:10:11] [PASSED] VRAM manager [12:10:11] ========= [PASSED] ttm_bo_validate_same_placement ========== [12:10:11] [PASSED] ttm_bo_validate_failed_alloc [12:10:11] [PASSED] ttm_bo_validate_pinned [12:10:11] [PASSED] ttm_bo_validate_busy_placement [12:10:11] ================ ttm_bo_validate_multihop ================= [12:10:11] [PASSED] Buffer object for userspace [12:10:11] [PASSED] Kernel buffer object [12:10:11] [PASSED] Shared buffer object [12:10:11] ============ [PASSED] ttm_bo_validate_multihop ============= [12:10:11] ========== ttm_bo_validate_no_placement_signaled ========== [12:10:11] [PASSED] Buffer object in system domain, no page vector [12:10:11] [PASSED] Buffer object in system domain with an existing page vector [12:10:11] ====== [PASSED] ttm_bo_validate_no_placement_signaled ====== [12:10:11] ======== ttm_bo_validate_no_placement_not_signaled ======== [12:10:11] [PASSED] Buffer object for userspace [12:10:11] [PASSED] Kernel buffer object [12:10:11] [PASSED] Shared buffer object [12:10:11] ==== [PASSED] ttm_bo_validate_no_placement_not_signaled ==== [12:10:11] [PASSED] ttm_bo_validate_move_fence_signaled [12:10:11] ========= ttm_bo_validate_move_fence_not_signaled ========= [12:10:11] [PASSED] Waits for GPU [12:10:11] [PASSED] Tries to lock straight away [12:10:11] ===== [PASSED] ttm_bo_validate_move_fence_not_signaled ===== [12:10:11] [PASSED] ttm_bo_validate_happy_evict [12:10:11] [PASSED] ttm_bo_validate_all_pinned_evict [12:10:11] [PASSED] ttm_bo_validate_allowed_only_evict [12:10:11] [PASSED] ttm_bo_validate_deleted_evict [12:10:11] [PASSED] ttm_bo_validate_busy_domain_evict [12:10:11] [PASSED] ttm_bo_validate_evict_gutting [12:10:11] [PASSED] ttm_bo_validate_recrusive_evict stty: 'standard input': Inappropriate ioctl for device [12:10:11] ================= [PASSED] ttm_bo_validate ================= [12:10:11] ============================================================ [12:10:11] Testing complete. Ran 101 tests: passed: 101 [12:10:11] Elapsed time: 10.020s total, 1.781s configuring, 8.023s building, 0.188s running + 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 drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 11:53 [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf Thomas Hellström 2025-09-16 12:10 ` ✓ CI.KUnit: success for " Patchwork @ 2025-09-16 12:43 ` Patchwork 2025-09-16 13:03 ` [RFC PATCH] " Matthew Auld ` (2 subsequent siblings) 4 siblings, 0 replies; 14+ messages in thread From: Patchwork @ 2025-09-16 12:43 UTC (permalink / raw) To: Thomas Hellström; +Cc: intel-xe [-- Attachment #1: Type: text/plain, Size: 867 bytes --] == Series Details == Series: drm/xe/dma-buf: Allow pinning of p2p dma-buf URL : https://patchwork.freedesktop.org/series/154593/ State : success == Summary == CI Bug Log - changes from xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2_BAT -> xe-pw-154593v1_BAT ==================================================== Summary ------- **SUCCESS** No regressions found. Participating hosts (11 -> 11) ------------------------------ No changes in participating hosts Changes ------- No changes found Build changes ------------- * Linux: xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2 -> xe-pw-154593v1 IGT_8541: 8541 xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2: ef7574e6dc54e86591031c75cd25cc484f89ead2 xe-pw-154593v1: 154593v1 == Logs == For more details see: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/index.html [-- Attachment #2: Type: text/html, Size: 1415 bytes --] ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 11:53 [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf Thomas Hellström 2025-09-16 12:10 ` ✓ CI.KUnit: success for " Patchwork 2025-09-16 12:43 ` ✓ Xe.CI.BAT: " Patchwork @ 2025-09-16 13:03 ` Matthew Auld 2025-09-16 13:06 ` Thomas Hellström 2025-09-16 14:44 ` ✓ Xe.CI.Full: success for " Patchwork 2025-09-17 5:43 ` [RFC PATCH] " Niranjana Vishwanathapura 4 siblings, 1 reply; 14+ messages in thread From: Matthew Auld @ 2025-09-16 13:03 UTC (permalink / raw) To: Thomas Hellström, intel-xe Cc: Dave Airlie, Simona Vetter, Joonas Lahtinen, Maarten Lankhorst, Matthew Brost, Rodrigo Vivi, Lucas De Marchi On 16/09/2025 12:53, Thomas Hellström wrote: > RDMA NICs typically requires the VRAM dma-bufs to be pinned in > VRAM for pcie-p2p communication, since they don't fully support > the move_notify() scheme. We would like to support that. > > However allowing unaccounted pinning of VRAM creates a DOS vector > so up until now we haven't allowed it. > > However with cgroups support in TTM, the amount of VRAM allocated > to a cgroup can be limited, and since also the pinned memory is > accounted as allocated VRAM we should be safe. > > An analogy with system memory can be made if we observe the > similarity with kernel system memory that is allocated as the > result of user-space action and that is accounted using __GFP_ACCOUNT. > > Ideally, to be more flexible, we would add a "pinned_memory", > or possibly "kernel_memory" limit to the dmem cgroups controller, > that would additionally limit the memory that is pinned in this way. > If we let that limit default to the dmem::max limit we can > introduce that without needing to care about regressions. > > Considering that we already pin VRAM in this way for at least > page-table memory and LRC memory, and the above path to greater > flexibility, allow this also for dma-bufs. > > Cc: Dave Airlie <airlied@gmail.com> > Cc: Simona Vetter <simona.vetter@ffwll.ch> > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> > Cc: Maarten Lankhorst <maarten.lankhorst@intel.com> > Cc: Matthew Brost <matthew.brost@intel.com> > Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> > Cc: Lucas De Marchi <lucas.demarchi@intel.com> > Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com> > --- > drivers/gpu/drm/xe/tests/xe_dma_buf.c | 13 +++++++++ > drivers/gpu/drm/xe/xe_dma_buf.c | 41 +++++++++++++++++---------- > 2 files changed, 39 insertions(+), 15 deletions(-) > > diff --git a/drivers/gpu/drm/xe/tests/xe_dma_buf.c b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > index a7e548a2bdfb..1f88ca71820c 100644 > --- a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > +++ b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > @@ -31,6 +31,7 @@ static void check_residency(struct kunit *test, struct xe_bo *exported, > struct drm_exec *exec) > { > struct dma_buf_test_params *params = to_dma_buf_test_params(test->priv); > + struct dma_buf_attachment *attach; > u32 mem_type; > int ret; > > @@ -88,6 +89,18 @@ static void check_residency(struct kunit *test, struct xe_bo *exported, > > KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, mem_type)); > > + /* Check that we can pin without migrating. */ > + attach = list_first_entry_or_null(&dmabuf->attachments, typeof(*attach), node); > + if (attach) { > + int err = dma_buf_pin(attach); > + > + if (!err) { > + KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, mem_type)); > + dma_buf_unpin(attach); > + } > + KUNIT_EXPECT_EQ(test, err, 0); > + } > + > if (params->force_different_devices) > KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(imported, XE_PL_TT)); > else > diff --git a/drivers/gpu/drm/xe/xe_dma_buf.c b/drivers/gpu/drm/xe/xe_dma_buf.c > index a7d67725c3ee..54e42960daad 100644 > --- a/drivers/gpu/drm/xe/xe_dma_buf.c > +++ b/drivers/gpu/drm/xe/xe_dma_buf.c > @@ -48,32 +48,43 @@ static void xe_dma_buf_detach(struct dma_buf *dmabuf, > > static int xe_dma_buf_pin(struct dma_buf_attachment *attach) > { > - struct drm_gem_object *obj = attach->dmabuf->priv; > + struct dma_buf *dmabuf = attach->dmabuf; > + struct drm_gem_object *obj = dmabuf->priv; > struct xe_bo *bo = gem_to_xe_bo(obj); > struct xe_device *xe = xe_bo_device(bo); > struct drm_exec *exec = XE_VALIDATION_UNSUPPORTED; > + bool allow_vram = true; > int ret; > > - /* > - * For now only support pinning in TT memory, for two reasons: > - * 1) Avoid pinning in a placement not accessible to some importers. > - * 2) Pinning in VRAM requires PIN accounting which is a to-do. > - */ > - if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, XE_PL_TT)) { > + if (!IS_ENABLED(CONFIG_DMABUF_MOVE_NOTIFY)) { > + allow_vram = false; > + } else { > + list_for_each_entry(attach, &dmabuf->attachments, node) { > + if (!attach->peer2peer) { > + allow_vram = false; > + break; > + } > + } > + } > + > + if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, XE_PL_TT) && > + !(xe_bo_is_vram(bo) && allow_vram)) { > drm_dbg(&xe->drm, "Can't migrate pinned bo for dma-buf pin.\n"); > return -EINVAL; > } > > - ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > - if (ret) { > - if (ret != -EINTR && ret != -ERESTARTSYS) > - drm_dbg(&xe->drm, > - "Failed migrating dma-buf to TT memory: %pe\n", > - ERR_PTR(ret)); > - return ret; > + if (!allow_vram) { > + ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > + if (ret) { > + if (ret != -EINTR && ret != -ERESTARTSYS) > + drm_dbg(&xe->drm, > + "Failed migrating dma-buf to TT memory: %pe\n", > + ERR_PTR(ret)); > + return ret; > + } > } > > - ret = xe_bo_pin_external(bo, true, exec); > + ret = xe_bo_pin_external(bo, !allow_vram, exec); Are we also missing save/restore support for such objects? Or at least I can't see where the save flow is happening for externally pinned VRAM? > xe_assert(xe, !ret); > > return 0; ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 13:03 ` [RFC PATCH] " Matthew Auld @ 2025-09-16 13:06 ` Thomas Hellström 2025-09-16 18:02 ` Matthew Brost 2025-09-16 19:53 ` Rodrigo Vivi 0 siblings, 2 replies; 14+ messages in thread From: Thomas Hellström @ 2025-09-16 13:06 UTC (permalink / raw) To: Matthew Auld, intel-xe Cc: Dave Airlie, Simona Vetter, Joonas Lahtinen, Maarten Lankhorst, Matthew Brost, Rodrigo Vivi, Lucas De Marchi On Tue, 2025-09-16 at 14:03 +0100, Matthew Auld wrote: > On 16/09/2025 12:53, Thomas Hellström wrote: > > RDMA NICs typically requires the VRAM dma-bufs to be pinned in > > VRAM for pcie-p2p communication, since they don't fully support > > the move_notify() scheme. We would like to support that. > > > > However allowing unaccounted pinning of VRAM creates a DOS vector > > so up until now we haven't allowed it. > > > > However with cgroups support in TTM, the amount of VRAM allocated > > to a cgroup can be limited, and since also the pinned memory is > > accounted as allocated VRAM we should be safe. > > > > An analogy with system memory can be made if we observe the > > similarity with kernel system memory that is allocated as the > > result of user-space action and that is accounted using > > __GFP_ACCOUNT. > > > > Ideally, to be more flexible, we would add a "pinned_memory", > > or possibly "kernel_memory" limit to the dmem cgroups controller, > > that would additionally limit the memory that is pinned in this > > way. > > If we let that limit default to the dmem::max limit we can > > introduce that without needing to care about regressions. > > > > Considering that we already pin VRAM in this way for at least > > page-table memory and LRC memory, and the above path to greater > > flexibility, allow this also for dma-bufs. > > > > Cc: Dave Airlie <airlied@gmail.com> > > Cc: Simona Vetter <simona.vetter@ffwll.ch> > > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> > > Cc: Maarten Lankhorst <maarten.lankhorst@intel.com> > > Cc: Matthew Brost <matthew.brost@intel.com> > > Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> > > Cc: Lucas De Marchi <lucas.demarchi@intel.com> > > Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com> > > --- > > drivers/gpu/drm/xe/tests/xe_dma_buf.c | 13 +++++++++ > > drivers/gpu/drm/xe/xe_dma_buf.c | 41 +++++++++++++++++----- > > ----- > > 2 files changed, 39 insertions(+), 15 deletions(-) > > > > diff --git a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > index a7e548a2bdfb..1f88ca71820c 100644 > > --- a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > +++ b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > @@ -31,6 +31,7 @@ static void check_residency(struct kunit *test, > > struct xe_bo *exported, > > struct drm_exec *exec) > > { > > struct dma_buf_test_params *params = > > to_dma_buf_test_params(test->priv); > > + struct dma_buf_attachment *attach; > > u32 mem_type; > > int ret; > > > > @@ -88,6 +89,18 @@ static void check_residency(struct kunit *test, > > struct xe_bo *exported, > > > > KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, > > mem_type)); > > > > + /* Check that we can pin without migrating. */ > > + attach = list_first_entry_or_null(&dmabuf->attachments, > > typeof(*attach), node); > > + if (attach) { > > + int err = dma_buf_pin(attach); > > + > > + if (!err) { > > + KUNIT_EXPECT_TRUE(test, > > xe_bo_is_mem_type(exported, mem_type)); > > + dma_buf_unpin(attach); > > + } > > + KUNIT_EXPECT_EQ(test, err, 0); > > + } > > + > > if (params->force_different_devices) > > KUNIT_EXPECT_TRUE(test, > > xe_bo_is_mem_type(imported, XE_PL_TT)); > > else > > diff --git a/drivers/gpu/drm/xe/xe_dma_buf.c > > b/drivers/gpu/drm/xe/xe_dma_buf.c > > index a7d67725c3ee..54e42960daad 100644 > > --- a/drivers/gpu/drm/xe/xe_dma_buf.c > > +++ b/drivers/gpu/drm/xe/xe_dma_buf.c > > @@ -48,32 +48,43 @@ static void xe_dma_buf_detach(struct dma_buf > > *dmabuf, > > > > static int xe_dma_buf_pin(struct dma_buf_attachment *attach) > > { > > - struct drm_gem_object *obj = attach->dmabuf->priv; > > + struct dma_buf *dmabuf = attach->dmabuf; > > + struct drm_gem_object *obj = dmabuf->priv; > > struct xe_bo *bo = gem_to_xe_bo(obj); > > struct xe_device *xe = xe_bo_device(bo); > > struct drm_exec *exec = XE_VALIDATION_UNSUPPORTED; > > + bool allow_vram = true; > > int ret; > > > > - /* > > - * For now only support pinning in TT memory, for two > > reasons: > > - * 1) Avoid pinning in a placement not accessible to some > > importers. > > - * 2) Pinning in VRAM requires PIN accounting which is a > > to-do. > > - */ > > - if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > XE_PL_TT)) { > > + if (!IS_ENABLED(CONFIG_DMABUF_MOVE_NOTIFY)) { > > + allow_vram = false; > > + } else { > > + list_for_each_entry(attach, &dmabuf->attachments, > > node) { > > + if (!attach->peer2peer) { > > + allow_vram = false; > > + break; > > + } > > + } > > + } > > + > > + if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > XE_PL_TT) && > > + !(xe_bo_is_vram(bo) && allow_vram)) { > > drm_dbg(&xe->drm, "Can't migrate pinned bo for > > dma-buf pin.\n"); > > return -EINVAL; > > } > > > > - ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > - if (ret) { > > - if (ret != -EINTR && ret != -ERESTARTSYS) > > - drm_dbg(&xe->drm, > > - "Failed migrating dma-buf to TT > > memory: %pe\n", > > - ERR_PTR(ret)); > > - return ret; > > + if (!allow_vram) { > > + ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > + if (ret) { > > + if (ret != -EINTR && ret != -ERESTARTSYS) > > + drm_dbg(&xe->drm, > > + "Failed migrating dma-buf > > to TT memory: %pe\n", > > + ERR_PTR(ret)); > > + return ret; > > + } > > } > > > > - ret = xe_bo_pin_external(bo, true, exec); > > + ret = xe_bo_pin_external(bo, !allow_vram, exec); > > Are we also missing save/restore support for such objects? Or at > least I > can't see where the save flow is happening for externally pinned > VRAM? Good point. I forgot about that. IIRC we once made a deliberate decision to leave that out since we didn't support it. I'll have a look at that as well depending if we decide to go ahead with this. /Thomas > > > xe_assert(xe, !ret); > > > > return 0; > ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 13:06 ` Thomas Hellström @ 2025-09-16 18:02 ` Matthew Brost 2025-09-16 18:54 ` Thomas Hellström 2025-09-16 19:53 ` Rodrigo Vivi 1 sibling, 1 reply; 14+ messages in thread From: Matthew Brost @ 2025-09-16 18:02 UTC (permalink / raw) To: Thomas Hellström Cc: Matthew Auld, intel-xe, Dave Airlie, Simona Vetter, Joonas Lahtinen, Maarten Lankhorst, Rodrigo Vivi, Lucas De Marchi On Tue, Sep 16, 2025 at 03:06:48PM +0200, Thomas Hellström wrote: > On Tue, 2025-09-16 at 14:03 +0100, Matthew Auld wrote: > > On 16/09/2025 12:53, Thomas Hellström wrote: > > > RDMA NICs typically requires the VRAM dma-bufs to be pinned in > > > VRAM for pcie-p2p communication, since they don't fully support > > > the move_notify() scheme. We would like to support that. > > > > > > However allowing unaccounted pinning of VRAM creates a DOS vector > > > so up until now we haven't allowed it. > > > > > > However with cgroups support in TTM, the amount of VRAM allocated > > > to a cgroup can be limited, and since also the pinned memory is > > > accounted as allocated VRAM we should be safe. > > > > > > An analogy with system memory can be made if we observe the > > > similarity with kernel system memory that is allocated as the > > > result of user-space action and that is accounted using > > > __GFP_ACCOUNT. > > > > > > Ideally, to be more flexible, we would add a "pinned_memory", > > > or possibly "kernel_memory" limit to the dmem cgroups controller, > > > that would additionally limit the memory that is pinned in this > > > way. > > > If we let that limit default to the dmem::max limit we can > > > introduce that without needing to care about regressions. > > > > > > Considering that we already pin VRAM in this way for at least > > > page-table memory and LRC memory, and the above path to greater > > > flexibility, allow this also for dma-bufs. > > > > > > Cc: Dave Airlie <airlied@gmail.com> > > > Cc: Simona Vetter <simona.vetter@ffwll.ch> > > > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> > > > Cc: Maarten Lankhorst <maarten.lankhorst@intel.com> > > > Cc: Matthew Brost <matthew.brost@intel.com> > > > Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> > > > Cc: Lucas De Marchi <lucas.demarchi@intel.com> > > > Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com> > > > --- > > > drivers/gpu/drm/xe/tests/xe_dma_buf.c | 13 +++++++++ > > > drivers/gpu/drm/xe/xe_dma_buf.c | 41 +++++++++++++++++----- > > > ----- > > > 2 files changed, 39 insertions(+), 15 deletions(-) > > > > > > diff --git a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > index a7e548a2bdfb..1f88ca71820c 100644 > > > --- a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > +++ b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > @@ -31,6 +31,7 @@ static void check_residency(struct kunit *test, > > > struct xe_bo *exported, > > > struct drm_exec *exec) > > > { > > > struct dma_buf_test_params *params = > > > to_dma_buf_test_params(test->priv); > > > + struct dma_buf_attachment *attach; > > > u32 mem_type; > > > int ret; > > > > > > @@ -88,6 +89,18 @@ static void check_residency(struct kunit *test, > > > struct xe_bo *exported, > > > > > > KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, > > > mem_type)); > > > > > > + /* Check that we can pin without migrating. */ > > > + attach = list_first_entry_or_null(&dmabuf->attachments, > > > typeof(*attach), node); > > > + if (attach) { > > > + int err = dma_buf_pin(attach); > > > + > > > + if (!err) { > > > + KUNIT_EXPECT_TRUE(test, > > > xe_bo_is_mem_type(exported, mem_type)); > > > + dma_buf_unpin(attach); > > > + } > > > + KUNIT_EXPECT_EQ(test, err, 0); > > > + } > > > + > > > if (params->force_different_devices) > > > KUNIT_EXPECT_TRUE(test, > > > xe_bo_is_mem_type(imported, XE_PL_TT)); > > > else > > > diff --git a/drivers/gpu/drm/xe/xe_dma_buf.c > > > b/drivers/gpu/drm/xe/xe_dma_buf.c > > > index a7d67725c3ee..54e42960daad 100644 > > > --- a/drivers/gpu/drm/xe/xe_dma_buf.c > > > +++ b/drivers/gpu/drm/xe/xe_dma_buf.c > > > @@ -48,32 +48,43 @@ static void xe_dma_buf_detach(struct dma_buf > > > *dmabuf, > > > > > > static int xe_dma_buf_pin(struct dma_buf_attachment *attach) > > > { > > > - struct drm_gem_object *obj = attach->dmabuf->priv; > > > + struct dma_buf *dmabuf = attach->dmabuf; > > > + struct drm_gem_object *obj = dmabuf->priv; > > > struct xe_bo *bo = gem_to_xe_bo(obj); > > > struct xe_device *xe = xe_bo_device(bo); > > > struct drm_exec *exec = XE_VALIDATION_UNSUPPORTED; > > > + bool allow_vram = true; > > > int ret; > > > > > > - /* > > > - * For now only support pinning in TT memory, for two > > > reasons: > > > - * 1) Avoid pinning in a placement not accessible to some > > > importers. > > > - * 2) Pinning in VRAM requires PIN accounting which is a > > > to-do. > > > - */ > > > - if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > XE_PL_TT)) { > > > + if (!IS_ENABLED(CONFIG_DMABUF_MOVE_NOTIFY)) { > > > + allow_vram = false; > > > + } else { > > > + list_for_each_entry(attach, &dmabuf->attachments, > > > node) { > > > + if (!attach->peer2peer) { > > > + allow_vram = false; > > > + break; > > > + } > > > + } > > > + } > > > + > > > + if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > XE_PL_TT) && > > > + !(xe_bo_is_vram(bo) && allow_vram)) { > > > drm_dbg(&xe->drm, "Can't migrate pinned bo for > > > dma-buf pin.\n"); > > > return -EINVAL; > > > } > > > > > > - ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > > - if (ret) { > > > - if (ret != -EINTR && ret != -ERESTARTSYS) > > > - drm_dbg(&xe->drm, > > > - "Failed migrating dma-buf to TT > > > memory: %pe\n", > > > - ERR_PTR(ret)); > > > - return ret; > > > + if (!allow_vram) { > > > + ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > > + if (ret) { > > > + if (ret != -EINTR && ret != -ERESTARTSYS) > > > + drm_dbg(&xe->drm, > > > + "Failed migrating dma-buf > > > to TT memory: %pe\n", > > > + ERR_PTR(ret)); > > > + return ret; > > > + } > > > } > > > > > > - ret = xe_bo_pin_external(bo, true, exec); > > > + ret = xe_bo_pin_external(bo, !allow_vram, exec); > > > > Are we also missing save/restore support for such objects? Or at > > least I > > can't see where the save flow is happening for externally pinned > > VRAM? > > Good point. I forgot about that. IIRC we once made a deliberate > decision to leave that out since we didn't support it. > > I'll have a look at that as well depending if we decide to go > ahead with this. > Don't we take a PM ref exporting device in xe_dma_buf_attach? So when memory attached to (or pinned in this case) we can't go through save / restore flows as the device should be awake? Matt > /Thomas > > > > > > xe_assert(xe, !ret); > > > > > > return 0; > > > ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 18:02 ` Matthew Brost @ 2025-09-16 18:54 ` Thomas Hellström 2025-09-17 8:48 ` Maarten Lankhorst 0 siblings, 1 reply; 14+ messages in thread From: Thomas Hellström @ 2025-09-16 18:54 UTC (permalink / raw) To: Matthew Brost Cc: Matthew Auld, intel-xe, Dave Airlie, Simona Vetter, Joonas Lahtinen, Maarten Lankhorst, Rodrigo Vivi, Lucas De Marchi On Tue, 2025-09-16 at 11:02 -0700, Matthew Brost wrote: > On Tue, Sep 16, 2025 at 03:06:48PM +0200, Thomas Hellström wrote: > > On Tue, 2025-09-16 at 14:03 +0100, Matthew Auld wrote: > > > On 16/09/2025 12:53, Thomas Hellström wrote: > > > > RDMA NICs typically requires the VRAM dma-bufs to be pinned in > > > > VRAM for pcie-p2p communication, since they don't fully support > > > > the move_notify() scheme. We would like to support that. > > > > > > > > However allowing unaccounted pinning of VRAM creates a DOS > > > > vector > > > > so up until now we haven't allowed it. > > > > > > > > However with cgroups support in TTM, the amount of VRAM > > > > allocated > > > > to a cgroup can be limited, and since also the pinned memory is > > > > accounted as allocated VRAM we should be safe. > > > > > > > > An analogy with system memory can be made if we observe the > > > > similarity with kernel system memory that is allocated as the > > > > result of user-space action and that is accounted using > > > > __GFP_ACCOUNT. > > > > > > > > Ideally, to be more flexible, we would add a "pinned_memory", > > > > or possibly "kernel_memory" limit to the dmem cgroups > > > > controller, > > > > that would additionally limit the memory that is pinned in this > > > > way. > > > > If we let that limit default to the dmem::max limit we can > > > > introduce that without needing to care about regressions. > > > > > > > > Considering that we already pin VRAM in this way for at least > > > > page-table memory and LRC memory, and the above path to greater > > > > flexibility, allow this also for dma-bufs. > > > > > > > > Cc: Dave Airlie <airlied@gmail.com> > > > > Cc: Simona Vetter <simona.vetter@ffwll.ch> > > > > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> > > > > Cc: Maarten Lankhorst <maarten.lankhorst@intel.com> > > > > Cc: Matthew Brost <matthew.brost@intel.com> > > > > Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> > > > > Cc: Lucas De Marchi <lucas.demarchi@intel.com> > > > > Signed-off-by: Thomas Hellström > > > > <thomas.hellstrom@linux.intel.com> > > > > --- > > > > drivers/gpu/drm/xe/tests/xe_dma_buf.c | 13 +++++++++ > > > > drivers/gpu/drm/xe/xe_dma_buf.c | 41 +++++++++++++++++- > > > > ---- > > > > ----- > > > > 2 files changed, 39 insertions(+), 15 deletions(-) > > > > > > > > diff --git a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > index a7e548a2bdfb..1f88ca71820c 100644 > > > > --- a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > +++ b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > @@ -31,6 +31,7 @@ static void check_residency(struct kunit > > > > *test, > > > > struct xe_bo *exported, > > > > struct drm_exec *exec) > > > > { > > > > struct dma_buf_test_params *params = > > > > to_dma_buf_test_params(test->priv); > > > > + struct dma_buf_attachment *attach; > > > > u32 mem_type; > > > > int ret; > > > > > > > > @@ -88,6 +89,18 @@ static void check_residency(struct kunit > > > > *test, > > > > struct xe_bo *exported, > > > > > > > > KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, > > > > mem_type)); > > > > > > > > + /* Check that we can pin without migrating. */ > > > > + attach = list_first_entry_or_null(&dmabuf- > > > > >attachments, > > > > typeof(*attach), node); > > > > + if (attach) { > > > > + int err = dma_buf_pin(attach); > > > > + > > > > + if (!err) { > > > > + KUNIT_EXPECT_TRUE(test, > > > > xe_bo_is_mem_type(exported, mem_type)); > > > > + dma_buf_unpin(attach); > > > > + } > > > > + KUNIT_EXPECT_EQ(test, err, 0); > > > > + } > > > > + > > > > if (params->force_different_devices) > > > > KUNIT_EXPECT_TRUE(test, > > > > xe_bo_is_mem_type(imported, XE_PL_TT)); > > > > else > > > > diff --git a/drivers/gpu/drm/xe/xe_dma_buf.c > > > > b/drivers/gpu/drm/xe/xe_dma_buf.c > > > > index a7d67725c3ee..54e42960daad 100644 > > > > --- a/drivers/gpu/drm/xe/xe_dma_buf.c > > > > +++ b/drivers/gpu/drm/xe/xe_dma_buf.c > > > > @@ -48,32 +48,43 @@ static void xe_dma_buf_detach(struct > > > > dma_buf > > > > *dmabuf, > > > > > > > > static int xe_dma_buf_pin(struct dma_buf_attachment *attach) > > > > { > > > > - struct drm_gem_object *obj = attach->dmabuf->priv; > > > > + struct dma_buf *dmabuf = attach->dmabuf; > > > > + struct drm_gem_object *obj = dmabuf->priv; > > > > struct xe_bo *bo = gem_to_xe_bo(obj); > > > > struct xe_device *xe = xe_bo_device(bo); > > > > struct drm_exec *exec = XE_VALIDATION_UNSUPPORTED; > > > > + bool allow_vram = true; > > > > int ret; > > > > > > > > - /* > > > > - * For now only support pinning in TT memory, for two > > > > reasons: > > > > - * 1) Avoid pinning in a placement not accessible to > > > > some > > > > importers. > > > > - * 2) Pinning in VRAM requires PIN accounting which is > > > > a > > > > to-do. > > > > - */ > > > > - if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > > XE_PL_TT)) { > > > > + if (!IS_ENABLED(CONFIG_DMABUF_MOVE_NOTIFY)) { > > > > + allow_vram = false; > > > > + } else { > > > > + list_for_each_entry(attach, &dmabuf- > > > > >attachments, > > > > node) { > > > > + if (!attach->peer2peer) { > > > > + allow_vram = false; > > > > + break; > > > > + } > > > > + } > > > > + } > > > > + > > > > + if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > > XE_PL_TT) && > > > > + !(xe_bo_is_vram(bo) && allow_vram)) { > > > > drm_dbg(&xe->drm, "Can't migrate pinned bo for > > > > dma-buf pin.\n"); > > > > return -EINVAL; > > > > } > > > > > > > > - ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > > > - if (ret) { > > > > - if (ret != -EINTR && ret != -ERESTARTSYS) > > > > - drm_dbg(&xe->drm, > > > > - "Failed migrating dma-buf to > > > > TT > > > > memory: %pe\n", > > > > - ERR_PTR(ret)); > > > > - return ret; > > > > + if (!allow_vram) { > > > > + ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > > > + if (ret) { > > > > + if (ret != -EINTR && ret != - > > > > ERESTARTSYS) > > > > + drm_dbg(&xe->drm, > > > > + "Failed migrating dma- > > > > buf > > > > to TT memory: %pe\n", > > > > + ERR_PTR(ret)); > > > > + return ret; > > > > + } > > > > } > > > > > > > > - ret = xe_bo_pin_external(bo, true, exec); > > > > + ret = xe_bo_pin_external(bo, !allow_vram, exec); > > > > > > Are we also missing save/restore support for such objects? Or at > > > least I > > > can't see where the save flow is happening for externally pinned > > > VRAM? > > > > Good point. I forgot about that. IIRC we once made a deliberate > > decision to leave that out since we didn't support it. > > > > I'll have a look at that as well depending if we decide to go > > ahead with this. > > > > Don't we take a PM ref exporting device in xe_dma_buf_attach? So when > memory attached to (or pinned in this case) we can't go through save > / > restore flows as the device should be awake? Yes, rpm save/restore should not happen, however system suspend or hibernate may. /Thomas > > Matt > > > /Thomas > > > > > > > > > xe_assert(xe, !ret); > > > > > > > > return 0; > > > > > ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 18:54 ` Thomas Hellström @ 2025-09-17 8:48 ` Maarten Lankhorst 2025-09-19 7:11 ` Thomas Hellström 0 siblings, 1 reply; 14+ messages in thread From: Maarten Lankhorst @ 2025-09-17 8:48 UTC (permalink / raw) To: Thomas Hellström, Matthew Brost Cc: Matthew Auld, intel-xe, Dave Airlie, Simona Vetter, Joonas Lahtinen, Rodrigo Vivi, Lucas De Marchi Hey, On 2025-09-16 20:54, Thomas Hellström wrote: > On Tue, 2025-09-16 at 11:02 -0700, Matthew Brost wrote: >> On Tue, Sep 16, 2025 at 03:06:48PM +0200, Thomas Hellström wrote: >>> On Tue, 2025-09-16 at 14:03 +0100, Matthew Auld wrote: >>>> On 16/09/2025 12:53, Thomas Hellström wrote: >>>>> RDMA NICs typically requires the VRAM dma-bufs to be pinned in >>>>> VRAM for pcie-p2p communication, since they don't fully support >>>>> the move_notify() scheme. We would like to support that. >>>>> >>>>> However allowing unaccounted pinning of VRAM creates a DOS >>>>> vector >>>>> so up until now we haven't allowed it. >>>>> >>>>> However with cgroups support in TTM, the amount of VRAM >>>>> allocated >>>>> to a cgroup can be limited, and since also the pinned memory is >>>>> accounted as allocated VRAM we should be safe. >>>>> >>>>> An analogy with system memory can be made if we observe the >>>>> similarity with kernel system memory that is allocated as the >>>>> result of user-space action and that is accounted using >>>>> __GFP_ACCOUNT. >>>>> >>>>> Ideally, to be more flexible, we would add a "pinned_memory", >>>>> or possibly "kernel_memory" limit to the dmem cgroups >>>>> controller, >>>>> that would additionally limit the memory that is pinned in this >>>>> way. >>>>> If we let that limit default to the dmem::max limit we can >>>>> introduce that without needing to care about regressions. >>>>> >>>>> Considering that we already pin VRAM in this way for at least >>>>> page-table memory and LRC memory, and the above path to greater >>>>> flexibility, allow this also for dma-bufs. >>>>> >>>>> Cc: Dave Airlie <airlied@gmail.com> >>>>> Cc: Simona Vetter <simona.vetter@ffwll.ch> >>>>> Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> >>>>> Cc: Maarten Lankhorst <maarten.lankhorst@intel.com> >>>>> Cc: Matthew Brost <matthew.brost@intel.com> >>>>> Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> >>>>> Cc: Lucas De Marchi <lucas.demarchi@intel.com> >>>>> Signed-off-by: Thomas Hellström >>>>> <thomas.hellstrom@linux.intel.com> >>>>> --- >>>>> drivers/gpu/drm/xe/tests/xe_dma_buf.c | 13 +++++++++ >>>>> drivers/gpu/drm/xe/xe_dma_buf.c | 41 +++++++++++++++++- >>>>> ---- >>>>> ----- >>>>> 2 files changed, 39 insertions(+), 15 deletions(-) >>>>> >>>>> diff --git a/drivers/gpu/drm/xe/tests/xe_dma_buf.c >>>>> b/drivers/gpu/drm/xe/tests/xe_dma_buf.c >>>>> index a7e548a2bdfb..1f88ca71820c 100644 >>>>> --- a/drivers/gpu/drm/xe/tests/xe_dma_buf.c >>>>> +++ b/drivers/gpu/drm/xe/tests/xe_dma_buf.c >>>>> @@ -31,6 +31,7 @@ static void check_residency(struct kunit >>>>> *test, >>>>> struct xe_bo *exported, >>>>> struct drm_exec *exec) >>>>> { >>>>> struct dma_buf_test_params *params = >>>>> to_dma_buf_test_params(test->priv); >>>>> + struct dma_buf_attachment *attach; >>>>> u32 mem_type; >>>>> int ret; >>>>> >>>>> @@ -88,6 +89,18 @@ static void check_residency(struct kunit >>>>> *test, >>>>> struct xe_bo *exported, >>>>> >>>>> KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, >>>>> mem_type)); >>>>> >>>>> + /* Check that we can pin without migrating. */ >>>>> + attach = list_first_entry_or_null(&dmabuf- >>>>>> attachments, >>>>> typeof(*attach), node); >>>>> + if (attach) { >>>>> + int err = dma_buf_pin(attach); >>>>> + >>>>> + if (!err) { >>>>> + KUNIT_EXPECT_TRUE(test, >>>>> xe_bo_is_mem_type(exported, mem_type)); >>>>> + dma_buf_unpin(attach); >>>>> + } >>>>> + KUNIT_EXPECT_EQ(test, err, 0); >>>>> + } >>>>> + >>>>> if (params->force_different_devices) >>>>> KUNIT_EXPECT_TRUE(test, >>>>> xe_bo_is_mem_type(imported, XE_PL_TT)); >>>>> else >>>>> diff --git a/drivers/gpu/drm/xe/xe_dma_buf.c >>>>> b/drivers/gpu/drm/xe/xe_dma_buf.c >>>>> index a7d67725c3ee..54e42960daad 100644 >>>>> --- a/drivers/gpu/drm/xe/xe_dma_buf.c >>>>> +++ b/drivers/gpu/drm/xe/xe_dma_buf.c >>>>> @@ -48,32 +48,43 @@ static void xe_dma_buf_detach(struct >>>>> dma_buf >>>>> *dmabuf, >>>>> >>>>> static int xe_dma_buf_pin(struct dma_buf_attachment *attach) >>>>> { >>>>> - struct drm_gem_object *obj = attach->dmabuf->priv; >>>>> + struct dma_buf *dmabuf = attach->dmabuf; >>>>> + struct drm_gem_object *obj = dmabuf->priv; >>>>> struct xe_bo *bo = gem_to_xe_bo(obj); >>>>> struct xe_device *xe = xe_bo_device(bo); >>>>> struct drm_exec *exec = XE_VALIDATION_UNSUPPORTED; >>>>> + bool allow_vram = true; >>>>> int ret; >>>>> >>>>> - /* >>>>> - * For now only support pinning in TT memory, for two >>>>> reasons: >>>>> - * 1) Avoid pinning in a placement not accessible to >>>>> some >>>>> importers. >>>>> - * 2) Pinning in VRAM requires PIN accounting which is >>>>> a >>>>> to-do. >>>>> - */ >>>>> - if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, >>>>> XE_PL_TT)) { >>>>> + if (!IS_ENABLED(CONFIG_DMABUF_MOVE_NOTIFY)) { >>>>> + allow_vram = false; >>>>> + } else { >>>>> + list_for_each_entry(attach, &dmabuf- >>>>>> attachments, >>>>> node) { >>>>> + if (!attach->peer2peer) { >>>>> + allow_vram = false; >>>>> + break; >>>>> + } >>>>> + } >>>>> + } >>>>> + >>>>> + if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, >>>>> XE_PL_TT) && >>>>> + !(xe_bo_is_vram(bo) && allow_vram)) { >>>>> drm_dbg(&xe->drm, "Can't migrate pinned bo for >>>>> dma-buf pin.\n"); >>>>> return -EINVAL; >>>>> } >>>>> >>>>> - ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); >>>>> - if (ret) { >>>>> - if (ret != -EINTR && ret != -ERESTARTSYS) >>>>> - drm_dbg(&xe->drm, >>>>> - "Failed migrating dma-buf to >>>>> TT >>>>> memory: %pe\n", >>>>> - ERR_PTR(ret)); >>>>> - return ret; >>>>> + if (!allow_vram) { >>>>> + ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); >>>>> + if (ret) { >>>>> + if (ret != -EINTR && ret != - >>>>> ERESTARTSYS) >>>>> + drm_dbg(&xe->drm, >>>>> + "Failed migrating dma- >>>>> buf >>>>> to TT memory: %pe\n", >>>>> + ERR_PTR(ret)); >>>>> + return ret; >>>>> + } >>>>> } >>>>> >>>>> - ret = xe_bo_pin_external(bo, true, exec); >>>>> + ret = xe_bo_pin_external(bo, !allow_vram, exec); >>>> Are we also missing save/restore support for such objects? Or at >>>> least I >>>> can't see where the save flow is happening for externally pinned >>>> VRAM? >>> Good point. I forgot about that. IIRC we once made a deliberate >>> decision to leave that out since we didn't support it. >>> >>> I'll have a look at that as well depending if we decide to go >>> ahead with this. >>> >> Don't we take a PM ref exporting device in xe_dma_buf_attach? So when >> memory attached to (or pinned in this case) we can't go through save >> / >> restore flows as the device should be awake? > Yes, rpm save/restore should not happen, however system suspend or > hibernate may. Just a quick review: A call to ttm_bo_validate() is missing to ensure we don't pin while in wrong placement or swapped out. By default the dmem cgroup controller is not yet used by most distributions, so introducing and using separate max_pinned + actually pinned accounting would work. It would make sense to make it first come first serve, which makes accounting simple. This would make the semantics the same as the first time hitting 'max' limit, but without the possibility for eviction. This will likely work better than re-using the 'min' semantics, since they serve different purposes. One might want to allow pinning, but not want to pin memory by default unless needed. Kind regards, ~Maarten ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-17 8:48 ` Maarten Lankhorst @ 2025-09-19 7:11 ` Thomas Hellström 0 siblings, 0 replies; 14+ messages in thread From: Thomas Hellström @ 2025-09-19 7:11 UTC (permalink / raw) To: Maarten Lankhorst, Matthew Brost Cc: Matthew Auld, intel-xe, Dave Airlie, Simona Vetter, Joonas Lahtinen, Rodrigo Vivi, Lucas De Marchi Hi, Maarten. On Wed, 2025-09-17 at 10:48 +0200, Maarten Lankhorst wrote: > Hey, > > On 2025-09-16 20:54, Thomas Hellström wrote: > > On Tue, 2025-09-16 at 11:02 -0700, Matthew Brost wrote: > > > On Tue, Sep 16, 2025 at 03:06:48PM +0200, Thomas Hellström wrote: > > > > On Tue, 2025-09-16 at 14:03 +0100, Matthew Auld wrote: > > > > > On 16/09/2025 12:53, Thomas Hellström wrote: > > > > > > RDMA NICs typically requires the VRAM dma-bufs to be pinned > > > > > > in > > > > > > VRAM for pcie-p2p communication, since they don't fully > > > > > > support > > > > > > the move_notify() scheme. We would like to support that. > > > > > > > > > > > > However allowing unaccounted pinning of VRAM creates a DOS > > > > > > vector > > > > > > so up until now we haven't allowed it. > > > > > > > > > > > > However with cgroups support in TTM, the amount of VRAM > > > > > > allocated > > > > > > to a cgroup can be limited, and since also the pinned > > > > > > memory is > > > > > > accounted as allocated VRAM we should be safe. > > > > > > > > > > > > An analogy with system memory can be made if we observe the > > > > > > similarity with kernel system memory that is allocated as > > > > > > the > > > > > > result of user-space action and that is accounted using > > > > > > __GFP_ACCOUNT. > > > > > > > > > > > > Ideally, to be more flexible, we would add a > > > > > > "pinned_memory", > > > > > > or possibly "kernel_memory" limit to the dmem cgroups > > > > > > controller, > > > > > > that would additionally limit the memory that is pinned in > > > > > > this > > > > > > way. > > > > > > If we let that limit default to the dmem::max limit we can > > > > > > introduce that without needing to care about regressions. > > > > > > > > > > > > Considering that we already pin VRAM in this way for at > > > > > > least > > > > > > page-table memory and LRC memory, and the above path to > > > > > > greater > > > > > > flexibility, allow this also for dma-bufs. > > > > > > > > > > > > Cc: Dave Airlie <airlied@gmail.com> > > > > > > Cc: Simona Vetter <simona.vetter@ffwll.ch> > > > > > > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> > > > > > > Cc: Maarten Lankhorst <maarten.lankhorst@intel.com> > > > > > > Cc: Matthew Brost <matthew.brost@intel.com> > > > > > > Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> > > > > > > Cc: Lucas De Marchi <lucas.demarchi@intel.com> > > > > > > Signed-off-by: Thomas Hellström > > > > > > <thomas.hellstrom@linux.intel.com> > > > > > > --- > > > > > > drivers/gpu/drm/xe/tests/xe_dma_buf.c | 13 +++++++++ > > > > > > drivers/gpu/drm/xe/xe_dma_buf.c | 41 > > > > > > +++++++++++++++++- > > > > > > ---- > > > > > > ----- > > > > > > 2 files changed, 39 insertions(+), 15 deletions(-) > > > > > > > > > > > > diff --git a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > > > b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > > > index a7e548a2bdfb..1f88ca71820c 100644 > > > > > > --- a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > > > +++ b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > > > @@ -31,6 +31,7 @@ static void check_residency(struct kunit > > > > > > *test, > > > > > > struct xe_bo *exported, > > > > > > struct drm_exec *exec) > > > > > > { > > > > > > struct dma_buf_test_params *params = > > > > > > to_dma_buf_test_params(test->priv); > > > > > > + struct dma_buf_attachment *attach; > > > > > > u32 mem_type; > > > > > > int ret; > > > > > > > > > > > > @@ -88,6 +89,18 @@ static void check_residency(struct kunit > > > > > > *test, > > > > > > struct xe_bo *exported, > > > > > > > > > > > > KUNIT_EXPECT_TRUE(test, > > > > > > xe_bo_is_mem_type(exported, > > > > > > mem_type)); > > > > > > > > > > > > + /* Check that we can pin without migrating. */ > > > > > > + attach = list_first_entry_or_null(&dmabuf- > > > > > > > attachments, > > > > > > typeof(*attach), node); > > > > > > + if (attach) { > > > > > > + int err = dma_buf_pin(attach); > > > > > > + > > > > > > + if (!err) { > > > > > > + KUNIT_EXPECT_TRUE(test, > > > > > > xe_bo_is_mem_type(exported, mem_type)); > > > > > > + dma_buf_unpin(attach); > > > > > > + } > > > > > > + KUNIT_EXPECT_EQ(test, err, 0); > > > > > > + } > > > > > > + > > > > > > if (params->force_different_devices) > > > > > > KUNIT_EXPECT_TRUE(test, > > > > > > xe_bo_is_mem_type(imported, XE_PL_TT)); > > > > > > else > > > > > > diff --git a/drivers/gpu/drm/xe/xe_dma_buf.c > > > > > > b/drivers/gpu/drm/xe/xe_dma_buf.c > > > > > > index a7d67725c3ee..54e42960daad 100644 > > > > > > --- a/drivers/gpu/drm/xe/xe_dma_buf.c > > > > > > +++ b/drivers/gpu/drm/xe/xe_dma_buf.c > > > > > > @@ -48,32 +48,43 @@ static void xe_dma_buf_detach(struct > > > > > > dma_buf > > > > > > *dmabuf, > > > > > > > > > > > > static int xe_dma_buf_pin(struct dma_buf_attachment > > > > > > *attach) > > > > > > { > > > > > > - struct drm_gem_object *obj = attach->dmabuf->priv; > > > > > > + struct dma_buf *dmabuf = attach->dmabuf; > > > > > > + struct drm_gem_object *obj = dmabuf->priv; > > > > > > struct xe_bo *bo = gem_to_xe_bo(obj); > > > > > > struct xe_device *xe = xe_bo_device(bo); > > > > > > struct drm_exec *exec = XE_VALIDATION_UNSUPPORTED; > > > > > > + bool allow_vram = true; > > > > > > int ret; > > > > > > > > > > > > - /* > > > > > > - * For now only support pinning in TT memory, for > > > > > > two > > > > > > reasons: > > > > > > - * 1) Avoid pinning in a placement not accessible > > > > > > to > > > > > > some > > > > > > importers. > > > > > > - * 2) Pinning in VRAM requires PIN accounting > > > > > > which is > > > > > > a > > > > > > to-do. > > > > > > - */ > > > > > > - if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > > > > XE_PL_TT)) { > > > > > > + if (!IS_ENABLED(CONFIG_DMABUF_MOVE_NOTIFY)) { > > > > > > + allow_vram = false; > > > > > > + } else { > > > > > > + list_for_each_entry(attach, &dmabuf- > > > > > > > attachments, > > > > > > node) { > > > > > > + if (!attach->peer2peer) { > > > > > > + allow_vram = false; > > > > > > + break; > > > > > > + } > > > > > > + } > > > > > > + } > > > > > > + > > > > > > + if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > > > > XE_PL_TT) && > > > > > > + !(xe_bo_is_vram(bo) && allow_vram)) { > > > > > > drm_dbg(&xe->drm, "Can't migrate pinned bo > > > > > > for > > > > > > dma-buf pin.\n"); > > > > > > return -EINVAL; > > > > > > } > > > > > > > > > > > > - ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > > > > > - if (ret) { > > > > > > - if (ret != -EINTR && ret != -ERESTARTSYS) > > > > > > - drm_dbg(&xe->drm, > > > > > > - "Failed migrating dma-buf > > > > > > to > > > > > > TT > > > > > > memory: %pe\n", > > > > > > - ERR_PTR(ret)); > > > > > > - return ret; > > > > > > + if (!allow_vram) { > > > > > > + ret = xe_bo_migrate(bo, XE_PL_TT, NULL, > > > > > > exec); > > > > > > + if (ret) { > > > > > > + if (ret != -EINTR && ret != - > > > > > > ERESTARTSYS) > > > > > > + drm_dbg(&xe->drm, > > > > > > + "Failed migrating > > > > > > dma- > > > > > > buf > > > > > > to TT memory: %pe\n", > > > > > > + ERR_PTR(ret)); > > > > > > + return ret; > > > > > > + } > > > > > > } > > > > > > > > > > > > - ret = xe_bo_pin_external(bo, true, exec); > > > > > > + ret = xe_bo_pin_external(bo, !allow_vram, exec); > > > > > Are we also missing save/restore support for such objects? Or > > > > > at > > > > > least I > > > > > can't see where the save flow is happening for externally > > > > > pinned > > > > > VRAM? > > > > Good point. I forgot about that. IIRC we once made a deliberate > > > > decision to leave that out since we didn't support it. > > > > > > > > I'll have a look at that as well depending if we decide to go > > > > ahead with this. > > > > > > > Don't we take a PM ref exporting device in xe_dma_buf_attach? So > > > when > > > memory attached to (or pinned in this case) we can't go through > > > save > > > / > > > restore flows as the device should be awake? > > Yes, rpm save/restore should not happen, however system suspend or > > hibernate may. > > Just a quick review: A call to ttm_bo_validate() is missing to ensure > we don't pin while in wrong placement or swapped out. Thanks for having a look! It's in the ttm_bo_pin_external() function. Although we skip it when we migrate to TT. > > By default the dmem cgroup controller is not yet used by most > distributions, so introducing and using separate max_pinned + > actually pinned accounting would work. It would make sense to make it > first come first serve, which makes accounting simple. This would > make the semantics the same as the first time hitting 'max' limit, > but without the possibility for eviction. > > This will likely work better than re-using the 'min' semantics, since > they serve different purposes. One might want to allow pinning, but > not want to pin memory by default unless needed. > > Kind regards, > ~Maarten Thanks, Thomas ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 13:06 ` Thomas Hellström 2025-09-16 18:02 ` Matthew Brost @ 2025-09-16 19:53 ` Rodrigo Vivi 2025-09-16 20:35 ` Thomas Hellström 1 sibling, 1 reply; 14+ messages in thread From: Rodrigo Vivi @ 2025-09-16 19:53 UTC (permalink / raw) To: Thomas Hellström Cc: Matthew Auld, intel-xe, Dave Airlie, Simona Vetter, Joonas Lahtinen, Maarten Lankhorst, Matthew Brost, Lucas De Marchi On Tue, Sep 16, 2025 at 03:06:48PM +0200, Thomas Hellström wrote: > On Tue, 2025-09-16 at 14:03 +0100, Matthew Auld wrote: > > On 16/09/2025 12:53, Thomas Hellström wrote: > > > RDMA NICs typically requires the VRAM dma-bufs to be pinned in > > > VRAM for pcie-p2p communication, since they don't fully support > > > the move_notify() scheme. We would like to support that. > > > > > > However allowing unaccounted pinning of VRAM creates a DOS vector > > > so up until now we haven't allowed it. > > > > > > However with cgroups support in TTM, the amount of VRAM allocated > > > to a cgroup can be limited, and since also the pinned memory is > > > accounted as allocated VRAM we should be safe. > > > > > > An analogy with system memory can be made if we observe the > > > similarity with kernel system memory that is allocated as the > > > result of user-space action and that is accounted using > > > __GFP_ACCOUNT. > > > > > > Ideally, to be more flexible, we would add a "pinned_memory", > > > or possibly "kernel_memory" limit to the dmem cgroups controller, > > > that would additionally limit the memory that is pinned in this > > > way. > > > If we let that limit default to the dmem::max limit we can > > > introduce that without needing to care about regressions. > > > > > > Considering that we already pin VRAM in this way for at least > > > page-table memory and LRC memory, and the above path to greater > > > flexibility, allow this also for dma-bufs. > > > > > > Cc: Dave Airlie <airlied@gmail.com> > > > Cc: Simona Vetter <simona.vetter@ffwll.ch> > > > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> > > > Cc: Maarten Lankhorst <maarten.lankhorst@intel.com> > > > Cc: Matthew Brost <matthew.brost@intel.com> > > > Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> > > > Cc: Lucas De Marchi <lucas.demarchi@intel.com> > > > Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com> > > > --- > > > drivers/gpu/drm/xe/tests/xe_dma_buf.c | 13 +++++++++ > > > drivers/gpu/drm/xe/xe_dma_buf.c | 41 +++++++++++++++++----- > > > ----- > > > 2 files changed, 39 insertions(+), 15 deletions(-) > > > > > > diff --git a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > index a7e548a2bdfb..1f88ca71820c 100644 > > > --- a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > +++ b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > @@ -31,6 +31,7 @@ static void check_residency(struct kunit *test, > > > struct xe_bo *exported, > > > struct drm_exec *exec) > > > { > > > struct dma_buf_test_params *params = > > > to_dma_buf_test_params(test->priv); > > > + struct dma_buf_attachment *attach; > > > u32 mem_type; > > > int ret; > > > > > > @@ -88,6 +89,18 @@ static void check_residency(struct kunit *test, > > > struct xe_bo *exported, > > > > > > KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, > > > mem_type)); > > > > > > + /* Check that we can pin without migrating. */ > > > + attach = list_first_entry_or_null(&dmabuf->attachments, > > > typeof(*attach), node); > > > + if (attach) { > > > + int err = dma_buf_pin(attach); > > > + > > > + if (!err) { > > > + KUNIT_EXPECT_TRUE(test, > > > xe_bo_is_mem_type(exported, mem_type)); > > > + dma_buf_unpin(attach); > > > + } > > > + KUNIT_EXPECT_EQ(test, err, 0); > > > + } > > > + > > > if (params->force_different_devices) > > > KUNIT_EXPECT_TRUE(test, > > > xe_bo_is_mem_type(imported, XE_PL_TT)); > > > else > > > diff --git a/drivers/gpu/drm/xe/xe_dma_buf.c > > > b/drivers/gpu/drm/xe/xe_dma_buf.c > > > index a7d67725c3ee..54e42960daad 100644 > > > --- a/drivers/gpu/drm/xe/xe_dma_buf.c > > > +++ b/drivers/gpu/drm/xe/xe_dma_buf.c > > > @@ -48,32 +48,43 @@ static void xe_dma_buf_detach(struct dma_buf > > > *dmabuf, > > > > > > static int xe_dma_buf_pin(struct dma_buf_attachment *attach) > > > { > > > - struct drm_gem_object *obj = attach->dmabuf->priv; > > > + struct dma_buf *dmabuf = attach->dmabuf; > > > + struct drm_gem_object *obj = dmabuf->priv; > > > struct xe_bo *bo = gem_to_xe_bo(obj); > > > struct xe_device *xe = xe_bo_device(bo); > > > struct drm_exec *exec = XE_VALIDATION_UNSUPPORTED; > > > + bool allow_vram = true; > > > int ret; > > > > > > - /* > > > - * For now only support pinning in TT memory, for two > > > reasons: > > > - * 1) Avoid pinning in a placement not accessible to some > > > importers. > > > - * 2) Pinning in VRAM requires PIN accounting which is a > > > to-do. > > > - */ > > > - if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > XE_PL_TT)) { > > > + if (!IS_ENABLED(CONFIG_DMABUF_MOVE_NOTIFY)) { I don't believe this check is the right one here. Perhaps the config is enabled, but the driver importing this dma-buf doesn't support it. perhaps we want a new config here? so when we transition to cgroups we "don't regress" ?! > > > + allow_vram = false; > > > + } else { > > > + list_for_each_entry(attach, &dmabuf->attachments, > > > node) { > > > + if (!attach->peer2peer) { > > > + allow_vram = false; > > > + break; > > > + } > > > + } > > > + } > > > + > > > + if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > XE_PL_TT) && > > > + !(xe_bo_is_vram(bo) && allow_vram)) { > > > drm_dbg(&xe->drm, "Can't migrate pinned bo for > > > dma-buf pin.\n"); > > > return -EINVAL; > > > } > > > > > > - ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > > - if (ret) { > > > - if (ret != -EINTR && ret != -ERESTARTSYS) > > > - drm_dbg(&xe->drm, > > > - "Failed migrating dma-buf to TT > > > memory: %pe\n", > > > - ERR_PTR(ret)); > > > - return ret; > > > + if (!allow_vram) { > > > + ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > > + if (ret) { > > > + if (ret != -EINTR && ret != -ERESTARTSYS) > > > + drm_dbg(&xe->drm, > > > + "Failed migrating dma-buf > > > to TT memory: %pe\n", > > > + ERR_PTR(ret)); > > > + return ret; > > > + } > > > } > > > > > > - ret = xe_bo_pin_external(bo, true, exec); > > > + ret = xe_bo_pin_external(bo, !allow_vram, exec); > > > > Are we also missing save/restore support for such objects? Or at > > least I > > can't see where the save flow is happening for externally pinned > > VRAM? > > Good point. I forgot about that. IIRC we once made a deliberate > decision to leave that out since we didn't support it. > > I'll have a look at that as well depending if we decide to go > ahead with this. > > /Thomas > > > > > > xe_assert(xe, !ret); > > > > > > return 0; > > > ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 19:53 ` Rodrigo Vivi @ 2025-09-16 20:35 ` Thomas Hellström 2025-09-16 21:05 ` Thomas Hellström 0 siblings, 1 reply; 14+ messages in thread From: Thomas Hellström @ 2025-09-16 20:35 UTC (permalink / raw) To: Rodrigo Vivi Cc: Matthew Auld, intel-xe, Dave Airlie, Simona Vetter, Joonas Lahtinen, Maarten Lankhorst, Matthew Brost, Lucas De Marchi On Tue, 2025-09-16 at 15:53 -0400, Rodrigo Vivi wrote: > On Tue, Sep 16, 2025 at 03:06:48PM +0200, Thomas Hellström wrote: > > On Tue, 2025-09-16 at 14:03 +0100, Matthew Auld wrote: > > > On 16/09/2025 12:53, Thomas Hellström wrote: > > > > RDMA NICs typically requires the VRAM dma-bufs to be pinned in > > > > VRAM for pcie-p2p communication, since they don't fully support > > > > the move_notify() scheme. We would like to support that. > > > > > > > > However allowing unaccounted pinning of VRAM creates a DOS > > > > vector > > > > so up until now we haven't allowed it. > > > > > > > > However with cgroups support in TTM, the amount of VRAM > > > > allocated > > > > to a cgroup can be limited, and since also the pinned memory is > > > > accounted as allocated VRAM we should be safe. > > > > > > > > An analogy with system memory can be made if we observe the > > > > similarity with kernel system memory that is allocated as the > > > > result of user-space action and that is accounted using > > > > __GFP_ACCOUNT. > > > > > > > > Ideally, to be more flexible, we would add a "pinned_memory", > > > > or possibly "kernel_memory" limit to the dmem cgroups > > > > controller, > > > > that would additionally limit the memory that is pinned in this > > > > way. > > > > If we let that limit default to the dmem::max limit we can > > > > introduce that without needing to care about regressions. > > > > > > > > Considering that we already pin VRAM in this way for at least > > > > page-table memory and LRC memory, and the above path to greater > > > > flexibility, allow this also for dma-bufs. > > > > > > > > Cc: Dave Airlie <airlied@gmail.com> > > > > Cc: Simona Vetter <simona.vetter@ffwll.ch> > > > > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> > > > > Cc: Maarten Lankhorst <maarten.lankhorst@intel.com> > > > > Cc: Matthew Brost <matthew.brost@intel.com> > > > > Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> > > > > Cc: Lucas De Marchi <lucas.demarchi@intel.com> > > > > Signed-off-by: Thomas Hellström > > > > <thomas.hellstrom@linux.intel.com> > > > > --- > > > > drivers/gpu/drm/xe/tests/xe_dma_buf.c | 13 +++++++++ > > > > drivers/gpu/drm/xe/xe_dma_buf.c | 41 +++++++++++++++++- > > > > ---- > > > > ----- > > > > 2 files changed, 39 insertions(+), 15 deletions(-) > > > > > > > > diff --git a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > index a7e548a2bdfb..1f88ca71820c 100644 > > > > --- a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > +++ b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > @@ -31,6 +31,7 @@ static void check_residency(struct kunit > > > > *test, > > > > struct xe_bo *exported, > > > > struct drm_exec *exec) > > > > { > > > > struct dma_buf_test_params *params = > > > > to_dma_buf_test_params(test->priv); > > > > + struct dma_buf_attachment *attach; > > > > u32 mem_type; > > > > int ret; > > > > > > > > @@ -88,6 +89,18 @@ static void check_residency(struct kunit > > > > *test, > > > > struct xe_bo *exported, > > > > > > > > KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, > > > > mem_type)); > > > > > > > > + /* Check that we can pin without migrating. */ > > > > + attach = list_first_entry_or_null(&dmabuf- > > > > >attachments, > > > > typeof(*attach), node); > > > > + if (attach) { > > > > + int err = dma_buf_pin(attach); > > > > + > > > > + if (!err) { > > > > + KUNIT_EXPECT_TRUE(test, > > > > xe_bo_is_mem_type(exported, mem_type)); > > > > + dma_buf_unpin(attach); > > > > + } > > > > + KUNIT_EXPECT_EQ(test, err, 0); > > > > + } > > > > + > > > > if (params->force_different_devices) > > > > KUNIT_EXPECT_TRUE(test, > > > > xe_bo_is_mem_type(imported, XE_PL_TT)); > > > > else > > > > diff --git a/drivers/gpu/drm/xe/xe_dma_buf.c > > > > b/drivers/gpu/drm/xe/xe_dma_buf.c > > > > index a7d67725c3ee..54e42960daad 100644 > > > > --- a/drivers/gpu/drm/xe/xe_dma_buf.c > > > > +++ b/drivers/gpu/drm/xe/xe_dma_buf.c > > > > @@ -48,32 +48,43 @@ static void xe_dma_buf_detach(struct > > > > dma_buf > > > > *dmabuf, > > > > > > > > static int xe_dma_buf_pin(struct dma_buf_attachment *attach) > > > > { > > > > - struct drm_gem_object *obj = attach->dmabuf->priv; > > > > + struct dma_buf *dmabuf = attach->dmabuf; > > > > + struct drm_gem_object *obj = dmabuf->priv; > > > > struct xe_bo *bo = gem_to_xe_bo(obj); > > > > struct xe_device *xe = xe_bo_device(bo); > > > > struct drm_exec *exec = XE_VALIDATION_UNSUPPORTED; > > > > + bool allow_vram = true; > > > > int ret; > > > > > > > > - /* > > > > - * For now only support pinning in TT memory, for two > > > > reasons: > > > > - * 1) Avoid pinning in a placement not accessible to > > > > some > > > > importers. > > > > - * 2) Pinning in VRAM requires PIN accounting which is > > > > a > > > > to-do. > > > > - */ > > > > - if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > > XE_PL_TT)) { > > > > + if (!IS_ENABLED(CONFIG_DMABUF_MOVE_NOTIFY)) { > > I don't believe this check is the right one here. > Perhaps the config is enabled, but the driver importing > this dma-buf doesn't support it. So this was actually shamelessly stolen from amdgpu. I'll see if I can sort out whether this works anyway even if the importer doesn't support move_notify(). > > perhaps we want a new config here? so when we transition to cgroups > we "don't regress" ?! We currently *do* use cgroups for VRAM. If enabled, all the cgroup's VRAM allocations (including this pinned memory) don't exceed the dmem:max limit. The plan moving forward is to, if needed, try to introduce a dmem:pinned_memory limit <= dmem:max and when we pin we account against that as well. If dmem:pinned_memory is set to dmem:max by default, we don't regress. Thanks, Thomas > > > > > + allow_vram = false; > > > > + } else { > > > > + list_for_each_entry(attach, &dmabuf- > > > > >attachments, > > > > node) { > > > > + if (!attach->peer2peer) { > > > > + allow_vram = false; > > > > + break; > > > > + } > > > > + } > > > > + } > > > > + > > > > + if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > > XE_PL_TT) && > > > > + !(xe_bo_is_vram(bo) && allow_vram)) { > > > > drm_dbg(&xe->drm, "Can't migrate pinned bo for > > > > dma-buf pin.\n"); > > > > return -EINVAL; > > > > } > > > > > > > > - ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > > > - if (ret) { > > > > - if (ret != -EINTR && ret != -ERESTARTSYS) > > > > - drm_dbg(&xe->drm, > > > > - "Failed migrating dma-buf to > > > > TT > > > > memory: %pe\n", > > > > - ERR_PTR(ret)); > > > > - return ret; > > > > + if (!allow_vram) { > > > > + ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > > > + if (ret) { > > > > + if (ret != -EINTR && ret != - > > > > ERESTARTSYS) > > > > + drm_dbg(&xe->drm, > > > > + "Failed migrating dma- > > > > buf > > > > to TT memory: %pe\n", > > > > + ERR_PTR(ret)); > > > > + return ret; > > > > + } > > > > } > > > > > > > > - ret = xe_bo_pin_external(bo, true, exec); > > > > + ret = xe_bo_pin_external(bo, !allow_vram, exec); > > > > > > Are we also missing save/restore support for such objects? Or at > > > least I > > > can't see where the save flow is happening for externally pinned > > > VRAM? > > > > Good point. I forgot about that. IIRC we once made a deliberate > > decision to leave that out since we didn't support it. > > > > I'll have a look at that as well depending if we decide to go > > ahead with this. > > > > /Thomas > > > > > > > > > xe_assert(xe, !ret); > > > > > > > > return 0; > > > > > ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 20:35 ` Thomas Hellström @ 2025-09-16 21:05 ` Thomas Hellström 0 siblings, 0 replies; 14+ messages in thread From: Thomas Hellström @ 2025-09-16 21:05 UTC (permalink / raw) To: Rodrigo Vivi Cc: Matthew Auld, intel-xe, Dave Airlie, Simona Vetter, Joonas Lahtinen, Maarten Lankhorst, Matthew Brost, Lucas De Marchi On Tue, 2025-09-16 at 22:35 +0200, Thomas Hellström wrote: > On Tue, 2025-09-16 at 15:53 -0400, Rodrigo Vivi wrote: > > On Tue, Sep 16, 2025 at 03:06:48PM +0200, Thomas Hellström wrote: > > > On Tue, 2025-09-16 at 14:03 +0100, Matthew Auld wrote: > > > > On 16/09/2025 12:53, Thomas Hellström wrote: > > > > > RDMA NICs typically requires the VRAM dma-bufs to be pinned > > > > > in > > > > > VRAM for pcie-p2p communication, since they don't fully > > > > > support > > > > > the move_notify() scheme. We would like to support that. > > > > > > > > > > However allowing unaccounted pinning of VRAM creates a DOS > > > > > vector > > > > > so up until now we haven't allowed it. > > > > > > > > > > However with cgroups support in TTM, the amount of VRAM > > > > > allocated > > > > > to a cgroup can be limited, and since also the pinned memory > > > > > is > > > > > accounted as allocated VRAM we should be safe. > > > > > > > > > > An analogy with system memory can be made if we observe the > > > > > similarity with kernel system memory that is allocated as the > > > > > result of user-space action and that is accounted using > > > > > __GFP_ACCOUNT. > > > > > > > > > > Ideally, to be more flexible, we would add a "pinned_memory", > > > > > or possibly "kernel_memory" limit to the dmem cgroups > > > > > controller, > > > > > that would additionally limit the memory that is pinned in > > > > > this > > > > > way. > > > > > If we let that limit default to the dmem::max limit we can > > > > > introduce that without needing to care about regressions. > > > > > > > > > > Considering that we already pin VRAM in this way for at least > > > > > page-table memory and LRC memory, and the above path to > > > > > greater > > > > > flexibility, allow this also for dma-bufs. > > > > > > > > > > Cc: Dave Airlie <airlied@gmail.com> > > > > > Cc: Simona Vetter <simona.vetter@ffwll.ch> > > > > > Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> > > > > > Cc: Maarten Lankhorst <maarten.lankhorst@intel.com> > > > > > Cc: Matthew Brost <matthew.brost@intel.com> > > > > > Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> > > > > > Cc: Lucas De Marchi <lucas.demarchi@intel.com> > > > > > Signed-off-by: Thomas Hellström > > > > > <thomas.hellstrom@linux.intel.com> > > > > > --- > > > > > drivers/gpu/drm/xe/tests/xe_dma_buf.c | 13 +++++++++ > > > > > drivers/gpu/drm/xe/xe_dma_buf.c | 41 > > > > > +++++++++++++++++- > > > > > ---- > > > > > ----- > > > > > 2 files changed, 39 insertions(+), 15 deletions(-) > > > > > > > > > > diff --git a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > > b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > > index a7e548a2bdfb..1f88ca71820c 100644 > > > > > --- a/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > > +++ b/drivers/gpu/drm/xe/tests/xe_dma_buf.c > > > > > @@ -31,6 +31,7 @@ static void check_residency(struct kunit > > > > > *test, > > > > > struct xe_bo *exported, > > > > > struct drm_exec *exec) > > > > > { > > > > > struct dma_buf_test_params *params = > > > > > to_dma_buf_test_params(test->priv); > > > > > + struct dma_buf_attachment *attach; > > > > > u32 mem_type; > > > > > int ret; > > > > > > > > > > @@ -88,6 +89,18 @@ static void check_residency(struct kunit > > > > > *test, > > > > > struct xe_bo *exported, > > > > > > > > > > KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, > > > > > mem_type)); > > > > > > > > > > + /* Check that we can pin without migrating. */ > > > > > + attach = list_first_entry_or_null(&dmabuf- > > > > > > attachments, > > > > > typeof(*attach), node); > > > > > + if (attach) { > > > > > + int err = dma_buf_pin(attach); > > > > > + > > > > > + if (!err) { > > > > > + KUNIT_EXPECT_TRUE(test, > > > > > xe_bo_is_mem_type(exported, mem_type)); > > > > > + dma_buf_unpin(attach); > > > > > + } > > > > > + KUNIT_EXPECT_EQ(test, err, 0); > > > > > + } > > > > > + > > > > > if (params->force_different_devices) > > > > > KUNIT_EXPECT_TRUE(test, > > > > > xe_bo_is_mem_type(imported, XE_PL_TT)); > > > > > else > > > > > diff --git a/drivers/gpu/drm/xe/xe_dma_buf.c > > > > > b/drivers/gpu/drm/xe/xe_dma_buf.c > > > > > index a7d67725c3ee..54e42960daad 100644 > > > > > --- a/drivers/gpu/drm/xe/xe_dma_buf.c > > > > > +++ b/drivers/gpu/drm/xe/xe_dma_buf.c > > > > > @@ -48,32 +48,43 @@ static void xe_dma_buf_detach(struct > > > > > dma_buf > > > > > *dmabuf, > > > > > > > > > > static int xe_dma_buf_pin(struct dma_buf_attachment > > > > > *attach) > > > > > { > > > > > - struct drm_gem_object *obj = attach->dmabuf->priv; > > > > > + struct dma_buf *dmabuf = attach->dmabuf; > > > > > + struct drm_gem_object *obj = dmabuf->priv; > > > > > struct xe_bo *bo = gem_to_xe_bo(obj); > > > > > struct xe_device *xe = xe_bo_device(bo); > > > > > struct drm_exec *exec = XE_VALIDATION_UNSUPPORTED; > > > > > + bool allow_vram = true; > > > > > int ret; > > > > > > > > > > - /* > > > > > - * For now only support pinning in TT memory, for > > > > > two > > > > > reasons: > > > > > - * 1) Avoid pinning in a placement not accessible to > > > > > some > > > > > importers. > > > > > - * 2) Pinning in VRAM requires PIN accounting which > > > > > is > > > > > a > > > > > to-do. > > > > > - */ > > > > > - if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > > > XE_PL_TT)) { > > > > > + if (!IS_ENABLED(CONFIG_DMABUF_MOVE_NOTIFY)) { > > > > I don't believe this check is the right one here. > > Perhaps the config is enabled, but the driver importing > > this dma-buf doesn't support it. > > So this was actually shamelessly stolen from amdgpu. I'll see if I > can > sort out whether this works anyway even if the importer doesn't > support > move_notify(). It turns out that the dma-buf core requires a move_notify() callback for p2p dma. So checking the attachments should be sufficient. However the config check avoids that in the case MOVE_NOTIFY is not enabled. /Thomas > > > > > perhaps we want a new config here? so when we transition to cgroups > > we "don't regress" ?! > > We currently *do* use cgroups for VRAM. If enabled, all the cgroup's > VRAM allocations (including this pinned memory) don't exceed the > dmem:max limit. > The plan moving forward is to, if needed, try to introduce a > dmem:pinned_memory limit <= dmem:max and when we pin we account > against > that as well. If dmem:pinned_memory is set to dmem:max by default, we > don't regress. > > Thanks, > Thomas > > > > > > > > > + allow_vram = false; > > > > > + } else { > > > > > + list_for_each_entry(attach, &dmabuf- > > > > > > attachments, > > > > > node) { > > > > > + if (!attach->peer2peer) { > > > > > + allow_vram = false; > > > > > + break; > > > > > + } > > > > > + } > > > > > + } > > > > > + > > > > > + if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, > > > > > XE_PL_TT) && > > > > > + !(xe_bo_is_vram(bo) && allow_vram)) { > > > > > drm_dbg(&xe->drm, "Can't migrate pinned bo > > > > > for > > > > > dma-buf pin.\n"); > > > > > return -EINVAL; > > > > > } > > > > > > > > > > - ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); > > > > > - if (ret) { > > > > > - if (ret != -EINTR && ret != -ERESTARTSYS) > > > > > - drm_dbg(&xe->drm, > > > > > - "Failed migrating dma-buf to > > > > > TT > > > > > memory: %pe\n", > > > > > - ERR_PTR(ret)); > > > > > - return ret; > > > > > + if (!allow_vram) { > > > > > + ret = xe_bo_migrate(bo, XE_PL_TT, NULL, > > > > > exec); > > > > > + if (ret) { > > > > > + if (ret != -EINTR && ret != - > > > > > ERESTARTSYS) > > > > > + drm_dbg(&xe->drm, > > > > > + "Failed migrating > > > > > dma- > > > > > buf > > > > > to TT memory: %pe\n", > > > > > + ERR_PTR(ret)); > > > > > + return ret; > > > > > + } > > > > > } > > > > > > > > > > - ret = xe_bo_pin_external(bo, true, exec); > > > > > + ret = xe_bo_pin_external(bo, !allow_vram, exec); > > > > > > > > Are we also missing save/restore support for such objects? Or > > > > at > > > > least I > > > > can't see where the save flow is happening for externally > > > > pinned > > > > VRAM? > > > > > > Good point. I forgot about that. IIRC we once made a deliberate > > > decision to leave that out since we didn't support it. > > > > > > I'll have a look at that as well depending if we decide to go > > > ahead with this. > > > > > > /Thomas > > > > > > > > > > > > xe_assert(xe, !ret); > > > > > > > > > > return 0; > > > > > > > > ^ permalink raw reply [flat|nested] 14+ messages in thread
* ✓ Xe.CI.Full: success for drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 11:53 [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf Thomas Hellström ` (2 preceding siblings ...) 2025-09-16 13:03 ` [RFC PATCH] " Matthew Auld @ 2025-09-16 14:44 ` Patchwork 2025-09-17 5:43 ` [RFC PATCH] " Niranjana Vishwanathapura 4 siblings, 0 replies; 14+ messages in thread From: Patchwork @ 2025-09-16 14:44 UTC (permalink / raw) To: Thomas Hellström; +Cc: intel-xe [-- Attachment #1: Type: text/plain, Size: 43883 bytes --] == Series Details == Series: drm/xe/dma-buf: Allow pinning of p2p dma-buf URL : https://patchwork.freedesktop.org/series/154593/ State : success == Summary == CI Bug Log - changes from xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2_FULL -> xe-pw-154593v1_FULL ==================================================== Summary ------- **SUCCESS** No regressions found. Participating hosts (4 -> 4) ------------------------------ No changes in participating hosts Known issues ------------ Here are the changes found in xe-pw-154593v1_FULL that come from known issues: ### IGT changes ### #### Issues hit #### * igt@kms_async_flips@alternate-sync-async-flip-atomic@pipe-a-dp-2: - shard-bmg: [PASS][1] -> [FAIL][2] ([Intel XE#3718]) +1 other test fail [1]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-4/igt@kms_async_flips@alternate-sync-async-flip-atomic@pipe-a-dp-2.html [2]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-4/igt@kms_async_flips@alternate-sync-async-flip-atomic@pipe-a-dp-2.html * igt@kms_big_fb@linear-16bpp-rotate-90: - shard-dg2-set2: NOTRUN -> [SKIP][3] ([Intel XE#316]) [3]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-436/igt@kms_big_fb@linear-16bpp-rotate-90.html * igt@kms_big_fb@x-tiled-max-hw-stride-32bpp-rotate-180: - shard-adlp: [PASS][4] -> [DMESG-WARN][5] ([Intel XE#2953] / [Intel XE#4173]) +5 other tests dmesg-warn [4]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-adlp-3/igt@kms_big_fb@x-tiled-max-hw-stride-32bpp-rotate-180.html [5]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-adlp-2/igt@kms_big_fb@x-tiled-max-hw-stride-32bpp-rotate-180.html * igt@kms_big_fb@y-tiled-64bpp-rotate-90: - shard-bmg: NOTRUN -> [SKIP][6] ([Intel XE#1124]) +5 other tests skip [6]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_big_fb@y-tiled-64bpp-rotate-90.html * igt@kms_big_fb@y-tiled-max-hw-stride-64bpp-rotate-0-hflip-async-flip: - shard-adlp: [PASS][7] -> [DMESG-FAIL][8] ([Intel XE#4543]) [7]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-adlp-2/igt@kms_big_fb@y-tiled-max-hw-stride-64bpp-rotate-0-hflip-async-flip.html [8]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-adlp-4/igt@kms_big_fb@y-tiled-max-hw-stride-64bpp-rotate-0-hflip-async-flip.html * igt@kms_big_fb@yf-tiled-16bpp-rotate-0: - shard-dg2-set2: NOTRUN -> [SKIP][9] ([Intel XE#1124]) +2 other tests skip [9]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-432/igt@kms_big_fb@yf-tiled-16bpp-rotate-0.html * igt@kms_big_fb@yf-tiled-addfb: - shard-dg2-set2: NOTRUN -> [SKIP][10] ([Intel XE#619]) [10]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@kms_big_fb@yf-tiled-addfb.html * igt@kms_bw@linear-tiling-1-displays-2560x1440p: - shard-bmg: NOTRUN -> [SKIP][11] ([Intel XE#367]) +1 other test skip [11]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_bw@linear-tiling-1-displays-2560x1440p.html * igt@kms_ccs@bad-rotation-90-4-tiled-bmg-ccs: - shard-dg2-set2: NOTRUN -> [SKIP][12] ([Intel XE#2907]) +1 other test skip [12]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@kms_ccs@bad-rotation-90-4-tiled-bmg-ccs.html * igt@kms_ccs@crc-primary-basic-4-tiled-mtl-rc-ccs@pipe-b-hdmi-a-6: - shard-dg2-set2: NOTRUN -> [SKIP][13] ([Intel XE#787]) +146 other tests skip [13]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-463/igt@kms_ccs@crc-primary-basic-4-tiled-mtl-rc-ccs@pipe-b-hdmi-a-6.html * igt@kms_ccs@crc-primary-rotation-180-4-tiled-lnl-ccs@pipe-b-dp-2: - shard-bmg: NOTRUN -> [SKIP][14] ([Intel XE#2652] / [Intel XE#787]) +8 other tests skip [14]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_ccs@crc-primary-rotation-180-4-tiled-lnl-ccs@pipe-b-dp-2.html * igt@kms_ccs@crc-sprite-planes-basic-4-tiled-dg2-rc-ccs-cc: - shard-bmg: NOTRUN -> [SKIP][15] ([Intel XE#2887]) +9 other tests skip [15]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-7/igt@kms_ccs@crc-sprite-planes-basic-4-tiled-dg2-rc-ccs-cc.html * igt@kms_ccs@missing-ccs-buffer-4-tiled-mtl-mc-ccs@pipe-d-dp-4: - shard-dg2-set2: NOTRUN -> [SKIP][16] ([Intel XE#455] / [Intel XE#787]) +24 other tests skip [16]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-436/igt@kms_ccs@missing-ccs-buffer-4-tiled-mtl-mc-ccs@pipe-d-dp-4.html * igt@kms_chamelium_color@ctm-green-to-red: - shard-bmg: NOTRUN -> [SKIP][17] ([Intel XE#2325]) [17]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-7/igt@kms_chamelium_color@ctm-green-to-red.html * igt@kms_chamelium_edid@dp-edid-change-during-hibernate: - shard-bmg: NOTRUN -> [SKIP][18] ([Intel XE#2252]) +5 other tests skip [18]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-7/igt@kms_chamelium_edid@dp-edid-change-during-hibernate.html * igt@kms_chamelium_hpd@dp-hpd-after-suspend: - shard-dg2-set2: NOTRUN -> [SKIP][19] ([Intel XE#373]) +1 other test skip [19]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-436/igt@kms_chamelium_hpd@dp-hpd-after-suspend.html * igt@kms_cursor_crc@cursor-offscreen-32x32: - shard-bmg: NOTRUN -> [SKIP][20] ([Intel XE#2320]) +2 other tests skip [20]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_cursor_crc@cursor-offscreen-32x32.html * igt@kms_cursor_crc@cursor-offscreen-512x170: - shard-dg2-set2: NOTRUN -> [SKIP][21] ([Intel XE#308]) [21]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-432/igt@kms_cursor_crc@cursor-offscreen-512x170.html * igt@kms_cursor_crc@cursor-sliding-512x512: - shard-bmg: NOTRUN -> [SKIP][22] ([Intel XE#2321]) +1 other test skip [22]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_cursor_crc@cursor-sliding-512x512.html * igt@kms_cursor_legacy@cursorb-vs-flipa-atomic-transitions: - shard-bmg: [PASS][23] -> [SKIP][24] ([Intel XE#2291]) +1 other test skip [23]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-2/igt@kms_cursor_legacy@cursorb-vs-flipa-atomic-transitions.html [24]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-6/igt@kms_cursor_legacy@cursorb-vs-flipa-atomic-transitions.html * igt@kms_dither@fb-8bpc-vs-panel-6bpc@pipe-a-hdmi-a-6: - shard-dg2-set2: NOTRUN -> [SKIP][25] ([Intel XE#4494] / [i915#3804]) [25]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-463/igt@kms_dither@fb-8bpc-vs-panel-6bpc@pipe-a-hdmi-a-6.html * igt@kms_dp_link_training@uhbr-sst: - shard-bmg: NOTRUN -> [SKIP][26] ([Intel XE#4354]) +1 other test skip [26]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_dp_link_training@uhbr-sst.html * igt@kms_dsc@dsc-fractional-bpp: - shard-bmg: NOTRUN -> [SKIP][27] ([Intel XE#2244]) [27]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-7/igt@kms_dsc@dsc-fractional-bpp.html * igt@kms_dsc@dsc-with-bpc-formats: - shard-dg2-set2: NOTRUN -> [SKIP][28] ([Intel XE#455]) +3 other tests skip [28]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-432/igt@kms_dsc@dsc-with-bpc-formats.html * igt@kms_fbcon_fbt@psr: - shard-bmg: NOTRUN -> [SKIP][29] ([Intel XE#776]) [29]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_fbcon_fbt@psr.html * igt@kms_feature_discovery@display-2x: - shard-bmg: [PASS][30] -> [SKIP][31] ([Intel XE#2373]) [30]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-2/igt@kms_feature_discovery@display-2x.html [31]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-6/igt@kms_feature_discovery@display-2x.html * igt@kms_flip@2x-absolute-wf_vblank: - shard-bmg: [PASS][32] -> [SKIP][33] ([Intel XE#2316]) +3 other tests skip [32]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-5/igt@kms_flip@2x-absolute-wf_vblank.html [33]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-6/igt@kms_flip@2x-absolute-wf_vblank.html * igt@kms_flip@flip-vs-expired-vblank-interruptible: - shard-dg2-set2: [PASS][34] -> [FAIL][35] ([Intel XE#301]) +1 other test fail [34]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-dg2-434/igt@kms_flip@flip-vs-expired-vblank-interruptible.html [35]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-434/igt@kms_flip@flip-vs-expired-vblank-interruptible.html * igt@kms_flip@flip-vs-expired-vblank@c-edp1: - shard-lnl: [PASS][36] -> [FAIL][37] ([Intel XE#301] / [Intel XE#3149]) [36]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-lnl-4/igt@kms_flip@flip-vs-expired-vblank@c-edp1.html [37]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-lnl-3/igt@kms_flip@flip-vs-expired-vblank@c-edp1.html * igt@kms_flip@flip-vs-suspend-interruptible: - shard-adlp: [PASS][38] -> [DMESG-WARN][39] ([Intel XE#2953] / [Intel XE#4173] / [Intel XE#4543]) [38]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-adlp-4/igt@kms_flip@flip-vs-suspend-interruptible.html [39]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-adlp-8/igt@kms_flip@flip-vs-suspend-interruptible.html * igt@kms_flip@flip-vs-suspend-interruptible@d-hdmi-a1: - shard-adlp: [PASS][40] -> [DMESG-WARN][41] ([Intel XE#4543]) +6 other tests dmesg-warn [40]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-adlp-4/igt@kms_flip@flip-vs-suspend-interruptible@d-hdmi-a1.html [41]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-adlp-8/igt@kms_flip@flip-vs-suspend-interruptible@d-hdmi-a1.html * igt@kms_flip_scaled_crc@flip-32bpp-ytileccs-to-64bpp-ytile-upscaling: - shard-bmg: NOTRUN -> [SKIP][42] ([Intel XE#2293] / [Intel XE#2380]) +1 other test skip [42]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-7/igt@kms_flip_scaled_crc@flip-32bpp-ytileccs-to-64bpp-ytile-upscaling.html * igt@kms_flip_scaled_crc@flip-32bpp-ytileccs-to-64bpp-ytile-upscaling@pipe-a-valid-mode: - shard-bmg: NOTRUN -> [SKIP][43] ([Intel XE#2293]) +1 other test skip [43]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-7/igt@kms_flip_scaled_crc@flip-32bpp-ytileccs-to-64bpp-ytile-upscaling@pipe-a-valid-mode.html * igt@kms_flip_scaled_crc@flip-64bpp-4tile-to-32bpp-4tiledg2rcccs-downscaling: - shard-bmg: NOTRUN -> [SKIP][44] ([Intel XE#2380]) +1 other test skip [44]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_flip_scaled_crc@flip-64bpp-4tile-to-32bpp-4tiledg2rcccs-downscaling.html * igt@kms_force_connector_basic@force-connector-state: - shard-adlp: [PASS][45] -> [ABORT][46] ([Intel XE#2953]) [45]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-adlp-6/igt@kms_force_connector_basic@force-connector-state.html [46]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-adlp-4/igt@kms_force_connector_basic@force-connector-state.html * igt@kms_frontbuffer_tracking@drrs-rgb101010-draw-render: - shard-bmg: NOTRUN -> [SKIP][47] ([Intel XE#2311]) +19 other tests skip [47]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_frontbuffer_tracking@drrs-rgb101010-draw-render.html * igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-spr-indfb-onoff: - shard-bmg: NOTRUN -> [SKIP][48] ([Intel XE#5390]) +9 other tests skip [48]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-spr-indfb-onoff.html * igt@kms_frontbuffer_tracking@fbc-tiling-y: - shard-bmg: NOTRUN -> [SKIP][49] ([Intel XE#2352]) [49]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_frontbuffer_tracking@fbc-tiling-y.html * igt@kms_frontbuffer_tracking@fbcdrrs-2p-primscrn-pri-indfb-draw-mmap-wc: - shard-dg2-set2: NOTRUN -> [SKIP][50] ([Intel XE#651]) +10 other tests skip [50]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-432/igt@kms_frontbuffer_tracking@fbcdrrs-2p-primscrn-pri-indfb-draw-mmap-wc.html * igt@kms_frontbuffer_tracking@fbcpsr-1p-offscren-pri-shrfb-draw-mmap-wc: - shard-bmg: NOTRUN -> [SKIP][51] ([Intel XE#2313]) +23 other tests skip [51]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-1/igt@kms_frontbuffer_tracking@fbcpsr-1p-offscren-pri-shrfb-draw-mmap-wc.html * igt@kms_frontbuffer_tracking@plane-fbc-rte: - shard-dg2-set2: NOTRUN -> [SKIP][52] ([Intel XE#1158]) [52]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@kms_frontbuffer_tracking@plane-fbc-rte.html * igt@kms_frontbuffer_tracking@psr-slowdraw: - shard-dg2-set2: NOTRUN -> [SKIP][53] ([Intel XE#653]) +7 other tests skip [53]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@kms_frontbuffer_tracking@psr-slowdraw.html * igt@kms_joiner@basic-big-joiner: - shard-bmg: NOTRUN -> [SKIP][54] ([Intel XE#346]) [54]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_joiner@basic-big-joiner.html * igt@kms_joiner@basic-force-big-joiner: - shard-bmg: [PASS][55] -> [SKIP][56] ([Intel XE#3012]) [55]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-5/igt@kms_joiner@basic-force-big-joiner.html [56]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-6/igt@kms_joiner@basic-force-big-joiner.html * igt@kms_joiner@basic-max-non-joiner: - shard-bmg: NOTRUN -> [SKIP][57] ([Intel XE#4298]) [57]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_joiner@basic-max-non-joiner.html * igt@kms_joiner@invalid-modeset-ultra-joiner: - shard-dg2-set2: NOTRUN -> [SKIP][58] ([Intel XE#2927]) [58]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-432/igt@kms_joiner@invalid-modeset-ultra-joiner.html * igt@kms_panel_fitting@legacy: - shard-bmg: NOTRUN -> [SKIP][59] ([Intel XE#2486]) [59]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-1/igt@kms_panel_fitting@legacy.html * igt@kms_plane_multiple@2x-tiling-none: - shard-bmg: [PASS][60] -> [SKIP][61] ([Intel XE#4596]) [60]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-5/igt@kms_plane_multiple@2x-tiling-none.html [61]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-6/igt@kms_plane_multiple@2x-tiling-none.html * igt@kms_plane_multiple@tiling-y: - shard-bmg: NOTRUN -> [SKIP][62] ([Intel XE#5020]) [62]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_plane_multiple@tiling-y.html * igt@kms_plane_scaling@planes-downscale-factor-0-5@pipe-c: - shard-bmg: NOTRUN -> [SKIP][63] ([Intel XE#2763]) +4 other tests skip [63]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_plane_scaling@planes-downscale-factor-0-5@pipe-c.html * igt@kms_pm_backlight@brightness-with-dpms: - shard-bmg: NOTRUN -> [SKIP][64] ([Intel XE#2938]) [64]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-7/igt@kms_pm_backlight@brightness-with-dpms.html * igt@kms_pm_backlight@fade-with-suspend: - shard-bmg: NOTRUN -> [SKIP][65] ([Intel XE#870]) [65]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_pm_backlight@fade-with-suspend.html * igt@kms_pm_dc@dc6-psr: - shard-dg2-set2: NOTRUN -> [SKIP][66] ([Intel XE#1129]) [66]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@kms_pm_dc@dc6-psr.html * igt@kms_pm_lpsp@kms-lpsp: - shard-bmg: NOTRUN -> [SKIP][67] ([Intel XE#2499]) [67]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_pm_lpsp@kms-lpsp.html * igt@kms_pm_rpm@dpms-mode-unset-lpsp: - shard-bmg: NOTRUN -> [SKIP][68] ([Intel XE#1439] / [Intel XE#836]) [68]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-1/igt@kms_pm_rpm@dpms-mode-unset-lpsp.html * igt@kms_psr2_sf@fbc-psr2-cursor-plane-move-continuous-exceed-fully-sf: - shard-dg2-set2: NOTRUN -> [SKIP][69] ([Intel XE#1406] / [Intel XE#1489]) +3 other tests skip [69]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@kms_psr2_sf@fbc-psr2-cursor-plane-move-continuous-exceed-fully-sf.html * igt@kms_psr2_sf@fbc-psr2-plane-move-sf-dmg-area: - shard-bmg: NOTRUN -> [SKIP][70] ([Intel XE#1406] / [Intel XE#1489]) +5 other tests skip [70]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-1/igt@kms_psr2_sf@fbc-psr2-plane-move-sf-dmg-area.html * igt@kms_psr2_su@page_flip-nv12: - shard-bmg: NOTRUN -> [SKIP][71] ([Intel XE#1406] / [Intel XE#2387]) [71]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_psr2_su@page_flip-nv12.html * igt@kms_psr@fbc-psr-sprite-render: - shard-dg2-set2: NOTRUN -> [SKIP][72] ([Intel XE#1406] / [Intel XE#2850] / [Intel XE#929]) +2 other tests skip [72]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-432/igt@kms_psr@fbc-psr-sprite-render.html * igt@kms_psr@pr-sprite-plane-onoff: - shard-bmg: NOTRUN -> [SKIP][73] ([Intel XE#1406] / [Intel XE#2234] / [Intel XE#2850]) +8 other tests skip [73]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_psr@pr-sprite-plane-onoff.html * igt@kms_rotation_crc@primary-y-tiled-reflect-x-90: - shard-dg2-set2: NOTRUN -> [SKIP][74] ([Intel XE#3414]) [74]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@kms_rotation_crc@primary-y-tiled-reflect-x-90.html * igt@kms_rotation_crc@sprite-rotation-90-pos-100-0: - shard-bmg: NOTRUN -> [SKIP][75] ([Intel XE#3414] / [Intel XE#3904]) +1 other test skip [75]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_rotation_crc@sprite-rotation-90-pos-100-0.html * igt@kms_scaling_modes@scaling-mode-full-aspect: - shard-bmg: NOTRUN -> [SKIP][76] ([Intel XE#2413]) [76]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-1/igt@kms_scaling_modes@scaling-mode-full-aspect.html * igt@kms_setmode@clone-exclusive-crtc: - shard-bmg: [PASS][77] -> [SKIP][78] ([Intel XE#1435]) [77]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-5/igt@kms_setmode@clone-exclusive-crtc.html [78]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-6/igt@kms_setmode@clone-exclusive-crtc.html * igt@kms_vrr@flip-suspend: - shard-bmg: NOTRUN -> [SKIP][79] ([Intel XE#1499]) [79]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@kms_vrr@flip-suspend.html * igt@xe_copy_basic@mem-copy-linear-0xfffe: - shard-dg2-set2: NOTRUN -> [SKIP][80] ([Intel XE#1123]) [80]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@xe_copy_basic@mem-copy-linear-0xfffe.html * igt@xe_eudebug_online@single-step: - shard-bmg: NOTRUN -> [SKIP][81] ([Intel XE#4837]) +7 other tests skip [81]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-1/igt@xe_eudebug_online@single-step.html * igt@xe_eudebug_online@writes-caching-sram-bb-sram-target-sram: - shard-dg2-set2: NOTRUN -> [SKIP][82] ([Intel XE#4837]) +3 other tests skip [82]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@xe_eudebug_online@writes-caching-sram-bb-sram-target-sram.html * igt@xe_exec_basic@multigpu-no-exec-basic-defer-mmap: - shard-dg2-set2: [PASS][83] -> [SKIP][84] ([Intel XE#1392]) +4 other tests skip [83]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-dg2-466/igt@xe_exec_basic@multigpu-no-exec-basic-defer-mmap.html [84]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-432/igt@xe_exec_basic@multigpu-no-exec-basic-defer-mmap.html * igt@xe_exec_basic@multigpu-no-exec-bindexecqueue: - shard-bmg: NOTRUN -> [SKIP][85] ([Intel XE#2322]) +6 other tests skip [85]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-7/igt@xe_exec_basic@multigpu-no-exec-bindexecqueue.html * igt@xe_exec_fault_mode@many-execqueues-userptr-invalidate: - shard-dg2-set2: NOTRUN -> [SKIP][86] ([Intel XE#288]) +7 other tests skip [86]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@xe_exec_fault_mode@many-execqueues-userptr-invalidate.html * igt@xe_exec_system_allocator@fault-threads-same-page-benchmark: - shard-dg2-set2: NOTRUN -> [SKIP][87] ([Intel XE#4915]) +79 other tests skip [87]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@xe_exec_system_allocator@fault-threads-same-page-benchmark.html * igt@xe_exec_system_allocator@threads-shared-vm-many-execqueues-mmap-new-huge: - shard-bmg: NOTRUN -> [SKIP][88] ([Intel XE#4943]) +18 other tests skip [88]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-7/igt@xe_exec_system_allocator@threads-shared-vm-many-execqueues-mmap-new-huge.html * igt@xe_oa@oa-regs-whitelisted: - shard-dg2-set2: NOTRUN -> [SKIP][89] ([Intel XE#3573]) +1 other test skip [89]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-432/igt@xe_oa@oa-regs-whitelisted.html * igt@xe_pm@d3cold-basic: - shard-bmg: NOTRUN -> [SKIP][90] ([Intel XE#2284]) [90]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@xe_pm@d3cold-basic.html * igt@xe_pm@vram-d3cold-threshold: - shard-bmg: NOTRUN -> [SKIP][91] ([Intel XE#579]) [91]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@xe_pm@vram-d3cold-threshold.html * igt@xe_pxp@display-pxp-fb: - shard-dg2-set2: NOTRUN -> [SKIP][92] ([Intel XE#4733]) [92]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@xe_pxp@display-pxp-fb.html * igt@xe_query@multigpu-query-invalid-size: - shard-dg2-set2: NOTRUN -> [SKIP][93] ([Intel XE#944]) [93]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-432/igt@xe_query@multigpu-query-invalid-size.html * igt@xe_query@multigpu-query-uc-fw-version-huc: - shard-bmg: NOTRUN -> [SKIP][94] ([Intel XE#944]) +1 other test skip [94]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-5/igt@xe_query@multigpu-query-uc-fw-version-huc.html #### Possible fixes #### * igt@kms_bw@connected-linear-tiling-2-displays-2560x1440p: - shard-bmg: [SKIP][95] ([Intel XE#2314] / [Intel XE#2894]) -> [PASS][96] +1 other test pass [95]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-6/igt@kms_bw@connected-linear-tiling-2-displays-2560x1440p.html [96]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-2/igt@kms_bw@connected-linear-tiling-2-displays-2560x1440p.html * igt@kms_ccs@crc-primary-suspend-4-tiled-dg2-mc-ccs: - shard-dg2-set2: [INCOMPLETE][97] ([Intel XE#3862]) -> [PASS][98] [97]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-dg2-464/igt@kms_ccs@crc-primary-suspend-4-tiled-dg2-mc-ccs.html [98]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-432/igt@kms_ccs@crc-primary-suspend-4-tiled-dg2-mc-ccs.html * igt@kms_ccs@random-ccs-data-4-tiled-dg2-mc-ccs@pipe-b-hdmi-a-6: - shard-dg2-set2: [INCOMPLETE][99] ([Intel XE#1727] / [Intel XE#3113] / [Intel XE#4345]) -> [PASS][100] +1 other test pass [99]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-dg2-436/igt@kms_ccs@random-ccs-data-4-tiled-dg2-mc-ccs@pipe-b-hdmi-a-6.html [100]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-466/igt@kms_ccs@random-ccs-data-4-tiled-dg2-mc-ccs@pipe-b-hdmi-a-6.html * igt@kms_cursor_legacy@cursora-vs-flipb-atomic-transitions-varying-size: - shard-bmg: [SKIP][101] ([Intel XE#2291]) -> [PASS][102] +2 other tests pass [101]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-6/igt@kms_cursor_legacy@cursora-vs-flipb-atomic-transitions-varying-size.html [102]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-2/igt@kms_cursor_legacy@cursora-vs-flipb-atomic-transitions-varying-size.html * igt@kms_cursor_legacy@flip-vs-cursor-atomic-transitions: - shard-bmg: [FAIL][103] ([Intel XE#1475]) -> [PASS][104] [103]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-3/igt@kms_cursor_legacy@flip-vs-cursor-atomic-transitions.html [104]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-8/igt@kms_cursor_legacy@flip-vs-cursor-atomic-transitions.html * igt@kms_flip@2x-nonexisting-fb: - shard-bmg: [SKIP][105] ([Intel XE#2316]) -> [PASS][106] +2 other tests pass [105]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-6/igt@kms_flip@2x-nonexisting-fb.html [106]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-2/igt@kms_flip@2x-nonexisting-fb.html * igt@kms_flip@flip-vs-expired-vblank@a-edp1: - shard-lnl: [FAIL][107] ([Intel XE#301]) -> [PASS][108] [107]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-lnl-4/igt@kms_flip@flip-vs-expired-vblank@a-edp1.html [108]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-lnl-3/igt@kms_flip@flip-vs-expired-vblank@a-edp1.html * igt@kms_flip@flip-vs-suspend@b-hdmi-a1: - shard-adlp: [DMESG-WARN][109] ([Intel XE#4543]) -> [PASS][110] +5 other tests pass [109]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-adlp-4/igt@kms_flip@flip-vs-suspend@b-hdmi-a1.html [110]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-adlp-8/igt@kms_flip@flip-vs-suspend@b-hdmi-a1.html * igt@kms_flip@plain-flip-ts-check: - shard-adlp: [DMESG-WARN][111] ([Intel XE#2953] / [Intel XE#4173] / [Intel XE#4543]) -> [PASS][112] [111]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-adlp-1/igt@kms_flip@plain-flip-ts-check.html [112]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-adlp-9/igt@kms_flip@plain-flip-ts-check.html * igt@kms_hdr@static-swap: - shard-bmg: [SKIP][113] ([Intel XE#1503]) -> [PASS][114] +2 other tests pass [113]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-6/igt@kms_hdr@static-swap.html [114]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-2/igt@kms_hdr@static-swap.html * igt@kms_plane_multiple@2x-tiling-4: - shard-bmg: [SKIP][115] ([Intel XE#4596]) -> [PASS][116] [115]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-6/igt@kms_plane_multiple@2x-tiling-4.html [116]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-1/igt@kms_plane_multiple@2x-tiling-4.html * igt@xe_exec_basic@many-execqueues-many-vm-basic-defer-mmap: - shard-adlp: [DMESG-WARN][117] ([Intel XE#2953] / [Intel XE#4173]) -> [PASS][118] +4 other tests pass [117]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-adlp-6/igt@xe_exec_basic@many-execqueues-many-vm-basic-defer-mmap.html [118]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-adlp-1/igt@xe_exec_basic@many-execqueues-many-vm-basic-defer-mmap.html * igt@xe_exec_basic@multigpu-no-exec-null-defer-mmap: - shard-dg2-set2: [SKIP][119] ([Intel XE#1392]) -> [PASS][120] +3 other tests pass [119]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-dg2-432/igt@xe_exec_basic@multigpu-no-exec-null-defer-mmap.html [120]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-463/igt@xe_exec_basic@multigpu-no-exec-null-defer-mmap.html * igt@xe_exec_compute_mode@many-execqueues-userptr-free: - shard-bmg: [FAIL][121] -> [PASS][122] [121]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-6/igt@xe_exec_compute_mode@many-execqueues-userptr-free.html [122]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-2/igt@xe_exec_compute_mode@many-execqueues-userptr-free.html #### Warnings #### * igt@kms_async_flips@async-flip-suspend-resume: - shard-adlp: [DMESG-WARN][123] ([Intel XE#4543]) -> [DMESG-WARN][124] ([Intel XE#2953] / [Intel XE#4173] / [Intel XE#4543]) +1 other test dmesg-warn [123]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-adlp-6/igt@kms_async_flips@async-flip-suspend-resume.html [124]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-adlp-4/igt@kms_async_flips@async-flip-suspend-resume.html * igt@kms_content_protection@atomic: - shard-bmg: [FAIL][125] ([Intel XE#1178]) -> [SKIP][126] ([Intel XE#2341]) +1 other test skip [125]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-2/igt@kms_content_protection@atomic.html [126]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-6/igt@kms_content_protection@atomic.html * igt@kms_flip@flip-vs-expired-vblank: - shard-lnl: [FAIL][127] ([Intel XE#301]) -> [FAIL][128] ([Intel XE#301] / [Intel XE#3149]) [127]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-lnl-4/igt@kms_flip@flip-vs-expired-vblank.html [128]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-lnl-3/igt@kms_flip@flip-vs-expired-vblank.html * igt@kms_frontbuffer_tracking@drrs-2p-pri-indfb-multidraw: - shard-bmg: [SKIP][129] ([Intel XE#2312]) -> [SKIP][130] ([Intel XE#2311]) +12 other tests skip [129]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-6/igt@kms_frontbuffer_tracking@drrs-2p-pri-indfb-multidraw.html [130]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-2/igt@kms_frontbuffer_tracking@drrs-2p-pri-indfb-multidraw.html * igt@kms_frontbuffer_tracking@drrs-2p-scndscrn-pri-indfb-draw-mmap-wc: - shard-bmg: [SKIP][131] ([Intel XE#2311]) -> [SKIP][132] ([Intel XE#2312]) +14 other tests skip [131]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-5/igt@kms_frontbuffer_tracking@drrs-2p-scndscrn-pri-indfb-draw-mmap-wc.html [132]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-6/igt@kms_frontbuffer_tracking@drrs-2p-scndscrn-pri-indfb-draw-mmap-wc.html * igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-pri-indfb-draw-mmap-wc: - shard-bmg: [SKIP][133] ([Intel XE#5390]) -> [SKIP][134] ([Intel XE#2312]) +3 other tests skip [133]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-2/igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-pri-indfb-draw-mmap-wc.html [134]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-6/igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-pri-indfb-draw-mmap-wc.html * igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-spr-indfb-draw-render: - shard-bmg: [SKIP][135] ([Intel XE#2312]) -> [SKIP][136] ([Intel XE#5390]) +4 other tests skip [135]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-6/igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-spr-indfb-draw-render.html [136]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-2/igt@kms_frontbuffer_tracking@fbc-2p-scndscrn-spr-indfb-draw-render.html * igt@kms_frontbuffer_tracking@fbcpsr-2p-scndscrn-shrfb-plflip-blt: - shard-bmg: [SKIP][137] ([Intel XE#2313]) -> [SKIP][138] ([Intel XE#2312]) +11 other tests skip [137]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-5/igt@kms_frontbuffer_tracking@fbcpsr-2p-scndscrn-shrfb-plflip-blt.html [138]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-6/igt@kms_frontbuffer_tracking@fbcpsr-2p-scndscrn-shrfb-plflip-blt.html * igt@kms_frontbuffer_tracking@psr-2p-primscrn-cur-indfb-onoff: - shard-bmg: [SKIP][139] ([Intel XE#2312]) -> [SKIP][140] ([Intel XE#2313]) +9 other tests skip [139]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-6/igt@kms_frontbuffer_tracking@psr-2p-primscrn-cur-indfb-onoff.html [140]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-2/igt@kms_frontbuffer_tracking@psr-2p-primscrn-cur-indfb-onoff.html * igt@kms_plane_multiple@2x-tiling-yf: - shard-bmg: [SKIP][141] ([Intel XE#4596]) -> [SKIP][142] ([Intel XE#5021]) [141]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-6/igt@kms_plane_multiple@2x-tiling-yf.html [142]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-2/igt@kms_plane_multiple@2x-tiling-yf.html * igt@kms_tiled_display@basic-test-pattern: - shard-dg2-set2: [FAIL][143] ([Intel XE#1729]) -> [SKIP][144] ([Intel XE#362]) [143]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-dg2-436/igt@kms_tiled_display@basic-test-pattern.html [144]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-463/igt@kms_tiled_display@basic-test-pattern.html * igt@kms_tiled_display@basic-test-pattern-with-chamelium: - shard-bmg: [SKIP][145] ([Intel XE#2426]) -> [SKIP][146] ([Intel XE#2509]) [145]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-bmg-7/igt@kms_tiled_display@basic-test-pattern-with-chamelium.html [146]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-bmg-1/igt@kms_tiled_display@basic-test-pattern-with-chamelium.html * igt@xe_fault_injection@probe-fail-guc-xe_guc_ct_send_recv: - shard-dg2-set2: [ABORT][147] ([Intel XE#5466]) -> [ABORT][148] ([Intel XE#4917] / [Intel XE#5466]) [147]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2/shard-dg2-432/igt@xe_fault_injection@probe-fail-guc-xe_guc_ct_send_recv.html [148]: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/shard-dg2-464/igt@xe_fault_injection@probe-fail-guc-xe_guc_ct_send_recv.html {name}: This element is suppressed. This means it is ignored when computing the status of the difference (SUCCESS, WARNING, or FAILURE). [Intel XE#1123]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1123 [Intel XE#1124]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1124 [Intel XE#1129]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1129 [Intel XE#1158]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1158 [Intel XE#1178]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1178 [Intel XE#1392]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1392 [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#1439]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1439 [Intel XE#1475]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1475 [Intel XE#1489]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1489 [Intel XE#1499]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1499 [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#1729]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/1729 [Intel XE#2234]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2234 [Intel XE#2244]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2244 [Intel XE#2252]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2252 [Intel XE#2284]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2284 [Intel XE#2291]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2291 [Intel XE#2293]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2293 [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#2320]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2320 [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#2325]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2325 [Intel XE#2341]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2341 [Intel XE#2352]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2352 [Intel XE#2373]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2373 [Intel XE#2380]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2380 [Intel XE#2387]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2387 [Intel XE#2413]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2413 [Intel XE#2426]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2426 [Intel XE#2486]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2486 [Intel XE#2499]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2499 [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#2763]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2763 [Intel XE#2850]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2850 [Intel XE#288]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/288 [Intel XE#2887]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2887 [Intel XE#2894]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2894 [Intel XE#2907]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2907 [Intel XE#2927]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2927 [Intel XE#2938]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2938 [Intel XE#2953]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/2953 [Intel XE#301]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/301 [Intel XE#3012]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3012 [Intel XE#308]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/308 [Intel XE#3113]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3113 [Intel XE#3149]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3149 [Intel XE#316]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/316 [Intel XE#3414]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3414 [Intel XE#346]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/346 [Intel XE#3573]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3573 [Intel XE#362]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/362 [Intel XE#367]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/367 [Intel XE#3718]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3718 [Intel XE#373]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/373 [Intel XE#3862]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3862 [Intel XE#3904]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/3904 [Intel XE#4173]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4173 [Intel XE#4298]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4298 [Intel XE#4345]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4345 [Intel XE#4354]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4354 [Intel XE#4494]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4494 [Intel XE#4543]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4543 [Intel XE#455]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/455 [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#4915]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4915 [Intel XE#4917]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4917 [Intel XE#4943]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/4943 [Intel XE#5007]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/5007 [Intel XE#5020]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/5020 [Intel XE#5021]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/5021 [Intel XE#5390]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/5390 [Intel XE#5466]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/5466 [Intel XE#579]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/579 [Intel XE#619]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/619 [Intel XE#651]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/651 [Intel XE#653]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/653 [Intel XE#776]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/776 [Intel XE#787]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/787 [Intel XE#836]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/836 [Intel XE#870]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/870 [Intel XE#929]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/929 [Intel XE#944]: https://gitlab.freedesktop.org/drm/xe/kernel/issues/944 [i915#3804]: https://gitlab.freedesktop.org/drm/i915/kernel/-/issues/3804 Build changes ------------- * Linux: xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2 -> xe-pw-154593v1 IGT_8541: 8541 xe-3770-ef7574e6dc54e86591031c75cd25cc484f89ead2: ef7574e6dc54e86591031c75cd25cc484f89ead2 xe-pw-154593v1: 154593v1 == Logs == For more details see: https://intel-gfx-ci.01.org/tree/intel-xe/xe-pw-154593v1/index.html [-- Attachment #2: Type: text/html, Size: 50282 bytes --] ^ permalink raw reply [flat|nested] 14+ messages in thread
* Re: [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf 2025-09-16 11:53 [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf Thomas Hellström ` (3 preceding siblings ...) 2025-09-16 14:44 ` ✓ Xe.CI.Full: success for " Patchwork @ 2025-09-17 5:43 ` Niranjana Vishwanathapura 4 siblings, 0 replies; 14+ messages in thread From: Niranjana Vishwanathapura @ 2025-09-17 5:43 UTC (permalink / raw) To: Thomas Hellström Cc: intel-xe, Dave Airlie, Simona Vetter, Joonas Lahtinen, Maarten Lankhorst, Matthew Brost, Rodrigo Vivi, Lucas De Marchi On Tue, Sep 16, 2025 at 01:53:22PM +0200, Thomas Hellström wrote: >RDMA NICs typically requires the VRAM dma-bufs to be pinned in >VRAM for pcie-p2p communication, since they don't fully support >the move_notify() scheme. We would like to support that. > >However allowing unaccounted pinning of VRAM creates a DOS vector >so up until now we haven't allowed it. > >However with cgroups support in TTM, the amount of VRAM allocated >to a cgroup can be limited, and since also the pinned memory is >accounted as allocated VRAM we should be safe. > >An analogy with system memory can be made if we observe the >similarity with kernel system memory that is allocated as the >result of user-space action and that is accounted using __GFP_ACCOUNT. > >Ideally, to be more flexible, we would add a "pinned_memory", >or possibly "kernel_memory" limit to the dmem cgroups controller, >that would additionally limit the memory that is pinned in this way. >If we let that limit default to the dmem::max limit we can >introduce that without needing to care about regressions. > >Considering that we already pin VRAM in this way for at least >page-table memory and LRC memory, and the above path to greater >flexibility, allow this also for dma-bufs. > >Cc: Dave Airlie <airlied@gmail.com> >Cc: Simona Vetter <simona.vetter@ffwll.ch> >Cc: Joonas Lahtinen <joonas.lahtinen@linux.intel.com> >Cc: Maarten Lankhorst <maarten.lankhorst@intel.com> >Cc: Matthew Brost <matthew.brost@intel.com> >Cc: Rodrigo Vivi <rodrigo.vivi@intel.com> >Cc: Lucas De Marchi <lucas.demarchi@intel.com> >Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com> >--- > drivers/gpu/drm/xe/tests/xe_dma_buf.c | 13 +++++++++ > drivers/gpu/drm/xe/xe_dma_buf.c | 41 +++++++++++++++++---------- > 2 files changed, 39 insertions(+), 15 deletions(-) > >diff --git a/drivers/gpu/drm/xe/tests/xe_dma_buf.c b/drivers/gpu/drm/xe/tests/xe_dma_buf.c >index a7e548a2bdfb..1f88ca71820c 100644 >--- a/drivers/gpu/drm/xe/tests/xe_dma_buf.c >+++ b/drivers/gpu/drm/xe/tests/xe_dma_buf.c >@@ -31,6 +31,7 @@ static void check_residency(struct kunit *test, struct xe_bo *exported, > struct drm_exec *exec) > { > struct dma_buf_test_params *params = to_dma_buf_test_params(test->priv); >+ struct dma_buf_attachment *attach; > u32 mem_type; > int ret; > >@@ -88,6 +89,18 @@ static void check_residency(struct kunit *test, struct xe_bo *exported, > > KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, mem_type)); > >+ /* Check that we can pin without migrating. */ >+ attach = list_first_entry_or_null(&dmabuf->attachments, typeof(*attach), node); >+ if (attach) { >+ int err = dma_buf_pin(attach); >+ >+ if (!err) { >+ KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(exported, mem_type)); >+ dma_buf_unpin(attach); >+ } >+ KUNIT_EXPECT_EQ(test, err, 0); >+ } LGTM...one minor comment though... I see below comment line in this test file, /* Pinning in VRAM is not allowed. */ Looks like that is for the case where dynamic import is not supported. Not sure if it makes sense to word it properly now that pinning is allowed in VRAM? Niranjana >+ > if (params->force_different_devices) > KUNIT_EXPECT_TRUE(test, xe_bo_is_mem_type(imported, XE_PL_TT)); > else >diff --git a/drivers/gpu/drm/xe/xe_dma_buf.c b/drivers/gpu/drm/xe/xe_dma_buf.c >index a7d67725c3ee..54e42960daad 100644 >--- a/drivers/gpu/drm/xe/xe_dma_buf.c >+++ b/drivers/gpu/drm/xe/xe_dma_buf.c >@@ -48,32 +48,43 @@ static void xe_dma_buf_detach(struct dma_buf *dmabuf, > > static int xe_dma_buf_pin(struct dma_buf_attachment *attach) > { >- struct drm_gem_object *obj = attach->dmabuf->priv; >+ struct dma_buf *dmabuf = attach->dmabuf; >+ struct drm_gem_object *obj = dmabuf->priv; > struct xe_bo *bo = gem_to_xe_bo(obj); > struct xe_device *xe = xe_bo_device(bo); > struct drm_exec *exec = XE_VALIDATION_UNSUPPORTED; >+ bool allow_vram = true; > int ret; > >- /* >- * For now only support pinning in TT memory, for two reasons: >- * 1) Avoid pinning in a placement not accessible to some importers. >- * 2) Pinning in VRAM requires PIN accounting which is a to-do. >- */ >- if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, XE_PL_TT)) { >+ if (!IS_ENABLED(CONFIG_DMABUF_MOVE_NOTIFY)) { >+ allow_vram = false; >+ } else { >+ list_for_each_entry(attach, &dmabuf->attachments, node) { >+ if (!attach->peer2peer) { >+ allow_vram = false; >+ break; >+ } >+ } >+ } >+ >+ if (xe_bo_is_pinned(bo) && !xe_bo_is_mem_type(bo, XE_PL_TT) && >+ !(xe_bo_is_vram(bo) && allow_vram)) { > drm_dbg(&xe->drm, "Can't migrate pinned bo for dma-buf pin.\n"); > return -EINVAL; > } > >- ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); >- if (ret) { >- if (ret != -EINTR && ret != -ERESTARTSYS) >- drm_dbg(&xe->drm, >- "Failed migrating dma-buf to TT memory: %pe\n", >- ERR_PTR(ret)); >- return ret; >+ if (!allow_vram) { >+ ret = xe_bo_migrate(bo, XE_PL_TT, NULL, exec); >+ if (ret) { >+ if (ret != -EINTR && ret != -ERESTARTSYS) >+ drm_dbg(&xe->drm, >+ "Failed migrating dma-buf to TT memory: %pe\n", >+ ERR_PTR(ret)); >+ return ret; >+ } > } > >- ret = xe_bo_pin_external(bo, true, exec); >+ ret = xe_bo_pin_external(bo, !allow_vram, exec); > xe_assert(xe, !ret); > > return 0; >-- >2.51.0 > ^ permalink raw reply [flat|nested] 14+ messages in thread
end of thread, other threads:[~2025-09-19 7:12 UTC | newest] Thread overview: 14+ messages (download: mbox.gz follow: Atom feed -- links below jump to the message on this page -- 2025-09-16 11:53 [RFC PATCH] drm/xe/dma-buf: Allow pinning of p2p dma-buf Thomas Hellström 2025-09-16 12:10 ` ✓ CI.KUnit: success for " Patchwork 2025-09-16 12:43 ` ✓ Xe.CI.BAT: " Patchwork 2025-09-16 13:03 ` [RFC PATCH] " Matthew Auld 2025-09-16 13:06 ` Thomas Hellström 2025-09-16 18:02 ` Matthew Brost 2025-09-16 18:54 ` Thomas Hellström 2025-09-17 8:48 ` Maarten Lankhorst 2025-09-19 7:11 ` Thomas Hellström 2025-09-16 19:53 ` Rodrigo Vivi 2025-09-16 20:35 ` Thomas Hellström 2025-09-16 21:05 ` Thomas Hellström 2025-09-16 14:44 ` ✓ Xe.CI.Full: success for " Patchwork 2025-09-17 5:43 ` [RFC PATCH] " Niranjana Vishwanathapura
This is a public inbox, see mirroring instructions for how to clone and mirror all data and code used for this inbox