From 96acb25c50e77355673b89765b96bd764abf487d Mon Sep 17 00:00:00 2001 From: Benoît Thébaudeau Date: Thu, 21 Jul 2016 12:41:28 +0200 Subject: rtc: rv8803: Remove the check for valid time MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The RTC core always calls rtc_valid_tm() after ->read_time() in case of success (in __rtc_read_time()), so do not call it twice. Signed-off-by: Benoît Thébaudeau Signed-off-by: Alexandre Belloni --- drivers/rtc/rtc-rv8803.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'drivers/rtc/rtc-rv8803.c') diff --git a/drivers/rtc/rtc-rv8803.c b/drivers/rtc/rtc-rv8803.c index 05c79c38689d..e740c8351659 100644 --- a/drivers/rtc/rtc-rv8803.c +++ b/drivers/rtc/rtc-rv8803.c @@ -150,7 +150,7 @@ static int rv8803_get_time(struct device *dev, struct rtc_time *tm) tm->tm_mon = bcd2bin(date[RV8803_MONTH] & 0x1f) - 1; tm->tm_year = bcd2bin(date[RV8803_YEAR]) + 100; - return rtc_valid_tm(tm); + return 0; } static int rv8803_set_time(struct device *dev, struct rtc_time *tm) -- cgit v1.2.3-59-g8ed1b