CHROMIUM: MALI: fix signaling of already signaled fences

Error code can be only set once, before fence is signaled.
So before setting error code, test if fence is signaled and do
not try to signal fence that has been already signaled.

BUG=chromium:760802
TEST=killall -9 surfaceflinger, no BUG_ON reboot

Change-Id: Ibc5f61381d51af3fa31903e3df43e715dc03e661
Signed-off-by: Dominik Behr <dbehr@chromium.org>
Reviewed-on: https://chromium-review.googlesource.com/644410
Commit-Ready: Douglas Anderson <dianders@chromium.org>
Tested-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: Douglas Anderson <dianders@chromium.org>
Reviewed-by: St├ęphane Marchesin <marcheu@chromium.org>
Reviewed-by: Tomasz Figa <tfiga@chromium.org>
(cherry picked from commit 466855709f5ac0afdbe27a8079437974bd314ec8)
Reviewed-on: https://chromium-review.googlesource.com/655997
1 file changed