search for: _remove_vq_common

Displaying 20 results from an estimated 22 matches for "_remove_vq_common".

Did you mean: remove_vq_common
2019 Nov 22
2
[PATCH net-next v2] drivers: net: virtio_net: Implement a dev_watchdog handler
...me = virtnet_get_phys_port_name, .ndo_set_features = virtnet_set_features, + .ndo_tx_timeout = virtnet_tx_timeout, }; static void virtnet_config_changed_work(struct work_struct *work) @@ -2982,6 +3017,62 @@ static int virtnet_validate(struct virtio_device *vdev) return 0; } +static void _remove_vq_common(struct virtnet_info *vi) +{ + vi->vdev->config->reset(vi->vdev); + + /* Free unused buffers in both send and recv, if any. */ + free_unused_bufs(vi); + + _free_receive_bufs(vi); + + free_receive_page_frags(vi); + + virtnet_del_vqs(vi); +} + +static int _virtnet_reset(struct virtnet_info...
2019 Nov 22
2
[PATCH net-next v2] drivers: net: virtio_net: Implement a dev_watchdog handler
...me = virtnet_get_phys_port_name, .ndo_set_features = virtnet_set_features, + .ndo_tx_timeout = virtnet_tx_timeout, }; static void virtnet_config_changed_work(struct work_struct *work) @@ -2982,6 +3017,62 @@ static int virtnet_validate(struct virtio_device *vdev) return 0; } +static void _remove_vq_common(struct virtnet_info *vi) +{ + vi->vdev->config->reset(vi->vdev); + + /* Free unused buffers in both send and recv, if any. */ + free_unused_bufs(vi); + + _free_receive_bufs(vi); + + free_receive_page_frags(vi); + + virtnet_del_vqs(vi); +} + +static int _virtnet_reset(struct virtnet_info...
2017 Mar 29
1
[PATCH net-next] virtio_net: don't reset twice on XDP on/off
...1 deletion(-) diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c index de42e9a..ed8f548 100644 --- a/drivers/net/virtio_net.c +++ b/drivers/net/virtio_net.c @@ -1810,7 +1810,6 @@ static int virtnet_reset(struct virtnet_info *vi, int curr_qp, int xdp_qp) virtnet_freeze_down(dev); _remove_vq_common(vi); - dev->config->reset(dev); virtio_add_status(dev, VIRTIO_CONFIG_S_ACKNOWLEDGE); virtio_add_status(dev, VIRTIO_CONFIG_S_DRIVER); -- MST
2017 Mar 29
1
[PATCH net-next] virtio_net: don't reset twice on XDP on/off
...1 deletion(-) diff --git a/drivers/net/virtio_net.c b/drivers/net/virtio_net.c index de42e9a..ed8f548 100644 --- a/drivers/net/virtio_net.c +++ b/drivers/net/virtio_net.c @@ -1810,7 +1810,6 @@ static int virtnet_reset(struct virtnet_info *vi, int curr_qp, int xdp_qp) virtnet_freeze_down(dev); _remove_vq_common(vi); - dev->config->reset(dev); virtio_add_status(dev, VIRTIO_CONFIG_S_ACKNOWLEDGE); virtio_add_status(dev, VIRTIO_CONFIG_S_DRIVER); -- MST
2017 Jul 18
1
[PATCH net-next 4/5] virtio-net: do not reset during XDP set
...g, 1, buf, ctx, gfp); > if (err < 0) > put_page(virt_to_head_page(buf)); > - > return err; > } > > @@ -1834,7 +1861,6 @@ static void virtnet_freeze_down(struct virtio_device *vdev) > } > > static int init_vqs(struct virtnet_info *vi); > -static void _remove_vq_common(struct virtnet_info *vi); > > static int virtnet_restore_up(struct virtio_device *vdev) > { > @@ -1863,39 +1889,6 @@ static int virtnet_restore_up(struct virtio_device *vdev) > return err; > } > > -static int virtnet_reset(struct virtnet_info *vi, int curr_qp, int x...
2017 Jul 18
1
[PATCH net-next 4/5] virtio-net: do not reset during XDP set
...g, 1, buf, ctx, gfp); > if (err < 0) > put_page(virt_to_head_page(buf)); > - > return err; > } > > @@ -1834,7 +1861,6 @@ static void virtnet_freeze_down(struct virtio_device *vdev) > } > > static int init_vqs(struct virtnet_info *vi); > -static void _remove_vq_common(struct virtnet_info *vi); > > static int virtnet_restore_up(struct virtio_device *vdev) > { > @@ -1863,39 +1889,6 @@ static int virtnet_restore_up(struct virtio_device *vdev) > return err; > } > > -static int virtnet_reset(struct virtnet_info *vi, int curr_qp, int x...
2017 Jul 17
0
[PATCH net-next 4/5] virtio-net: do not reset during XDP set
...rq, err = virtqueue_add_inbuf_ctx(rq->vq, rq->sg, 1, buf, ctx, gfp); if (err < 0) put_page(virt_to_head_page(buf)); - return err; } @@ -1834,7 +1861,6 @@ static void virtnet_freeze_down(struct virtio_device *vdev) } static int init_vqs(struct virtnet_info *vi); -static void _remove_vq_common(struct virtnet_info *vi); static int virtnet_restore_up(struct virtio_device *vdev) { @@ -1863,39 +1889,6 @@ static int virtnet_restore_up(struct virtio_device *vdev) return err; } -static int virtnet_reset(struct virtnet_info *vi, int curr_qp, int xdp_qp) -{ - struct virtio_device *dev =...
2019 Nov 26
0
[net-next V3 2/2] drivers: net: virtio_net: Implement a dev_watchdog handler
...rtnet_get_phys_port_name, .ndo_set_features = virtnet_set_features, + .ndo_tx_timeout = virtnet_tx_timeout, }; static void virtnet_config_changed_work(struct work_struct *work) @@ -2982,6 +3005,62 @@ static int virtnet_validate(struct virtio_device *vdev) return 0; } +static void _remove_vq_common(struct virtnet_info *vi) +{ + vi->vdev->config->reset(vi->vdev); + + /* Free unused buffers in both send and recv, if any. */ + free_unused_bufs(vi); + + _free_receive_bufs(vi); + + free_receive_page_frags(vi); + + virtnet_del_vqs(vi); +} + +static int _virtnet_reset(struct virtnet_info...
2019 Nov 22
0
[PATCH] drivers: net: virtio_net: Implement a dev_watchdog handler
...me = virtnet_get_phys_port_name, .ndo_set_features = virtnet_set_features, + .ndo_tx_timeout = virtnet_tx_timeout, }; static void virtnet_config_changed_work(struct work_struct *work) @@ -2982,6 +3017,62 @@ static int virtnet_validate(struct virtio_device *vdev) return 0; } +static void _remove_vq_common(struct virtnet_info *vi) +{ + vi->vdev->config->reset(vi->vdev); + + /* Free unused buffers in both send and recv, if any. */ + free_unused_bufs(vi); + + _free_receive_bufs(vi); + + free_receive_page_frags(vi); + + virtnet_del_vqs(vi); +} + +static int _virtnet_reset(struct virtnet_info...
2019 Nov 22
0
[PATCH net-next v2] drivers: net: virtio_net: Implement a dev_watchdog handler
...eatures = virtnet_set_features, > + .ndo_tx_timeout = virtnet_tx_timeout, > }; > > static void virtnet_config_changed_work(struct work_struct *work) > @@ -2982,6 +3017,62 @@ static int virtnet_validate(struct virtio_device *vdev) > return 0; > } > > +static void _remove_vq_common(struct virtnet_info *vi) > +{ > + vi->vdev->config->reset(vi->vdev); > + > + /* Free unused buffers in both send and recv, if any. */ > + free_unused_bufs(vi); > + > + _free_receive_bufs(vi); > + > + free_receive_page_frags(vi); > + > + virtnet_del_vqs(v...
2017 Jul 17
13
[PATCH net-next 0/5] refine virtio-net XDP
Hi: This series brings two optimizations for virtio-net XDP: - avoid reset during XDP set - turn off offloads on demand Please review. Thanks Jason Wang (5): virtio_ring: allow to store zero as the ctx virtio-net: pack headroom into ctx for mergeable buffer virtio-net: switch to use new ctx API for small buffer virtio-net: do not reset during XDP set virtio-net: switch off offloads
2017 Jul 17
13
[PATCH net-next 0/5] refine virtio-net XDP
Hi: This series brings two optimizations for virtio-net XDP: - avoid reset during XDP set - turn off offloads on demand Please review. Thanks Jason Wang (5): virtio_ring: allow to store zero as the ctx virtio-net: pack headroom into ctx for mergeable buffer virtio-net: switch to use new ctx API for small buffer virtio-net: do not reset during XDP set virtio-net: switch off offloads
2017 Jul 19
9
[PATCH net-next V2 0/5] Refine virtio-net XDP
Hi: This series brings two optimizations for virtio-net XDP: - avoid reset during XDP set - turn off offloads on demand Changes from V1: - Various tweaks on commit logs and comments - Use virtnet_napi_enable() when enabling NAPI on XDP set - Copy the small buffer packet only if xdp_headroom is smaller than required Please review. Thanks Jason Wang (5): virtio_ring: allow to store zero as
2017 Jul 19
9
[PATCH net-next V2 0/5] Refine virtio-net XDP
Hi: This series brings two optimizations for virtio-net XDP: - avoid reset during XDP set - turn off offloads on demand Changes from V1: - Various tweaks on commit logs and comments - Use virtnet_napi_enable() when enabling NAPI on XDP set - Copy the small buffer packet only if xdp_headroom is smaller than required Please review. Thanks Jason Wang (5): virtio_ring: allow to store zero as
2017 Feb 15
3
[PATCH net-next] virito-net: set queues after reset during xdp_set
We set queues before reset which will cause a crash[1]. This is because is_xdp_raw_buffer_queue() depends on the old xdp queue pairs number to do the correct detection. So fix this by: - set queues after reset, to keep the old vi->curr_queue_pairs. (in fact setting queues before reset does not works since after feature set, all queue pairs were enabled by default during reset). - change
2017 Feb 15
3
[PATCH net-next] virito-net: set queues after reset during xdp_set
We set queues before reset which will cause a crash[1]. This is because is_xdp_raw_buffer_queue() depends on the old xdp queue pairs number to do the correct detection. So fix this by: - set queues after reset, to keep the old vi->curr_queue_pairs. (in fact setting queues before reset does not works since after feature set, all queue pairs were enabled by default during reset). - change
2019 Nov 22
0
[PATCH net-next v2] drivers: net: virtio_net: Implement a dev_watchdog handler
...t; > > }; > > > > > > static void virtnet_config_changed_work(struct work_struct *work) > > > @@ -2982,6 +3017,62 @@ static int virtnet_validate(struct virtio_device *vdev) > > > return 0; > > > } > > > > > > +static void _remove_vq_common(struct virtnet_info *vi) > > > +{ > > > + vi->vdev->config->reset(vi->vdev); > > > + > > > + /* Free unused buffers in both send and recv, if any. */ > > > + free_unused_bufs(vi); > > > + > > > + _free_receiv...
2019 Nov 23
1
[PATCH net-next v2] drivers: net: virtio_net: Implement a dev_watchdog handler
...; > > > > static void virtnet_config_changed_work(struct work_struct *work) > > > > @@ -2982,6 +3017,62 @@ static int virtnet_validate(struct virtio_device *vdev) > > > > return 0; > > > > } > > > > > > > > +static void _remove_vq_common(struct virtnet_info *vi) > > > > +{ > > > > + vi->vdev->config->reset(vi->vdev); > > > > + > > > > + /* Free unused buffers in both send and recv, if any. */ > > > > + free_unused_bufs(vi); > > > > + &gt...
2019 Nov 22
4
[PATCH net-next v2] drivers: net: virtio_net: Implement a dev_watchdog handler
...timeout = virtnet_tx_timeout, > > }; > > > > static void virtnet_config_changed_work(struct work_struct *work) > > @@ -2982,6 +3017,62 @@ static int virtnet_validate(struct virtio_device *vdev) > > return 0; > > } > > > > +static void _remove_vq_common(struct virtnet_info *vi) > > +{ > > + vi->vdev->config->reset(vi->vdev); > > + > > + /* Free unused buffers in both send and recv, if any. */ > > + free_unused_bufs(vi); > > + > > + _free_receive_bufs(vi); > > + > > +...
2019 Nov 22
4
[PATCH net-next v2] drivers: net: virtio_net: Implement a dev_watchdog handler
...timeout = virtnet_tx_timeout, > > }; > > > > static void virtnet_config_changed_work(struct work_struct *work) > > @@ -2982,6 +3017,62 @@ static int virtnet_validate(struct virtio_device *vdev) > > return 0; > > } > > > > +static void _remove_vq_common(struct virtnet_info *vi) > > +{ > > + vi->vdev->config->reset(vi->vdev); > > + > > + /* Free unused buffers in both send and recv, if any. */ > > + free_unused_bufs(vi); > > + > > + _free_receive_bufs(vi); > > + > > +...