Skip to content

Fix error propagation amongst request

Andi Shyti dri-devel intel-gfx stable 4 versions – In review

Get series with b4
b4 am [email protected]

Versions newest first · linked by author and title

  1. v5 Latest5 patches 9 repliesIn review
  2. v45 patches 9 repliesSuperseded
  3. v32 patches 2 repliesSuperseded
Earlier versions · 1
VersionPostedPatchesRepliesStatus
v22 patches0 repliesSuperseded

Changes in v5 from the cover letter

- add timeline locking also in the copy operation, which was forgottein in v4.
- rearrange the patches in order to avoid a bisect break.

Patches in v5 No applies recorded yet

#Subject and filesSizeRepliesApplied
1/5drm/i915/gt: Add intel_context_timeline_is_locked helperdrivers/gpu/drm/i915/gt/intel_context.h+6 -01 reply
2/5drm/i915: Create the locked version of the request createdrivers/gpu/drm/i915/i915_request.c drivers/gpu/drm/i915/i915_request.h+30 -102 replies
3/5drm/i915: Create the locked version of the request adddrivers/gpu/drm/i915/i915_request.c drivers/gpu/drm/i915/i915_request.h+12 -32 replies
4/5drm/i915: Throttle for ringspace prior to taking the timeline mutexdrivers/gpu/drm/i915/gt/intel_context.c drivers/gpu/drm/i915/gt/intel_context.h drivers/gpu/drm/i915/i915_request.c+46 -00 replies
5/5drm/i915/gt: Make sure that errors are propagated through request chainsdrivers/gpu/drm/i915/gt/intel_migrate.c+39 -124 replies

Reviews trailers per patch

All 5 patches have a Reviewed-by or Acked-by.

PatchNirmoy DasAndrzej HajdaMatthew Auld
1/5R-b R-b
2/5R-b R-b
3/5R-b
4/5R-b
5/5A-b R-b

Trailers given in replies are filled; those carried in the patches from earlier versions are outlined with dashes. Scroll the table sideways for all 3 reviewers.

Read the v5 thread

Cover letter [PATCH v5 0/5] Fix error propagation amongst request

Hi,

This series of two patches fixes the issue introduced in cf586021642d80 ("drm/i915/gt: Pipelined page migration") where, as reported by Matt, in a chain of requests an error is reported only if happens in the last request.

However Chris noticed that without ensuring exclusivity in the locking we might end up in some deadlock. That's why patch 1 throttles for the ringspace in order to make sure that no one is holding it.

Version 1 of this patch has been reviewed by matt and this version is adding Chris exclusive locking.

Thanks Chris for this work.

Andi

Changelog
=========
v4 -> v5
- add timeline locking also in the copy operation, which was forgottein in v4.
- rearrange the patches in order to avoid a bisect break.

v3 -> v4
- In v3 the timeline was being locked, but I forgot that also request_create() and request_add() are locking the timeline as well. The former does the locking, the latter does the unlocking. In order to avoid this extra lock/unlock, we need the "_locked" version of the said functions.

v2 -> v3
- Really lock the timeline before generating all the requests until the last.

v1 -> v2
- Add patch 1 for ensuring exclusive locking of the timeline
- Reword git commit of patch 2.

Andi Shyti (4):
drm/i915/gt: Add intel_context_timeline_is_locked helper drm/i915: Create the locked version of the request create drm/i915: Create the locked version of the request add drm/i915/gt: Make sure that errors are propagated through request
chains

Chris Wilson (1):
drm/i915: Throttle for ringspace prior to taking the timeline mutex

 drivers/gpu/drm/i915/gt/intel_context.c | 41 ++++++++++++++++++
 drivers/gpu/drm/i915/gt/intel_context.h |  8 ++++
 drivers/gpu/drm/i915/gt/intel_migrate.c | 51 +++++++++++++++++------
 drivers/gpu/drm/i915/i915_request.c     | 55 +++++++++++++++++++------
 drivers/gpu/drm/i915/i915_request.h     |  3 ++
 5 files changed, 133 insertions(+), 25 deletions(-)
Signature · 1 line
2.39.2