MCPcopy Create free account
hub / github.com/F-Stack/f-stack / rte_vhost_get_mtu

Function rte_vhost_get_mtu

dpdk/lib/vhost/vhost.c:862–879  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

860}
861
862int
863rte_vhost_get_mtu(int vid, uint16_t *mtu)
864{
865 struct virtio_net *dev = get_device(vid);
866
867 if (dev == NULL || mtu == NULL)
868 return -ENODEV;
869
870 if (!(dev->flags & VIRTIO_DEV_READY))
871 return -EAGAIN;
872
873 if (!(dev->features & (1ULL << VIRTIO_NET_F_MTU)))
874 return -ENOTSUP;
875
876 *mtu = dev->mtu;
877
878 return 0;
879}
880
881int
882rte_vhost_get_numa_node(int vid)

Callers 2

new_deviceFunction · 0.85
mlx5_vdpa_mtu_setFunction · 0.85

Calls 1

get_deviceFunction · 0.85

Tested by

no test coverage detected