lkml.org 
[lkml]   [2018]   [Feb]   [21]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    Patch in this message
    /
    From
    Subject[PATCH 084/100] rtc: abx80x: remove useless message
    Date
    It is not necessary to print a message when the time is invalid as
    userspace will already get an error (and an optional dev_dbg message).

    Signed-off-by: Alexandre Belloni <alexandre.belloni@bootlin.com>
    ---
    drivers/rtc/rtc-abx80x.c | 6 +-----
    1 file changed, 1 insertion(+), 5 deletions(-)

    diff --git a/drivers/rtc/rtc-abx80x.c b/drivers/rtc/rtc-abx80x.c
    index b033bc556f5d..2cefa67a1132 100644
    --- a/drivers/rtc/rtc-abx80x.c
    +++ b/drivers/rtc/rtc-abx80x.c
    @@ -172,11 +172,7 @@ static int abx80x_rtc_read_time(struct device *dev, struct rtc_time *tm)
    tm->tm_mon = bcd2bin(buf[ABX8XX_REG_MO] & 0x1F) - 1;
    tm->tm_year = bcd2bin(buf[ABX8XX_REG_YR]) + 100;

    - err = rtc_valid_tm(tm);
    - if (err < 0)
    - dev_err(&client->dev, "retrieved date/time is not valid.\n");
    -
    - return err;
    + return 0;
    }

    static int abx80x_rtc_set_time(struct device *dev, struct rtc_time *tm)
    --
    2.16.1
    \
     
     \ /
      Last update: 2018-02-21 22:07    [W:3.059 / U:0.072 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site