summaryrefslogtreecommitdiffstats
path: root/src/vnet/devices/virtio/pci.h
diff options
context:
space:
mode:
authorMohsin Kazmi <sykazmi@cisco.com>2019-05-02 13:54:59 +0200
committerDamjan Marion <dmarion@me.com>2019-05-27 11:40:38 +0000
commitbbd6b746e09cc4ae4239173081d95349e0263759 (patch)
treeb49f623111f0bb5680a25ee1560c2a9c6a1b73d5 /src/vnet/devices/virtio/pci.h
parent423fbb1deaed9db9eb662d4b7407fb7274cb8e90 (diff)
virtio: Add gso support for native virtio driver
Change-Id: I7b735f5a540e8c278bac88245acb3f8c041c49c0 Signed-off-by: Mohsin Kazmi <sykazmi@cisco.com>
Diffstat (limited to 'src/vnet/devices/virtio/pci.h')
-rw-r--r--src/vnet/devices/virtio/pci.h13
1 files changed, 13 insertions, 0 deletions
diff --git a/src/vnet/devices/virtio/pci.h b/src/vnet/devices/virtio/pci.h
index dcf9b146463..b1e29162108 100644
--- a/src/vnet/devices/virtio/pci.h
+++ b/src/vnet/devices/virtio/pci.h
@@ -101,10 +101,22 @@ typedef enum
* at the end of the used ring. Guest should ignore the used->flags field. */ \
_ (VHOST_USER_F_PROTOCOL_FEATURES, 30)
+#define VIRTIO_NET_F_CTRL_GUEST_OFFLOADS 2
#define VIRTIO_NET_F_MTU 3
#define VIRTIO_NET_S_LINK_UP 1 /* Link is up */
#define VIRTIO_NET_S_ANNOUNCE 2 /* Announcement is needed */
+/*
+ * Control network offloads
+ * Reconfigures the network offloads that Guest can handle.
+ * Available with the VIRTIO_NET_F_CTRL_GUEST_OFFLOADS feature bit.
+ * Command data format matches the feature bit mask exactly.
+ * See VIRTIO_NET_F_GUEST_* for the list of offloads
+ * that can be enabled/disabled.
+ */
+#define VIRTIO_NET_CTRL_GUEST_OFFLOADS 5
+#define VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET 0
+
/* Common configuration */
#define VIRTIO_PCI_CAP_COMMON_CFG 1
/* Notifications */
@@ -233,6 +245,7 @@ typedef struct
u8 mac_addr_set;
u8 mac_addr[6];
u64 features;
+ u8 gso_enabled;
clib_error_t *error;
} virtio_pci_create_if_args_t;