qseecom: Add API to set bandwidth for CE HW

Add API to allow kernel space clients to bump up
CE clks for improved performance

Change-Id: Iecd13cf4efe9b2b1415be56d3ec9e4dc040918f8
Signed-off-by: Mona Hossain <mhossain@codeaurora.org>
This commit is contained in:
Mona Hossain 2012-11-07 19:58:30 -08:00 committed by Iliyan Malchev
parent 5e5949c4f1
commit 4a226f77f3
2 changed files with 16 additions and 1 deletions

View file

@ -1579,6 +1579,21 @@ int qseecom_send_command(struct qseecom_handle *handle, void *send_buf,
}
EXPORT_SYMBOL(qseecom_send_command);
int qseecom_set_bandwidth(struct qseecom_handle *handle, bool high)
{
if ((handle == NULL) || (handle->dev == NULL)) {
pr_err("No valid kernel client\n");
return -EINVAL;
}
if (high)
return qsee_vote_for_clock(CLK_DFAB);
else {
qsee_disable_clock_vote(CLK_DFAB);
return 0;
}
}
EXPORT_SYMBOL(qseecom_set_bandwidth);
static int qseecom_send_resp(void)
{
qseecom.send_resp_flag = 1;

View file

@ -31,6 +31,6 @@ int qseecom_start_app(struct qseecom_handle **handle,
int qseecom_shutdown_app(struct qseecom_handle **handle);
int qseecom_send_command(struct qseecom_handle *handle, void *send_buf,
uint32_t sbuf_len, void *resp_buf, uint32_t rbuf_len);
int qseecom_set_bandwidth(struct qseecom_handle *handle, bool high);
#endif /* __QSEECOM_KERNEL_H_ */