summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorYingying Tang <yintang@codeaurora.org>2017-02-22 21:10:19 +0800
committerqcabuildsw <qcabuildsw@localhost>2017-02-28 23:40:56 -0800
commitd653c2a995d8a4827d772a7084c8cdeee5535777 (patch)
treedc26d8d1c2db7dce70978e1e9c51ed13abe4f7fd
parent61bec2b57bb193e8bee934123e2816157e13899b (diff)
qcacld-3.0: Add "static" to fix compilation error for HL bus
Add "static" before some functions which only be used in 1 file and remove some unused function to resolve compilation error. Change-Id: Id1b1101c3bb04910ad1e3639887f74e44d5b7c36 CRs-Fixed: 2010227
-rw-r--r--core/bmi/src/bmi.c3
-rw-r--r--core/bmi/src/i_bmi.h14
-rw-r--r--core/cds/src/cds_concurrency.c2
-rw-r--r--core/dp/txrx/ol_tx.c2
-rw-r--r--core/dp/txrx/ol_tx_classify.c153
-rw-r--r--core/dp/txrx/ol_tx_queue.c4
-rw-r--r--core/dp/txrx/ol_tx_sched.c18
-rw-r--r--core/wma/src/wma_ocb.c19
8 files changed, 28 insertions, 187 deletions
diff --git a/core/bmi/src/bmi.c b/core/bmi/src/bmi.c
index 33f5986cca0d..d1039f2e8a61 100644
--- a/core/bmi/src/bmi.c
+++ b/core/bmi/src/bmi.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014-2016 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2014-2017 The Linux Foundation. All rights reserved.
*
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
*
@@ -27,6 +27,7 @@
#include "i_bmi.h"
#include "cds_api.h"
+#include "hif.h"
/* APIs visible to the driver */
diff --git a/core/bmi/src/i_bmi.h b/core/bmi/src/i_bmi.h
index 712bf9e30be5..8b476469cddf 100644
--- a/core/bmi/src/i_bmi.h
+++ b/core/bmi/src/i_bmi.h
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2014-2016 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2014-2017 The Linux Foundation. All rights reserved.
*
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
*
@@ -184,16 +184,4 @@ void ramdump_work_handler(void *arg);
void fw_indication_work_handler(void *arg);
struct ol_config_info *ol_get_ini_handle(struct ol_context *ol_ctx);
-#ifdef HIF_SDIO
-QDF_STATUS hif_reg_based_get_target_info(struct hif_opaque_softc *hif_ctx,
- struct bmi_target_info *targ_info);
-#endif
-#if defined(HIF_PCI) || defined(SNOC) || defined(HIF_AHB) || defined(HIF_USB)
-static inline QDF_STATUS
-hif_reg_based_get_target_info(struct hif_opaque_softc *hif_ctx,
- struct bmi_target_info *targ_info)
-{
- return QDF_STATUS_SUCCESS;
-}
-#endif
#endif
diff --git a/core/cds/src/cds_concurrency.c b/core/cds/src/cds_concurrency.c
index 2832db68836f..c9cfab952af4 100644
--- a/core/cds/src/cds_concurrency.c
+++ b/core/cds/src/cds_concurrency.c
@@ -7259,7 +7259,7 @@ QDF_STATUS cds_handle_conc_multiport(uint8_t session_id, uint8_t channel)
*
* Return: None
*/
-void cds_restart_softap(hdd_adapter_t *pHostapdAdapter)
+static void cds_restart_softap(hdd_adapter_t *pHostapdAdapter)
{
tHddAvoidFreqList hdd_avoid_freq_list;
hdd_context_t *hdd_ctx;
diff --git a/core/dp/txrx/ol_tx.c b/core/dp/txrx/ol_tx.c
index 713dc3ba1400..1fb06e790f8e 100644
--- a/core/dp/txrx/ol_tx.c
+++ b/core/dp/txrx/ol_tx.c
@@ -49,6 +49,7 @@
/* internal header files relevant only for specific systems (Pronto) */
#include <ol_txrx_encap.h> /* OL_TX_ENCAP, etc */
#include <ol_tx.h>
+#include <cdp_txrx_ipa.h>
#ifdef WLAN_FEATURE_FASTPATH
#include <hif.h> /* HIF_DEVICE */
@@ -56,7 +57,6 @@
#include <htt_internal.h>
#include <htt_types.h> /* htc_endpoint */
#include <cdp_txrx_peer_ops.h>
-#include <cdp_txrx_ipa.h>
int ce_send_fast(struct CE_handle *copyeng, qdf_nbuf_t msdu,
unsigned int transfer_id, uint32_t download_len);
diff --git a/core/dp/txrx/ol_tx_classify.c b/core/dp/txrx/ol_tx_classify.c
index 16da47658a9c..195c1155187c 100644
--- a/core/dp/txrx/ol_tx_classify.c
+++ b/core/dp/txrx/ol_tx_classify.c
@@ -367,7 +367,7 @@ struct ol_txrx_peer_t *ol_tx_tdls_peer_find(struct ol_txrx_pdev_t *pdev,
}
#else
-struct ol_txrx_peer_t *ol_tx_tdls_peer_find(struct ol_txrx_pdev_t *pdev,
+static struct ol_txrx_peer_t *ol_tx_tdls_peer_find(struct ol_txrx_pdev_t *pdev,
struct ol_txrx_vdev_t *vdev,
uint8_t *peer_id)
{
@@ -732,155 +732,4 @@ ol_tx_classify_mgmt(
TX_SCHED_DEBUG_PRINT("Leave %s\n", __func__);
return txq;
}
-
-A_STATUS
-ol_tx_classify_extension(
- struct ol_txrx_vdev_t *vdev,
- struct ol_tx_desc_t *tx_desc,
- qdf_nbuf_t tx_msdu,
- struct ol_txrx_msdu_info_t *msdu_info)
-{
- A_UINT8 *datap = qdf_nbuf_data(tx_msdu);
- struct ol_txrx_peer_t *peer;
- int which_key;
-
- /*
- * The following msdu_info fields were already filled in by the
- * ol_tx entry function or the regular ol_tx_classify function:
- * htt.info.vdev_id (ol_tx_hl or ol_tx_non_std_hl)
- * htt.info.ext_tid (ol_tx_non_std_hl or ol_tx_classify)
- * htt.info.frame_type (ol_tx_hl or ol_tx_non_std_hl)
- * htt.info.l2_hdr_type (ol_tx_hl or ol_tx_non_std_hl)
- * htt.info.is_unicast (ol_tx_classify)
- * htt.info.peer_id (ol_tx_classify)
- * peer (ol_tx_classify)
- * if (is_unicast) {
- * htt.info.ethertype (ol_tx_classify)
- * htt.info.l3_hdr_offset (ol_tx_classify)
- * }
- * The following fields need to be filled in by this function:
- * if (!is_unicast) {
- * htt.info.ethertype
- * htt.info.l3_hdr_offset
- * }
- * htt.action.band (NOT CURRENTLY USED)
- * htt.action.do_encrypt
- * htt.action.do_tx_complete
- * The following fields are not needed for data frames, and can
- * be left uninitialized:
- * htt.info.frame_subtype
- */
-
- if (!msdu_info->htt.info.is_unicast) {
- int l2_hdr_size;
- A_UINT16 ethertype;
-
- if (msdu_info->htt.info.l2_hdr_type == htt_pkt_type_ethernet) {
- struct ethernet_hdr_t *eh;
-
- eh = (struct ethernet_hdr_t *)datap;
- l2_hdr_size = sizeof(*eh);
- ethertype = (eh->ethertype[0] << 8) | eh->ethertype[1];
-
- if (ethertype == ETHERTYPE_VLAN) {
- struct ethernet_vlan_hdr_t *evh;
-
- evh = (struct ethernet_vlan_hdr_t *)datap;
- l2_hdr_size = sizeof(*evh);
- ethertype = (evh->ethertype[0] << 8) |
- evh->ethertype[1];
- }
-
- if (!IS_ETHERTYPE(ethertype)) {
- /* 802.3 header*/
- struct llc_snap_hdr_t *llc =
- (struct llc_snap_hdr_t *)(datap +
- l2_hdr_size);
- ethertype = (llc->ethertype[0] << 8) |
- llc->ethertype[1];
- l2_hdr_size += sizeof(*llc);
- }
- msdu_info->htt.info.l3_hdr_offset = l2_hdr_size;
- msdu_info->htt.info.ethertype = ethertype;
- } else { /* 802.11 */
- struct llc_snap_hdr_t *llc;
- l2_hdr_size = ol_txrx_ieee80211_hdrsize(datap);
- llc = (struct llc_snap_hdr_t *)(datap + l2_hdr_size);
- ethertype = (llc->ethertype[0] << 8) |
- llc->ethertype[1];
- /*
- * Don't include the LLC/SNAP header in l2_hdr_size,
- * because l3_hdr_offset is actually supposed to refer
- * to the header after the 802.3 or 802.11 header,
- * which could be a LLC/SNAP header rather
- * than the L3 header.
- */
- }
- msdu_info->htt.info.l3_hdr_offset = l2_hdr_size;
- msdu_info->htt.info.ethertype = ethertype;
- which_key = txrx_sec_mcast;
- } else {
- which_key = txrx_sec_ucast;
- }
- peer = msdu_info->peer;
- /*
- * msdu_info->htt.action.do_encrypt is initially set in ol_tx_desc_hl.
- * Add more check here.
- */
- msdu_info->htt.action.do_encrypt = (!peer) ? 0 :
- (peer->security[which_key].sec_type == htt_sec_type_none) ? 0 :
- msdu_info->htt.action.do_encrypt;
- /*
- * For systems that have a frame by frame spec for whether to receive
- * a tx completion notification, use the tx completion notification
- * only for certain management frames, not for data frames.
- * (In the future, this may be changed slightly, e.g. to request a
- * tx completion notification for the final EAPOL message sent by a
- * STA during the key delivery handshake.)
- */
- msdu_info->htt.action.do_tx_complete = 0;
-
- return A_OK;
-}
-
-A_STATUS
-ol_tx_classify_mgmt_extension(
- struct ol_txrx_vdev_t *vdev,
- struct ol_tx_desc_t *tx_desc,
- qdf_nbuf_t tx_msdu,
- struct ol_txrx_msdu_info_t *msdu_info)
-{
- struct ieee80211_frame *wh;
-
- /*
- * The following msdu_info fields were already filled in by the
- * ol_tx entry function or the regular ol_tx_classify_mgmt function:
- * htt.info.vdev_id (ol_txrx_mgmt_send)
- * htt.info.frame_type (ol_txrx_mgmt_send)
- * htt.info.l2_hdr_type (ol_txrx_mgmt_send)
- * htt.action.do_tx_complete (ol_txrx_mgmt_send)
- * htt.info.peer_id (ol_tx_classify_mgmt)
- * htt.info.ext_tid (ol_tx_classify_mgmt)
- * htt.info.is_unicast (ol_tx_classify_mgmt)
- * peer (ol_tx_classify_mgmt)
- * The following fields need to be filled in by this function:
- * htt.info.frame_subtype
- * htt.info.l3_hdr_offset
- * htt.action.band (NOT CURRENTLY USED)
- * The following fields are not needed for mgmt frames, and can
- * be left uninitialized:
- * htt.info.ethertype
- * htt.action.do_encrypt
- * (This will be filled in by other SW, which knows whether
- * the peer has robust-managment-frames enabled.)
- */
- wh = (struct ieee80211_frame *)qdf_nbuf_data(tx_msdu);
- msdu_info->htt.info.frame_subtype =
- (wh->i_fc[0] & IEEE80211_FC0_SUBTYPE_MASK) >>
- IEEE80211_FC0_SUBTYPE_SHIFT;
- msdu_info->htt.info.l3_hdr_offset = sizeof(struct ieee80211_frame);
-
- return A_OK;
-}
-
#endif /* defined(CONFIG_HL_SUPPORT) */
diff --git a/core/dp/txrx/ol_tx_queue.c b/core/dp/txrx/ol_tx_queue.c
index 52cec26ba3d5..470496affbb1 100644
--- a/core/dp/txrx/ol_tx_queue.c
+++ b/core/dp/txrx/ol_tx_queue.c
@@ -837,7 +837,7 @@ ol_txrx_bad_peer_txctl_update_threshold(struct ol_txrx_pdev_t *pdev,
*
* Return: None
*/
-void
+static void
ol_tx_pdev_peer_bal_timer(void *context)
{
int i;
@@ -1171,7 +1171,7 @@ ol_tx_queue_log_oldest_update(struct ol_txrx_pdev_t *pdev, int offset)
*
* Return: log element
*/
-void*
+static void*
ol_tx_queue_log_alloc(
struct ol_txrx_pdev_t *pdev,
u_int8_t type /* ol_tx_log_entry_type */,
diff --git a/core/dp/txrx/ol_tx_sched.c b/core/dp/txrx/ol_tx_sched.c
index dc2dd854c56d..4fd26fcf3a7f 100644
--- a/core/dp/txrx/ol_tx_sched.c
+++ b/core/dp/txrx/ol_tx_sched.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2012-2016 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2012-2017 The Linux Foundation. All rights reserved.
*
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
*
@@ -935,7 +935,7 @@ ol_tx_sched_txq_deactivate_wrr_adv(
category->state.active = 0;
}
-ol_tx_frms_queue_list *
+static ol_tx_frms_queue_list *
ol_tx_sched_category_tx_queues_wrr_adv(struct ol_txrx_pdev_t *pdev, int cat)
{
struct ol_tx_sched_wrr_adv_t *scheduler = pdev->tx_sched.scheduler;
@@ -945,7 +945,7 @@ ol_tx_sched_category_tx_queues_wrr_adv(struct ol_txrx_pdev_t *pdev, int cat)
return &category->state.head;
}
-int
+static int
ol_tx_sched_discard_select_category_wrr_adv(struct ol_txrx_pdev_t *pdev)
{
struct ol_tx_sched_wrr_adv_t *scheduler;
@@ -972,7 +972,7 @@ ol_tx_sched_discard_select_category_wrr_adv(struct ol_txrx_pdev_t *pdev)
return cat;
}
-void
+static void
ol_tx_sched_txq_discard_wrr_adv(
struct ol_txrx_pdev_t *pdev,
struct ol_tx_frms_queue_t *txq,
@@ -994,7 +994,7 @@ ol_tx_sched_txq_discard_wrr_adv(
category->state.active = 0;
}
-void
+static void
ol_tx_sched_category_info_wrr_adv(
struct ol_txrx_pdev_t *pdev,
int cat, int *active,
@@ -1019,7 +1019,7 @@ ol_tx_sched_category_info_wrr_adv(
*
* Return: none
*/
-void ol_tx_sched_wrr_param_update(struct ol_txrx_pdev_t *pdev,
+static void ol_tx_sched_wrr_param_update(struct ol_txrx_pdev_t *pdev,
struct ol_tx_sched_wrr_adv_t *scheduler)
{
int i;
@@ -1075,7 +1075,7 @@ void ol_tx_sched_wrr_param_update(struct ol_txrx_pdev_t *pdev,
}
}
-void *
+static void *
ol_tx_sched_init_wrr_adv(
struct ol_txrx_pdev_t *pdev)
{
@@ -1223,7 +1223,7 @@ void ol_tx_sched_stats_clear(struct ol_txrx_pdev_t *pdev)
/*--- congestion control discard --------------------------------------------*/
-struct ol_tx_frms_queue_t *
+static struct ol_tx_frms_queue_t *
ol_tx_sched_discard_select_txq(
struct ol_txrx_pdev_t *pdev,
ol_tx_frms_queue_list *tx_queues)
@@ -1363,7 +1363,7 @@ ol_tx_sched_notify(
#define OL_TX_MSDU_ID_STORAGE_ERR(ptr) (NULL == ptr)
-void
+static void
ol_tx_sched_dispatch(
struct ol_txrx_pdev_t *pdev,
struct ol_tx_sched_ctx *sctx)
diff --git a/core/wma/src/wma_ocb.c b/core/wma/src/wma_ocb.c
index 0a4dcfb395e4..196d5d76eaf0 100644
--- a/core/wma/src/wma_ocb.c
+++ b/core/wma/src/wma_ocb.c
@@ -1,5 +1,5 @@
/*
- * Copyright (c) 2013-2016 The Linux Foundation. All rights reserved.
+ * Copyright (c) 2013-2017 The Linux Foundation. All rights reserved.
*
* Previously licensed under the ISC license by Qualcomm Atheros, Inc.
*
@@ -424,8 +424,9 @@ int wma_ocb_get_tsf_timer(tp_wma_handle wma_handle,
*
* Return: 0 on success
*/
-int wma_ocb_get_tsf_timer_resp_event_handler(void *handle, uint8_t *event_buf,
- uint32_t len)
+static int wma_ocb_get_tsf_timer_resp_event_handler(void *handle,
+ uint8_t *event_buf,
+ uint32_t len)
{
QDF_STATUS qdf_status;
struct sir_ocb_get_tsf_timer_response *response;
@@ -494,8 +495,9 @@ int wma_dcc_get_stats(tp_wma_handle wma_handle,
*
* Return: 0 on success
*/
-int wma_dcc_get_stats_resp_event_handler(void *handle, uint8_t *event_buf,
- uint32_t len)
+static int wma_dcc_get_stats_resp_event_handler(void *handle,
+ uint8_t *event_buf,
+ uint32_t len)
{
QDF_STATUS qdf_status;
struct sir_dcc_get_stats_response *response;
@@ -593,8 +595,9 @@ int wma_dcc_update_ndl(tp_wma_handle wma_handle,
*
* Return: 0 on success
*/
-int wma_dcc_update_ndl_resp_event_handler(void *handle, uint8_t *event_buf,
- uint32_t len)
+static int wma_dcc_update_ndl_resp_event_handler(void *handle,
+ uint8_t *event_buf,
+ uint32_t len)
{
QDF_STATUS qdf_status;
struct sir_dcc_update_ndl_response *resp;
@@ -634,7 +637,7 @@ int wma_dcc_update_ndl_resp_event_handler(void *handle, uint8_t *event_buf,
*
* Return: 0 on success
*/
-int wma_dcc_stats_event_handler(void *handle, uint8_t *event_buf,
+static int wma_dcc_stats_event_handler(void *handle, uint8_t *event_buf,
uint32_t len)
{
QDF_STATUS qdf_status;