diff options
author | Peter Maydell <peter.maydell@linaro.org> | 2021-02-19 14:45:36 +0000 |
---|---|---|
committer | Peter Maydell <peter.maydell@linaro.org> | 2021-03-08 17:20:01 +0000 |
commit | cd3a53b727d2f86e9db795cee69cc142332ca079 (patch) | |
tree | a3f955d06d5c007f522254e702d6c4f9659af55d /docs/devel/tracing.rst | |
parent | e4341623a3b87e7eca87d42b7b88da967cd21c49 (diff) | |
download | qemu-cd3a53b727d2f86e9db795cee69cc142332ca079.zip qemu-cd3a53b727d2f86e9db795cee69cc142332ca079.tar.gz qemu-cd3a53b727d2f86e9db795cee69cc142332ca079.tar.bz2 |
clock: Add clock_ns_to_ticks() function
Add a clock_ns_to_ticks() function which does the opposite of
clock_ticks_to_ns(): given a duration in nanoseconds, it returns the
number of clock ticks that would happen in that time. This is useful
for devices that have a free running counter register whose value can
be calculated when it is read.
Signed-off-by: Peter Maydell <peter.maydell@linaro.org>
Reviewed-by: Luc Michel <luc@lmichel.fr>
Reviewed-by: Hao Wu <wuhaotsh@google.com>
Tested-by: Philippe Mathieu-Daudé <f4bug@amsat.org>
Message-id: 20210219144617.4782-4-peter.maydell@linaro.org
Diffstat (limited to 'docs/devel/tracing.rst')
0 files changed, 0 insertions, 0 deletions