From: Leo Liang <ycliang@andestech.com>
To: Chanho Park <chanho61.park@samsung.com>
Cc: Rick Chen <rick@andestech.com>, Simon Glass <sjg@chromium.org>,
<u-boot@lists.denx.de>
Subject: Re: [PATCH v3 2/3] riscv: timer: add timer_get_boot_us for BOOTSTAGE
Date: Wed, 4 Oct 2023 17:24:59 +0800 [thread overview]
Message-ID: <ZR0va8xS0rcSru3B@swlinux02> (raw)
In-Reply-To: <20230906051814.1393464-3-chanho61.park@samsung.com>
On Wed, Sep 06, 2023 at 02:18:13PM +0900, Chanho Park wrote:
> timer_get_boot_us function is required to record the boot stages as
> us-based timestamp.
> To get a micro-second time from a timer tick, this converts the
> formula like below to avoid zero result of (tick / rate) part.
>
> From: time(us) = (tick / rate) * 10000000
> To : time(us) = (tick * 1000) / (rate / 1000)
>
> Signed-off-by: Chanho Park <chanho61.park@samsung.com>
> ---
> drivers/timer/riscv_timer.c | 22 ++++++++++++++++++++++
> 1 file changed, 22 insertions(+)
Reviewed-by: Leo Yu-Chi Liang <ycliang@andestech.com>
next prev parent reply other threads:[~2023-10-04 9:27 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
[not found] <CGME20230906051831epcas2p31b9a8d38140b0cde3aee89f5038edd69@epcas2p3.samsung.com>
2023-09-06 5:18 ` [PATCH v3 0/3] bootstage support for risc-v Chanho Park
2023-09-06 5:18 ` [PATCH v3 1/3] riscv: bootstage: correct bootstage_report guard Chanho Park
2023-09-06 5:18 ` [PATCH v3 2/3] riscv: timer: add timer_get_boot_us for BOOTSTAGE Chanho Park
2023-10-04 9:24 ` Leo Liang [this message]
2023-09-06 5:18 ` [PATCH v3 3/3] timer: riscv_aclint_timer: " Chanho Park
2023-09-06 17:26 ` Heinrich Schuchardt
2023-09-07 6:39 ` Chanho Park
2023-10-04 9:08 ` Leo Liang
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=ZR0va8xS0rcSru3B@swlinux02 \
--to=ycliang@andestech.com \
--cc=chanho61.park@samsung.com \
--cc=rick@andestech.com \
--cc=sjg@chromium.org \
--cc=u-boot@lists.denx.de \
/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