dri-devel Archive on lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH v5 0/5] accel/amdxdna: SYNC_BO correctness fixes
@ 2026-08-19 22:44 Taimuraz Kaitmazov
  2026-08-19 22:44 ` [PATCH v5 1/5] accel/amdxdna: refuse an I/O memory mapping of an imported BO Taimuraz Kaitmazov
                   ` (4 more replies)
  0 siblings, 5 replies; 11+ messages in thread
From: Taimuraz Kaitmazov @ 2026-08-19 22:44 UTC (permalink / raw)
  To: Lizhi Hou, Min Ma, Oded Gabbay
  Cc: taimuraz, Christian König, Sumit Semwal, Alex Deucher,
	Max Zhen, Sonal Santan, dri-devel, linux-kernel, linux-media,
	linaro-mm-sig

Same five fixes as v4, with both review comments addressed.

Changes in v5:
  - patch 3: XDNA_DBG rather than XDNA_ERR, per Lizhi. An unprivileged
    caller can repeat it, which is the same reason patch 1 does not log
    at error level.
  - patch 5: reworked as Lizhi asked. The assigned_hwctx test moves into
    amdxdna_drm_sync_bo_ioctl(), which has the object already, so
    amdxdna_hwctx_sync_debug_bo() keeps -EINVAL for a context that is
    named but gone, and the handle is not resolved twice.
  - patches 1, 2 and 4 carry Lizhi's Reviewed-by, otherwise unchanged.

One behaviour change userspace can see, spelled out in patch 4: SYNC_BO
answers -EOPNOTSUPP for an imported BO, which on a carveout device is every
AMDXDNA_BO_DEV.

Patch 4 still needs "accel/amdxdna: return early from a zero-length
flush", which is now in drm-misc-fixes, so it wants that backmerged into
drm-misc-next. Patches 1, 2, 3 and 5 apply without it.

  https://lore.kernel.org/all/20260817230655.356785-1-taimuraz@kaitmazov.com/

v4: https://lore.kernel.org/all/20260817230707.356828-1-taimuraz@kaitmazov.com/

Built on drm-misc-next plus that commit, each commit on its own: x86_64
with DRM_ACCEL_AMDXDNA=m, clang 22.1.8, W=1, no warnings, checkpatch
--strict clean.

Taimuraz Kaitmazov (5):
  accel/amdxdna: refuse an I/O memory mapping of an imported BO
  accel/amdxdna: check the sync range for overflow on a device BO
  accel/amdxdna: do not warn when a sync request is rejected
  accel/amdxdna: refuse to flush an imported BO
  accel/amdxdna: do not fail a sync for a BO with no debug context

 drivers/accel/amdxdna/amdxdna_gem.c | 30 ++++++++++++++++++++---------
 1 file changed, 21 insertions(+), 9 deletions(-)

-- 
2.55.0


^ permalink raw reply	[flat|nested] 11+ messages in thread

end of thread, other threads:[~2026-09-17 20:25 UTC | newest]

Thread overview: 11+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-08-19 22:44 [PATCH v5 0/5] accel/amdxdna: SYNC_BO correctness fixes Taimuraz Kaitmazov
2026-08-19 22:44 ` [PATCH v5 1/5] accel/amdxdna: refuse an I/O memory mapping of an imported BO Taimuraz Kaitmazov
2026-08-19 22:44 ` [PATCH v5 2/5] accel/amdxdna: check the sync range for overflow on a device BO Taimuraz Kaitmazov
2026-08-19 22:44 ` [PATCH v5 3/5] accel/amdxdna: do not warn when a sync request is rejected Taimuraz Kaitmazov
2026-09-17 15:55   ` Lizhi Hou
2026-09-17 20:24     ` Lizhi Hou
2026-08-19 22:44 ` [PATCH v5 4/5] accel/amdxdna: refuse to flush an imported BO Taimuraz Kaitmazov
2026-09-02 15:39   ` Lizhi Hou
2026-08-19 22:44 ` [PATCH v5 5/5] accel/amdxdna: do not fail a sync for a BO with no debug context Taimuraz Kaitmazov
2026-09-17 16:11   ` Lizhi Hou
2026-09-17 20:25     ` Lizhi Hou

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox