hwmon: (lm80) Fix missing unlock on error in set_fan_div()
authorWei Yongjun <weiyongjun1@huawei.com>
Wed, 26 Dec 2018 11:28:24 +0000 (11:28 +0000)
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Sat, 23 Feb 2019 08:06:42 +0000 (09:06 +0100)
commit48dc41afef9fe5b63a5fbc82852bb6a913f5a99c
tree8f46cb0aa0c3d0106290dd59e5ef24048432a278
parent58cdc5947af63eb33fd631803101d37e5d4b4301
hwmon: (lm80) Fix missing unlock on error in set_fan_div()

[ Upstream commit 07bd14ccc3049f9c0147a91a4227a571f981601a ]

Add the missing unlock before return from function set_fan_div()
in the error handling case.

Fixes: c9c63915519b ("hwmon: (lm80) fix a missing check of the status of SMBus read")
Signed-off-by: Wei Yongjun <weiyongjun1@huawei.com>
Signed-off-by: Guenter Roeck <linux@roeck-us.net>
Signed-off-by: Sasha Levin <sashal@kernel.org>
drivers/hwmon/lm80.c