qcacld-3.0: Replace typedef tSirSmeHOFailureInd

The Linux Coding Style enumerates a few special cases where typedefs
are useful, but stresses "NEVER EVER use a typedef unless you can
clearly match one of those rules." The tSirSmeHOFailureInd typedef
does not meet any of those criteria, so replace it (and the "tp"
variant) with a reference to the underlying struct.

Further note the Linux Coding Style frowns upon mixed-case names and
so-called Hungarian notation, so in conjunction rename the underlying
struct to be in compliance.

Change-Id: I313e1155aa463bc55ae2467539755fd75cf8a8eb
CRs-Fixed: 2399109
This commit is contained in:
Jeff Johnson 2019-02-08 19:59:17 -08:00 committed by nshrivas
parent 17ba1d345f
commit 10cde6968b
3 changed files with 11 additions and 10 deletions

View File

@ -3139,9 +3139,9 @@ struct roam_offload_synch_ind {
};
#ifdef WLAN_FEATURE_ROAM_OFFLOAD
typedef struct sSirSmeHOFailureInd {
uint8_t sessionId;
} tSirSmeHOFailureInd, *tpSirSmeHOFailureInd;
struct handoff_failure_ind {
uint8_t vdev_id;
};
struct roam_offload_synch_fail {
uint8_t session_id;

View File

@ -19983,16 +19983,17 @@ void csr_roaming_report_diag_event(struct mac_context *mac_ctx,
*/
void csr_process_ho_fail_ind(struct mac_context *mac_ctx, void *pMsgBuf)
{
tSirSmeHOFailureInd *pSmeHOFailInd = (tSirSmeHOFailureInd *) pMsgBuf;
struct handoff_failure_ind *pSmeHOFailInd = pMsgBuf;
uint32_t sessionId;
if (pSmeHOFailInd)
sessionId = pSmeHOFailInd->sessionId;
else {
if (!pSmeHOFailInd) {
QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR,
"LFR3: Hand-Off Failure Ind is NULL");
return;
}
sessionId = pSmeHOFailInd->vdev_id;
/* Roaming is supported only on Infra STA Mode. */
if (!csr_roam_is_sta_mode(mac_ctx, sessionId)) {
QDF_TRACE(QDF_MODULE_ID_SME, QDF_TRACE_LEVEL_ERROR,

View File

@ -3022,15 +3022,15 @@ int wma_rssi_breached_event_handler(void *handle,
*/
static void wma_roam_ho_fail_handler(tp_wma_handle wma, uint32_t vdev_id)
{
tSirSmeHOFailureInd *ho_failure_ind;
struct handoff_failure_ind *ho_failure_ind;
struct scheduler_msg sme_msg = { 0 };
QDF_STATUS qdf_status;
ho_failure_ind = qdf_mem_malloc(sizeof(tSirSmeHOFailureInd));
ho_failure_ind = qdf_mem_malloc(sizeof(*ho_failure_ind));
if (!ho_failure_ind)
return;
ho_failure_ind->sessionId = vdev_id;
ho_failure_ind->vdev_id = vdev_id;
sme_msg.type = eWNI_SME_HO_FAIL_IND;
sme_msg.bodyptr = ho_failure_ind;
sme_msg.bodyval = 0;