Displaying 20 results from an estimated 110 matches for "tx_work".
2019 May 29
2
[PATCH 3/4] vsock/virtio: fix flush of works during the .remove()
...static int virtio_vsock_probe(struct virtio_device *vdev)
> return ret;
> }
>
> +static void virtio_vsock_flush_works(struct virtio_vsock *vsock)
> +{
> + flush_work(&vsock->loopback_work);
> + flush_work(&vsock->rx_work);
> + flush_work(&vsock->tx_work);
> + flush_work(&vsock->event_work);
> + flush_work(&vsock->send_pkt_work);
> +}
> +
> static void virtio_vsock_remove(struct virtio_device *vdev)
> {
> struct virtio_vsock *vsock = vdev->priv;
> @@ -668,12 +677,6 @@ static void virtio_vsock_remove(s...
2019 May 29
2
[PATCH 3/4] vsock/virtio: fix flush of works during the .remove()
...static int virtio_vsock_probe(struct virtio_device *vdev)
> return ret;
> }
>
> +static void virtio_vsock_flush_works(struct virtio_vsock *vsock)
> +{
> + flush_work(&vsock->loopback_work);
> + flush_work(&vsock->rx_work);
> + flush_work(&vsock->tx_work);
> + flush_work(&vsock->event_work);
> + flush_work(&vsock->send_pkt_work);
> +}
> +
> static void virtio_vsock_remove(struct virtio_device *vdev)
> {
> struct virtio_vsock *vsock = vdev->priv;
> @@ -668,12 +677,6 @@ static void virtio_vsock_remove(s...
2015 Dec 10
1
[PATCH v3 2/4] VSOCK: Introduce virtio-vsock.ko
...> +struct virtio_vsock {
> + /* Virtio device */
> + struct virtio_device *vdev;
> + /* Virtio virtqueue */
> + struct virtqueue *vqs[VSOCK_VQ_MAX];
> + /* Wait queue for send pkt */
> + wait_queue_head_t queue_wait;
> + /* Work item to send pkt */
> + struct work_struct tx_work;
> + /* Work item to recv pkt */
> + struct work_struct rx_work;
> + /* Mutex to protect send pkt*/
> + struct mutex tx_lock;
> + /* Mutex to protect recv pkt*/
> + struct mutex rx_lock;
Further down I got confused by what lock was what and exactly what was
being protected. If th...
2015 Dec 10
1
[PATCH v3 2/4] VSOCK: Introduce virtio-vsock.ko
...> +struct virtio_vsock {
> + /* Virtio device */
> + struct virtio_device *vdev;
> + /* Virtio virtqueue */
> + struct virtqueue *vqs[VSOCK_VQ_MAX];
> + /* Wait queue for send pkt */
> + wait_queue_head_t queue_wait;
> + /* Work item to send pkt */
> + struct work_struct tx_work;
> + /* Work item to recv pkt */
> + struct work_struct rx_work;
> + /* Mutex to protect send pkt*/
> + struct mutex tx_lock;
> + /* Mutex to protect recv pkt*/
> + struct mutex rx_lock;
Further down I got confused by what lock was what and exactly what was
being protected. If th...
2019 May 30
2
[PATCH 3/4] vsock/virtio: fix flush of works during the .remove()
...e *vdev)
>>> return ret;
>>> }
>>> +static void virtio_vsock_flush_works(struct virtio_vsock *vsock)
>>> +{
>>> + flush_work(&vsock->loopback_work);
>>> + flush_work(&vsock->rx_work);
>>> + flush_work(&vsock->tx_work);
>>> + flush_work(&vsock->event_work);
>>> + flush_work(&vsock->send_pkt_work);
>>> +}
>>> +
>>> static void virtio_vsock_remove(struct virtio_device *vdev)
>>> {
>>> struct virtio_vsock *vsock = vdev->priv;...
2019 May 30
2
[PATCH 3/4] vsock/virtio: fix flush of works during the .remove()
...e *vdev)
>>> return ret;
>>> }
>>> +static void virtio_vsock_flush_works(struct virtio_vsock *vsock)
>>> +{
>>> + flush_work(&vsock->loopback_work);
>>> + flush_work(&vsock->rx_work);
>>> + flush_work(&vsock->tx_work);
>>> + flush_work(&vsock->event_work);
>>> + flush_work(&vsock->send_pkt_work);
>>> +}
>>> +
>>> static void virtio_vsock_remove(struct virtio_device *vdev)
>>> {
>>> struct virtio_vsock *vsock = vdev->priv;...
2014 Jul 05
0
[RFC V2 4/7] VSOCK: Introduce virtio-vsock.ko
..._vsock_rx_fill(struct virtio_vsock *vsock);
+
+struct virtio_vsock {
+ /* Virtio device */
+ struct virtio_device *vdev;
+ /* Virtio virtqueue */
+ struct virtqueue *vqs[VSOCK_VQ_MAX];
+ /* Wait queue for send pkt */
+ wait_queue_head_t queue_wait;
+ /* Work item to send pkt */
+ struct work_struct tx_work;
+ /* Work item to recv pkt */
+ struct work_struct rx_work;
+ /* Mutex to protect send pkt*/
+ struct mutex tx_lock;
+ /* Mutex to protect recv pkt*/
+ struct mutex rx_lock;
+ /* Number of recv buffers */
+ int rx_buf_nr;
+ /* Number of max recv buffers */
+ int rx_buf_max_nr;
+ /* Used for global...
2015 Dec 09
0
[PATCH v3 2/4] VSOCK: Introduce virtio-vsock.ko
..._vsock_rx_fill(struct virtio_vsock *vsock);
+
+struct virtio_vsock {
+ /* Virtio device */
+ struct virtio_device *vdev;
+ /* Virtio virtqueue */
+ struct virtqueue *vqs[VSOCK_VQ_MAX];
+ /* Wait queue for send pkt */
+ wait_queue_head_t queue_wait;
+ /* Work item to send pkt */
+ struct work_struct tx_work;
+ /* Work item to recv pkt */
+ struct work_struct rx_work;
+ /* Mutex to protect send pkt*/
+ struct mutex tx_lock;
+ /* Mutex to protect recv pkt*/
+ struct mutex rx_lock;
+ /* Number of recv buffers */
+ int rx_buf_nr;
+ /* Number of max recv buffers */
+ int rx_buf_max_nr;
+ /* Used for global...
2019 May 28
0
[PATCH 3/4] vsock/virtio: fix flush of works during the .remove()
...ock/virtio_transport.c
@@ -660,6 +660,15 @@ static int virtio_vsock_probe(struct virtio_device *vdev)
return ret;
}
+static void virtio_vsock_flush_works(struct virtio_vsock *vsock)
+{
+ flush_work(&vsock->loopback_work);
+ flush_work(&vsock->rx_work);
+ flush_work(&vsock->tx_work);
+ flush_work(&vsock->event_work);
+ flush_work(&vsock->send_pkt_work);
+}
+
static void virtio_vsock_remove(struct virtio_device *vdev)
{
struct virtio_vsock *vsock = vdev->priv;
@@ -668,12 +677,6 @@ static void virtio_vsock_remove(struct virtio_device *vdev)
mutex_lock(&am...
2019 Jun 28
0
[PATCH v2 3/3] vsock/virtio: fix flush of works during the .remove()
...+++ b/net/vmw_vsock/virtio_transport.c
@@ -680,12 +680,6 @@ static void virtio_vsock_remove(struct virtio_device *vdev)
rcu_assign_pointer(the_virtio_vsock, NULL);
synchronize_rcu();
- flush_work(&vsock->loopback_work);
- flush_work(&vsock->rx_work);
- flush_work(&vsock->tx_work);
- flush_work(&vsock->event_work);
- flush_work(&vsock->send_pkt_work);
-
/* Reset all connected sockets when the device disappear */
vsock_for_each_connected_socket(virtio_vsock_reset_sock);
@@ -740,6 +734,15 @@ static void virtio_vsock_remove(struct virtio_device *vdev)
/*...
2019 Jul 05
0
[PATCH v3 3/3] vsock/virtio: fix flush of works during the .remove()
...+++ b/net/vmw_vsock/virtio_transport.c
@@ -681,12 +681,6 @@ static void virtio_vsock_remove(struct virtio_device *vdev)
rcu_assign_pointer(the_virtio_vsock, NULL);
synchronize_rcu();
- flush_work(&vsock->loopback_work);
- flush_work(&vsock->rx_work);
- flush_work(&vsock->tx_work);
- flush_work(&vsock->event_work);
- flush_work(&vsock->send_pkt_work);
-
/* Reset all connected sockets when the device disappear */
vsock_for_each_connected_socket(virtio_vsock_reset_sock);
@@ -741,6 +735,15 @@ static void virtio_vsock_remove(struct virtio_device *vdev)
/*...
2019 May 28
8
[PATCH 0/4] vsock/virtio: several fixes in the .probe() and .remove()
During the review of "[PATCH] vsock/virtio: Initialize core virtio vsock
before registering the driver", Stefan pointed out some possible issues
in the .probe() and .remove() callbacks of the virtio-vsock driver.
This series tries to solve these issues:
- Patch 1 postpones the 'the_virtio_vsock' assignment at the end of the
.probe() to avoid that some sockets queue works when
2019 May 28
8
[PATCH 0/4] vsock/virtio: several fixes in the .probe() and .remove()
During the review of "[PATCH] vsock/virtio: Initialize core virtio vsock
before registering the driver", Stefan pointed out some possible issues
in the .probe() and .remove() callbacks of the virtio-vsock driver.
This series tries to solve these issues:
- Patch 1 postpones the 'the_virtio_vsock' assignment at the end of the
.probe() to avoid that some sockets queue works when
2019 May 29
0
[PATCH 3/4] vsock/virtio: fix flush of works during the .remove()
...obe(struct virtio_device *vdev)
> > return ret;
> > }
> > +static void virtio_vsock_flush_works(struct virtio_vsock *vsock)
> > +{
> > + flush_work(&vsock->loopback_work);
> > + flush_work(&vsock->rx_work);
> > + flush_work(&vsock->tx_work);
> > + flush_work(&vsock->event_work);
> > + flush_work(&vsock->send_pkt_work);
> > +}
> > +
> > static void virtio_vsock_remove(struct virtio_device *vdev)
> > {
> > struct virtio_vsock *vsock = vdev->priv;
> > @@ -668,12 +67...
2018 Jul 02
2
[PATCH vhost] vhost_net: Fix too many vring kick on busypoll
...usypoll
>> can run unexpectedly long.
>
> I think the total amount of time for busy polling is bounded. If I was
> wrong, it should be a bug somewhere.
Consider this kind of scenario:
0. Set 100us busypoll for example.
1. handle_tx() runs busypoll.
2. Something like zerocopy queues tx_work within 100us.
3. busypoll exits and call handle_tx() again.
4. Repeat 1-3.
In this case handle_tx() does not process packets but busypoll
essentially runs beyond 100us without endtime memorized. This may be
just a theoretical problem, but I was worried that more code to poll tx
queue can be added...
2018 Jul 02
2
[PATCH vhost] vhost_net: Fix too many vring kick on busypoll
...usypoll
>> can run unexpectedly long.
>
> I think the total amount of time for busy polling is bounded. If I was
> wrong, it should be a bug somewhere.
Consider this kind of scenario:
0. Set 100us busypoll for example.
1. handle_tx() runs busypoll.
2. Something like zerocopy queues tx_work within 100us.
3. busypoll exits and call handle_tx() again.
4. Repeat 1-3.
In this case handle_tx() does not process packets but busypoll
essentially runs beyond 100us without endtime memorized. This may be
just a theoretical problem, but I was worried that more code to poll tx
queue can be added...
2019 May 30
0
[PATCH 3/4] vsock/virtio: fix flush of works during the .remove()
...> > > }
> > > > +static void virtio_vsock_flush_works(struct virtio_vsock *vsock)
> > > > +{
> > > > + flush_work(&vsock->loopback_work);
> > > > + flush_work(&vsock->rx_work);
> > > > + flush_work(&vsock->tx_work);
> > > > + flush_work(&vsock->event_work);
> > > > + flush_work(&vsock->send_pkt_work);
> > > > +}
> > > > +
> > > > static void virtio_vsock_remove(struct virtio_device *vdev)
> > > > {
> > > >...
2019 Sep 25
2
[PATCH v2 03/27] drm/dp_mst: Destroy MSTBs asynchronously
...mutex_unlock(&mgr->lock);
> flush_work(&mgr->work);
> - flush_work(&mgr->destroy_connector_work);
> + flush_work(&mgr->delayed_destroy_work);
> }
> EXPORT_SYMBOL(drm_dp_mst_topology_mgr_suspend);
>
> @@ -3740,34 +3723,104 @@ static void drm_dp_tx_work(struct work_struct *work)
> mutex_unlock(&mgr->qlock);
> }
>
> -static void drm_dp_destroy_connector_work(struct work_struct *work)
> +static inline void
> +drm_dp_delayed_destroy_port(struct drm_dp_mst_port *port)
> {
> - struct drm_dp_mst_topology_mgr *mgr = c...
2018 Jul 02
2
[PATCH vhost] vhost_net: Fix too many vring kick on busypoll
...gt;>> I think the total amount of time for busy polling is bounded. If I was
>>> wrong, it should be a bug somewhere.
>> Consider this kind of scenario:
>> 0. Set 100us busypoll for example.
>> 1. handle_tx() runs busypoll.
>> 2. Something like zerocopy queues tx_work within 100us.
>> 3. busypoll exits and call handle_tx() again.
>> 4. Repeat 1-3.
>>
>> In this case handle_tx() does not process packets but busypoll
>> essentially runs beyond 100us without endtime memorized. This may be
>> just a theoretical problem, but I was...
2018 Jul 02
2
[PATCH vhost] vhost_net: Fix too many vring kick on busypoll
...gt;>> I think the total amount of time for busy polling is bounded. If I was
>>> wrong, it should be a bug somewhere.
>> Consider this kind of scenario:
>> 0. Set 100us busypoll for example.
>> 1. handle_tx() runs busypoll.
>> 2. Something like zerocopy queues tx_work within 100us.
>> 3. busypoll exits and call handle_tx() again.
>> 4. Repeat 1-3.
>>
>> In this case handle_tx() does not process packets but busypoll
>> essentially runs beyond 100us without endtime memorized. This may be
>> just a theoretical problem, but I was...