Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 13301984 authored by Isaac J. Manjarres's avatar Isaac J. Manjarres Committed by Venkata Narendra Kumar Gutta
Browse files

soc: qcom: service-notifier: Use high priority wq for PDR



Use unbound and high priority workqueue for handling
indications from PDs, and sending ACKs, quickly
during PDR.

Change-Id: I617504cf0107b05b635e77fb3e5593d68ed69dbd
Signed-off-by: default avatarIsaac J. Manjarres <isaacm@codeaurora.org>
Signed-off-by: default avatarVenkata Narendra Kumar Gutta <vnkgutta@codeaurora.org>
parent 863ea3f1
Loading
Loading
Loading
Loading
+13 −1
Original line number Diff line number Diff line
@@ -106,6 +106,7 @@ struct qmi_client_info {
static LIST_HEAD(qmi_client_list);
static DEFINE_MUTEX(qmi_list_lock);
static DEFINE_MUTEX(notif_add_lock);
static struct workqueue_struct *pdr_wq;

static struct service_notif_info *_find_service_info(const char *service_path)
{
@@ -226,7 +227,7 @@ static void root_service_service_ind_cb(struct qmi_handle *qmi,
	snprintf(qmi_data->ind_msg.service_path,
		ARRAY_SIZE(qmi_data->ind_msg.service_path), "%s",
		ind_msg.service_name);
	schedule_work(&qmi_data->ind_ack);
	queue_work(pdr_wq, &qmi_data->ind_ack);
}

static int send_notif_listener_msg_req(struct service_notif_info *service_notif,
@@ -700,3 +701,14 @@ int service_notif_unregister_notifier(void *service_notif_handle,
				&service_notif->service_notif_rcvr_list, nb);
}
EXPORT_SYMBOL(service_notif_unregister_notifier);

static int __init service_notif_init(void)
{

	pdr_wq = alloc_workqueue("pdr_wq", WQ_CPU_INTENSIVE | WQ_UNBOUND |
				 WQ_HIGHPRI, 0);
	BUG_ON(!pdr_wq);

	return 0;
}
arch_initcall(service_notif_init);