lkml.org 
[lkml]   [2017]   [Nov]   [8]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
From
Date
SubjectRe: [PATCH 2/2] rtc: sprd: Add Spreadtrum RTC driver
On 8 November 2017 at 13:35, Alexandre Belloni
<alexandre.belloni@free-electrons.com> wrote:
> On 08/11/2017 at 13:29:21 +0800, Baolin Wang wrote:
>> > Don't do that. This is a valuable information. If you know the time is
>> > invalid, return -EINVAL in read_time(). What your are doing here is
>> > confusing the system by making it believe your fake date is the correct
>> > time.
>>
>> Usually for mobile device, we should give one reasonable start time if
>> the RTC powered down. Anyway I can remove this feature now.
>> Very appreciated for your helpful comments.
>
> Then userspace will have -EINVAL when reading the RTC and will be able
> to set the RTC to whatever value it wants. Don't encode that policy in
> the kernel.

That's great. Thanks for explanation.

--
Baolin.wang
Best Regards

\
 
 \ /
  Last update: 2017-11-08 21:10    [W:0.041 / U:1.084 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site