Bläddra i källkod

qcacmn: Make static API's as global to be used in other files

Make static API's as global so that they can be used in external
architecture specific related files.

Change-Id: Ida906d5dba18cc7c87a3965addf882eecfe55e0e
CRs-Fixed: 3382927
Karthik Kantamneni 2 år sedan
förälder
incheckning
609cff4e50
4 ändrade filer med 96 tillägg och 73 borttagningar
  1. 5 34
      dp/wifi3.0/dp_htt.c
  2. 40 0
      dp/wifi3.0/dp_htt.h
  3. 6 39
      dp/wifi3.0/dp_rx_defrag.c
  4. 45 0
      dp/wifi3.0/dp_rx_defrag.h

+ 5 - 34
dp/wifi3.0/dp_htt.c

@@ -263,12 +263,7 @@ dp_htt_h2t_send_complete_free_netbuf(
 }
 
 #ifdef ENABLE_CE4_COMP_DISABLE_HTT_HTC_MISC_LIST
-/**
- * dp_htt_h2t_send_complete() - H2T completion handler
- * @context:	Opaque context (HTT SOC handle)
- * @htc_pkt:	HTC packet
- */
-static void
+void
 dp_htt_h2t_send_complete(void *context, HTC_PACKET *htc_pkt)
 {
 	struct htt_soc *soc =  (struct htt_soc *) context;
@@ -290,7 +285,7 @@ dp_htt_h2t_send_complete(void *context, HTC_PACKET *htc_pkt)
 
 #else /* ENABLE_CE4_COMP_DISABLE_HTT_HTC_MISC_LIST */
 
-static void
+void
 dp_htt_h2t_send_complete(void *context, HTC_PACKET *htc_pkt)
 {
 	void (*send_complete_part2)(
@@ -3483,12 +3478,7 @@ static void dp_ipa_rx_cce_super_rule_setup_done_handler(struct htt_soc *soc,
 }
 #endif
 
-/*
- * dp_htt_t2h_msg_handler() - Generic Target to host Msg/event handler
- * @context:	Opaque context (HTT SOC handle)
- * @pkt:	HTC packet
- */
-static void dp_htt_t2h_msg_handler(void *context, HTC_PACKET *pkt)
+void dp_htt_t2h_msg_handler(void *context, HTC_PACKET *pkt)
 {
 	struct htt_soc *soc = (struct htt_soc *) context;
 	qdf_nbuf_t htt_t2h_msg = (qdf_nbuf_t) pkt->pPktContext;
@@ -3944,32 +3934,13 @@ static void dp_htt_t2h_msg_handler(void *context, HTC_PACKET *pkt)
 		qdf_nbuf_free(htt_t2h_msg);
 }
 
-/**
- * dp_htt_h2t_full() - Send full handler (called from HTC)
- * @context:	Opaque context (HTT SOC handle)
- * @pkt:	HTC packet
- *
- * Return: enum htc_send_full_action
- */
-static enum htc_send_full_action
+enum htc_send_full_action
 dp_htt_h2t_full(void *context, HTC_PACKET *pkt)
 {
 	return HTC_SEND_FULL_KEEP;
 }
 
-/**
- * dp_htt_hif_t2h_hp_callback() - HIF callback for high priority T2H messages
- * @context:	Opaque context (HTT SOC handle)
- * @nbuf:	nbuf containing T2H message
- * @pipe_id:	HIF pipe ID
- *
- * Return: QDF_STATUS
- *
- * TODO: Temporary change to bypass HTC connection for this new HIF pipe, which
- * will be used for packet log and other high-priority HTT messages. Proper
- * HTC connection to be added later once required FW changes are available
- */
-static QDF_STATUS
+QDF_STATUS
 dp_htt_hif_t2h_hp_callback (void *context, qdf_nbuf_t nbuf, uint8_t pipe_id)
 {
 	QDF_STATUS rc = QDF_STATUS_SUCCESS;

+ 40 - 0
dp/wifi3.0/dp_htt.h

@@ -914,6 +914,39 @@ htt_soc_initialize(struct htt_soc *htt_soc,
 		   HTC_HANDLE htc_soc,
 		   hal_soc_handle_t hal_soc_hdl, qdf_device_t osdev);
 
+/**
+ * dp_htt_h2t_full() - Send full handler (called from HTC)
+ * @context:	Opaque context (HTT SOC handle)
+ * @pkt:	HTC packet
+ *
+ * Return: enum htc_send_full_action
+ */
+enum htc_send_full_action
+dp_htt_h2t_full(void *context, HTC_PACKET *pkt);
+
+/**
+ * dp_htt_h2t_send_complete() - H2T completion handler
+ * @context:	Opaque context (HTT SOC handle)
+ * @htc_pkt:	HTC packet
+ */
+void
+dp_htt_h2t_send_complete(void *context, HTC_PACKET *htc_pkt);
+
+/**
+ * dp_htt_hif_t2h_hp_callback() - HIF callback for high priority T2H messages
+ * @context:	Opaque context (HTT SOC handle)
+ * @nbuf:	nbuf containing T2H message
+ * @pipe_id:	HIF pipe ID
+ *
+ * Return: QDF_STATUS
+ *
+ * TODO: Temporary change to bypass HTC connection for this new HIF pipe, which
+ * will be used for packet log and other high-priority HTT messages. Proper
+ * HTC connection to be added later once required FW changes are available
+ */
+QDF_STATUS
+dp_htt_hif_t2h_hp_callback(void *context, qdf_nbuf_t nbuf, uint8_t pipe_id);
+
 /**
  * htt_soc_attach() - attach DP and HTT SOC
  * @soc: DP SOC handle
@@ -1001,6 +1034,13 @@ int htt_h2t_rx_ring_cfg(struct htt_soc *htt_soc, int pdev_id,
 			int hal_ring_type, int ring_buf_size,
 			struct htt_rx_ring_tlv_filter *htt_tlv_filter);
 
+/**
+ * dp_htt_t2h_msg_handler() - Generic Target to host Msg/event handler
+ * @context:	Opaque context (HTT SOC handle)
+ * @pkt:	HTC packet
+ */
+void dp_htt_t2h_msg_handler(void *context, HTC_PACKET *pkt);
+
 /**
  * htt_t2h_stats_handler() - target to host stats work handler
  * @context:	context (dp soc context)

+ 6 - 39
dp/wifi3.0/dp_rx_defrag.c

@@ -227,17 +227,8 @@ void dp_rx_defrag_waitlist_flush(struct dp_soc *soc)
 	}
 }
 
-/**
- * dp_rx_defrag_waitlist_add() - Update per-PDEV defrag wait list
- * @txrx_peer: Pointer to the peer data structure
- * @tid: Transmit ID (TID)
- *
- * Appends per-tid fragments to global fragment wait list
- *
- * Return: None
- */
-static void dp_rx_defrag_waitlist_add(struct dp_txrx_peer *txrx_peer,
-				      unsigned int tid)
+void dp_rx_defrag_waitlist_add(struct dp_txrx_peer *txrx_peer,
+			       unsigned int tid)
 {
 	struct dp_soc *psoc = txrx_peer->vdev->pdev->soc;
 	struct dp_rx_tid_defrag *waitlist_elem = &txrx_peer->rx_tid[tid];
@@ -291,20 +282,7 @@ void dp_rx_defrag_waitlist_remove(struct dp_txrx_peer *txrx_peer,
 	qdf_spin_unlock_bh(&soc->rx.defrag.defrag_lock);
 }
 
-/**
- * dp_rx_defrag_fraglist_insert() - Create a per-sequence fragment list
- * @txrx_peer: Pointer to the peer data structure
- * @tid: Transmit ID (TID)
- * @head_addr: Pointer to head list
- * @tail_addr: Pointer to tail list
- * @frag: Incoming fragment
- * @all_frag_present: Flag to indicate whether all fragments are received
- *
- * Build a per-tid, per-sequence fragment list.
- *
- * Return: Success, if inserted
- */
-static QDF_STATUS
+QDF_STATUS
 dp_rx_defrag_fraglist_insert(struct dp_txrx_peer *txrx_peer, unsigned int tid,
 			     qdf_nbuf_t *head_addr, qdf_nbuf_t *tail_addr,
 			     qdf_nbuf_t frag, uint8_t *all_frag_present)
@@ -1429,20 +1407,9 @@ static QDF_STATUS dp_rx_defrag_gcmp_demic(struct dp_soc *soc, qdf_nbuf_t nbuf,
 	return QDF_STATUS_SUCCESS;
 }
 
-/**
- * dp_rx_defrag() - Defragment the fragment chain
- * @txrx_peer: Pointer to the peer
- * @tid: Transmit Identifier
- * @frag_list_head: Pointer to head list
- * @frag_list_tail: Pointer to tail list
- *
- * Defragment the fragment chain
- *
- * Return: QDF_STATUS
- */
-static QDF_STATUS dp_rx_defrag(struct dp_txrx_peer *txrx_peer, unsigned int tid,
-			       qdf_nbuf_t frag_list_head,
-			       qdf_nbuf_t frag_list_tail)
+QDF_STATUS dp_rx_defrag(struct dp_txrx_peer *txrx_peer, unsigned int tid,
+			qdf_nbuf_t frag_list_head,
+			qdf_nbuf_t frag_list_tail)
 {
 	qdf_nbuf_t tmp_next;
 	qdf_nbuf_t cur = frag_list_head, msdu;

+ 45 - 0
dp/wifi3.0/dp_rx_defrag.h

@@ -156,6 +156,51 @@ uint8_t dp_rx_get_pkt_dir(struct dp_soc *soc, uint8_t *rx_desc_info)
 	return mac_hdr->i_fc[1] & IEEE80211_FC1_DIR_MASK;
 }
 
+/**
+ * dp_rx_defrag_fraglist_insert() - Create a per-sequence fragment list
+ * @txrx_peer: Pointer to the peer data structure
+ * @tid: Transmit ID (TID)
+ * @head_addr: Pointer to head list
+ * @tail_addr: Pointer to tail list
+ * @frag: Incoming fragment
+ * @all_frag_present: Flag to indicate whether all fragments are received
+ *
+ * Build a per-tid, per-sequence fragment list.
+ *
+ * Return: Success, if inserted
+ */
+QDF_STATUS
+dp_rx_defrag_fraglist_insert(struct dp_txrx_peer *txrx_peer, unsigned int tid,
+			     qdf_nbuf_t *head_addr, qdf_nbuf_t *tail_addr,
+			     qdf_nbuf_t frag, uint8_t *all_frag_present);
+
+/**
+ * dp_rx_defrag_waitlist_add() - Update per-PDEV defrag wait list
+ * @txrx_peer: Pointer to the peer data structure
+ * @tid: Transmit ID (TID)
+ *
+ * Appends per-tid fragments to global fragment wait list
+ *
+ * Return: None
+ */
+void dp_rx_defrag_waitlist_add(struct dp_txrx_peer *txrx_peer,
+			       unsigned int tid);
+
+/**
+ * dp_rx_defrag() - Defragment the fragment chain
+ * @txrx_peer: Pointer to the peer
+ * @tid: Transmit Identifier
+ * @frag_list_head: Pointer to head list
+ * @frag_list_tail: Pointer to tail list
+ *
+ * Defragment the fragment chain
+ *
+ * Return: QDF_STATUS
+ */
+QDF_STATUS dp_rx_defrag(struct dp_txrx_peer *txrx_peer, unsigned int tid,
+			qdf_nbuf_t frag_list_head,
+			qdf_nbuf_t frag_list_tail);
+
 /**
  * dp_rx_defrag_waitlist_flush() - Flush SOC defrag wait list
  * @soc: DP SOC