Re: [PATCH 2/2] rtc: sprd: Add Spreadtrum RTC driver

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

 




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.


-- 
Alexandre Belloni, Free Electrons
Embedded Linux and Kernel engineering
http://free-electrons.com
--
To unsubscribe from this list: send the line "unsubscribe devicetree" in
the body of a message to majordomo@xxxxxxxxxxxxxxx
More majordomo info at  http://vger.kernel.org/majordomo-info.html



[Index of Archives]     [Device Tree Compilter]     [Device Tree Spec]     [Linux Driver Backports]     [Video for Linux]     [Linux USB Devel]     [Linux PCI Devel]     [Linux Audio Users]     [Linux Kernel]     [Linux SCSI]     [XFree86]     [Yosemite Backpacking]


  Powered by Linux