From a6758b25d25089a65944dece669bd4ef6927f876 Mon Sep 17 00:00:00 2001 From: Jinwei Chen Date: Fri, 5 Jun 2020 23:09:20 +0800 Subject: [PATCH] qcacld-3.0: Bypass FISA for RX DHCP frame DHCP frame usually can not be aggregated, but if they go to FISA path which will require FISA resource support for them, this looks is not necessary. Bypass FISA path for RX DHCP frame. Change-Id: Ic1eac06abb5790813ee4d17ec1df6b215a1bcdb5 CRs-Fixed: 2691447 --- core/dp/txrx3.0/dp_fisa_rx.c | 21 +++++++++++++++++++-- 1 file changed, 19 insertions(+), 2 deletions(-) diff --git a/core/dp/txrx3.0/dp_fisa_rx.c b/core/dp/txrx3.0/dp_fisa_rx.c index b891c6c33de2..77b52763775c 100644 --- a/core/dp/txrx3.0/dp_fisa_rx.c +++ b/core/dp/txrx3.0/dp_fisa_rx.c @@ -1001,6 +1001,22 @@ static int dp_add_nbuf_to_fisa_flow(struct dp_rx_fst *fisa_hdl, return FISA_AGGR_DONE; } +/** + * dp_is_nbuf_bypass_fisa() - FISA bypass check for RX frame + * @nbuf: RX nbuf pointer + * + * Return: true if FISA should be bypassed else false + */ +static bool dp_is_nbuf_bypass_fisa(qdf_nbuf_t nbuf) +{ + /* RX frame from non-regular path or DHCP packet */ + if (qdf_nbuf_is_exc_frame(nbuf) || + qdf_nbuf_is_ipv4_dhcp_pkt(nbuf)) + return true; + + return false; +} + /** * dp_fisa_rx() - Entry function to FISA to handle aggregation * @soc: core txrx main context @@ -1023,8 +1039,9 @@ QDF_STATUS dp_fisa_rx(struct dp_soc *soc, struct dp_vdev *vdev, while (head_nbuf) { next_nbuf = head_nbuf->next; qdf_nbuf_set_next(head_nbuf, NULL); - /* bypass FISA for non-regular RX frame */ - if (qdf_nbuf_is_exc_frame(head_nbuf)) + + /* bypass FISA check */ + if (dp_is_nbuf_bypass_fisa(head_nbuf)) goto deliver_nbuf; qdf_nbuf_push_head(head_nbuf, RX_PKT_TLVS_LEN +