+ drivers-rtc-rtc-ds1742c-report-to-rtc-core-if-retrieved-time-is-invalid.patch added to -mm tree

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Subject: + drivers-rtc-rtc-ds1742c-report-to-rtc-core-if-retrieved-time-is-invalid.patch added to -mm tree
To: shc_work@xxxxxxx,jg1.han@xxxxxxxxxxx
From: akpm@xxxxxxxxxxxxxxxxxxxx
Date: Thu, 29 Aug 2013 15:03:33 -0700


The patch titled
     Subject: drivers/rtc/rtc-ds1742.c: report to RTC core if retrieved time is invalid
has been added to the -mm tree.  Its filename is
     drivers-rtc-rtc-ds1742c-report-to-rtc-core-if-retrieved-time-is-invalid.patch

This patch should soon appear at
    http://ozlabs.org/~akpm/mmots/broken-out/drivers-rtc-rtc-ds1742c-report-to-rtc-core-if-retrieved-time-is-invalid.patch
and later at
    http://ozlabs.org/~akpm/mmotm/broken-out/drivers-rtc-rtc-ds1742c-report-to-rtc-core-if-retrieved-time-is-invalid.patch

Before you just go and hit "reply", please:
   a) Consider who else should be cc'ed
   b) Prefer to cc a suitable mailing list as well
   c) Ideally: find the original patch on the mailing list and do a
      reply-to-all to that, adding suitable additional cc's

*** Remember to use Documentation/SubmitChecklist when testing your code ***

The -mm tree is included into linux-next and is updated
there every 3-4 working days

------------------------------------------------------
From: Alexander Shiyan <shc_work@xxxxxxx>
Subject: drivers/rtc/rtc-ds1742.c: report to RTC core if retrieved time is invalid

Let RTC core decide if the retrieved time is invalid, instead of
processing errors in the driver.

Signed-off-by: Alexander Shiyan <shc_work@xxxxxxx>
Cc: Jingoo Han <jg1.han@xxxxxxxxxxx>
Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx>
---

 drivers/rtc/rtc-ds1742.c |    6 +-----
 1 file changed, 1 insertion(+), 5 deletions(-)

diff -puN drivers/rtc/rtc-ds1742.c~drivers-rtc-rtc-ds1742c-report-to-rtc-core-if-retrieved-time-is-invalid drivers/rtc/rtc-ds1742.c
--- a/drivers/rtc/rtc-ds1742.c~drivers-rtc-rtc-ds1742c-report-to-rtc-core-if-retrieved-time-is-invalid
+++ a/drivers/rtc/rtc-ds1742.c
@@ -115,11 +115,7 @@ static int ds1742_rtc_read_time(struct d
 	/* year is 1900 + tm->tm_year */
 	tm->tm_year = bcd2bin(year) + bcd2bin(century) * 100 - 1900;
 
-	if (rtc_valid_tm(tm) < 0) {
-		dev_err(dev, "retrieved date/time is not valid.\n");
-		rtc_time_to_tm(0, tm);
-	}
-	return 0;
+	return rtc_valid_tm(tm);
 }
 
 static const struct rtc_class_ops ds1742_rtc_ops = {
_

Patches currently in -mm which might be from shc_work@xxxxxxx are

drivers-rtc-rtc-ds1742c-use-devm_ioremap_resource.patch
drivers-rtc-rtc-ds1742c-remove-unused-field-rtc-from-private-structure.patch
drivers-rtc-rtc-ds1742c-report-to-rtc-core-if-retrieved-time-is-invalid.patch
linux-next.patch

--
To unsubscribe from this list: send the line "unsubscribe mm-commits" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html




[Index of Archives]     [Kernel Newbies FAQ]     [Kernel Archive]     [IETF Annouce]     [DCCP]     [Netdev]     [Networking]     [Security]     [Bugtraq]     [Photo]     [Yosemite]     [MIPS Linux]     [ARM Linux]     [Linux Security]     [Linux RAID]     [Linux SCSI]

  Powered by Linux