In rtc_suspend() and rtc_resume(), the error after rtc_read_time() is not
checked. If rtc device fail to read time, we cannot guarantee the following
process.
Add the verification code for returned rtc_read_time() error.
Signed-off-by: Hyogi Gim
---
drivers/rtc/class.c | 16 ++--
1
ot;return 0" to clarify
the rtc device error.
Signed-off-by: Hyogi Gim
---
kernel/time/alarmtimer.c | 12 ++--
1 file changed, 10 insertions(+), 2 deletions(-)
diff --git a/kernel/time/alarmtimer.c b/kernel/time/alarmtimer.c
index 88c9c65..8cc43b8 100644
--- a/kernel/time/alarmtimer
In __rtc_set_alarm(), the error after __rtc_read_time() is not checked.
If rtc device fail to read time, we cannot guarantee the following process.
Add the verification code for returned __rtc_read_time() error.
Signed-off-by: Hyogi Gim
---
drivers/rtc/interface.c | 2 ++
1 file changed, 2
returned alarmtimer_type from
clock2alarm().
Signed-off-by: Hyogi Gim
Cc: Thomas Gleixner
---
kernel/time/alarmtimer.c | 27 ---
1 file changed, 24 insertions(+), 3 deletions(-)
diff --git a/kernel/time/alarmtimer.c b/kernel/time/alarmtimer.c
index 88c9c65..0b117c6
On 07/24/2014 09:19 AM, Andrew Morton wrote:
>
> So what should rtc do in this case? At present it pretends the read
> succeeded. Either way, this doesn't seem to be the place to be making
> such policy decisions..
>
>
>
I agree. But, in this case, RTC device driver can not do anything. An
On 07/31/2014 02:58 AM, John Stultz wrote:
>
> Hey! Sorry for the late response here.
>
> So this seems reasonable as always failing suspend is problematic, but
> I worry that for the case where we do have a failure to read or set
> the RTC, we'd suspend and not wake up as specified, which is a
Some of 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 d
On Tue, Oct 14, 2014 at 03:21:31PM -0700, Andrew Morton wrote:
> On Wed, 8 Oct 2014 11:05:29 +0900 Hyogi Gim wrote:
>
> > Some of rtc devices always return '0' when rtc_class_ops.read_time is
> > called.
> > So if rtc_time isn't verified in call
On Wed, Dec 17, 2014 at 01:51:50PM -0800, Andrew Morton wrote:
> On Wed, 17 Dec 2014 12:15:24 +0900 Hyogi Gim wrote:
>
> > Add the verification code for returned __rtc_read_time() error in
> > rtc_update_irq_enable() and rtc_timer_do_work().
> >
> > ...
> L
Add the verification code for returned __rtc_read_time() error in
rtc_update_irq_enable() and rtc_timer_do_work().
Signed-off-by: Hyogi Gim
---
drivers/rtc/interface.c | 13 ++---
1 file changed, 10 insertions(+), 3 deletions(-)
diff --git a/drivers/rtc/interface.c b/drivers/rtc
10 matches
Mail list logo