[Intel-gfx] [PATCH] drm/i915: Unwind partial VMA rebinding after failure in set-cache-level

Chris Wilson chris at chris-wilson.co.uk
Fri Oct 9 05:19:43 PDT 2015

On Fri, Oct 09, 2015 at 01:11:47PM +0100, Tvrtko Ursulin wrote:
> On 09/10/15 12:51, Chris Wilson wrote:
> >If the impossible happens and we fail to rebind a VMA in the middle of
> >rebinding all VMA for an object we currently bail out and leave the
> >object in an inconsistent state. Attempt to unwind the incomplete update
> >by reverting all updated VMA back to the original cache-level, and WARN
> >if that fails.
> Hey a BUG_ON would have been more your style! ;)

Propagating error returns trumps throwing a tantrum and then as we are
on the the error path we've already proved the impossible could happen,
so presume it could happen again.

Chris Wilson, Intel Open Source Technology Centre

More information about the Intel-gfx mailing list