All the mail mirrored from lore.kernel.org
 help / color / mirror / Atom feed
From: Nirmoy Das <nirmoy.das@intel.com>
To: intel-xe@lists.freedesktop.org
Cc: Nirmoy Das <nirmoy.das@intel.com>,
	Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>,
	Brian Welty <brian.welty@intel.com>,
	Fei Yang <fei.yang@intel.com>, Jose Souza <jose.souza@intel.com>,
	Lionel G Landwerlin <lionel.g.landwerlin@intel.com>,
	Matt Roper <matthew.d.roper@intel.com>,
	Matthew Brost <matthew.brost@intel.com>,
	Michal Mrozek <michal.mrozek@intel.com>,
	Oak Zeng <oak.zeng@intel.com>,
	Thomas Hellstr_m <thomas.hellstrom@linux.intel.com>
Subject: [PATCH v5 0/5] Refactor default device atomic settings
Date: Fri, 26 Apr 2024 12:56:50 +0200	[thread overview]
Message-ID: <20240426105655.23738-1-nirmoy.das@intel.com> (raw)

The default behavior of device atomics depends on the
VM type and buffer allocation types. Device atomics are
expected to function with all types of allocations for
traditional applications/APIs. Additionally, in compute/SVM
API scenarios with fault mode or LR mode VMs, device atomics
must work with single-region allocations. In all other cases
device atomics should be disabled by default. PVC needs special 
care as it doesn't support device atomics on SMEM.

v5: Fix broken atomics on PVC from v4 changes.

v4: Previous assumption that device atomics should be disabled
    by default on SMEM only BO was wrong as traditional applications
    will not use such allocations for CPU atomics. So remove the
    VM bind flag and the query uAPI and instead refactor default device 
    atomics settings as per VM type and buffer allocations.
      

v3: Capture ret value of xe_vm_bind_ioctl_validate_bo(Matt B).
    Remove redundant coh_mode param from xe_vm_bind_ioctl_validate_bo().
    Remove has_device_atomics_on_smem from xe_graphics_desc(Jose).
    Replace DRM_XE_QUERY_CONFIG_SUPP_DEV_ATOMIC_ON_SMEM with 
    config flag DRM_XE_QUERY_CONFIG_FLAG_HAS_DEV_ATOMIC_ON_SMEM(Jose).
    Mention that PTE_AE will not be applied to userptr(Matt R)

v2: Add BO helper func in xe_vm_bind_ioctl()(Matt B).
    Use XE_IOCTL_DBG for checks(Matt B).
    Move platform checks with help of adding flags in
    intel_device_info(Matt B).
    Add document for DRM_XE_VM_BIND_FLAG_DEVICE_ATOMICS(Matt B). 
    Create query uAPI for this newly added VM bind flag(Jose, Lionel).

Cc: Balasubramani Vivekanandan <balasubramani.vivekanandan@intel.com>
Cc: Brian Welty <brian.welty@intel.com>
Cc: Fei Yang <fei.yang@intel.com>
Cc: Jose Souza <jose.souza@intel.com>
Cc: Lionel G Landwerlin <lionel.g.landwerlin@intel.com>
Cc: Matt Roper <matthew.d.roper@intel.com>
Cc: Matthew Brost <matthew.brost@intel.com>
Cc: Michal Mrozek <michal.mrozek@intel.com>
Cc: Oak Zeng <oak.zeng@intel.com>
Cc: Thomas Hellstr_m <thomas.hellstrom@linux.intel.com>

Nirmoy Das (5):
  drm/xe: Introduce has_atomic_enable_pte_bit device info
  drm/xe: Move vm bind bo validation to a helper function
  drm/xe: Introduce has_device_atomics_on_smem device info
  drm/xe: Add function to check if BO has single placement
  drm/xe: Refactor default device atomic settings

 drivers/gpu/drm/xe/xe_bo.c           | 14 +++++
 drivers/gpu/drm/xe/xe_bo.h           |  1 +
 drivers/gpu/drm/xe/xe_device_types.h |  4 ++
 drivers/gpu/drm/xe/xe_pci.c          |  5 ++
 drivers/gpu/drm/xe/xe_pci_types.h    |  1 +
 drivers/gpu/drm/xe/xe_pt.c           | 27 ++++++++--
 drivers/gpu/drm/xe/xe_vm.c           | 79 ++++++++++++++++------------
 7 files changed, 93 insertions(+), 38 deletions(-)

-- 
2.42.0


             reply	other threads:[~2024-04-26 11:11 UTC|newest]

Thread overview: 23+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2024-04-26 10:56 Nirmoy Das [this message]
2024-04-26 10:56 ` [PATCH v5 1/5] drm/xe: Introduce has_atomic_enable_pte_bit device info Nirmoy Das
2024-04-26 10:56 ` [PATCH v5 2/5] drm/xe: Move vm bind bo validation to a helper function Nirmoy Das
2024-04-26 10:56 ` [PATCH v5 3/5] drm/xe: Introduce has_device_atomics_on_smem device info Nirmoy Das
2024-04-26 10:56 ` [PATCH v5 4/5] drm/xe: Add function to check if BO has single placement Nirmoy Das
2024-04-26 10:56 ` [PATCH v5 5/5] drm/xe: Refactor default device atomic settings Nirmoy Das
2024-04-26 21:04   ` Souza, Jose
2024-04-29  9:05     ` Nirmoy Das
2024-04-29 13:46       ` Souza, Jose
2024-04-29 14:15         ` Nirmoy Das
2024-04-26 12:49 ` ✓ CI.Patch_applied: success for Refactor default device atomic settings (rev3) Patchwork
2024-04-26 12:49 ` ✓ CI.checkpatch: " Patchwork
2024-04-26 12:50 ` ✓ CI.KUnit: " Patchwork
2024-04-26 13:05 ` ✓ CI.Build: " Patchwork
2024-04-26 13:08 ` ✓ CI.Hooks: " Patchwork
2024-04-26 13:09 ` ✓ CI.checksparse: " Patchwork
2024-04-26 13:40 ` ✓ CI.BAT: " Patchwork
2024-04-26 16:26 ` ✗ CI.FULL: failure " Patchwork
2024-04-26 20:41 ` ✓ CI.Patch_applied: success for Refactor default device atomic settings (rev4) Patchwork
2024-04-26 20:42 ` ✓ CI.checkpatch: " Patchwork
2024-04-26 20:43 ` ✓ CI.KUnit: " Patchwork
2024-04-29  9:11 ` ✗ CI.Patch_applied: failure for Refactor default device atomic settings (rev5) Patchwork
2024-04-29 15:43 ` [PATCH v5 0/5] Refactor default device atomic settings Mrozek, Michal

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=20240426105655.23738-1-nirmoy.das@intel.com \
    --to=nirmoy.das@intel.com \
    --cc=balasubramani.vivekanandan@intel.com \
    --cc=brian.welty@intel.com \
    --cc=fei.yang@intel.com \
    --cc=intel-xe@lists.freedesktop.org \
    --cc=jose.souza@intel.com \
    --cc=lionel.g.landwerlin@intel.com \
    --cc=matthew.brost@intel.com \
    --cc=matthew.d.roper@intel.com \
    --cc=michal.mrozek@intel.com \
    --cc=oak.zeng@intel.com \
    --cc=thomas.hellstrom@linux.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 an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.