Last change
on this file was 679, checked in by David Azarewicz, 4 years ago |
Merge changes from Paul's uniaud32next branch.
|
File size:
856 bytes
|
Line | |
---|
1 | #ifndef __LINUX_PM_QOS_PARAMS_H
|
---|
2 | #define __LINUX_PM_QOS_PARAMS_H
|
---|
3 |
|
---|
4 | #if 0
|
---|
5 | // moved to pm_qos.h
|
---|
6 | #define PM_QOS_RESERVED 0
|
---|
7 | #define PM_QOS_CPU_DMA_LATENCY 1
|
---|
8 | #define PM_QOS_NETWORK_LATENCY 2
|
---|
9 | #define PM_QOS_NETWORK_THROUGHPUT 3
|
---|
10 |
|
---|
11 | #define PM_QOS_NUM_CLASSES 4
|
---|
12 | #define PM_QOS_DEFAULT_VALUE -1
|
---|
13 | #endif
|
---|
14 |
|
---|
15 | #include <linux/version.h>
|
---|
16 | #if LINUX_VERSION_CODE >= KERNEL_VERSION(2, 6, 19)
|
---|
17 | #include <linux/latency.h>
|
---|
18 |
|
---|
19 | static inline int pm_qos_add_requirement(int qos, char *name, s32 value)
|
---|
20 | {
|
---|
21 | set_acceptable_latency(name, value);
|
---|
22 | return 0;
|
---|
23 | }
|
---|
24 |
|
---|
25 | static inline void pm_qos_remove_requirement(int qos, char *name)
|
---|
26 | {
|
---|
27 | remove_acceptable_latency(name);
|
---|
28 | }
|
---|
29 |
|
---|
30 | #else
|
---|
31 |
|
---|
32 | static inline int pm_qos_add_requirement(int qos, char *name, s32 value)
|
---|
33 | {
|
---|
34 | return 0;
|
---|
35 | }
|
---|
36 |
|
---|
37 | static inline void pm_qos_remove_requirement(int qos, char *name)
|
---|
38 | {
|
---|
39 | }
|
---|
40 |
|
---|
41 | #endif /* >= 2.6.19 */
|
---|
42 |
|
---|
43 | #endif /* __LINUX_PM_QOS_PARAMS_H */
|
---|
Note:
See
TracBrowser
for help on using the repository browser.