diff mbox series

[1/2] net/netvsc: remove unused code

Message ID 20201123221918.20825-2-stephen@networkplumber.org (mailing list archive)
State Changes Requested
Delegated to: Ferruh Yigit
Headers show
Series net/netvsc: fix supported_ptypes | expand

Checks

Context Check Description
ci/checkpatch success coding style OK

Commit Message

Stephen Hemminger Nov. 23, 2020, 10:19 p.m. UTC
This code is not called anywhere.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 drivers/net/netvsc/hn_rndis.c | 31 -------------------------------
 drivers/net/netvsc/hn_rndis.h |  1 -
 2 files changed, 32 deletions(-)
diff mbox series

Patch

diff --git a/drivers/net/netvsc/hn_rndis.c b/drivers/net/netvsc/hn_rndis.c
index 1ce260c89b95..beb716f3c96c 100644
--- a/drivers/net/netvsc/hn_rndis.c
+++ b/drivers/net/netvsc/hn_rndis.c
@@ -946,37 +946,6 @@  int hn_rndis_get_offload(struct hn_data *hv,
 	return 0;
 }
 
-uint32_t
-hn_rndis_get_ptypes(struct hn_data *hv)
-{
-	struct ndis_offload hwcaps;
-	uint32_t ptypes;
-	int error;
-
-	memset(&hwcaps, 0, sizeof(hwcaps));
-
-	error = hn_rndis_query_hwcaps(hv, &hwcaps);
-	if (error) {
-		PMD_DRV_LOG(ERR, "hwcaps query failed: %d", error);
-		return RTE_PTYPE_L2_ETHER;
-	}
-
-	ptypes = RTE_PTYPE_L2_ETHER;
-
-	if (hwcaps.ndis_csum.ndis_ip4_rxcsum & NDIS_RXCSUM_CAP_IP4)
-		ptypes |= RTE_PTYPE_L3_IPV4;
-
-	if ((hwcaps.ndis_csum.ndis_ip4_rxcsum & NDIS_RXCSUM_CAP_TCP4) ||
-	    (hwcaps.ndis_csum.ndis_ip6_rxcsum & NDIS_RXCSUM_CAP_TCP6))
-		ptypes |= RTE_PTYPE_L4_TCP;
-
-	if ((hwcaps.ndis_csum.ndis_ip4_rxcsum & NDIS_RXCSUM_CAP_UDP4) ||
-	    (hwcaps.ndis_csum.ndis_ip6_rxcsum & NDIS_RXCSUM_CAP_UDP6))
-		ptypes |= RTE_PTYPE_L4_UDP;
-
-	return ptypes;
-}
-
 int
 hn_rndis_set_rxfilter(struct hn_data *hv, uint32_t filter)
 {
diff --git a/drivers/net/netvsc/hn_rndis.h b/drivers/net/netvsc/hn_rndis.h
index 9a8251fc2fb4..11b89042dd4b 100644
--- a/drivers/net/netvsc/hn_rndis.h
+++ b/drivers/net/netvsc/hn_rndis.h
@@ -25,7 +25,6 @@  int	hn_rndis_query_rsscaps(struct hn_data *hv,
 int	hn_rndis_query_rss(struct hn_data *hv,
 			   struct rte_eth_rss_conf *rss_conf);
 int	hn_rndis_conf_rss(struct hn_data *hv, uint32_t flags);
-uint32_t hn_rndis_get_ptypes(struct hn_data *hv);
 
 #ifdef RTE_LIBRTE_NETVSC_DEBUG_DUMP
 void hn_rndis_dump(const void *buf);