Sound Open Firmware
Loading...
Searching...
No Matches
pm_runtime.h
Go to the documentation of this file.
1/* SPDX-License-Identifier: BSD-3-Clause
2 *
3 * Copyright(c) 2024 Intel Corporation.
4 */
5
6#ifndef __SOF_LIB_PM_RUNTIME_H__
7#define __SOF_LIB_PM_RUNTIME_H__
8
9#include <rtos/sof.h>
10#include <stdint.h>
11
19
24
28static inline void pm_runtime_init(struct sof *sof)
29{
30}
31
38void pm_runtime_get(enum pm_runtime_context context, uint32_t index);
39
46static inline void pm_runtime_get_sync(enum pm_runtime_context context, uint32_t index)
47{
48}
49
50
57void pm_runtime_put(enum pm_runtime_context context, uint32_t index);
58
65static inline void pm_runtime_put_sync(enum pm_runtime_context context, uint32_t index)
66{
67}
68
75void pm_runtime_enable(enum pm_runtime_context context, uint32_t index);
76
83void pm_runtime_disable(enum pm_runtime_context context, uint32_t index);
84
93bool pm_runtime_is_active(enum pm_runtime_context context, uint32_t index);
94
95static inline void platform_pm_runtime_prepare_d0ix_en(uint32_t index)
96{
97}
98
99#if CONFIG_DSP_RESIDENCY_COUNTERS
100
106static inline void init_dsp_r_state(enum dsp_r_state)
107{
108}
109
115static inline void report_dsp_r_state(enum dsp_r_state)
116{
117}
118
124static inline enum dsp_r_state get_dsp_r_state(void)
125{
126}
127#endif
128
130
131#endif /* __SOF_LIB_PM_RUNTIME_H__ */
pm_runtime_context
Runtime power management context.
Definition pm_runtime.h:21
void pm_runtime_put(enum pm_runtime_context context, uint32_t index)
Releases power management resource (async).
static void pm_runtime_init(struct sof *sof)
Initializes runtime power management.
Definition pm_runtime.h:28
void pm_runtime_enable(enum pm_runtime_context context, uint32_t index)
Enables power management operations for the resource.
void pm_runtime_get(enum pm_runtime_context context, uint32_t index)
Retrieves power management resource (async).
void pm_runtime_disable(enum pm_runtime_context context, uint32_t index)
Disables power management operations for the resource.
static void pm_runtime_put_sync(enum pm_runtime_context context, uint32_t index)
Releases power management resource.
Definition pm_runtime.h:65
static void pm_runtime_get_sync(enum pm_runtime_context context, uint32_t index)
Retrieves power management resource.
Definition pm_runtime.h:46
bool pm_runtime_is_active(enum pm_runtime_context context, uint32_t index)
Reports state of the power managed resource.
static void platform_pm_runtime_prepare_d0ix_en(uint32_t index)
Definition pm_runtime.h:95
@ PM_RUNTIME_DSP
DSP.
Definition pm_runtime.h:22
General firmware context.
Definition sof.h:44