Skip to content
Commit 16682c86 authored by Hyogi Gim's avatar Hyogi Gim Committed by Linus Torvalds
Browse files

drivers/rtc/interface.c: check the validation of rtc_time in __rtc_read_time



Some rtc devices always return '0' when rtc_class_ops.read_time is
called.  So if rtc_time isn't verified in callback, rtc interface cannot
know whether rtc_time is valid.

Check rtc_time by using 'rtc_valid_tm' in '__rtc_read_time'.  And add
the message for debugging.

Signed-off-by: default avatarHyogi Gim <hyogi.gim@lge.com>
Cc: Alessandro Zummo <a.zummo@towertech.it>
Cc: John Stultz <john.stultz@linaro.org>
Signed-off-by: default avatarAndrew Morton <akpm@linux-foundation.org>
Signed-off-by: default avatarLinus Torvalds <torvalds@linux-foundation.org>
parent 0e953255
Loading
Loading
Loading
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment