diff options
author | Frank Oltmanns <[email protected]> | 2023-08-07 14:43:39 +0200 |
---|---|---|
committer | Chen-Yu Tsai <[email protected]> | 2023-08-09 23:33:58 +0800 |
commit | c0380d14745194906c378d2494fc494239e16a85 (patch) | |
tree | b4fba792bf372a2e8bcbbc6dcc71a518cdd70f58 /lib/test_fortify/write_overflow-strncpy-src.c | |
parent | e373315d8ff839543132d2a0dcea546fda8b5048 (diff) |
clk: sunxi-ng: nm: Support finding closest rate
Use the helper function ccu_is_better_rate() to determine the rate that
is closest to the requested rate, thereby supporting rates that are
higher than the requested rate if the clock uses the
CCU_FEATURE_CLOSEST_RATE.
Add the macro SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK_MIN_MAX_CLOSEST which
sets CCU_FEATURE_CLOSEST_RATE.
To avoid code duplication, add the macros
SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK_MIN_MAX_FEAT that allows selecting
arbitrary features and use it in the original
SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK_MIN_MAX as well as the newly introduced
SUNXI_CCU_NM_WITH_FRAC_GATE_LOCK_MIN_MAX_CLOSEST macros.
Acked-by: Maxime Ripard <[email protected]>
Reviewed-by: Jernej Skrabec <[email protected]>
Signed-off-by: Frank Oltmanns <[email protected]>
Link: https://lore.kernel.org/r/[email protected]
Signed-off-by: Chen-Yu Tsai <[email protected]>
Diffstat (limited to 'lib/test_fortify/write_overflow-strncpy-src.c')
0 files changed, 0 insertions, 0 deletions