drivers/rtc: remove redundant ret variable
PATCH 1/1 drivers/rtc: remove redundant ret variable
From: Minghao Chi <[email protected]>
Return value from tps65910_rtc_set_calibration() directly instead of taking this in another redundant variable.
Reported-by Zeal Robot <[email protected]>
Signed-off-by Minghao Chi <[email protected]>
Signed-off-by CGEL ZTE <[email protected]>
--- drivers/rtc/rtc-tps65910.c | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-)
drivers/rtc/rtc-tps65910.c +1 -4
@@ -304,7 +304,6 @@ static int tps65910_set_offset(struct device *dev, long offset) {int calibration;s64 tmp; -int ret;/* Make sure offset value is within supported range */ if (offset <MIN_OFFSET || offset >MAX_OFFSET )
@@ -321,9 +320,7 @@ static int tps65910_set_offset(struct device *dev, long offset)/* Offset value operates in negative way, so swap sign */ calibration = (int )-tmp; - ret =tps65910_rtc_set_calibration (dev, calibration); - -return ret; +return tps65910_rtc_set_calibration (dev, calibration); }static irqreturn_t tps65910_rtc_interrupt (int irq,void *rtc)
Signature · 1 line
2.25.1