Procházet zdrojové kódy

qcacmn: Add cdp support for external tx completion for mesh mode

Added cdp support for external tx completion. In case of mesh mode per
packet tx completion stats has to be filled in the meta header and external
function has to be called for updating these stats. It is the responsibility
of external function to free the buffer after reading the stats

Change-Id: I45ba800acf9b4d6091cc3f9aafc67c1f1f00f379
CRs-Fixed: 2003389
Venkateswara Swamy Bandaru před 8 roky
rodič
revize
9748234151
3 změnil soubory, kde provedl 10 přidání a 0 odebrání
  1. 7 0
      dp/inc/cdp_txrx_cmn_struct.h
  2. 2 0
      dp/wifi3.0/dp_main.c
  3. 1 0
      dp/wifi3.0/dp_types.h

+ 7 - 0
dp/inc/cdp_txrx_cmn_struct.h

@@ -212,6 +212,12 @@ typedef QDF_STATUS(*ol_txrx_rsim_rx_decap_fp)(void *osif_dev,
 						qdf_nbuf_t *list_head,
 						qdf_nbuf_t *list_tail);
 
+/* ol_txrx_rx_fp - external tx free function to read per packet stats and
+ *                            free tx buffer externally
+ * @netbuf - tx network buffer
+ */
+typedef void (*ol_txrx_tx_free_ext_fp)(qdf_nbuf_t netbuf);
+
 /**
  * ol_txrx_rx_check_wai_fp - OSIF WAPI receive function
 */
@@ -291,6 +297,7 @@ struct ol_txrx_ops {
 	/* tx function pointers - specified by txrx, stored by OS shim */
 	struct {
 		ol_txrx_tx_fp         tx;
+		ol_txrx_tx_free_ext_fp tx_free_ext;
 	} tx;
 
 	/* rx function pointers - specified by OS shim, stored by txrx */

+ 2 - 0
dp/wifi3.0/dp_main.c

@@ -1318,6 +1318,7 @@ static struct cdp_vdev *dp_vdev_attach_wifi3(struct cdp_pdev *txrx_pdev,
 	vdev->osif_rx = NULL;
 	vdev->osif_rsim_rx_decap = NULL;
 	vdev->osif_rx_mon = NULL;
+	vdev->osif_tx_free_ext = NULL;
 	vdev->osif_vdev = NULL;
 
 	vdev->delete.pending = 0;
@@ -1376,6 +1377,7 @@ static void dp_vdev_register_wifi3(struct cdp_vdev *vdev_handle,
 	vdev->osif_rx = txrx_ops->rx.rx;
 	vdev->osif_rsim_rx_decap = txrx_ops->rx.rsim_rx_decap;
 	vdev->osif_rx_mon = txrx_ops->rx.mon;
+	vdev->osif_tx_free_ext = txrx_ops->tx.tx_free_ext;
 #ifdef notyet
 #if ATH_SUPPORT_WAPI
 	vdev->osif_check_wai = txrx_ops->rx.wai_check;

+ 1 - 0
dp/wifi3.0/dp_types.h

@@ -594,6 +594,7 @@ struct dp_vdev {
 	/* callback to hand rx frames to the OS shim */
 	ol_txrx_rx_fp osif_rx;
 	ol_txrx_rsim_rx_decap_fp osif_rsim_rx_decap;
+	ol_txrx_tx_free_ext_fp osif_tx_free_ext;
 
 #ifdef notyet
 	/* callback to check if the msdu is an WAI (WAPI) frame */