Skip to content
Commit 8816cd72 authored by Qiushi Wu's avatar Qiushi Wu Committed by Alexandre Belloni
Browse files

rtc: mc13xxx: fix a double-unlock issue



In function mc13xxx_rtc_probe, the mc13xxx_unlock() is called
before rtc_register_device(). But in the error path of
rtc_register_device(), the mc13xxx_unlock() is called again,
which causes a double-unlock problem. Thus add a call of the
function “mc13xxx_lock” in an if branch for the completion
of the exception handling.

Fixes: e4ae7023 ("rtc: mc13xxx: set range")
Signed-off-by: default avatarQiushi Wu <wu000273@umn.edu>
Link: https://lore.kernel.org/r/20200503182235.1652-1-wu000273@umn.edu


Signed-off-by: default avatarAlexandre Belloni <alexandre.belloni@bootlin.com>
parent 32271efd
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please to comment