diff options
author | Colin Ian King | 2017-06-07 16:26:15 +0100 |
---|---|---|
committer | Alexandre Belloni | 2017-07-31 00:17:48 +0200 |
commit | 2f7f1b780dd60278819d396b67db8c41db6a3b1f (patch) | |
tree | 3712b88971a42cee5f5b93268d87a12ee1fddeca /drivers/rtc | |
parent | 1a37c34811f6d115063042a17211cd70ab560ddd (diff) |
rtc: max8925: remove redundant check on ret
The check on ret < 0 is redundant as the goto destination is the
next statment. Remove this redudant check and goto.
Detected by CoverityScan, CID#1268785 ("Identical code for different
branches")
Signed-off-by: Colin Ian King <colin.king@canonical.com>
Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Diffstat (limited to 'drivers/rtc')
-rw-r--r-- | drivers/rtc/rtc-max8925.c | 2 |
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/rtc/rtc-max8925.c b/drivers/rtc/rtc-max8925.c index 16d129a0bb3b..67d6fc2d23e6 100644 --- a/drivers/rtc/rtc-max8925.c +++ b/drivers/rtc/rtc-max8925.c @@ -234,8 +234,6 @@ static int max8925_rtc_set_alarm(struct device *dev, struct rtc_wkalrm *alrm) ret = max8925_reg_write(info->rtc, MAX8925_ALARM0_CNTL, 0x77); else ret = max8925_reg_write(info->rtc, MAX8925_ALARM0_CNTL, 0x0); - if (ret < 0) - goto out; out: return ret; } |