mirror of
https://github.com/breeze303/nss-packages.git
synced 2025-12-16 16:57:29 +00:00
nss-dp: edma-v1: switch to napi_gro_receive
Utilize napi_gro_receive instead of plain netif_receive_skb on EDMA v1. It provides significant performance improvements when testing with iperf3. Signed-off-by: Robert Marko <robimarko@gmail.com>
This commit is contained in:
parent
3395afd07a
commit
76602b9c18
@ -0,0 +1,46 @@
|
||||
From 57b521e876986844dfe34457f39c62dc8100424d Mon Sep 17 00:00:00 2001
|
||||
From: Robert Marko <robimarko@gmail.com>
|
||||
Date: Thu, 23 Jun 2022 14:18:50 +0200
|
||||
Subject: [PATCH] nss-dp: edma-v1: switch to napi_gro_receive
|
||||
|
||||
Utilize napi_gro_receive instead of plain netif_receive_skb on EDMA v1.
|
||||
It provides significant performance improvements when testing with iperf3.
|
||||
|
||||
Signed-off-by: Robert Marko <robimarko@gmail.com>
|
||||
---
|
||||
Makefile | 2 +-
|
||||
hal/dp_ops/edma_dp/edma_v1/edma_tx_rx.c | 4 ++++
|
||||
2 files changed, 5 insertions(+), 1 deletion(-)
|
||||
|
||||
diff --git a/Makefile b/Makefile
|
||||
index 8e81317..dcfa8ca 100644
|
||||
--- a/Makefile
|
||||
+++ b/Makefile
|
||||
@@ -25,7 +25,7 @@ qca-nss-dp-objs += hal/dp_ops/edma_dp/edma_v1/edma_cfg.o \
|
||||
hal/gmac_ops/qcom/qcom_if.o \
|
||||
hal/gmac_ops/syn/xgmac/syn_if.o
|
||||
NSS_DP_INCLUDE += -I$(obj)/hal/dp_ops/edma_dp/edma_v1/include
|
||||
-ccflags-y += -DNSS_DP_PPE_SUPPORT
|
||||
+ccflags-y += -DNSS_DP_PPE_SUPPORT -DNSS_DP_ENABLE_NAPI_GRO
|
||||
endif
|
||||
|
||||
ifeq ($(SoC),$(filter $(SoC),ipq807x))
|
||||
diff --git a/hal/dp_ops/edma_dp/edma_v1/edma_tx_rx.c b/hal/dp_ops/edma_dp/edma_v1/edma_tx_rx.c
|
||||
index 5780a30..6ee1451 100644
|
||||
--- a/hal/dp_ops/edma_dp/edma_v1/edma_tx_rx.c
|
||||
+++ b/hal/dp_ops/edma_dp/edma_v1/edma_tx_rx.c
|
||||
@@ -411,7 +411,11 @@ static uint32_t edma_clean_rx(struct edma_hw *ehw,
|
||||
NSS_PTP_EVENT_SERVICE_CODE))
|
||||
nss_phy_tstamp_rx_buf(ndev, skb);
|
||||
else
|
||||
+#if defined(NSS_DP_ENABLE_NAPI_GRO)
|
||||
+ napi_gro_receive(&ehw->napi, skb);
|
||||
+#else
|
||||
netif_receive_skb(skb);
|
||||
+#endif
|
||||
|
||||
next_rx_desc:
|
||||
/*
|
||||
--
|
||||
2.36.1
|
||||
|
||||
Loading…
Reference in New Issue
Block a user