1 /* SPDX-License-Identifier: GPL-2.0 */
3 /* Copyright (c) 2012-2018, The Linux Foundation. All rights reserved.
4 * Copyright (C) 2018-2024 Linaro Ltd.
9 #include <linux/types.h>
14 struct ipa_power_data;
16 /* IPA device power management function block */
17 extern const struct dev_pm_ops ipa_pm_ops;
20 * ipa_core_clock_rate() - Return the current IPA core clock rate
23 * Return: The current clock rate (in Hz), or 0.
25 u32 ipa_core_clock_rate(struct ipa *ipa);
28 * ipa_power_retention() - Control register retention on power collapse
30 * @enable: Whether retention should be enabled or disabled
32 void ipa_power_retention(struct ipa *ipa, bool enable);
35 * ipa_power_init() - Initialize IPA power management
37 * @data: Clock configuration data
39 * Return: A pointer to an ipa_power structure, or a pointer-coded error
41 struct ipa_power *ipa_power_init(struct device *dev,
42 const struct ipa_power_data *data);
45 * ipa_power_exit() - Inverse of ipa_power_init()
46 * @power: IPA power pointer
48 void ipa_power_exit(struct ipa_power *power);
50 #endif /* _IPA_POWER_H_ */