msm: kgsl: Add placeholders for KGSL power limit functions
Add placeholders for the KGSL power limit functions if CONFIG_QCOM_KGSL is not enabled in the kernel config. Change-Id: Ic0dedbad15b54cd8c3eba1b0649cb23193dbc16c Signed-off-by: Jordan Crouse <jcrouse@codeaurora.org>
This commit is contained in:
parent
25becb4433
commit
411b19b48e
1 changed files with 21 additions and 0 deletions
|
@ -3,11 +3,32 @@
|
|||
|
||||
#include <uapi/linux/msm_kgsl.h>
|
||||
|
||||
#ifdef CONFIG_QCOM_KGSL
|
||||
/* Limits mitigations APIs */
|
||||
void *kgsl_pwr_limits_add(enum kgsl_deviceid id);
|
||||
void kgsl_pwr_limits_del(void *limit);
|
||||
int kgsl_pwr_limits_set_freq(void *limit, unsigned int freq);
|
||||
void kgsl_pwr_limits_set_default(void *limit);
|
||||
unsigned int kgsl_pwr_limits_get_freq(enum kgsl_deviceid id);
|
||||
#else
|
||||
static inline void *kgsl_pwr_limits_add(enum kgsl_deviceid id)
|
||||
{
|
||||
return NULL;
|
||||
}
|
||||
|
||||
static inline void kgsl_pwr_limits_del(void *limit) { }
|
||||
|
||||
static inline int kgsl_pwr_limits_set_freq(void *limit, unsigned int freq)
|
||||
{
|
||||
return -EINVAL;
|
||||
}
|
||||
|
||||
static inline void kgsl_pwr_limits_set_default(void *limit) { }
|
||||
|
||||
static inline unsigned int kgsl_pwr_limits_get_freq(enum kgsl_deviceid id)
|
||||
{
|
||||
return 0;
|
||||
}
|
||||
#endif
|
||||
|
||||
#endif /* _MSM_KGSL_H */
|
||||
|
|
Loading…
Add table
Reference in a new issue