DPDK patches and discussions
 help / color / mirror / Atom feed
* [dpdk-dev] [PATCH] vhost: add event areas to vq_is_ready()
@ 2020-01-25  8:52 Adrian Moreno
  2020-02-05  3:20 ` Tiwei Bie
  2020-02-05  9:48 ` Maxime Coquelin
  0 siblings, 2 replies; 3+ messages in thread
From: Adrian Moreno @ 2020-01-25  8:52 UTC (permalink / raw)
  To: dev; +Cc: Zhihong Wang, Maxime Coquelin, Tiwei Bie, Adrian Moreno, yliu, stable

Consider a virtqueue ready when, apart from the the descriptor area,
both event supression areas have been mapped.

Fixes: 2d1541e2b6b3 ("vhost: add vring address setup for packed queues")
Cc: yliu@fridaylinux.org
Cc: stable@dpdk.org

Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
---
 lib/librte_vhost/vhost_user.c | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/lib/librte_vhost/vhost_user.c b/lib/librte_vhost/vhost_user.c
index 69b84a882..c9cc4d648 100644
--- a/lib/librte_vhost/vhost_user.c
+++ b/lib/librte_vhost/vhost_user.c
@@ -1298,7 +1298,8 @@ vq_is_ready(struct virtio_net *dev, struct vhost_virtqueue *vq)
 		return false;
 
 	if (vq_is_packed(dev))
-		rings_ok = !!vq->desc_packed;
+		rings_ok = vq->desc_packed && vq->driver_event &&
+			vq->device_event;
 	else
 		rings_ok = vq->desc && vq->avail && vq->used;
 
-- 
2.21.1


^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [dpdk-dev] [PATCH] vhost: add event areas to vq_is_ready()
  2020-01-25  8:52 [dpdk-dev] [PATCH] vhost: add event areas to vq_is_ready() Adrian Moreno
@ 2020-02-05  3:20 ` Tiwei Bie
  2020-02-05  9:48 ` Maxime Coquelin
  1 sibling, 0 replies; 3+ messages in thread
From: Tiwei Bie @ 2020-02-05  3:20 UTC (permalink / raw)
  To: Adrian Moreno; +Cc: dev, Zhihong Wang, Maxime Coquelin, yliu, stable

On Sat, Jan 25, 2020 at 09:52:16AM +0100, Adrian Moreno wrote:
> Consider a virtqueue ready when, apart from the the descriptor area,

s/the the/the/

> both event supression areas have been mapped.

s/supression/suppression/

> 
> Fixes: 2d1541e2b6b3 ("vhost: add vring address setup for packed queues")
> Cc: yliu@fridaylinux.org
> Cc: stable@dpdk.org
> 
> Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
> ---
>  lib/librte_vhost/vhost_user.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)

Reviewed-by: Tiwei Bie <tiwei.bie@intel.com>

Thanks,
Tiwei

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [dpdk-dev] [PATCH] vhost: add event areas to vq_is_ready()
  2020-01-25  8:52 [dpdk-dev] [PATCH] vhost: add event areas to vq_is_ready() Adrian Moreno
  2020-02-05  3:20 ` Tiwei Bie
@ 2020-02-05  9:48 ` Maxime Coquelin
  1 sibling, 0 replies; 3+ messages in thread
From: Maxime Coquelin @ 2020-02-05  9:48 UTC (permalink / raw)
  To: Adrian Moreno, dev; +Cc: Zhihong Wang, Tiwei Bie, yliu, stable



On 1/25/20 9:52 AM, Adrian Moreno wrote:
> Consider a virtqueue ready when, apart from the the descriptor area,
> both event supression areas have been mapped.
> 
> Fixes: 2d1541e2b6b3 ("vhost: add vring address setup for packed queues")
> Cc: yliu@fridaylinux.org
> Cc: stable@dpdk.org
> 
> Signed-off-by: Adrian Moreno <amorenoz@redhat.com>
> ---
>  lib/librte_vhost/vhost_user.c | 3 ++-
>  1 file changed, 2 insertions(+), 1 deletion(-)

Applied to dpdk-next-virtio tree.

Thanks,
Maxime


^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2020-02-05  9:48 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2020-01-25  8:52 [dpdk-dev] [PATCH] vhost: add event areas to vq_is_ready() Adrian Moreno
2020-02-05  3:20 ` Tiwei Bie
2020-02-05  9:48 ` Maxime Coquelin

DPDK patches and discussions

This inbox may be cloned and mirrored by anyone:

	git clone --mirror https://inbox.dpdk.org/dev/0 dev/git/0.git

	# If you have public-inbox 1.1+ installed, you may
	# initialize and index your mirror using the following commands:
	public-inbox-init -V2 dev dev/ https://inbox.dpdk.org/dev \
		dev@dpdk.org
	public-inbox-index dev

Example config snippet for mirrors.
Newsgroup available over NNTP:
	nntp://inbox.dpdk.org/inbox.dpdk.dev


AGPL code for this site: git clone https://public-inbox.org/public-inbox.git