| 822 | } |
| 823 | |
| 824 | static __rte_always_inline struct virtio_net * |
| 825 | get_device(int vid) |
| 826 | { |
| 827 | struct virtio_net *dev = NULL; |
| 828 | |
| 829 | if (likely(vid >= 0 && vid < RTE_MAX_VHOST_DEVICE)) |
| 830 | dev = vhost_devices[vid]; |
| 831 | |
| 832 | if (unlikely(!dev)) { |
| 833 | VHOST_LOG_CONFIG("device", ERR, "(%d) device not found.\n", vid); |
| 834 | } |
| 835 | |
| 836 | return dev; |
| 837 | } |
| 838 | |
| 839 | int vhost_new_device(struct vhost_backend_ops *ops); |
| 840 | void cleanup_device(struct virtio_net *dev, int destroy); |
no outgoing calls
no test coverage detected