linux-rtc.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Alexandre Belloni <alexandre.belloni@bootlin.com>
To: Peter Korsgaard <peter@korsgaard.com>
Cc: "Neeli, Srinivas" <srinivas.neeli@amd.com>,
	Srinivas Neeli <srinivas.neeli@xilinx.com>,
	"a.zummo@towertech.it" <a.zummo@towertech.it>,
	"robh+dt@kernel.org" <robh+dt@kernel.org>,
	"krzysztof.kozlowski+dt@linaro.org" 
	<krzysztof.kozlowski+dt@linaro.org>,
	"michal.simek@xilinx.com" <michal.simek@xilinx.com>,
	"sgoud@xilinx.com" <sgoud@xilinx.com>,
	"shubhraj@xilinx.com" <shubhraj@xilinx.com>,
	"neelisrinivas18@gmail.com" <neelisrinivas18@gmail.com>,
	"devicetree@vger.kernel.org" <devicetree@vger.kernel.org>,
	"linux-rtc@vger.kernel.org" <linux-rtc@vger.kernel.org>,
	"linux-arm-kernel@lists.infradead.org" 
	<linux-arm-kernel@lists.infradead.org>,
	"linux-kernel@vger.kernel.org" <linux-kernel@vger.kernel.org>,
	"git@xilinx.com" <git@xilinx.com>
Subject: Re: [PATCH V6 2/2] rtc: zynqmp: Add calibration set and get support
Date: Fri, 10 Jun 2022 12:40:16 +0200	[thread overview]
Message-ID: <YqMfkNwAidCpYY1E@mail.local> (raw)
In-Reply-To: <87pmjgyghw.fsf@dell.be.48ers.dk>

On 10/06/2022 12:12:11+0200, Peter Korsgaard wrote:
> >>>>> "Neeli," == Neeli, Srinivas <srinivas.neeli@amd.com> writes:
> 
> Hi,
> 
>  >> >> Where do you see that? ug1085 rev2.2 still lists:
>  >> >>
>  >> >> Programming Sequences
>  >> >> init rtc
>  >> >> 1. Write the value 0019_8231h into the calibration register, CALIB_WRITE.
>  >> >>
>  >> 
>  >> > This is a very weird value. Last time I had a look, I couldn't find an  >
>  >> explanation for it.
>  >> 
>  >> Agreed. I am not arguing that it is sensible, I just wondered where this new
>  >> value comes from?
>  >> 
>  > This information is missing in our TRM, as per the internal RTC IP
>  > design specification document, the calibration value should be crystal
>  > clock frequency minus one.
>  > For a crystal oscillator of 32.768KHz(0x8000) frequency, the calibration value will be 0x7FFF.
> 
>  > Will update TRM with the required information.
> 
> Ok, great!
> 
> Please put this change in a separate commit from the get/set logic.

I'm not sure it is worth it as it is probably being set (to the wrong
value) from your device tree anyway and the driver won't forcefully
change it in that case. The worse that can happen is that your new
boards will have the correct value.


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

      reply	other threads:[~2022-06-10 10:45 UTC|newest]

Thread overview: 8+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2022-06-09 14:08 [PATCH V6 1/2] dt-bindings: rtc: zynqmp: Add clock information Srinivas Neeli
2022-06-09 14:08 ` [PATCH V6 2/2] rtc: zynqmp: Add calibration set and get support Srinivas Neeli
2022-06-09 14:50   ` Peter Korsgaard
2022-06-09 14:53     ` Alexandre Belloni
2022-06-09 14:59       ` Peter Korsgaard
2022-06-10 10:02         ` Neeli, Srinivas
2022-06-10 10:12           ` Peter Korsgaard
2022-06-10 10:40             ` Alexandre Belloni [this message]

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=YqMfkNwAidCpYY1E@mail.local \
    --to=alexandre.belloni@bootlin.com \
    --cc=a.zummo@towertech.it \
    --cc=devicetree@vger.kernel.org \
    --cc=git@xilinx.com \
    --cc=krzysztof.kozlowski+dt@linaro.org \
    --cc=linux-arm-kernel@lists.infradead.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-rtc@vger.kernel.org \
    --cc=michal.simek@xilinx.com \
    --cc=neelisrinivas18@gmail.com \
    --cc=peter@korsgaard.com \
    --cc=robh+dt@kernel.org \
    --cc=sgoud@xilinx.com \
    --cc=shubhraj@xilinx.com \
    --cc=srinivas.neeli@amd.com \
    --cc=srinivas.neeli@xilinx.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).