blob: b378f73b34d43e18ba4bac5a0520112df1be3bd8 [file] [log] [blame]
Vidyakumar Athota5d45f4c2019-03-10 22:35:07 -07001/* SPDX-License-Identifier: GPL-2.0-only */
2/*
3 * Copyright (c) 2019, The Linux Foundation. All rights reserved.
4 */
5
6#ifndef BOLERO_CLK_RSC_H
7#define BOLERO_CLK_RSC_H
8
9#include <linux/regmap.h>
10#include <dt-bindings/sound/qcom,bolero-clk-rsc.h>
11
12#if IS_ENABLED(CONFIG_SND_SOC_BOLERO)
13int bolero_clk_rsc_mgr_init(void);
14void bolero_clk_rsc_mgr_exit(void);
15void bolero_clk_rsc_fs_gen_request(struct device *dev,
16 bool enable);
17int bolero_clk_rsc_request_clock(struct device *dev,
18 int default_clk_id,
19 int clk_id_req,
20 bool enable);
21#else
22static inline void bolero_clk_rsc_fs_gen_request(struct device *dev,
23 bool enable)
24{
25}
26static inline int bolero_clk_rsc_mgr_init(void)
27{
28 return 0;
29}
30static inline void bolero_clk_rsc_mgr_exit(void)
31{
32}
33static inline int bolero_clk_rsc_request_clock(struct device *dev,
34 int default_clk_id,
35 int clk_id_req,
36 bool enable)
37{
38 return 0;
39}
40
41#endif /* CONFIG_SND_SOC_BOLERO */
42#endif /* BOLERO_CLK_RSC_H */