[v2,26/32] net/sssnic: support dev MTU set

Message ID 20230831095650.219964-27-wanry@3snic.com (mailing list archive)
State Superseded, archived
Delegated to: Thomas Monjalon
Headers
Series Introduce sssnic PMD for 3SNIC's 9x0 serials Ethernet adapters |

Checks

Context Check Description
ci/checkpatch warning coding style issues

Commit Message

Renyong Wan Aug. 31, 2023, 9:56 a.m. UTC
  From: Renyong Wan <wanry@3snic.com>

Signed-off-by: Steven Song <steven.song@3snic.com>
Signed-off-by: Renyong Wan <wanry@3snic.com>
---
 drivers/net/sssnic/sssnic_ethdev.c | 7 +++++++
 1 file changed, 7 insertions(+)
  

Patch

diff --git a/drivers/net/sssnic/sssnic_ethdev.c b/drivers/net/sssnic/sssnic_ethdev.c
index a00e96bebe..b086e91d2d 100644
--- a/drivers/net/sssnic/sssnic_ethdev.c
+++ b/drivers/net/sssnic/sssnic_ethdev.c
@@ -733,6 +733,12 @@  sssnic_ethdev_promiscuous_disable(struct rte_eth_dev *ethdev)
 	return 0;
 }
 
+static int
+sssnic_ethdev_mtu_set(struct rte_eth_dev *ethdev, uint16_t mtu)
+{
+	return sssnic_ethdev_tx_max_size_set(ethdev, mtu);
+}
+
 static const struct eth_dev_ops sssnic_ethdev_ops = {
 	.dev_start = sssnic_ethdev_start,
 	.dev_stop = sssnic_ethdev_stop,
@@ -770,6 +776,7 @@  static const struct eth_dev_ops sssnic_ethdev_ops = {
 	.rss_hash_update = sssnic_ethdev_rss_hash_update,
 	.reta_update = sssnic_ethdev_rss_reta_update,
 	.reta_query = sssnic_ethdev_rss_reta_query,
+	.mtu_set = sssnic_ethdev_mtu_set,
 };
 
 static int