summaryrefslogtreecommitdiffstats
path: root/drivers/rtc/rtc-m41t80.c
diff options
context:
space:
mode:
authorUwe Kleine-König <uwe@kleine-koenig.org>2016-06-28 10:43:45 +0200
committerAlexandre Belloni <alexandre.belloni@free-electrons.com>2016-07-09 10:24:45 +0200
commit56d86a7e799d3d893cb96f5b17b13de134af8de5 (patch)
tree2e88564cc608cc35a0d41fafdce4b8a3af06e54c /drivers/rtc/rtc-m41t80.c
parente29385fab0bf94017fac130ee32f5bb2daf74417 (diff)
downloadtalos-obmc-linux-56d86a7e799d3d893cb96f5b17b13de134af8de5.tar.gz
talos-obmc-linux-56d86a7e799d3d893cb96f5b17b13de134af8de5.zip
rtc: simplify implementations of read_alarm
Since commit d68778b80dd7 ("rtc: initialize output parameter for read alarm to "uninitialized"") there is no need to explicitly set unsupported members to -1. So drop the respective assignments from drivers. Signed-off-by: Uwe Kleine-König <uwe@kleine-koenig.org> Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Diffstat (limited to 'drivers/rtc/rtc-m41t80.c')
-rw-r--r--drivers/rtc/rtc-m41t80.c2
1 files changed, 0 insertions, 2 deletions
diff --git a/drivers/rtc/rtc-m41t80.c b/drivers/rtc/rtc-m41t80.c
index d1bf93a87200..c829bc45a371 100644
--- a/drivers/rtc/rtc-m41t80.c
+++ b/drivers/rtc/rtc-m41t80.c
@@ -320,10 +320,8 @@ static int m41t80_read_alarm(struct device *dev, struct rtc_wkalrm *alrm)
alrm->time.tm_sec = bcd2bin(alarmvals[4] & 0x7f);
alrm->time.tm_min = bcd2bin(alarmvals[3] & 0x7f);
alrm->time.tm_hour = bcd2bin(alarmvals[2] & 0x3f);
- alrm->time.tm_wday = -1;
alrm->time.tm_mday = bcd2bin(alarmvals[1] & 0x3f);
alrm->time.tm_mon = bcd2bin(alarmvals[0] & 0x3f);
- alrm->time.tm_year = -1;
alrm->enabled = !!(alarmvals[0] & M41T80_ALMON_AFE);
alrm->pending = (flags & M41T80_FLAGS_AF) && alrm->enabled;
OpenPOWER on IntegriCloud