Re: MTIME update frequency


Ved Shanbhogue
 

On Tue, Nov 16, 2021 at 11:31:44AM -0800, Greg Favor wrote:
On Tue, Nov 16, 2021 at 10:50 AM Jonathan Behrens <behrensj@...> wrote:

To Ved's last post, it is the timebase resolution (and not update
frequency) that determines the conversion from time to ticks.

So the question is whether there should be a fixed resolution so that
platform-compliant software can simply do a fixed absolute time to
mtime/time conversion, and conversely how much or little change to Linux
would be required to support a discoverable variable conversion?
Linux discovers the timebase from device-tree and does not assume a fixed frequency:
https://elixir.bootlin.com/linux/latest/source/arch/riscv/kernel/time.c#L14

regards
ved

Join tech-unixplatformspec@lists.riscv.org to automatically receive all group messages.