qcacld-3.0: Replace typedef tSirRoamOffloadScanReq

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 tSirRoamOffloadScanReq 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: I3e7d5bd70618d132cc028b978583e55c729a2c21
CRs-Fixed: 2396066
This commit is contained in:
Jeff Johnson
2019-02-06 22:22:04 -08:00
committed by nshrivas
parent 562ccad1e9
commit e6da4b054b
10 changed files with 99 additions and 90 deletions

View File

@@ -2264,7 +2264,7 @@ struct mawc_params {
uint8_t mawc_roam_rssi_low_adjust; uint8_t mawc_roam_rssi_low_adjust;
}; };
typedef struct sSirRoamOffloadScanReq { struct roam_offload_scan_req {
uint16_t message_type; uint16_t message_type;
uint16_t length; uint16_t length;
bool RoamScanOffloadEnabled; bool RoamScanOffloadEnabled;
@@ -2345,7 +2345,7 @@ typedef struct sSirRoamOffloadScanReq {
/* bss load triggered roam related params */ /* bss load triggered roam related params */
bool bss_load_trig_enabled; bool bss_load_trig_enabled;
struct wmi_bss_load_config bss_load_config; struct wmi_bss_load_config bss_load_config;
} tSirRoamOffloadScanReq, *tpSirRoamOffloadScanReq; };
typedef struct sSirRoamOffloadScanRsp { typedef struct sSirRoamOffloadScanRsp {
uint8_t sessionId; uint8_t sessionId;

View File

@@ -209,7 +209,7 @@ bool lim_verify_fils_params_assoc_rsp(struct mac_context *mac_ctx,
* Return: None * Return: None
*/ */
void lim_update_fils_rik(struct pe_session *pe_session, void lim_update_fils_rik(struct pe_session *pe_session,
tSirRoamOffloadScanReq *req_buffer); struct roam_offload_scan_req *req_buffer);
#else #else
static inline bool lim_process_fils_auth_frame2(struct mac_context *mac_ctx, static inline bool lim_process_fils_auth_frame2(struct mac_context *mac_ctx,
struct pe_session *pe_session, tSirMacAuthFrameBody *rx_auth_frm_body) struct pe_session *pe_session, tSirMacAuthFrameBody *rx_auth_frm_body)
@@ -279,6 +279,6 @@ static inline bool lim_verify_fils_params_assoc_rsp(struct mac_context *mac_ctx,
} }
static inline void lim_update_fils_rik(struct pe_session *pe_session, static inline void lim_update_fils_rik(struct pe_session *pe_session,
tSirRoamOffloadScanReq *req_buffer) struct roam_offload_scan_req *req_buffer)
{ } { }
#endif #endif

View File

@@ -1804,7 +1804,7 @@ QDF_STATUS aead_decrypt_assoc_rsp(struct mac_context *mac_ctx,
} }
void lim_update_fils_rik(struct pe_session *pe_session, void lim_update_fils_rik(struct pe_session *pe_session,
tSirRoamOffloadScanReq *req_buffer) struct roam_offload_scan_req *req_buffer)
{ {
struct pe_fils_session *pe_fils_info = pe_session->fils_info; struct pe_fils_session *pe_fils_info = pe_session->fils_info;
struct roam_fils_params *roam_fils_params = struct roam_fils_params *roam_fils_params =

View File

@@ -3716,11 +3716,11 @@ static void __lim_process_roam_scan_offload_req(struct mac_context *mac_ctx,
struct pe_session *pe_session; struct pe_session *pe_session;
struct scheduler_msg wma_msg = {0}; struct scheduler_msg wma_msg = {0};
QDF_STATUS status; QDF_STATUS status;
tSirRoamOffloadScanReq *req_buffer; struct roam_offload_scan_req *req_buffer;
uint16_t local_ie_len; uint16_t local_ie_len;
uint8_t *local_ie_buf; uint8_t *local_ie_buf;
req_buffer = (tSirRoamOffloadScanReq *)msg_buf; req_buffer = (struct roam_offload_scan_req *)msg_buf;
pe_session = pe_find_session_by_sme_session_id(mac_ctx, pe_session = pe_find_session_by_sme_session_id(mac_ctx,
req_buffer->sessionId); req_buffer->sessionId);

View File

@@ -6221,7 +6221,7 @@ QDF_STATUS sme_stop_roaming(mac_handle_t mac_handle, uint8_t session_id,
{ {
struct scheduler_msg wma_msg = {0}; struct scheduler_msg wma_msg = {0};
QDF_STATUS status; QDF_STATUS status;
tSirRoamOffloadScanReq *req; struct roam_offload_scan_req *req;
struct mac_context *mac_ctx = MAC_CONTEXT(mac_handle); struct mac_context *mac_ctx = MAC_CONTEXT(mac_handle);
tpCsrNeighborRoamControlInfo roam_info; tpCsrNeighborRoamControlInfo roam_info;
struct csr_roam_session *session; struct csr_roam_session *session;

View File

@@ -2019,7 +2019,7 @@ static void
csr_fetch_ch_lst_from_received_list(struct mac_context *mac_ctx, csr_fetch_ch_lst_from_received_list(struct mac_context *mac_ctx,
tpCsrNeighborRoamControlInfo roam_info, tpCsrNeighborRoamControlInfo roam_info,
tpCsrChannelInfo curr_ch_lst_info, tpCsrChannelInfo curr_ch_lst_info,
tSirRoamOffloadScanReq *req_buf) struct roam_offload_scan_req *req_buf)
{ {
uint8_t i = 0; uint8_t i = 0;
uint8_t num_channels = 0; uint8_t num_channels = 0;
@@ -17078,7 +17078,7 @@ QDF_STATUS csr_roam_set_key_mgmt_offload(struct mac_context *mac_ctx,
*/ */
#ifdef FEATURE_WLAN_ESE #ifdef FEATURE_WLAN_ESE
static static
void csr_update_roam_scan_ese_params(tSirRoamOffloadScanReq *req_buf, void csr_update_roam_scan_ese_params(struct roam_offload_scan_req *req_buf,
struct csr_roam_session *session) struct csr_roam_session *session)
{ {
if (csr_is_auth_type_ese(req_buf->ConnectedNetwork.authentication)) { if (csr_is_auth_type_ese(req_buf->ConnectedNetwork.authentication)) {
@@ -17094,7 +17094,7 @@ void csr_update_roam_scan_ese_params(tSirRoamOffloadScanReq *req_buf,
} }
#else #else
static inline static inline
void csr_update_roam_scan_ese_params(tSirRoamOffloadScanReq *req_buf, void csr_update_roam_scan_ese_params(struct roam_offload_scan_req *req_buf,
struct csr_roam_session *session) struct csr_roam_session *session)
{ {
} }
@@ -17111,7 +17111,7 @@ void csr_update_roam_scan_ese_params(tSirRoamOffloadScanReq *req_buf,
*/ */
static void static void
csr_update_roam_scan_offload_request(struct mac_context *mac_ctx, csr_update_roam_scan_offload_request(struct mac_context *mac_ctx,
tSirRoamOffloadScanReq *req_buf, struct roam_offload_scan_req *req_buf,
struct csr_roam_session *session) struct csr_roam_session *session)
{ {
qdf_mem_copy(req_buf->PSK_PMK, session->psk_pmk, qdf_mem_copy(req_buf->PSK_PMK, session->psk_pmk,
@@ -17192,7 +17192,7 @@ csr_check_band_channel_match(enum band_info band, uint8_t channel)
static QDF_STATUS static QDF_STATUS
csr_fetch_ch_lst_from_ini(struct mac_context *mac_ctx, csr_fetch_ch_lst_from_ini(struct mac_context *mac_ctx,
tpCsrNeighborRoamControlInfo roam_info, tpCsrNeighborRoamControlInfo roam_info,
tSirRoamOffloadScanReq *req_buf) struct roam_offload_scan_req *req_buf)
{ {
enum band_info band; enum band_info band;
uint8_t i = 0; uint8_t i = 0;
@@ -17286,7 +17286,7 @@ static void
csr_fetch_ch_lst_from_occupied_lst(struct mac_context *mac_ctx, csr_fetch_ch_lst_from_occupied_lst(struct mac_context *mac_ctx,
uint8_t session_id, uint8_t session_id,
uint8_t reason, uint8_t reason,
tSirRoamOffloadScanReq *req_buf, struct roam_offload_scan_req *req_buf,
tpCsrNeighborRoamControlInfo roam_info) tpCsrNeighborRoamControlInfo roam_info)
{ {
uint8_t i = 0; uint8_t i = 0;
@@ -17369,7 +17369,7 @@ csr_fetch_ch_lst_from_occupied_lst(struct mac_context *mac_ctx,
*/ */
static QDF_STATUS static QDF_STATUS
csr_fetch_valid_ch_lst(struct mac_context *mac_ctx, csr_fetch_valid_ch_lst(struct mac_context *mac_ctx,
tSirRoamOffloadScanReq *req_buf, struct roam_offload_scan_req *req_buf,
uint8_t session_id) uint8_t session_id)
{ {
QDF_STATUS status; QDF_STATUS status;
@@ -17475,7 +17475,7 @@ csr_fetch_valid_ch_lst(struct mac_context *mac_ctx,
* *
* Return: roam offload scan request packet buffer * Return: roam offload scan request packet buffer
*/ */
static tSirRoamOffloadScanReq * static struct roam_offload_scan_req *
csr_create_roam_scan_offload_request(struct mac_context *mac_ctx, csr_create_roam_scan_offload_request(struct mac_context *mac_ctx,
uint8_t command, uint8_t command,
uint8_t session_id, uint8_t session_id,
@@ -17487,7 +17487,7 @@ csr_create_roam_scan_offload_request(struct mac_context *mac_ctx,
uint8_t i, j, dot11_mode; uint8_t i, j, dot11_mode;
bool ese_neighbor_list_recvd = false; bool ese_neighbor_list_recvd = false;
uint8_t ch_cache_str[128] = { 0 }; uint8_t ch_cache_str[128] = { 0 };
tSirRoamOffloadScanReq *req_buf = NULL; struct roam_offload_scan_req *req_buf = NULL;
tpCsrChannelInfo curr_ch_lst_info = tpCsrChannelInfo curr_ch_lst_info =
&roam_info->roamChannelInfo.currentChannelListInfo; &roam_info->roamChannelInfo.currentChannelListInfo;
#ifdef FEATURE_WLAN_ESE #ifdef FEATURE_WLAN_ESE
@@ -17501,7 +17501,7 @@ csr_create_roam_scan_offload_request(struct mac_context *mac_ctx,
|| (roam_info->isESEAssoc == false); || (roam_info->isESEAssoc == false);
#endif /* FEATURE_WLAN_ESE */ #endif /* FEATURE_WLAN_ESE */
req_buf = qdf_mem_malloc(sizeof(tSirRoamOffloadScanReq)); req_buf = qdf_mem_malloc(sizeof(struct roam_offload_scan_req));
if (!req_buf) if (!req_buf)
return NULL; return NULL;
@@ -17759,10 +17759,11 @@ csr_create_roam_scan_offload_request(struct mac_context *mac_ctx,
* *
* Return: none * Return: none
*/ */
static void csr_update_11k_offload_params(struct mac_context *mac_ctx, static void
struct csr_roam_session *session, csr_update_11k_offload_params(struct mac_context *mac_ctx,
tSirRoamOffloadScanReq *req_buffer, struct csr_roam_session *session,
bool enabled) struct roam_offload_scan_req *req_buffer,
bool enabled)
{ {
struct wmi_11k_offload_params *params = &req_buffer->offload_11k_params; struct wmi_11k_offload_params *params = &req_buffer->offload_11k_params;
struct csr_config *csr_config = &mac_ctx->roam.configParam; struct csr_config *csr_config = &mac_ctx->roam.configParam;
@@ -17906,8 +17907,8 @@ QDF_STATUS csr_invoke_neighbor_report_request(uint8_t session_id,
* *
* Return: None * Return: None
*/ */
static void check_allowed_ssid_list(tSirRoamOffloadScanReq *req_buffer, static void check_allowed_ssid_list(struct roam_offload_scan_req *req_buffer,
struct roam_ext_params *roam_params) struct roam_ext_params *roam_params)
{ {
int i = 0; int i = 0;
bool match = false; bool match = false;
@@ -18074,13 +18075,14 @@ static bool csr_is_RSO_cmd_allowed(struct mac_context *mac_ctx,
* csr_roam_send_rso_cmd() - API to send RSO command to PE * csr_roam_send_rso_cmd() - API to send RSO command to PE
* @mac_ctx: Pointer to global MAC structure * @mac_ctx: Pointer to global MAC structure
* @session_id: Session ID * @session_id: Session ID
* @request_buf: Pointer to tSirRoamOffloadScanReq * @request_buf: Pointer to struct roam_offload_scan_req
* *
* Return: QDF_STATUS * Return: QDF_STATUS
*/ */
static QDF_STATUS csr_roam_send_rso_cmd(struct mac_context *mac_ctx, static QDF_STATUS
uint8_t session_id, csr_roam_send_rso_cmd(struct mac_context *mac_ctx,
tSirRoamOffloadScanReq *request_buf) uint8_t session_id,
struct roam_offload_scan_req *request_buf)
{ {
QDF_STATUS status; QDF_STATUS status;
@@ -18106,8 +18108,9 @@ static QDF_STATUS csr_roam_send_rso_cmd(struct mac_context *mac_ctx,
* Return: None * Return: None
*/ */
static void csr_append_assoc_ies(struct mac_context *mac_ctx, static void csr_append_assoc_ies(struct mac_context *mac_ctx,
tSirRoamOffloadScanReq *req_buf, uint8_t ie_id, struct roam_offload_scan_req *req_buf,
uint8_t ie_len, uint8_t *ie_data) uint8_t ie_id, uint8_t ie_len,
uint8_t *ie_data)
{ {
tSirAddie *assoc_ie = &req_buf->assoc_ie; tSirAddie *assoc_ie = &req_buf->assoc_ie;
@@ -18135,8 +18138,9 @@ static void csr_append_assoc_ies(struct mac_context *mac_ctx,
* Return: None * Return: None
*/ */
static void ese_populate_addtional_ies(struct mac_context *mac_ctx, static void ese_populate_addtional_ies(struct mac_context *mac_ctx,
struct csr_roam_session *session, struct csr_roam_session *session,
tSirRoamOffloadScanReq *req_buf) { struct roam_offload_scan_req *req_buf)
{
uint8_t tspec_ie_hdr[SIR_MAC_OUI_WME_HDR_MIN] uint8_t tspec_ie_hdr[SIR_MAC_OUI_WME_HDR_MIN]
= { 0x00, 0x50, 0xf2, 0x02, 0x02, 0x01 }; = { 0x00, 0x50, 0xf2, 0x02, 0x02, 0x01 };
@@ -18166,9 +18170,10 @@ static void ese_populate_addtional_ies(struct mac_context *mac_ctx,
} }
#else #else
static inline void ese_populate_addtional_ies( static void ese_populate_addtional_ies(struct mac_context *mac_ctx,
struct mac_context *mac_ctx, struct csr_roam_session *session,
struct csr_roam_session *session, tSirRoamOffloadScanReq *req_buf) { struct roam_offload_scan_req *req_buf)
{
} }
#endif #endif
/** /**
@@ -18181,7 +18186,7 @@ static inline void ese_populate_addtional_ies(
*/ */
static void csr_update_driver_assoc_ies(struct mac_context *mac_ctx, static void csr_update_driver_assoc_ies(struct mac_context *mac_ctx,
struct csr_roam_session *session, struct csr_roam_session *session,
tSirRoamOffloadScanReq *req_buf) struct roam_offload_scan_req *req_buf)
{ {
bool power_caps_populated = false; bool power_caps_populated = false;
uint32_t csr_11henable; uint32_t csr_11henable;
@@ -18425,7 +18430,7 @@ static uint32_t copy_all_before_char(char *str, uint32_t str_len,
*/ */
static void csr_update_fils_params_rso(struct mac_context *mac, static void csr_update_fils_params_rso(struct mac_context *mac,
struct csr_roam_session *session, struct csr_roam_session *session,
tSirRoamOffloadScanReq *req_buffer) struct roam_offload_scan_req *req_buffer)
{ {
struct roam_fils_params *roam_fils_params; struct roam_fils_params *roam_fils_params;
struct cds_fils_connection_info *fils_info; struct cds_fils_connection_info *fils_info;
@@ -18482,7 +18487,7 @@ static void csr_update_fils_params_rso(struct mac_context *mac,
#else #else
static inline void csr_update_fils_params_rso(struct mac_context *mac, static inline void csr_update_fils_params_rso(struct mac_context *mac,
struct csr_roam_session *session, struct csr_roam_session *session,
tSirRoamOffloadScanReq *req_buffer) struct roam_offload_scan_req *req_buffer)
{} {}
#endif #endif
@@ -18494,7 +18499,7 @@ static inline void csr_update_fils_params_rso(struct mac_context *mac,
* Return: None * Return: None
*/ */
static void csr_update_score_params(struct mac_context *mac_ctx, static void csr_update_score_params(struct mac_context *mac_ctx,
tSirRoamOffloadScanReq *req_buffer) struct roam_offload_scan_req *req_buffer)
{ {
struct scoring_param *req_score_params; struct scoring_param *req_score_params;
struct rssi_scoring *req_rssi_score; struct rssi_scoring *req_rssi_score;
@@ -18612,7 +18617,7 @@ csr_roam_offload_scan(struct mac_context *mac_ctx, uint8_t session_id,
uint8_t command, uint8_t reason) uint8_t command, uint8_t reason)
{ {
uint8_t *state = NULL; uint8_t *state = NULL;
tSirRoamOffloadScanReq *req_buf; struct roam_offload_scan_req *req_buf;
QDF_STATUS status = QDF_STATUS_SUCCESS; QDF_STATUS status = QDF_STATUS_SUCCESS;
struct csr_roam_session *session = CSR_GET_SESSION(mac_ctx, session_id); struct csr_roam_session *session = CSR_GET_SESSION(mac_ctx, session_id);
tpCsrNeighborRoamControlInfo roam_info = tpCsrNeighborRoamControlInfo roam_info =

View File

@@ -2340,7 +2340,7 @@ void wma_vdev_clear_pause_bit(uint8_t vdev_id, wmi_tx_pause_type bit_pos)
* Return: QDF status * Return: QDF status
*/ */
QDF_STATUS wma_process_roaming_config(tp_wma_handle wma_handle, QDF_STATUS wma_process_roaming_config(tp_wma_handle wma_handle,
tSirRoamOffloadScanReq *roam_req); struct roam_offload_scan_req *roam_req);
#ifdef WMI_INTERFACE_EVENT_LOGGING #ifdef WMI_INTERFACE_EVENT_LOGGING
static inline void wma_print_wmi_cmd_log(uint32_t count, static inline void wma_print_wmi_cmd_log(uint32_t count,

View File

@@ -236,13 +236,13 @@ QDF_STATUS wma_update_channel_list(WMA_HANDLE handle,
QDF_STATUS wma_roam_scan_fill_self_caps(tp_wma_handle wma_handle, QDF_STATUS wma_roam_scan_fill_self_caps(tp_wma_handle wma_handle,
roam_offload_param * roam_offload_param *
roam_offload_params, roam_offload_params,
tSirRoamOffloadScanReq *roam_req); struct roam_offload_scan_req *roam_req);
#endif #endif
QDF_STATUS wma_roam_scan_offload_mode(tp_wma_handle wma_handle, QDF_STATUS wma_roam_scan_offload_mode(tp_wma_handle wma_handle,
wmi_start_scan_cmd_fixed_param * wmi_start_scan_cmd_fixed_param *
scan_cmd_fp, scan_cmd_fp,
tSirRoamOffloadScanReq *roam_req, struct roam_offload_scan_req *roam_req,
uint32_t mode, uint32_t vdev_id); uint32_t mode, uint32_t vdev_id);
/** /**
@@ -256,10 +256,20 @@ QDF_STATUS wma_roam_scan_offload_mode(tp_wma_handle wma_handle,
* Return: QDF status * Return: QDF status
*/ */
QDF_STATUS wma_roam_scan_mawc_params(tp_wma_handle wma_handle, QDF_STATUS wma_roam_scan_mawc_params(tp_wma_handle wma_handle,
tSirRoamOffloadScanReq *roam_req); struct roam_offload_scan_req *roam_req);
QDF_STATUS wma_roam_scan_offload_rssi_thresh(tp_wma_handle wma_handle, /**
tSirRoamOffloadScanReq *roam_req); * wma_roam_scan_offload_rssi_threshold() - set scan offload rssi threashold
* @wma_handle: wma handle
* @roam_req: Roaming request buffer
*
* Send WMI_ROAM_SCAN_RSSI_THRESHOLD TLV to firmware
*
* Return: QDF status
*/
QDF_STATUS
wma_roam_scan_offload_rssi_thresh(tp_wma_handle wma_handle,
struct roam_offload_scan_req *roam_req);
QDF_STATUS wma_roam_scan_offload_scan_period(tp_wma_handle wma_handle, QDF_STATUS wma_roam_scan_offload_scan_period(tp_wma_handle wma_handle,
uint32_t scan_period, uint32_t scan_period,
@@ -284,7 +294,7 @@ A_UINT32 e_csr_encryption_type_to_rsn_cipherset(eCsrEncryptionType encr);
void wma_roam_scan_fill_scan_params(tp_wma_handle wma_handle, void wma_roam_scan_fill_scan_params(tp_wma_handle wma_handle,
struct mac_context *mac, struct mac_context *mac,
tSirRoamOffloadScanReq *roam_req, struct roam_offload_scan_req *roam_req,
wmi_start_scan_cmd_fixed_param * wmi_start_scan_cmd_fixed_param *
scan_params); scan_params);
@@ -516,11 +526,6 @@ static inline bool wma_is_roam_synch_in_progress(tp_wma_handle wma,
{ {
return false; return false;
} }
static inline uint32_t wma_roam_scan_get_cckm_mode(
struct sSirRoamOffloadScanReq *roam_req, uint32_t auth_mode)
{
return WMI_AUTH_CCKM;
}
#endif #endif
/* /*

View File

@@ -8486,11 +8486,7 @@ static QDF_STATUS wma_mc_process_msg(struct scheduler_msg *msg)
qdf_mem_free(msg->bodyptr); qdf_mem_free(msg->bodyptr);
break; break;
case WMA_ROAM_SCAN_OFFLOAD_REQ: case WMA_ROAM_SCAN_OFFLOAD_REQ:
/* wma_process_roaming_config(wma_handle, msg->bodyptr);
* Main entry point or roaming directives from CSR.
*/
wma_process_roaming_config(wma_handle,
(tSirRoamOffloadScanReq *) msg->bodyptr);
break; break;
case WMA_RATE_UPDATE_IND: case WMA_RATE_UPDATE_IND:

View File

@@ -194,7 +194,7 @@ QDF_STATUS wma_update_channel_list(WMA_HANDLE handle,
} }
QDF_STATUS wma_roam_scan_mawc_params(tp_wma_handle wma_handle, QDF_STATUS wma_roam_scan_mawc_params(tp_wma_handle wma_handle,
tSirRoamOffloadScanReq *roam_req) struct roam_offload_scan_req *roam_req)
{ {
struct wmi_mawc_roam_params *params; struct wmi_mawc_roam_params *params;
QDF_STATUS status; QDF_STATUS status;
@@ -241,7 +241,7 @@ QDF_STATUS wma_roam_scan_mawc_params(tp_wma_handle wma_handle,
*/ */
static void wma_roam_scan_fill_fils_params(tp_wma_handle wma_handle, static void wma_roam_scan_fill_fils_params(tp_wma_handle wma_handle,
struct roam_offload_scan_params struct roam_offload_scan_params
*params, tSirRoamOffloadScanReq *params, struct roam_offload_scan_req
*roam_req) *roam_req)
{ {
struct roam_fils_params *dst_fils_params, *src_fils_params; struct roam_fils_params *dst_fils_params, *src_fils_params;
@@ -277,7 +277,7 @@ static void wma_roam_scan_fill_fils_params(tp_wma_handle wma_handle,
static inline void wma_roam_scan_fill_fils_params( static inline void wma_roam_scan_fill_fils_params(
tp_wma_handle wma_handle, tp_wma_handle wma_handle,
struct roam_offload_scan_params *params, struct roam_offload_scan_params *params,
tSirRoamOffloadScanReq *roam_req) struct roam_offload_scan_req *roam_req)
{ } { }
#endif #endif
@@ -297,7 +297,7 @@ static inline void wma_roam_scan_fill_fils_params(
static void wma_roam_scan_offload_set_params( static void wma_roam_scan_offload_set_params(
tp_wma_handle wma_handle, tp_wma_handle wma_handle,
struct roam_offload_scan_params *params, struct roam_offload_scan_params *params,
tSirRoamOffloadScanReq *roam_req) struct roam_offload_scan_req *roam_req)
{ {
params->auth_mode = WMI_AUTH_NONE; params->auth_mode = WMI_AUTH_NONE;
if (!roam_req) if (!roam_req)
@@ -346,7 +346,7 @@ static void wma_roam_scan_offload_set_params(
static void wma_roam_scan_offload_set_params( static void wma_roam_scan_offload_set_params(
tp_wma_handle wma_handle, tp_wma_handle wma_handle,
struct roam_offload_scan_params *params, struct roam_offload_scan_params *params,
tSirRoamOffloadScanReq *roam_req) struct roam_offload_scan_req *roam_req)
{} {}
#endif #endif
@@ -366,7 +366,7 @@ static void wma_roam_scan_offload_set_params(
QDF_STATUS wma_roam_scan_offload_mode(tp_wma_handle wma_handle, QDF_STATUS wma_roam_scan_offload_mode(tp_wma_handle wma_handle,
wmi_start_scan_cmd_fixed_param * wmi_start_scan_cmd_fixed_param *
scan_cmd_fp, scan_cmd_fp,
tSirRoamOffloadScanReq *roam_req, struct roam_offload_scan_req *roam_req,
uint32_t mode, uint32_t vdev_id) uint32_t mode, uint32_t vdev_id)
{ {
QDF_STATUS status = QDF_STATUS_SUCCESS; QDF_STATUS status = QDF_STATUS_SUCCESS;
@@ -419,17 +419,9 @@ QDF_STATUS wma_roam_scan_offload_mode(tp_wma_handle wma_handle,
return status; return status;
} }
/** QDF_STATUS
* wma_roam_scan_offload_rssi_threshold() - set scan offload rssi threashold wma_roam_scan_offload_rssi_thresh(tp_wma_handle wma_handle,
* @wma_handle: wma handle struct roam_offload_scan_req *roam_req)
* @roam_req: Roaming request buffer
*
* Send WMI_ROAM_SCAN_RSSI_THRESHOLD TLV to firmware
*
* Return: QDF status
*/
QDF_STATUS wma_roam_scan_offload_rssi_thresh(tp_wma_handle wma_handle,
tSirRoamOffloadScanReq *roam_req)
{ {
struct roam_offload_scan_rssi_params params = {0}; struct roam_offload_scan_rssi_params params = {0};
QDF_STATUS status = QDF_STATUS_SUCCESS; QDF_STATUS status = QDF_STATUS_SUCCESS;
@@ -835,8 +827,9 @@ A_UINT32 e_csr_encryption_type_to_rsn_cipherset(eCsrEncryptionType encr)
* Return: if LFR2.0, then return WMI_AUTH_CCKM for backward compatibility * Return: if LFR2.0, then return WMI_AUTH_CCKM for backward compatibility
* if LFR3.0 then return the appropriate auth type * if LFR3.0 then return the appropriate auth type
*/ */
static uint32_t wma_roam_scan_get_cckm_mode(tSirRoamOffloadScanReq *roam_req, static
uint32_t auth_mode) uint32_t wma_roam_scan_get_cckm_mode(struct roam_offload_scan_req *roam_req,
uint32_t auth_mode)
{ {
if (roam_req->roam_offload_enabled) if (roam_req->roam_offload_enabled)
return auth_mode; return auth_mode;
@@ -844,6 +837,13 @@ static uint32_t wma_roam_scan_get_cckm_mode(tSirRoamOffloadScanReq *roam_req,
return WMI_AUTH_CCKM; return WMI_AUTH_CCKM;
} }
#else
static
uint32_t wma_roam_scan_get_cckm_mode(struct roam_offload_scan_req *roam_req,
uint32_t auth_mode)
{
return WMI_AUTH_CCKM;
}
#endif #endif
/** /**
* wma_roam_scan_fill_ap_profile() - fill ap_profile * wma_roam_scan_fill_ap_profile() - fill ap_profile
@@ -854,8 +854,9 @@ static uint32_t wma_roam_scan_get_cckm_mode(tSirRoamOffloadScanReq *roam_req,
* *
* Return: none * Return: none
*/ */
static void wma_roam_scan_fill_ap_profile(tSirRoamOffloadScanReq *roam_req, static void
struct ap_profile *profile) wma_roam_scan_fill_ap_profile(struct roam_offload_scan_req *roam_req,
struct ap_profile *profile)
{ {
uint32_t rsn_authmode; uint32_t rsn_authmode;
@@ -1041,7 +1042,7 @@ void wma_process_set_pdev_vht_ie_req(tp_wma_handle wma,
*/ */
void wma_roam_scan_fill_scan_params(tp_wma_handle wma_handle, void wma_roam_scan_fill_scan_params(tp_wma_handle wma_handle,
struct mac_context *mac, struct mac_context *mac,
tSirRoamOffloadScanReq *roam_req, struct roam_offload_scan_req *roam_req,
wmi_start_scan_cmd_fixed_param * wmi_start_scan_cmd_fixed_param *
scan_params) scan_params)
{ {
@@ -1197,7 +1198,7 @@ void wma_roam_scan_fill_scan_params(tp_wma_handle wma_handle,
* Return: QDF status * Return: QDF status
*/ */
static QDF_STATUS wma_roam_scan_offload_ap_profile(tp_wma_handle wma_handle, static QDF_STATUS wma_roam_scan_offload_ap_profile(tp_wma_handle wma_handle,
tSirRoamOffloadScanReq *roam_req) struct roam_offload_scan_req *roam_req)
{ {
struct ap_profile_params ap_profile; struct ap_profile_params ap_profile;
bool db2dbm_enabled; bool db2dbm_enabled;
@@ -1238,7 +1239,7 @@ static QDF_STATUS wma_roam_scan_offload_ap_profile(tp_wma_handle wma_handle,
* parameters to the firmware, otherwise failure. * parameters to the firmware, otherwise failure.
*/ */
static QDF_STATUS wma_roam_scan_filter(tp_wma_handle wma_handle, static QDF_STATUS wma_roam_scan_filter(tp_wma_handle wma_handle,
tSirRoamOffloadScanReq *roam_req) struct roam_offload_scan_req *roam_req)
{ {
int i; int i;
QDF_STATUS status = QDF_STATUS_SUCCESS; QDF_STATUS status = QDF_STATUS_SUCCESS;
@@ -1425,8 +1426,9 @@ QDF_STATUS wma_roam_scan_offload_command(tp_wma_handle wma_handle,
* *
* Return: QDF status * Return: QDF status
*/ */
static QDF_STATUS wma_roam_scan_btm_offload(tp_wma_handle wma_handle, static QDF_STATUS
tSirRoamOffloadScanReq *roam_req) wma_roam_scan_btm_offload(tp_wma_handle wma_handle,
struct roam_offload_scan_req *roam_req)
{ {
struct wmi_btm_config *params; struct wmi_btm_config *params;
QDF_STATUS status; QDF_STATUS status;
@@ -1535,7 +1537,7 @@ QDF_STATUS wma_send_offload_11k_params(WMA_HANDLE handle,
* Return: QDF status * Return: QDF status
*/ */
QDF_STATUS wma_process_roaming_config(tp_wma_handle wma_handle, QDF_STATUS wma_process_roaming_config(tp_wma_handle wma_handle,
tSirRoamOffloadScanReq *roam_req) struct roam_offload_scan_req *roam_req)
{ {
QDF_STATUS qdf_status = QDF_STATUS_SUCCESS; QDF_STATUS qdf_status = QDF_STATUS_SUCCESS;
wmi_start_scan_cmd_fixed_param scan_params; wmi_start_scan_cmd_fixed_param scan_params;
@@ -1566,9 +1568,10 @@ QDF_STATUS wma_process_roaming_config(tp_wma_handle wma_handle,
intr = &wma_handle->interfaces[roam_req->sessionId]; intr = &wma_handle->interfaces[roam_req->sessionId];
intr->delay_before_vdev_stop = roam_req->delay_before_vdev_stop; intr->delay_before_vdev_stop = roam_req->delay_before_vdev_stop;
/* /*
* Scan/Roam threshold parameters are translated from fields of * Scan/Roam threshold parameters are translated from
* tSirRoamOffloadScanReq to WMITLV values sent to Rome firmware * fields of struct roam_offload_scan_req to WMITLV
* some of these parameters are configurable in qcom_cfg.ini * values sent to Rome firmware some of these
* parameters are configurable in qcom_cfg.ini
*/ */
/* First param is positive rssi value to trigger rssi based scan /* First param is positive rssi value to trigger rssi based scan
@@ -2403,7 +2406,7 @@ int wma_roam_synch_event_handler(void *handle, uint8_t *event,
uint8_t channel; uint8_t channel;
uint16_t ie_len = 0; uint16_t ie_len = 0;
int status = -EINVAL; int status = -EINVAL;
tSirRoamOffloadScanReq *roam_req; struct roam_offload_scan_req *roam_req;
qdf_time_t roam_synch_received = qdf_get_system_timestamp(); qdf_time_t roam_synch_received = qdf_get_system_timestamp();
uint32_t roam_synch_data_len; uint32_t roam_synch_data_len;
A_UINT32 bcn_probe_rsp_len; A_UINT32 bcn_probe_rsp_len;
@@ -2622,7 +2625,7 @@ cleanup_label:
if (roam_synch_ind_ptr) if (roam_synch_ind_ptr)
wma->csr_roam_synch_cb((struct mac_context *)wma->mac_context, wma->csr_roam_synch_cb((struct mac_context *)wma->mac_context,
roam_synch_ind_ptr, NULL, SIR_ROAMING_ABORT); roam_synch_ind_ptr, NULL, SIR_ROAMING_ABORT);
roam_req = qdf_mem_malloc(sizeof(tSirRoamOffloadScanReq)); roam_req = qdf_mem_malloc(sizeof(struct roam_offload_scan_req));
if (roam_req && synch_event) { if (roam_req && synch_event) {
roam_req->Command = ROAM_SCAN_OFFLOAD_STOP; roam_req->Command = ROAM_SCAN_OFFLOAD_STOP;
roam_req->reason = REASON_ROAM_SYNCH_FAILED; roam_req->reason = REASON_ROAM_SYNCH_FAILED;
@@ -2793,7 +2796,7 @@ int wma_roam_synch_frame_event_handler(void *handle, uint8_t *event,
QDF_STATUS wma_roam_scan_fill_self_caps(tp_wma_handle wma_handle, QDF_STATUS wma_roam_scan_fill_self_caps(tp_wma_handle wma_handle,
roam_offload_param * roam_offload_param *
roam_offload_params, roam_offload_params,
tSirRoamOffloadScanReq *roam_req) struct roam_offload_scan_req *roam_req)
{ {
qdf_size_t val_len; qdf_size_t val_len;
struct mac_context *mac = NULL; struct mac_context *mac = NULL;