From a2f8e8fe2cad86ede91c494518b75f0dc1ef091d Mon Sep 17 00:00:00 2001 From: Jeff Johnson Date: Sun, 30 Dec 2018 18:06:58 -0800 Subject: [PATCH] qcacld-3.0: Harmonize legacy PMM and SME definitions The PMM module and message definitions are not used by the current version of the driver. However the message ID number space overlaps with the SME message IDs. In order to harmonize the code: - Remove the legacy PMM Module & Message ID definitions - Consolidate the SME Module & Message ID definitions - Update the dispatch logic to correctly indicate it is SME and not PMM messages which are being dispatched Change-Id: Idcf66633c2060e52e930addaa8cecb3faf89bc90 CRs-Fixed: 2378317 --- core/mac/inc/sir_api.h | 2 +- core/mac/inc/wni_api.h | 12 +++--------- core/mac/src/include/sir_params.h | 5 ----- core/wma/src/wlan_qct_wma_legacy.c | 4 ++-- 4 files changed, 6 insertions(+), 17 deletions(-) diff --git a/core/mac/inc/sir_api.h b/core/mac/inc/sir_api.h index e8d235f572d9..6a582f992ebd 100644 --- a/core/mac/inc/sir_api.h +++ b/core/mac/inc/sir_api.h @@ -165,7 +165,7 @@ enum { SIR_LIM_MODULE_ID, SIR_ARQ_MODULE_ID, SIR_SCH_MODULE_ID, - SIR_PMM_MODULE_ID, + SIR_SME_MODULE_ID, SIR_DBG_MODULE_ID, SIR_DPH_MODULE_ID, SIR_SYS_MODULE_ID, diff --git a/core/mac/inc/wni_api.h b/core/mac/inc/wni_api.h index 5c0eaf9a54b1..535120660a1a 100644 --- a/core/mac/inc/wni_api.h +++ b/core/mac/inc/wni_api.h @@ -32,18 +32,12 @@ #ifndef __WNI_API_H #define __WNI_API_H -#define SIR_SME_MODULE_ID 0x16 +#include "sir_api.h" -/* / Start of Sirius/Host message types */ -#define WNI_HOST_MSG_START 0x1500 +#define SIR_SME_MSG_TYPES_BEGIN (SIR_SME_MODULE_ID << 8) enum eWniMsgTypes { - /* / CFG message types */ - eWNI_CFG_MSG_TYPES_BEGIN = WNI_HOST_MSG_START, - eWNI_CFG_MSG_TYPES_END = eWNI_CFG_MSG_TYPES_BEGIN + 0xFF, - - /* / SME message types */ - eWNI_SME_MSG_TYPES_BEGIN = eWNI_CFG_MSG_TYPES_END, + eWNI_SME_MSG_TYPES_BEGIN = SIR_SME_MSG_TYPES_BEGIN, eWNI_SME_SYS_READY_IND, eWNI_SME_JOIN_REQ, eWNI_SME_JOIN_RSP, diff --git a/core/mac/src/include/sir_params.h b/core/mac/src/include/sir_params.h index 8aa2c3dc044e..6e2d50800645 100644 --- a/core/mac/src/include/sir_params.h +++ b/core/mac/src/include/sir_params.h @@ -745,11 +745,6 @@ struct sir_cfg_action_frm_tb_ppdu { #define SIR_LIM_MSG_TYPES_END (SIR_LIM_MSG_TYPES_BEGIN+0xFF) -/* PMM message types */ -#define SIR_PMM_MSG_TYPES_BEGIN (SIR_PMM_MODULE_ID << 8) -#define SIR_PMM_CHANGE_PM_MODE (SIR_PMM_MSG_TYPES_BEGIN) -#define SIR_PMM_MSG_TYPES_END (SIR_PMM_MSG_TYPES_BEGIN+0xFF) - /* ****************************************** * * * * EVENT TYPE Definitions * diff --git a/core/wma/src/wlan_qct_wma_legacy.c b/core/wma/src/wlan_qct_wma_legacy.c index d9d60a098692..10212d77e3c4 100644 --- a/core/wma/src/wlan_qct_wma_legacy.c +++ b/core/wma/src/wlan_qct_wma_legacy.c @@ -1,5 +1,5 @@ /* - * Copyright (c) 2013-2018 The Linux Foundation. All rights reserved. + * Copyright (c) 2013-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 @@ -122,7 +122,7 @@ QDF_STATUS u_mac_post_ctrl_msg(void *pSirGlobal, tSirMbMsg *pMb) status = wma_post_cfg_msg(mac, &msg); break; - case SIR_PMM_MSG_TYPES_BEGIN: /* Posts a message to the LIM MsgQ */ + case SIR_SME_MSG_TYPES_BEGIN: /* Posts a message to the LIM MsgQ */ status = sme_post_pe_message(mac, &msg); break;