blob: 09b3e50918b5482ea950add468276cb14292b454 [file] [log] [blame]
Hai Pham06d8f972023-01-26 21:06:07 +01001/* SPDX-License-Identifier: GPL-2.0 */
2/*
3 * R-Car Gen3 Clock Pulse Generator Library
4 *
5 * Copyright (C) 2015-2018 Glider bvba
6 * Copyright (C) 2019 Renesas Electronics Corp.
7 *
8 * Based on clk-rcar-gen3.c
9 *
10 * Copyright (C) 2015 Renesas Electronics Corp.
11 */
12
13#ifndef __CLK_RENESAS_RCAR_CPG_LIB_H__
14#define __CLK_RENESAS_RCAR_CPG_LIB_H__
15
16s64 rcar_clk_get_rate64_div_table(unsigned int parent, u64 parent_rate,
17 void __iomem *reg, const u32 mask,
18 const struct clk_div_table *table, char *name);
19
20int rcar_clk_set_rate64_div_table(unsigned int parent, u64 parent_rate, ulong rate,
21 void __iomem *reg, const u32 mask,
22 const struct clk_div_table *table, char *name);
23
24s64 rcar_clk_get_rate64_sdh(unsigned int parent, u64 parent_rate, void __iomem *reg);
25s64 rcar_clk_get_rate64_sd(unsigned int parent, u64 parent_rate, void __iomem *reg);
26s64 rcar_clk_get_rate64_rpc(unsigned int parent, u64 parent_rate, void __iomem *reg);
27u64 rcar_clk_get_rate64_rpcd2(unsigned int parent, u64 parent_rate);
28int rcar_clk_set_rate64_sdh(unsigned int parent, u64 parent_rate, ulong rate,
29 void __iomem *reg);
30int rcar_clk_set_rate64_sd(unsigned int parent, u64 parent_rate, ulong rate,
31 void __iomem *reg);
32
33#endif