drm/i915: fix handling gen8_emit_flush_coherentl3_wa result
authorAndrzej Hajda <a.hajda@samsung.com>
Mon, 21 Sep 2015 13:33:35 +0000 (15:33 +0200)
committerDaniel Vetter <daniel.vetter@ffwll.ch>
Tue, 22 Sep 2015 15:10:52 +0000 (17:10 +0200)
commit604ef7346862bb761a091932e99c14204ff4050a
tree38375e1e1b12f11af1e7baefdd349a207512e625
parent5389e916c3b64c3dd249018dfaf983e2e3a06c6f
drm/i915: fix handling gen8_emit_flush_coherentl3_wa result

The function can return negative value.

The problem has been detected using proposed semantic patch
scripts/coccinelle/tests/unsigned_lesser_than_zero.cocci [1].

[1]: http://permalink.gmane.org/gmane.linux.kernel/2038576

Signed-off-by: Andrzej Hajda <a.hajda@samsung.com>
Reviewed-by: Jani Nikula <jani.nikula@intel.com>
Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
drivers/gpu/drm/i915/intel_lrc.c