qcacmn: Add support for que_id in scheduler

Currently the scheduler cant differentiate between
the destination, and que to which it has to post the
message.

Add que_id, to differentiate between the destination
and que.

Change-Id: I94f81cb4b976dba4571f9cd0d6e059dc72024fcd
CRs-Fixed: 2308108
这个提交包含在:
gaurank kathpalia
2018-09-03 19:43:14 +05:30
提交者 nshrivas
父节点 3c5c017507
当前提交 302a1d9701
修改 2 个文件,包含 17 行新增9 行删除

查看文件

@@ -41,9 +41,11 @@
*/
#define SYS_MSG_COOKIE 0xFACE
#define scheduler_get_src_id(qid) ((qid) >> 16)
#define scheduler_get_dest_id(qid) ((qid) & 0xFFFF)
#define scheduler_get_qid(src, dest) ((dest) | ((src) << 16))
#define scheduler_get_src_id(qid) (((qid) >> 20) & 0x3FF)
#define scheduler_get_dest_id(qid) (((qid) >> 10) & 0x3FF)
#define scheduler_get_que_id(qid) ((qid) & 0x3FF)
#define scheduler_get_qid(src, dest, que_id) ((que_id) | ((dest) << 10) |\
((src) << 20))
typedef enum {
SYS_MSG_ID_MC_TIMER,
@@ -171,6 +173,7 @@ static inline QDF_STATUS scheduler_post_msg(uint32_t qid,
* scheduler_post_message() - post normal messages(no priority)
* @src_id: Source module of the message
* @dest_id: Destination module of the message
* @que_id: Queue to which the message has to posted.
* @msg: message pointer
*
* This function will mask the src_id, and destination id to qid of
@@ -179,9 +182,11 @@ static inline QDF_STATUS scheduler_post_msg(uint32_t qid,
*/
static inline QDF_STATUS scheduler_post_message(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), msg);
return scheduler_post_msg(scheduler_get_qid(src_id, dest_id, que_id),
msg);
}
/**