In eb_lookup_vma(), the code checks that the context vm matches before
incrementing the i915 vma usage count, but for the non-matching case it
didn't clear the non-matching vma pointer, so it would then mistakenly
be returned, causing potential UaF and refcount issues.
Reported-by: Yassine Mounir <[email protected]>
Suggested-by: Ville Syrjälä <[email protected]>
Signed-off-by: Linus Torvalds <[email protected]>