[media] media: venus: hfi: fix mutex unlock
authorStanimir Varbanov <stanimir.varbanov@linaro.org>
Thu, 15 Jun 2017 16:31:51 +0000 (13:31 -0300)
committerMauro Carvalho Chehab <mchehab@s-opensource.com>
Tue, 20 Jun 2017 11:53:40 +0000 (08:53 -0300)
This fixed a warning when build driver with gcc7:

drivers/media/platform/qcom/venus/hfi.c:171
hfi_core_ping() warn: inconsistent returns 'mutex:&core->lock'.
  Locked on:   line 159
  Unlocked on: line 171

Signed-off-by: Stanimir Varbanov <stanimir.varbanov@linaro.org>
Signed-off-by: Hans Verkuil <hans.verkuil@cisco.com>
Signed-off-by: Mauro Carvalho Chehab <mchehab@s-opensource.com>
drivers/media/platform/qcom/venus/hfi.c

index 20c9205fdbb4102d491e4b6a795d0882906c8398..c09490876516fbd0ebc793aad7d93cf3c8d38a5f 100644 (file)
@@ -156,7 +156,7 @@ int hfi_core_ping(struct venus_core *core)
 
        ret = core->ops->core_ping(core, 0xbeef);
        if (ret)
-               return ret;
+               goto unlock;
 
        ret = wait_for_completion_timeout(&core->done, TIMEOUT);
        if (!ret) {