Linux Audio

Check our new training course

Loading...
v5.9
 1/* SPDX-License-Identifier: GPL-2.0 */
 2/* Copyright (C) 2012-2019 ARM Limited (or its affiliates). */
 3
 4/* \file cc_pm.h
 5 */
 6
 7#ifndef __CC_POWER_MGR_H__
 8#define __CC_POWER_MGR_H__
 9
10#include "cc_driver.h"
11
12#define CC_SUSPEND_TIMEOUT 3000
13
14#if defined(CONFIG_PM)
15
16extern const struct dev_pm_ops ccree_pm;
17
 
 
 
 
18int cc_pm_get(struct device *dev);
19void cc_pm_put_suspend(struct device *dev);
20
21#else
22
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
23static inline int cc_pm_get(struct device *dev)
24{
25	return 0;
26}
27
28static inline void cc_pm_put_suspend(struct device *dev) {}
 
 
 
29
30#endif
31
32#endif /*__POWER_MGR_H__*/
v4.17
 1/* SPDX-License-Identifier: GPL-2.0 */
 2/* Copyright (C) 2012-2018 ARM Limited or its affiliates. */
 3
 4/* \file cc_pm.h
 5 */
 6
 7#ifndef __CC_POWER_MGR_H__
 8#define __CC_POWER_MGR_H__
 9
10#include "cc_driver.h"
11
12#define CC_SUSPEND_TIMEOUT 3000
13
14#if defined(CONFIG_PM)
15
16extern const struct dev_pm_ops ccree_pm;
17
18int cc_pm_init(struct cc_drvdata *drvdata);
19void cc_pm_fini(struct cc_drvdata *drvdata);
20int cc_pm_suspend(struct device *dev);
21int cc_pm_resume(struct device *dev);
22int cc_pm_get(struct device *dev);
23int cc_pm_put_suspend(struct device *dev);
24
25#else
26
27static inline int cc_pm_init(struct cc_drvdata *drvdata)
28{
29	return 0;
30}
31
32static inline void cc_pm_fini(struct cc_drvdata *drvdata) {}
33
34static inline int cc_pm_suspend(struct device *dev)
35{
36	return 0;
37}
38
39static inline int cc_pm_resume(struct device *dev)
40{
41	return 0;
42}
43
44static inline int cc_pm_get(struct device *dev)
45{
46	return 0;
47}
48
49static inline int cc_pm_put_suspend(struct device *dev)
50{
51	return 0;
52}
53
54#endif
55
56#endif /*__POWER_MGR_H__*/