qcacmn: Optimize schedule msg post error logging
This change will reduce the repeated logging of scheduler posts Change-Id: I26c297d2d3def55377f062a2de94f61cf09522de CRs-Fixed: 2373005
This commit is contained in:

committed by
nshrivas

parent
84da07f17e
commit
1397a33f48
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright (c) 2014-2018 The Linux Foundation. All rights reserved.
|
||||
* Copyright (c) 2014-2019 The Linux Foundation. All rights reserved.
|
||||
*
|
||||
* Permission to use, copy, modify, and/or distribute this software for
|
||||
* any purpose with or without fee is hereby granted, provided that the
|
||||
@@ -188,14 +188,16 @@ static inline QDF_STATUS scheduler_post_msg(uint32_t qid,
|
||||
* scheduler_post_msg
|
||||
* Return: QDF status
|
||||
*/
|
||||
static inline QDF_STATUS scheduler_post_message(QDF_MODULE_ID src_id,
|
||||
QDF_STATUS scheduler_post_message_debug(QDF_MODULE_ID src_id,
|
||||
QDF_MODULE_ID dest_id,
|
||||
QDF_MODULE_ID que_id,
|
||||
struct scheduler_msg *msg)
|
||||
{
|
||||
return scheduler_post_msg(scheduler_get_qid(src_id, dest_id, que_id),
|
||||
msg);
|
||||
}
|
||||
struct scheduler_msg *msg,
|
||||
int line,
|
||||
const char *func);
|
||||
|
||||
#define scheduler_post_message(src_id, dest_id, que_id, msg) \
|
||||
scheduler_post_message_debug(src_id, dest_id, que_id, msg, \
|
||||
__LINE__, __func__)
|
||||
|
||||
/**
|
||||
* scheduler_resume() - resume scheduler thread
|
||||
|
@@ -661,3 +661,22 @@ QDF_STATUS scheduler_get_queue_size(QDF_MODULE_ID qid, uint32_t *size)
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
}
|
||||
|
||||
QDF_STATUS scheduler_post_message_debug(QDF_MODULE_ID src_id,
|
||||
QDF_MODULE_ID dest_id,
|
||||
QDF_MODULE_ID que_id,
|
||||
struct scheduler_msg *msg,
|
||||
int line,
|
||||
const char *func)
|
||||
{
|
||||
QDF_STATUS status;
|
||||
|
||||
status = scheduler_post_msg(scheduler_get_qid(src_id, dest_id, que_id),
|
||||
msg);
|
||||
|
||||
if (QDF_IS_STATUS_ERROR(status))
|
||||
sched_err("couldn't post from %d to %d - called from %d, %s",
|
||||
src_id, dest_id, line, func);
|
||||
|
||||
return status;
|
||||
}
|
||||
|
@@ -989,7 +989,6 @@ ucfg_scan_start(struct scan_start_request *req)
|
||||
QDF_MODULE_ID_OS_IF, &msg);
|
||||
if (QDF_IS_STATUS_ERROR(status)) {
|
||||
wlan_objmgr_vdev_release_ref(req->vdev, WLAN_SCAN_ID);
|
||||
scm_err("failed to post to QDF_MODULE_ID_OS_IF");
|
||||
scm_scan_free_scan_request_mem(req);
|
||||
}
|
||||
|
||||
@@ -1182,10 +1181,8 @@ ucfg_scan_cancel(struct scan_cancel_request *req)
|
||||
status = scheduler_post_message(QDF_MODULE_ID_OS_IF,
|
||||
QDF_MODULE_ID_SCAN,
|
||||
QDF_MODULE_ID_OS_IF, &msg);
|
||||
if (QDF_IS_STATUS_ERROR(status)) {
|
||||
scm_err("failed to post to QDF_MODULE_ID_OS_IF");
|
||||
if (QDF_IS_STATUS_ERROR(status))
|
||||
goto vdev_put;
|
||||
}
|
||||
|
||||
return QDF_STATUS_SUCCESS;
|
||||
|
||||
@@ -1224,10 +1221,8 @@ ucfg_scan_cancel_sync(struct scan_cancel_request *req)
|
||||
|
||||
vdev = req->vdev;
|
||||
status = ucfg_scan_cancel(req);
|
||||
if (QDF_IS_STATUS_ERROR(status)) {
|
||||
scm_err("failed to post to QDF_MODULE_ID_OS_IF");
|
||||
if (QDF_IS_STATUS_ERROR(status))
|
||||
return status;
|
||||
}
|
||||
|
||||
memset(&cancel_scan_event, 0, sizeof(cancel_scan_event));
|
||||
/*
|
||||
|
Reference in New Issue
Block a user