From b9d5c7d2b70beb4fc2c41759d8b653fe4fefce61 Mon Sep 17 00:00:00 2001 From: Tallapragada Kalyan Date: Mon, 2 Nov 2020 18:09:10 +0530 Subject: [PATCH] qcacmn: move the TX notify comp flag to MCL specific cb structure The TX notify comp flag is used only by MCL, hence moving to the MCL this field to the MCL specific cb private structure. Change-Id: I707ab9252dea705552df9678eedd8501f479672e --- dp/wifi3.0/dp_tx.c | 3 +-- qdf/inc/i_qdf_nbuf_api_m.h | 10 ++++++++++ qdf/inc/i_qdf_nbuf_api_w.h | 10 ++++++++++ qdf/linux/src/i_qdf_nbuf.h | 8 ++++---- qdf/linux/src/i_qdf_nbuf_m.h | 3 +++ 5 files changed, 28 insertions(+), 6 deletions(-) diff --git a/dp/wifi3.0/dp_tx.c b/dp/wifi3.0/dp_tx.c index a75215c2db..0d9d03dc0a 100644 --- a/dp/wifi3.0/dp_tx.c +++ b/dp/wifi3.0/dp_tx.c @@ -4309,8 +4309,7 @@ dp_tx_comp_process_desc_list(struct dp_soc *soc, netbuf = desc->nbuf; /* check tx complete notification */ - if (peer && - QDF_NBUF_CB_TX_EXTRA_FRAG_FLAGS_NOTIFY_COMP(netbuf)) + if (peer && qdf_nbuf_tx_notify_comp_get(netbuf)) dp_tx_notify_completion(soc, peer->vdev, desc, netbuf, ts.status); diff --git a/qdf/inc/i_qdf_nbuf_api_m.h b/qdf/inc/i_qdf_nbuf_api_m.h index 843d313d68..3fad9424b4 100644 --- a/qdf/inc/i_qdf_nbuf_api_m.h +++ b/qdf/inc/i_qdf_nbuf_api_m.h @@ -55,6 +55,16 @@ static inline void qdf_nbuf_ipa_priv_set(qdf_nbuf_t buf, uint32_t priv) __qdf_nbuf_ipa_priv_set(buf, priv); } +static inline void qdf_nbuf_tx_notify_comp_set(qdf_nbuf_t buf, uint8_t val) +{ + QDF_NBUF_CB_TX_EXTRA_FRAG_FLAGS_NOTIFY_COMP(buf) = val; +} + +static inline uint8_t qdf_nbuf_tx_notify_comp_get(qdf_nbuf_t buf) +{ + return QDF_NBUF_CB_TX_EXTRA_FRAG_FLAGS_NOTIFY_COMP(buf); +} + /** * qdf_nbuf_set_rx_protocol_tag() * @buf: Network buffer diff --git a/qdf/inc/i_qdf_nbuf_api_w.h b/qdf/inc/i_qdf_nbuf_api_w.h index 34b82ff7fc..58bf508019 100644 --- a/qdf/inc/i_qdf_nbuf_api_w.h +++ b/qdf/inc/i_qdf_nbuf_api_w.h @@ -155,4 +155,14 @@ static inline void qdf_nbuf_set_rx_reo_dest_ind(qdf_nbuf_t buf, uint8_t value) { } + +static inline void qdf_nbuf_tx_notify_comp_set(qdf_nbuf_t buf, uint8_t val) +{ +} + +static inline uint8_t qdf_nbuf_tx_notify_comp_get(qdf_nbuf_t buf) +{ + return 0; +} + #endif /* _QDF_NBUF_W_H */ diff --git a/qdf/linux/src/i_qdf_nbuf.h b/qdf/linux/src/i_qdf_nbuf.h index ecc543357a..6d09704a76 100644 --- a/qdf/linux/src/i_qdf_nbuf.h +++ b/qdf/linux/src/i_qdf_nbuf.h @@ -305,7 +305,9 @@ struct qdf_nbuf_cb { uint8_t bi_map:1, reserved:7; } dma_option; - uint8_t reserved[3]; + uint8_t flag_notify_comp:1, + rsvd:7; + uint8_t reserved[2]; } priv_cb_m; } dev; uint8_t ftype; @@ -320,7 +322,7 @@ struct qdf_nbuf_cb { flag_chfrag_cont:1, flag_chfrag_end:1, flag_ext_header:1, - flag_notify_comp:1; + reserved:1; } bits; uint8_t u8; } flags; @@ -465,8 +467,6 @@ QDF_COMPILE_TIME_ASSERT(qdf_nbuf_cb_size, ((skb)->cb))->u.tx.flags.bits.flag_nbuf) #define QDF_NBUF_CB_TX_NUM_EXTRA_FRAGS(skb) \ (((struct qdf_nbuf_cb *)((skb)->cb))->u.tx.flags.bits.num) -#define QDF_NBUF_CB_TX_EXTRA_FRAG_FLAGS_NOTIFY_COMP(skb) \ - (((struct qdf_nbuf_cb *)((skb)->cb))->u.tx.flags.bits.flag_notify_comp) #define QDF_NBUF_CB_TX_EXTRA_FRAG_FLAGS_CHFRAG_START(skb) \ (((struct qdf_nbuf_cb *) \ ((skb)->cb))->u.tx.flags.bits.flag_chfrag_start) diff --git a/qdf/linux/src/i_qdf_nbuf_m.h b/qdf/linux/src/i_qdf_nbuf_m.h index a29a04ade1..5cafb1397e 100644 --- a/qdf/linux/src/i_qdf_nbuf_m.h +++ b/qdf/linux/src/i_qdf_nbuf_m.h @@ -45,6 +45,9 @@ #define QDF_NBUF_CB_TX_DMA_BI_MAP(skb) \ (((struct qdf_nbuf_cb *)((skb)->cb))->u.tx.dev.priv_cb_m. \ dma_option.bi_map) +#define QDF_NBUF_CB_TX_EXTRA_FRAG_FLAGS_NOTIFY_COMP(skb) \ + (((struct qdf_nbuf_cb *)((skb)->cb))->u.tx.dev.priv_cb_m. \ + flag_notify_comp) #define QDF_NBUF_CB_RX_PEER_ID(skb) \ (((struct qdf_nbuf_cb *)((skb)->cb))->u.rx.dev.priv_cb_m.dp. \