raw/ifpga/base: unlock mutex on Nios init failure
authorWei Huang <wei.huang@intel.com>
Thu, 5 Nov 2020 02:05:39 +0000 (21:05 -0500)
committerFerruh Yigit <ferruh.yigit@intel.com>
Fri, 13 Nov 2020 15:26:54 +0000 (16:26 +0100)
commit2414339cee422a1401a399ba225132dd1a49d34a
treedca6987f56371007b1cb37cdd337b9973b772c2e
parente9d5c5fb6872e885aadbec2baeec47e681e0edc7
raw/ifpga/base: unlock mutex on Nios init failure

In fme_nios_spi_init(), a mutex is locked for protecting nios
initialization process, the mutex is only unlocked when process
is successful, it should also be unlocked when process fail.

Coverity issue: 363751
Fixes: e41856b515ce ("raw/ifpga/base: enhance driver reliability in multi-process")

Signed-off-by: Wei Huang <wei.huang@intel.com>
Acked-by: Rosen Xu <rosen.xu@intel.com>
drivers/raw/ifpga/base/ifpga_fme.c