Browse Source

qcacld-3.0: Refine csr_issue_set_context_req_helper()

The function csr_issue_set_context_req_helper() currently takes 9
parameters. However, three of these parameters are unused, so remove
them from the function signature. In addition, rename the session_id
parameter to vdev_id to align with current nomenclature.

Change-Id: I3eec487bb8d29c39d615c54dd8c5f58c26894bc4
CRs-Fixed: 3429882
Jeff Johnson 2 years ago
parent
commit
d3dc58e48b
2 changed files with 12 additions and 22 deletions
  1. 5 10
      core/sme/src/csr/csr_api_roam.c
  2. 7 12
      core/sme/src/csr/csr_inside_api.h

+ 5 - 10
core/sme/src/csr/csr_api_roam.c

@@ -2795,11 +2795,9 @@ static void csr_roam_process_start_bss_success(struct mac_context *mac_ctx,
 	 */
 	if (opmode == QDF_SAP_MODE || opmode == QDF_P2P_GO_MODE) {
 		if (wlan_is_open_wep_cipher(mac_ctx->pdev, vdev_id)) {
-			/* NO keys. these key parameters don't matter */
 			csr_issue_set_context_req_helper(mac_ctx, vdev_id,
 							 &bcast_mac, false,
-							 false, eSIR_TX_RX,
-							 0, 0, NULL);
+							 false, 0);
 		}
 	}
 
@@ -3588,12 +3586,10 @@ static QDF_STATUS csr_roam_issue_set_context_req(struct mac_context *mac_ctx,
 
 QDF_STATUS
 csr_issue_set_context_req_helper(struct mac_context *mac_ctx,
-				 uint32_t session_id, tSirMacAddr *bssid,
-				 bool addkey, bool unicast,
-				 tAniKeyDirection key_direction, uint8_t key_id,
-				 uint16_t key_length, uint8_t *key)
+				 uint32_t vdev_id, tSirMacAddr *bssid,
+				 bool addkey, bool unicast, uint8_t key_id)
 {
-	return csr_roam_issue_set_context_req(mac_ctx, session_id, addkey,
+	return csr_roam_issue_set_context_req(mac_ctx, vdev_id, addkey,
 					      unicast, key_id,
 					      (struct qdf_mac_addr *)bssid);
 }
@@ -3985,10 +3981,9 @@ csr_roam_chk_lnk_assoc_ind(struct mac_context *mac_ctx, tSirSmeRsp *msg_ptr)
 
 	if (opmode == QDF_SAP_MODE || opmode == QDF_P2P_GO_MODE) {
 		if (wlan_is_open_wep_cipher(mac_ctx->pdev, sessionId)) {
-			/* NO keys... these key parameters don't matter. */
 			csr_issue_set_context_req_helper(mac_ctx, sessionId,
 					&roam_info->peerMac.bytes, false, true,
-					eSIR_TX_RX, 0, 0, NULL);
+					0);
 			roam_info->fAuthRequired = false;
 		} else {
 			roam_info->fAuthRequired = true;

+ 7 - 12
core/sme/src/csr/csr_inside_api.h

@@ -1,6 +1,6 @@
 /*
  * Copyright (c) 2011-2021 The Linux Foundation. All rights reserved.
- * Copyright (c) 2022 Qualcomm Innovation Center, Inc. All rights reserved.
+ * Copyright (c) 2022-2023 Qualcomm Innovation Center, Inc. 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
@@ -89,25 +89,20 @@ void csr_roam_complete(struct mac_context *mac, uint8_t session_id);
 /**
  * csr_issue_set_context_req_helper  - Function to fill unicast/broadcast keys
  * request to set the keys to fw
- * @mac:         Pointer to mac context
+ * @mac_ctx:     Pointer to mac context
  * @vdev_id:     vdev id
  * @bssid:       Connected BSSID
  * @addkey:      Is add key request to crypto
  * @unicast:     Unicast(1) or broadcast key(0)
- * @key_direction: Key used in TX or RX or both Tx and RX path
- * @key_id:       Key index
- * @key_length:   Key length
- * @key:          Pointer to the key
+ * @key_id:      Key index
  *
  * Return: QDF_STATUS
  */
 QDF_STATUS
-csr_issue_set_context_req_helper(struct mac_context *mac,
-				 uint32_t session_id,
-				 tSirMacAddr *bssid, bool addkey,
-				 bool unicast, tAniKeyDirection key_direction,
-				 uint8_t key_id, uint16_t key_length,
-				 uint8_t *key);
+csr_issue_set_context_req_helper(struct mac_context *mac_ctx,
+				 uint32_t vdev_id, tSirMacAddr *bssid,
+				 bool addkey, bool unicast, uint8_t key_id);
+
 void csr_roam_check_for_link_status_change(struct mac_context *mac,
 					tSirSmeRsp *pSirMsg);
 QDF_STATUS csr_send_mb_disassoc_req_msg(struct mac_context *mac, uint32_t sessionId,