Displaying 20 results from an estimated 39 matches for "virtio_net_ctrl_guest_offloads_set".
2013 Mar 28
3
[PATCH 0/2 V2] virtio-spec: dynamic network offloads configuration
From: Dmitry Fleytman <dfleytma at redhat.com>
V2 changes:
1. _GUEST_ added to command and feature names
2. Live migration logic fixed
Reported-by: Michael S. Tsirkin <mst at redhat.com>
One of recently introduced Windows features (RSC)
requires network driver to be able to enable and disable
HW LRO offload on the fly without device reinitialization.
Current Virtio
2013 Mar 28
3
[PATCH 0/2 V2] virtio-spec: dynamic network offloads configuration
From: Dmitry Fleytman <dfleytma at redhat.com>
V2 changes:
1. _GUEST_ added to command and feature names
2. Live migration logic fixed
Reported-by: Michael S. Tsirkin <mst at redhat.com>
One of recently introduced Windows features (RSC)
requires network driver to be able to enable and disable
HW LRO offload on the fly without device reinitialization.
Current Virtio
2013 Apr 04
3
[PATCH 0/2 V4] virtio-spec/net: dynamic network offloads configuration
From: Dmitry Fleytman <dfleytma at redhat.com>
V4 changes:
1. Feature definitions re-used for command bitmask
2. Command data made uint64
3. Commit messsages fixed
Reported-by: Rusty Russell rusty at rustcorp.com.au
V3 changes:
1. Compat macro added
2. Feature name beautification
V2 changes:
1. _GUEST_ added to command and feature names
2. Live migration logic fixed
2013 Apr 04
3
[PATCH 0/2 V4] virtio-spec/net: dynamic network offloads configuration
From: Dmitry Fleytman <dfleytma at redhat.com>
V4 changes:
1. Feature definitions re-used for command bitmask
2. Command data made uint64
3. Commit messsages fixed
Reported-by: Rusty Russell rusty at rustcorp.com.au
V3 changes:
1. Compat macro added
2. Feature name beautification
V2 changes:
1. _GUEST_ added to command and feature names
2. Live migration logic fixed
2013 Apr 02
3
[PATCH 0/2 V3] virtio-spec/net: dynamic network offloads configuration
From: Dmitry Fleytman <dfleytma at redhat.com>
V3 changes:
1. Compat macro added
2. Feature name beautification
V2 changes:
1. _GUEST_ added to command and feature names
2. Live migration logic fixed
Reported-by: Michael S. Tsirkin <mst at redhat.com>
One of recently introduced Windows features (RSC)
requires network driver to be able to enable and disable
HW LRO offload on
2013 Apr 02
3
[PATCH 0/2 V3] virtio-spec/net: dynamic network offloads configuration
From: Dmitry Fleytman <dfleytma at redhat.com>
V3 changes:
1. Compat macro added
2. Feature name beautification
V2 changes:
1. _GUEST_ added to command and feature names
2. Live migration logic fixed
Reported-by: Michael S. Tsirkin <mst at redhat.com>
One of recently introduced Windows features (RSC)
requires network driver to be able to enable and disable
HW LRO offload on
2017 Jul 18
2
[PATCH net-next 5/5] virtio-net: switch off offloads on demand if possible on XDP set
...offloads)
> +{
> + struct scatterlist sg;
> + vi->ctrl_offloads = cpu_to_virtio64(vi->vdev, offloads);
> +
> + sg_init_one(&sg, &vi->ctrl_offloads, sizeof(vi->ctrl_offloads));
> +
> + if (!virtnet_send_command(vi, VIRTIO_NET_CTRL_GUEST_OFFLOADS,
> + VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET, &sg)) {
> + dev_warn(&vi->dev->dev, "Fail to set guest offload. \n");
> + return -EINVAL;
> + }
> +
> + return 0;
> +}
> +
> +static int virtnet_clear_guest_offloads(struct virtnet_info *vi)
> +{
> + u64 offloads = 0;
> +
> + if (!vi-&g...
2017 Jul 18
2
[PATCH net-next 5/5] virtio-net: switch off offloads on demand if possible on XDP set
...offloads)
> +{
> + struct scatterlist sg;
> + vi->ctrl_offloads = cpu_to_virtio64(vi->vdev, offloads);
> +
> + sg_init_one(&sg, &vi->ctrl_offloads, sizeof(vi->ctrl_offloads));
> +
> + if (!virtnet_send_command(vi, VIRTIO_NET_CTRL_GUEST_OFFLOADS,
> + VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET, &sg)) {
> + dev_warn(&vi->dev->dev, "Fail to set guest offload. \n");
> + return -EINVAL;
> + }
> +
> + return 0;
> +}
> +
> +static int virtnet_clear_guest_offloads(struct virtnet_info *vi)
> +{
> + u64 offloads = 0;
> +
> + if (!vi-&g...
2017 Jul 24
1
[PATCH net-next V2 5/5] virtio-net: switch off offloads on demand if possible on XDP set
...offloads)
> +{
> + struct scatterlist sg;
> + vi->ctrl_offloads = cpu_to_virtio64(vi->vdev, offloads);
> +
> + sg_init_one(&sg, &vi->ctrl_offloads, sizeof(vi->ctrl_offloads));
> +
> + if (!virtnet_send_command(vi, VIRTIO_NET_CTRL_GUEST_OFFLOADS,
> + VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET, &sg)) {
> + dev_warn(&vi->dev->dev, "Fail to set guest offload. \n");
> + return -EINVAL;
> + }
> +
> + return 0;
> +}
> +
> +static int virtnet_clear_guest_offloads(struct virtnet_info *vi)
> +{
> + u64 offloads = 0;
> +
> + if (!vi-&g...
2017 Jul 24
1
[PATCH net-next V2 5/5] virtio-net: switch off offloads on demand if possible on XDP set
...offloads)
> +{
> + struct scatterlist sg;
> + vi->ctrl_offloads = cpu_to_virtio64(vi->vdev, offloads);
> +
> + sg_init_one(&sg, &vi->ctrl_offloads, sizeof(vi->ctrl_offloads));
> +
> + if (!virtnet_send_command(vi, VIRTIO_NET_CTRL_GUEST_OFFLOADS,
> + VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET, &sg)) {
> + dev_warn(&vi->dev->dev, "Fail to set guest offload. \n");
> + return -EINVAL;
> + }
> +
> + return 0;
> +}
> +
> +static int virtnet_clear_guest_offloads(struct virtnet_info *vi)
> +{
> + u64 offloads = 0;
> +
> + if (!vi-&g...
2020 Mar 02
2
[PATCH v3 2/3] virtio-net: Introduce RSS receive steering feature
On Mon, Mar 02, 2020 at 10:53:14AM +0200, Yuri Benditovich wrote:
> On Sun, Mar 1, 2020 at 9:58 PM Michael S. Tsirkin <mst at redhat.com> wrote:
> >
> > On Sun, Mar 01, 2020 at 04:33:01PM +0200, Yuri Benditovich wrote:
> > > RSS (Receive-side scaling) defines hash calculation
> > > rules and decision on receive virtqueue according to
> > > the
2020 Mar 02
2
[PATCH v3 2/3] virtio-net: Introduce RSS receive steering feature
On Mon, Mar 02, 2020 at 10:53:14AM +0200, Yuri Benditovich wrote:
> On Sun, Mar 1, 2020 at 9:58 PM Michael S. Tsirkin <mst at redhat.com> wrote:
> >
> > On Sun, Mar 01, 2020 at 04:33:01PM +0200, Yuri Benditovich wrote:
> > > RSS (Receive-side scaling) defines hash calculation
> > > rules and decision on receive virtqueue according to
> > > the
2015 Jun 29
0
[PATCH] virtio_net: document VIRTIO_NET_CTRL_GUEST_OFFLOADS
...an 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
+
#endif /* _LINUX_VIRTIO_NET_H */
--
MST
2019 Apr 03
1
[PATCH] virtio-net: Fix some minor formatting errors
...queue failure: %d\n",
+ qnum, err);
dev->stats.tx_dropped++;
dev_kfree_skb_any(skb);
return NETDEV_TX_OK;
@@ -2383,7 +2384,7 @@ static int virtnet_set_guest_offloads(struct virtnet_info *vi, u64 offloads)
if (!virtnet_send_command(vi, VIRTIO_NET_CTRL_GUEST_OFFLOADS,
VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET, &sg)) {
- dev_warn(&vi->dev->dev, "Fail to set guest offload. \n");
+ dev_warn(&vi->dev->dev, "Fail to set guest offload.\n");
return -EINVAL;
}
@@ -3114,8 +3115,9 @@ static int virtnet_probe(struct virtio_device *vdev)
/* Should never trigg...
2015 Jun 29
0
[PATCH] virtio_net: document VIRTIO_NET_CTRL_GUEST_OFFLOADS
...an 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
+
#endif /* _LINUX_VIRTIO_NET_H */
--
MST
2019 Apr 03
1
[PATCH] virtio-net: Fix some minor formatting errors
...queue failure: %d\n",
+ qnum, err);
dev->stats.tx_dropped++;
dev_kfree_skb_any(skb);
return NETDEV_TX_OK;
@@ -2383,7 +2384,7 @@ static int virtnet_set_guest_offloads(struct virtnet_info *vi, u64 offloads)
if (!virtnet_send_command(vi, VIRTIO_NET_CTRL_GUEST_OFFLOADS,
VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET, &sg)) {
- dev_warn(&vi->dev->dev, "Fail to set guest offload. \n");
+ dev_warn(&vi->dev->dev, "Fail to set guest offload.\n");
return -EINVAL;
}
@@ -3114,8 +3115,9 @@ static int virtnet_probe(struct virtio_device *vdev)
/* Should never trigg...
2018 Apr 19
1
[PATCH v2 net 1/3] virtio_net: split out ctrl buffer
...>offloads = cpu_to_virtio64(vi->vdev, offloads);
- sg_init_one(&sg, &vi->ctrl_offloads, sizeof(vi->ctrl_offloads));
+ sg_init_one(&sg, &vi->ctrl->offloads, sizeof(vi->ctrl->offloads));
if (!virtnet_send_command(vi, VIRTIO_NET_CTRL_GUEST_OFFLOADS,
VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET, &sg)) {
@@ -2351,6 +2355,7 @@ static void virtnet_free_queues(struct virtnet_info *vi)
kfree(vi->rq);
kfree(vi->sq);
+ kfree(vi->ctrl);
}
static void _free_receive_bufs(struct virtnet_info *vi)
@@ -2543,6 +2548,9 @@ static int virtnet_alloc_queues(struct virtnet_info *vi)
{...
2020 Mar 02
0
[PATCH v3 2/3] virtio-net: Introduce RSS receive steering feature
All the classes of commands are defined without indentation.
All the commands are defined with indentation of 1 space.
Only the last one (VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET at the end of
the file) does not have an indentation.
On Mon, Mar 2, 2020 at 12:54 PM Michael S. Tsirkin <mst at redhat.com> wrote:
>
> On Mon, Mar 02, 2020 at 10:53:14AM +0200, Yuri Benditovich wrote:
> > On Sun, Mar 1, 2020 at 9:58 PM Michael S. Tsirkin <mst at redhat.com>...
2017 Jul 17
0
[PATCH net-next 5/5] virtio-net: switch off offloads on demand if possible on XDP set
...st_offloads(struct virtnet_info *vi, u64 offloads)
+{
+ struct scatterlist sg;
+ vi->ctrl_offloads = cpu_to_virtio64(vi->vdev, offloads);
+
+ sg_init_one(&sg, &vi->ctrl_offloads, sizeof(vi->ctrl_offloads));
+
+ if (!virtnet_send_command(vi, VIRTIO_NET_CTRL_GUEST_OFFLOADS,
+ VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET, &sg)) {
+ dev_warn(&vi->dev->dev, "Fail to set guest offload. \n");
+ return -EINVAL;
+ }
+
+ return 0;
+}
+
+static int virtnet_clear_guest_offloads(struct virtnet_info *vi)
+{
+ u64 offloads = 0;
+
+ if (!vi->guest_offloads)
+ return 0;
+
+ if (virtio_has_feature(vi...
2017 Jul 19
0
[PATCH net-next V2 5/5] virtio-net: switch off offloads on demand if possible on XDP set
...st_offloads(struct virtnet_info *vi, u64 offloads)
+{
+ struct scatterlist sg;
+ vi->ctrl_offloads = cpu_to_virtio64(vi->vdev, offloads);
+
+ sg_init_one(&sg, &vi->ctrl_offloads, sizeof(vi->ctrl_offloads));
+
+ if (!virtnet_send_command(vi, VIRTIO_NET_CTRL_GUEST_OFFLOADS,
+ VIRTIO_NET_CTRL_GUEST_OFFLOADS_SET, &sg)) {
+ dev_warn(&vi->dev->dev, "Fail to set guest offload. \n");
+ return -EINVAL;
+ }
+
+ return 0;
+}
+
+static int virtnet_clear_guest_offloads(struct virtnet_info *vi)
+{
+ u64 offloads = 0;
+
+ if (!vi->guest_offloads)
+ return 0;
+
+ if (virtio_has_feature(vi...