2022-06-10 11:57:19

by Srinivas Neeli

[permalink] [raw]
Subject: [PATCH V7 3/3] rtc: zynqmp: Updated calibration value

As per RTC spec default calibration value is 0x7FFF.

Signed-off-by: Srinivas Neeli <[email protected]>
---
Changes in V7:
-New patch
-TRM not updated yet, Internal design document contains 0x7FFF as
default value. TRM Will update in next release.
---
drivers/rtc/rtc-zynqmp.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/rtc/rtc-zynqmp.c b/drivers/rtc/rtc-zynqmp.c
index 39b23f88ee26..1dd389b891fe 100644
--- a/drivers/rtc/rtc-zynqmp.c
+++ b/drivers/rtc/rtc-zynqmp.c
@@ -37,7 +37,7 @@
#define RTC_OSC_EN BIT(24)
#define RTC_BATT_EN BIT(31)

-#define RTC_CALIB_DEF 0x198233
+#define RTC_CALIB_DEF 0x7FFF
#define RTC_CALIB_MASK 0x1FFFFF
#define RTC_ALRM_MASK BIT(1)
#define RTC_MSEC 1000
--
2.25.1


2022-06-10 12:24:51

by Alexandre Belloni

[permalink] [raw]
Subject: Re: [PATCH V7 3/3] rtc: zynqmp: Updated calibration value

On 10/06/2022 17:07:09+0530, Srinivas Neeli wrote:
> As per RTC spec default calibration value is 0x7FFF.
>

Having that as a second patch breaks the calculation in your previous
patch, really, this should just be a single patch.

> Signed-off-by: Srinivas Neeli <[email protected]>
> ---
> Changes in V7:
> -New patch
> -TRM not updated yet, Internal design document contains 0x7FFF as
> default value. TRM Will update in next release.
> ---
> drivers/rtc/rtc-zynqmp.c | 2 +-
> 1 file changed, 1 insertion(+), 1 deletion(-)
>
> diff --git a/drivers/rtc/rtc-zynqmp.c b/drivers/rtc/rtc-zynqmp.c
> index 39b23f88ee26..1dd389b891fe 100644
> --- a/drivers/rtc/rtc-zynqmp.c
> +++ b/drivers/rtc/rtc-zynqmp.c
> @@ -37,7 +37,7 @@
> #define RTC_OSC_EN BIT(24)
> #define RTC_BATT_EN BIT(31)
>
> -#define RTC_CALIB_DEF 0x198233
> +#define RTC_CALIB_DEF 0x7FFF
> #define RTC_CALIB_MASK 0x1FFFFF
> #define RTC_ALRM_MASK BIT(1)
> #define RTC_MSEC 1000
> --
> 2.25.1
>

--
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com

2022-06-10 15:12:17

by Srinivas Neeli

[permalink] [raw]
Subject: RE: [PATCH V7 3/3] rtc: zynqmp: Updated calibration value

[AMD Official Use Only - General]

Hi,

> -----Original Message-----
> From: Alexandre Belloni <[email protected]>
> Sent: Friday, June 10, 2022 5:34 PM
> To: Srinivas Neeli <[email protected]>
> Cc: [email protected]; [email protected];
> [email protected]; [email protected];
> [email protected]; [email protected]; Neeli, Srinivas
> <[email protected]>; [email protected];
> [email protected]; [email protected]; linux-arm-
> [email protected]; [email protected]; [email protected]
> Subject: Re: [PATCH V7 3/3] rtc: zynqmp: Updated calibration value
>
> On 10/06/2022 17:07:09+0530, Srinivas Neeli wrote:
> > As per RTC spec default calibration value is 0x7FFF.
> >
>
> Having that as a second patch breaks the calculation in your previous patch,
> really, this should just be a single patch.

Can I swap 3/3 and 2/3, Will that be fine ?.

>
> > Signed-off-by: Srinivas Neeli <[email protected]>
> > ---
> > Changes in V7:
> > -New patch
> > -TRM not updated yet, Internal design document contains 0x7FFF as
> > default value. TRM Will update in next release.
> > ---
> > drivers/rtc/rtc-zynqmp.c | 2 +-
> > 1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/drivers/rtc/rtc-zynqmp.c b/drivers/rtc/rtc-zynqmp.c index
> > 39b23f88ee26..1dd389b891fe 100644
> > --- a/drivers/rtc/rtc-zynqmp.c
> > +++ b/drivers/rtc/rtc-zynqmp.c
> > @@ -37,7 +37,7 @@
> > #define RTC_OSC_EN BIT(24)
> > #define RTC_BATT_EN BIT(31)
> >
> > -#define RTC_CALIB_DEF 0x198233
> > +#define RTC_CALIB_DEF 0x7FFF
> > #define RTC_CALIB_MASK 0x1FFFFF
> > #define RTC_ALRM_MASK BIT(1)
> > #define RTC_MSEC 1000
> > --
> > 2.25.1
> >
>
> --
> Alexandre Belloni, co-owner and COO, Bootlin
> Embedded Linux and Kernel engineering
> https://bootlin.com

2022-06-11 15:51:01

by Alexandre Belloni

[permalink] [raw]
Subject: Re: [PATCH V7 3/3] rtc: zynqmp: Updated calibration value

On 10/06/2022 15:04:31+0000, Neeli, Srinivas wrote:
> [AMD Official Use Only - General]
>
> Hi,
>
> > -----Original Message-----
> > From: Alexandre Belloni <[email protected]>
> > Sent: Friday, June 10, 2022 5:34 PM
> > To: Srinivas Neeli <[email protected]>
> > Cc: [email protected]; [email protected];
> > [email protected]; [email protected];
> > [email protected]; [email protected]; Neeli, Srinivas
> > <[email protected]>; [email protected];
> > [email protected]; [email protected]; linux-arm-
> > [email protected]; [email protected]; [email protected]
> > Subject: Re: [PATCH V7 3/3] rtc: zynqmp: Updated calibration value
> >
> > On 10/06/2022 17:07:09+0530, Srinivas Neeli wrote:
> > > As per RTC spec default calibration value is 0x7FFF.
> > >
> >
> > Having that as a second patch breaks the calculation in your previous patch,
> > really, this should just be a single patch.
>
> Can I swap 3/3 and 2/3, Will that be fine ?.

That would be better, yes

>
> >
> > > Signed-off-by: Srinivas Neeli <[email protected]>
> > > ---
> > > Changes in V7:
> > > -New patch
> > > -TRM not updated yet, Internal design document contains 0x7FFF as
> > > default value. TRM Will update in next release.
> > > ---
> > > drivers/rtc/rtc-zynqmp.c | 2 +-
> > > 1 file changed, 1 insertion(+), 1 deletion(-)
> > >
> > > diff --git a/drivers/rtc/rtc-zynqmp.c b/drivers/rtc/rtc-zynqmp.c index
> > > 39b23f88ee26..1dd389b891fe 100644
> > > --- a/drivers/rtc/rtc-zynqmp.c
> > > +++ b/drivers/rtc/rtc-zynqmp.c
> > > @@ -37,7 +37,7 @@
> > > #define RTC_OSC_EN BIT(24)
> > > #define RTC_BATT_EN BIT(31)
> > >
> > > -#define RTC_CALIB_DEF 0x198233
> > > +#define RTC_CALIB_DEF 0x7FFF
> > > #define RTC_CALIB_MASK 0x1FFFFF
> > > #define RTC_ALRM_MASK BIT(1)
> > > #define RTC_MSEC 1000
> > > --
> > > 2.25.1
> > >
> >
> > --
> > Alexandre Belloni, co-owner and COO, Bootlin
> > Embedded Linux and Kernel engineering
> > https://bootlin.com

--
Alexandre Belloni, co-owner and COO, Bootlin
Embedded Linux and Kernel engineering
https://bootlin.com