浏览代码

rtc: hym8563: in .read_alarm set .tm_sec to 0 to signal minute accuracy

Set .tm_sec to 0 instead of -1 to signal minute accuracy.

Signed-off-by: Uwe Kleine-König <uwe@kleine-koenig.org>
Signed-off-by: Alexandre Belloni <alexandre.belloni@free-electrons.com>
Uwe Kleine-König 9 年之前
父节点
当前提交
bb9dbb01be
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      drivers/rtc/rtc-hym8563.c

+ 1 - 1
drivers/rtc/rtc-hym8563.c

@@ -198,7 +198,7 @@ static int hym8563_rtc_read_alarm(struct device *dev, struct rtc_wkalrm *alm)
 		return ret;
 
 	/* The alarm only has a minute accuracy */
-	alm_tm->tm_sec = -1;
+	alm_tm->tm_sec = 0;
 
 	alm_tm->tm_min = (buf[0] & HYM8563_ALM_BIT_DISABLE) ?
 					-1 :