RE: [EXT] Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-26 Thread Biwen Li
> > Hi, > > On 26/08/2019 09:49:49+, Biwen Li wrote: > > > > > > On 8/26/19 7:29 AM, Biwen Li wrote: > > > >> > > > >> On 8/16/19 10:40 PM, Li Yang wrote: > > > >>> On Fri, Aug 16, 2019 at 11:30 AM Alexandre Belloni > > > >>> wrote: > > > > > > On 16/08/2019 10:50:49-0500, Li Yang

Re: [EXT] Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-26 Thread Alexandre Belloni
Hi, On 26/08/2019 09:49:49+, Biwen Li wrote: > > > > On 8/26/19 7:29 AM, Biwen Li wrote: > > >> > > >> On 8/16/19 10:40 PM, Li Yang wrote: > > >>> On Fri, Aug 16, 2019 at 11:30 AM Alexandre Belloni > > >>> wrote: > > > > On 16/08/2019 10:50:49-0500, Li Yang wrote: > > > On

RE: [EXT] Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-26 Thread Biwen Li
> > On 8/26/19 7:29 AM, Biwen Li wrote: > >> > >> On 8/16/19 10:40 PM, Li Yang wrote: > >>> On Fri, Aug 16, 2019 at 11:30 AM Alexandre Belloni > >>> wrote: > > On 16/08/2019 10:50:49-0500, Li Yang wrote: > > On Fri, Aug 16, 2019 at 3:05 AM Alexandre Belloni > > wrote: > >>

Re: [EXT] Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-26 Thread Nandor Han
On 8/26/19 7:29 AM, Biwen Li wrote: On 8/16/19 10:40 PM, Li Yang wrote: On Fri, Aug 16, 2019 at 11:30 AM Alexandre Belloni wrote: On 16/08/2019 10:50:49-0500, Li Yang wrote: On Fri, Aug 16, 2019 at 3:05 AM Alexandre Belloni wrote: On 16/08/2019 10:46:36+0800, Biwen Li wrote: Issue:

RE: [EXT] Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-25 Thread Biwen Li
> > On 8/16/19 10:40 PM, Li Yang wrote: > > On Fri, Aug 16, 2019 at 11:30 AM Alexandre Belloni > > wrote: > >> > >> On 16/08/2019 10:50:49-0500, Li Yang wrote: > >>> On Fri, Aug 16, 2019 at 3:05 AM Alexandre Belloni > >>> wrote: > > On 16/08/2019 10:46:36+0800, Biwen Li wrote: > >

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-21 Thread Mark Brown
On Wed, Aug 21, 2019 at 01:38:56PM +0200, Alexandre Belloni wrote: > On 21/08/2019 12:30:29+0100, Mark Brown wrote: > > What's the mechanism here? It's a very strange thing to require. > The clock control is on the first register, then you have sec, min, > hour, day, mon, year. > To be able to

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-21 Thread Alexandre Belloni
On 21/08/2019 12:30:29+0100, Mark Brown wrote: > On Wed, Aug 21, 2019 at 01:24:13PM +0200, Alexandre Belloni wrote: > > On 21/08/2019 12:21:42+0100, Mark Brown wrote: > > > On Tue, Aug 20, 2019 at 01:33:14PM -0500, Li Yang wrote: > > > > > violation check of regmap rejects such access. According

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-21 Thread Mark Brown
On Wed, Aug 21, 2019 at 01:24:13PM +0200, Alexandre Belloni wrote: > On 21/08/2019 12:21:42+0100, Mark Brown wrote: > > On Tue, Aug 20, 2019 at 01:33:14PM -0500, Li Yang wrote: > > > violation check of regmap rejects such access. According to > > > Alexcandre, the address wrapping is essential

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-21 Thread Alexandre Belloni
On 21/08/2019 12:21:42+0100, Mark Brown wrote: > On Tue, Aug 20, 2019 at 01:33:14PM -0500, Li Yang wrote: > > > Some of the RTC hardware has the capability of address wrapping which > > means if you access a continuous address range across a certain > > boundary(could be the boundary of a regmap

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-21 Thread Mark Brown
On Tue, Aug 20, 2019 at 01:33:14PM -0500, Li Yang wrote: > Some of the RTC hardware has the capability of address wrapping which > means if you access a continuous address range across a certain > boundary(could be the boundary of a regmap region) the hardware > actually wrap the access to a

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-21 Thread Nandor Han
On 8/16/19 10:40 PM, Li Yang wrote: On Fri, Aug 16, 2019 at 11:30 AM Alexandre Belloni wrote: On 16/08/2019 10:50:49-0500, Li Yang wrote: On Fri, Aug 16, 2019 at 3:05 AM Alexandre Belloni wrote: On 16/08/2019 10:46:36+0800, Biwen Li wrote: Issue: - # hwclock -w hwclock:

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-20 Thread Li Yang
On Tue, Aug 20, 2019 at 1:24 PM Mark Brown wrote: > > On Fri, Aug 16, 2019 at 02:40:47PM -0500, Li Yang wrote: > > On Fri, Aug 16, 2019 at 11:30 AM Alexandre Belloni > > > > Most of the i2c RTCs do address wrapping which is sometimes the only way > > > to properly set the time. > > > Adding Mark

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-20 Thread Mark Brown
On Fri, Aug 16, 2019 at 02:40:47PM -0500, Li Yang wrote: > On Fri, Aug 16, 2019 at 11:30 AM Alexandre Belloni > > Most of the i2c RTCs do address wrapping which is sometimes the only way > > to properly set the time. > Adding Mark and Nandor to the loop. Is there a specific question or

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-16 Thread Li Yang
On Fri, Aug 16, 2019 at 11:30 AM Alexandre Belloni wrote: > > On 16/08/2019 10:50:49-0500, Li Yang wrote: > > On Fri, Aug 16, 2019 at 3:05 AM Alexandre Belloni > > wrote: > > > > > > On 16/08/2019 10:46:36+0800, Biwen Li wrote: > > > > Issue: > > > > - # hwclock -w > > > > hwclock:

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-16 Thread Alexandre Belloni
On 16/08/2019 10:50:49-0500, Li Yang wrote: > On Fri, Aug 16, 2019 at 3:05 AM Alexandre Belloni > wrote: > > > > On 16/08/2019 10:46:36+0800, Biwen Li wrote: > > > Issue: > > > - # hwclock -w > > > hwclock: RTC_SET_TIME: Invalid argument > > > > > > Why: > > > - Relative patch:

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-16 Thread Li Yang
On Fri, Aug 16, 2019 at 3:05 AM Alexandre Belloni wrote: > > On 16/08/2019 10:46:36+0800, Biwen Li wrote: > > Issue: > > - # hwclock -w > > hwclock: RTC_SET_TIME: Invalid argument > > > > Why: > > - Relative patch: https://lkml.org/lkml/2019/4/3/55 , this patch > > will always

Re: [v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-16 Thread Alexandre Belloni
On 16/08/2019 10:46:36+0800, Biwen Li wrote: > Issue: > - # hwclock -w > hwclock: RTC_SET_TIME: Invalid argument > > Why: > - Relative patch: https://lkml.org/lkml/2019/4/3/55 , this patch > will always check for unwritable registers, it will compare reg > with

[v2] rtc: pcf85363/pcf85263: fix error that failed to run hwclock -w

2019-08-15 Thread Biwen Li
Issue: - # hwclock -w hwclock: RTC_SET_TIME: Invalid argument Why: - Relative patch: https://lkml.org/lkml/2019/4/3/55 , this patch will always check for unwritable registers, it will compare reg with max_register in regmap_writeable. - In