Message ID | 20220201070340.16457-1-thomas.hellstrom@linux.intel.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | drm/i915/ttm: Return some errors instead of trying memcpy move | expand |
On 01/02/2022 07:03, Thomas Hellström wrote: > The i915_ttm_accel_move() function may return error codes that should > be propagated further up the stack rather than consumed assuming that > the accel move failed and could be replaced with a memcpy move. > > For -EINTR, -ERESTARTSYS and -EAGAIN, just propagate those codes, rather > than retrying with a memcpy move. > > Fixes: 2b0a750caf33 ("drm/i915/ttm: Failsafe migration blits") > Cc: Matthew Auld <matthew.auld@intel.com> > Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com> Reviewed-by: Matthew Auld <matthew.auld@intel.com>
On 2/1/22 10:16, Patchwork wrote: > Project List - Patchwork *Patch Details* > *Series:* drm/i915/ttm: Return some errors instead of trying memcpy move > *URL:* https://patchwork.freedesktop.org/series/99553/ > *State:* failure > *Details:* > https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22145/index.html > > > CI Bug Log - changes from CI_DRM_11168_full -> Patchwork_22145_full > > > Summary > > *FAILURE* > > Serious unknown changes coming with Patchwork_22145_full absolutely > need to be > verified manually. > > If you think the reported changes have nothing to do with the changes > introduced in Patchwork_22145_full, please notify your bug team to > allow them > to document this new failure mode, which will reduce false positives > in CI. > > > Participating hosts (11 -> 13) > > Additional (2): shard-rkl shard-dg1 > > > Possible new issues > > Here are the unknown changes that may have been introduced in > Patchwork_22145_full: > > > IGT changes > > > Possible regressions > > * igt@gem_ctx_persistence@smoketest: > o shard-apl: PASS > <https://intel-gfx-ci.01.org/tree/drm-tip/CI_DRM_11168/shard-apl6/igt@gem_ctx_persistence@smoketest.html> > -> FAIL > <https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22145/shard-apl4/igt@gem_ctx_persistence@smoketest.html> > > > Suppressed > > The following results come from untrusted machines, tests, or statuses. > They do not affect the overall result. > > * > > igt@kms_scaling_modes@scaling-mode-full-aspect: > > o {shard-rkl}: NOTRUN -> SKIP > <https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22145/shard-rkl-1/igt@kms_scaling_modes@scaling-mode-full-aspect.html> > * > > igt@kms_scaling_modes@scaling-mode-none: > > o {shard-dg1}: NOTRUN -> SKIP > <https://intel-gfx-ci.01.org/tree/drm-tip/Patchwork_22145/shard-dg1-15/igt@kms_scaling_modes@scaling-mode-none.html> > These are unrelated. /Thomas
diff --git a/drivers/gpu/drm/i915/gem/i915_gem_ttm_move.c b/drivers/gpu/drm/i915/gem/i915_gem_ttm_move.c index 1de306c03aaf..1ebe6e4086a1 100644 --- a/drivers/gpu/drm/i915/gem/i915_gem_ttm_move.c +++ b/drivers/gpu/drm/i915/gem/i915_gem_ttm_move.c @@ -436,11 +436,17 @@ __i915_ttm_move(struct ttm_buffer_object *bo, if (!IS_ERR(fence)) goto out; - } else if (move_deps) { - int err = i915_deps_sync(move_deps, ctx); + } else { + int err = PTR_ERR(fence); + + if (err == -EINTR || err == -ERESTARTSYS || err == -EAGAIN) + return fence; - if (err) - return ERR_PTR(err); + if (move_deps) { + err = i915_deps_sync(move_deps, ctx); + if (err) + return ERR_PTR(err); + } } /* Error intercept failed or no accelerated migration to start with */
The i915_ttm_accel_move() function may return error codes that should be propagated further up the stack rather than consumed assuming that the accel move failed and could be replaced with a memcpy move. For -EINTR, -ERESTARTSYS and -EAGAIN, just propagate those codes, rather than retrying with a memcpy move. Fixes: 2b0a750caf33 ("drm/i915/ttm: Failsafe migration blits") Cc: Matthew Auld <matthew.auld@intel.com> Signed-off-by: Thomas Hellström <thomas.hellstrom@linux.intel.com> --- drivers/gpu/drm/i915/gem/i915_gem_ttm_move.c | 14 ++++++++++---- 1 file changed, 10 insertions(+), 4 deletions(-)