Intel-XE Archive on lore.kernel.org
 help / color / mirror / Atom feed
From: "Thomas Hellström" <thomas.hellstrom@linux.intel.com>
To: intel-xe@lists.freedesktop.org
Cc: Rodrigo Vivi <rodrigo.vivi@intel.com>
Subject: [PATCH v2 2/2] drm/xe: Use DRM_GPUVM_RESV_PROTECTED for gpuvm
Date: Tue, 12 Dec 2023 11:01:44 +0100	[thread overview]
Message-ID: <20231212100144.6833-3-thomas.hellstrom@linux.intel.com> (raw)
In-Reply-To: <20231212100144.6833-1-thomas.hellstrom@linux.intel.com>

Use DRM_GPUVM_RESV_PROTECTED to use corse-grained locking for the
evict and external object list.
Since we are already holding the relevant RESV locks, for now at least,
we don't need the fine-grained locking.

Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com>
Reviewed-by: Rodrigo Vivi <rodrigo.vivi@intel.com>
---
 drivers/gpu/drm/xe/xe_vm.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/drivers/gpu/drm/xe/xe_vm.c b/drivers/gpu/drm/xe/xe_vm.c
index 7a3b680d01a3..0b9510595db0 100644
--- a/drivers/gpu/drm/xe/xe_vm.c
+++ b/drivers/gpu/drm/xe/xe_vm.c
@@ -1282,8 +1282,8 @@ struct xe_vm *xe_vm_create(struct xe_device *xe, u32 flags)
 		goto err_no_resv;
 	}
 
-	drm_gpuvm_init(&vm->gpuvm, "Xe VM", 0, &xe->drm, vm_resv_obj,
-		       0, vm->size, 0, 0, &gpuvm_ops);
+	drm_gpuvm_init(&vm->gpuvm, "Xe VM", DRM_GPUVM_RESV_PROTECTED, &xe->drm,
+		       vm_resv_obj, 0, vm->size, 0, 0, &gpuvm_ops);
 
 	drm_gem_object_put(vm_resv_obj);
 
-- 
2.42.0


  parent reply	other threads:[~2023-12-12 10:02 UTC|newest]

Thread overview: 18+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2023-12-12 10:01 [PATCH v2 0/2] Use DRM_GPUVM helpers for the vm evict and exobj lists Thomas Hellström
2023-12-12 10:01 ` [PATCH v2 1/2] drm/xe: Use DRM GPUVM helpers for external- and evicted objects Thomas Hellström
2023-12-12 16:16   ` Matthew Brost
2023-12-12 10:01 ` Thomas Hellström [this message]
2023-12-12 10:26 ` ✓ CI.Patch_applied: success for Use DRM_GPUVM helpers for the vm evict and exobj lists Patchwork
2023-12-12 10:26 ` ✓ CI.checkpatch: " Patchwork
2023-12-12 10:28 ` ✓ CI.KUnit: " Patchwork
2023-12-12 10:35 ` ✓ CI.Build: " Patchwork
2023-12-12 10:35 ` ✓ CI.Hooks: " Patchwork
2023-12-12 10:37 ` ✓ CI.checksparse: " Patchwork
2023-12-12 11:07 ` ✗ CI.BAT: failure " Patchwork
2023-12-12 12:52 ` ✓ CI.Patch_applied: success for Use DRM_GPUVM helpers for the vm evict and exobj lists (rev2) Patchwork
2023-12-12 12:52 ` ✓ CI.checkpatch: " Patchwork
2023-12-12 12:53 ` ✓ CI.KUnit: " Patchwork
2023-12-12 13:01 ` ✓ CI.Build: " Patchwork
2023-12-12 13:01 ` ✓ CI.Hooks: " Patchwork
2023-12-12 13:02 ` ✓ CI.checksparse: " Patchwork
2023-12-12 13:37 ` ✓ CI.BAT: " Patchwork

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=20231212100144.6833-3-thomas.hellstrom@linux.intel.com \
    --to=thomas.hellstrom@linux.intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=rodrigo.vivi@intel.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox