]> git.baikalelectronics.ru Git - uboot.git/commit
clk: add clk_round_rate()
authorDario Binacchi <dariobin@libero.it>
Tue, 29 Dec 2020 23:06:31 +0000 (00:06 +0100)
committerLokesh Vutla <lokeshvutla@ti.com>
Tue, 12 Jan 2021 05:28:04 +0000 (10:58 +0530)
commit02eef9fec756b6e11b992846f729bb379afbda2b
treed586303823a6aa0aa980451e53610dc20e7e66b5
parentdc8b3f89e640e082d1346edae341f1e02830e677
clk: add clk_round_rate()

It returns the rate which will be set if you ask clk_set_rate() to set
that rate. It provides a way to query exactly what rate you'll get if
you call clk_set_rate() with that same argument.
So essentially, clk_round_rate() and clk_set_rate() are equivalent
except the former does not modify the clock hardware in any way.

Signed-off-by: Dario Binacchi <dariobin@libero.it>
Reviewed-by: Simon Glass <sjg@chromium.org>
Reviewed-by: Sean Anderson <seanga2@gmail.com>
arch/sandbox/include/asm/clk.h
drivers/clk/clk-uclass.c
drivers/clk/clk_sandbox.c
drivers/clk/clk_sandbox_test.c
include/clk-uclass.h
include/clk.h
test/dm/clk.c