Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]


Groups > linux.kernel > #1447786 > unrolled thread

[PATCH 2/6] rtc: rv8803: Remove the check for valid time

Started byBenoît Thébaudeau <benoit@wsystem.com>
First post2016-07-21 12:50 +0200
Last post2016-07-21 12:50 +0200
Articles 1 — 1 participant

Back to article view | Back to linux.kernel

This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by below is the oldest one visible, not the original post.


Contents

  [PATCH 2/6] rtc: rv8803: Remove the check for valid time Benoît Thébaudeau <benoit@wsystem.com> - 2016-07-21 12:50 +0200

#1447786 — [PATCH 2/6] rtc: rv8803: Remove the check for valid time

FromBenoît Thébaudeau <benoit@wsystem.com>
Date2016-07-21 12:50 +0200
Subject[PATCH 2/6] rtc: rv8803: Remove the check for valid time
Message-ID<rXjIf-6iZ-49@gated-at.bofh.it>
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 <benoit@wsystem.com>
---
 drivers/rtc/rtc-rv8803.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/rtc/rtc-rv8803.c b/drivers/rtc/rtc-rv8803.c
index 05c79c3..e740c83 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)
-- 
2.5.0

[toc] | [standalone]


Back to top | Article view | linux.kernel


csiph-web