qseecom: Remove the dead code from driver
For kernel clients, some of the flags are maintained which is not required as those are specific to userspace clients. So remove the code which is not required. Change-Id: If7fb51cc17e9a8c0f3c2632e9c42d84489bda4f6 Signed-off-by: Mallikarjuna Reddy Amireddy <mamire@codeaurora.org>
This commit is contained in:
parent
73c7ed27c7
commit
9a11e43908
1 changed files with 0 additions and 27 deletions
|
@ -3863,7 +3863,6 @@ int qseecom_start_app(struct qseecom_handle **handle,
|
|||
data->client.ihandle = NULL;
|
||||
|
||||
init_waitqueue_head(&data->abort_wq);
|
||||
atomic_set(&data->ioctl_count, 0);
|
||||
|
||||
data->client.ihandle = ion_alloc(qseecom.ion_clnt, size, 4096,
|
||||
ION_HEAP(ION_QSECOM_HEAP_ID), 0);
|
||||
|
@ -3995,7 +3994,6 @@ int qseecom_shutdown_app(struct qseecom_handle **handle)
|
|||
}
|
||||
data = (struct qseecom_dev_handle *) ((*handle)->dev);
|
||||
mutex_lock(&app_access_lock);
|
||||
atomic_inc(&data->ioctl_count);
|
||||
|
||||
spin_lock_irqsave(&qseecom.registered_kclient_list_lock, flags);
|
||||
list_for_each_entry(kclient, &qseecom.registered_kclient_list_head,
|
||||
|
@ -4012,25 +4010,6 @@ int qseecom_shutdown_app(struct qseecom_handle **handle)
|
|||
else
|
||||
ret = qseecom_unload_app(data, false);
|
||||
|
||||
if (qseecom.support_bus_scaling) {
|
||||
mutex_lock(&qsee_bw_mutex);
|
||||
if (data->mode != INACTIVE) {
|
||||
qseecom_unregister_bus_bandwidth_needs(data);
|
||||
if (qseecom.cumulative_mode == INACTIVE) {
|
||||
ret = __qseecom_set_msm_bus_request(INACTIVE);
|
||||
if (ret)
|
||||
pr_err("Fail to scale down bus\n");
|
||||
}
|
||||
}
|
||||
mutex_unlock(&qsee_bw_mutex);
|
||||
} else {
|
||||
if (data->fast_load_enabled == true)
|
||||
qsee_disable_clock_vote(data, CLK_SFPB);
|
||||
if (data->perf_enabled == true)
|
||||
qsee_disable_clock_vote(data, CLK_DFAB);
|
||||
}
|
||||
|
||||
atomic_dec(&data->ioctl_count);
|
||||
mutex_unlock(&app_access_lock);
|
||||
if (ret == 0) {
|
||||
kzfree(data);
|
||||
|
@ -4072,12 +4051,10 @@ int qseecom_send_command(struct qseecom_handle *handle, void *send_buf,
|
|||
return -EINVAL;
|
||||
|
||||
mutex_lock(&app_access_lock);
|
||||
atomic_inc(&data->ioctl_count);
|
||||
if (qseecom.support_bus_scaling) {
|
||||
ret = qseecom_scale_bus_bandwidth_timer(INACTIVE);
|
||||
if (ret) {
|
||||
pr_err("Failed to set bw.\n");
|
||||
atomic_dec(&data->ioctl_count);
|
||||
mutex_unlock(&app_access_lock);
|
||||
return ret;
|
||||
}
|
||||
|
@ -4095,7 +4072,6 @@ int qseecom_send_command(struct qseecom_handle *handle, void *send_buf,
|
|||
if (ret) {
|
||||
pr_err("Failed to vote for clock with err %d\n",
|
||||
ret);
|
||||
atomic_dec(&data->ioctl_count);
|
||||
mutex_unlock(&app_access_lock);
|
||||
return -EINVAL;
|
||||
}
|
||||
|
@ -4112,7 +4088,6 @@ int qseecom_send_command(struct qseecom_handle *handle, void *send_buf,
|
|||
qsee_disable_clock_vote(data, CLK_SFPB);
|
||||
}
|
||||
|
||||
atomic_dec(&data->ioctl_count);
|
||||
mutex_unlock(&app_access_lock);
|
||||
|
||||
if (ret)
|
||||
|
@ -4137,8 +4112,6 @@ int qseecom_set_bandwidth(struct qseecom_handle *handle, bool high)
|
|||
__qseecom_register_bus_bandwidth_needs(handle->dev,
|
||||
HIGH);
|
||||
mutex_unlock(&qsee_bw_mutex);
|
||||
if (ret)
|
||||
pr_err("Failed to scale bus (med) %d\n", ret);
|
||||
} else {
|
||||
ret = qseecom_perf_enable(handle->dev);
|
||||
if (ret)
|
||||
|
|
Loading…
Add table
Reference in a new issue