* [dpdk-dev] [PATCH] examples/vhost_scsi: drop unimplemented EVENT_IDX feature bit
@ 2018-01-31 17:48 Stefan Hajnoczi
2018-02-01 0:29 ` Liu, Changpeng
2018-02-01 14:47 ` Yuanhan Liu
0 siblings, 2 replies; 4+ messages in thread
From: Stefan Hajnoczi @ 2018-01-31 17:48 UTC (permalink / raw)
To: dev
Cc: Junjie Chen, Yuanhan Liu, Changpeng Liu, Maxime Coquelin,
Stefan Hajnoczi
The vhost_scsi example application negotiates the
VIRTIO_RING_F_EVENT_IDX feature bit but does not honor it when accessing
vrings.
In particular, commit e37ff954405addb8ea422426a2d162d00dcad196 ("vhost:
support virtqueue interrupt/notification suppression") broke vring call
because vq->last_used_idx is never updated by vhost_scsi. The
vq->last_used_idx field is not even available via the librte_vhost
public API, so VIRTIO_RING_F_EVENT_IDX is currently only usable by the
built-in virtio_net.c driver in librte_vhost.
This patch drops VIRTIO_RING_F_EVENT_IDX from vhost_scsi so that vring
call works again.
Cc: Changpeng Liu <changpeng.liu@intel.com>
Cc: Junjie Chen <junjie.j.chen@intel.com>
Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
---
examples/vhost_scsi/vhost_scsi.c | 1 -
1 file changed, 1 deletion(-)
diff --git a/examples/vhost_scsi/vhost_scsi.c b/examples/vhost_scsi/vhost_scsi.c
index da01ad378..3cb4383e9 100644
--- a/examples/vhost_scsi/vhost_scsi.c
+++ b/examples/vhost_scsi/vhost_scsi.c
@@ -21,7 +21,6 @@
#include "scsi_spec.h"
#define VIRTIO_SCSI_FEATURES ((1 << VIRTIO_F_NOTIFY_ON_EMPTY) |\
- (1 << VIRTIO_RING_F_EVENT_IDX) |\
(1 << VIRTIO_SCSI_F_INOUT) |\
(1 << VIRTIO_SCSI_F_CHANGE))
--
2.14.3
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [dpdk-dev] [PATCH] examples/vhost_scsi: drop unimplemented EVENT_IDX feature bit
2018-01-31 17:48 [dpdk-dev] [PATCH] examples/vhost_scsi: drop unimplemented EVENT_IDX feature bit Stefan Hajnoczi
@ 2018-02-01 0:29 ` Liu, Changpeng
2018-02-01 14:47 ` Yuanhan Liu
1 sibling, 0 replies; 4+ messages in thread
From: Liu, Changpeng @ 2018-02-01 0:29 UTC (permalink / raw)
To: Stefan Hajnoczi, dev; +Cc: Chen, Junjie J, Yuanhan Liu, Maxime Coquelin
> -----Original Message-----
> From: Stefan Hajnoczi [mailto:stefanha@redhat.com]
> Sent: Thursday, February 1, 2018 1:48 AM
> To: dev@dpdk.org
> Cc: Chen, Junjie J <junjie.j.chen@intel.com>; Yuanhan Liu <yliu@fridaylinux.org>;
> Liu, Changpeng <changpeng.liu@intel.com>; Maxime Coquelin
> <maxime.coquelin@redhat.com>; Stefan Hajnoczi <stefanha@redhat.com>
> Subject: [PATCH] examples/vhost_scsi: drop unimplemented EVENT_IDX feature
> bit
>
> The vhost_scsi example application negotiates the
> VIRTIO_RING_F_EVENT_IDX feature bit but does not honor it when accessing
> vrings.
>
> In particular, commit e37ff954405addb8ea422426a2d162d00dcad196 ("vhost:
> support virtqueue interrupt/notification suppression") broke vring call
> because vq->last_used_idx is never updated by vhost_scsi. The
> vq->last_used_idx field is not even available via the librte_vhost
> public API, so VIRTIO_RING_F_EVENT_IDX is currently only usable by the
> built-in virtio_net.c driver in librte_vhost.
>
> This patch drops VIRTIO_RING_F_EVENT_IDX from vhost_scsi so that vring
> call works again.
>
> Cc: Changpeng Liu <changpeng.liu@intel.com>
> Cc: Junjie Chen <junjie.j.chen@intel.com>
> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
> ---
> examples/vhost_scsi/vhost_scsi.c | 1 -
> 1 file changed, 1 deletion(-)
Reviewed-by: Changpeng Liu <changpeng.liu@intel.com>
>
> diff --git a/examples/vhost_scsi/vhost_scsi.c b/examples/vhost_scsi/vhost_scsi.c
> index da01ad378..3cb4383e9 100644
> --- a/examples/vhost_scsi/vhost_scsi.c
> +++ b/examples/vhost_scsi/vhost_scsi.c
> @@ -21,7 +21,6 @@
> #include "scsi_spec.h"
>
> #define VIRTIO_SCSI_FEATURES ((1 << VIRTIO_F_NOTIFY_ON_EMPTY) |\
> - (1 << VIRTIO_RING_F_EVENT_IDX) |\
> (1 << VIRTIO_SCSI_F_INOUT) |\
> (1 << VIRTIO_SCSI_F_CHANGE))
>
> --
> 2.14.3
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [dpdk-dev] [PATCH] examples/vhost_scsi: drop unimplemented EVENT_IDX feature bit
2018-01-31 17:48 [dpdk-dev] [PATCH] examples/vhost_scsi: drop unimplemented EVENT_IDX feature bit Stefan Hajnoczi
2018-02-01 0:29 ` Liu, Changpeng
@ 2018-02-01 14:47 ` Yuanhan Liu
2018-02-05 14:21 ` Ferruh Yigit
1 sibling, 1 reply; 4+ messages in thread
From: Yuanhan Liu @ 2018-02-01 14:47 UTC (permalink / raw)
To: Stefan Hajnoczi, Thomas Monjalon
Cc: dev, Junjie Chen, Changpeng Liu, Maxime Coquelin
On Wed, Jan 31, 2018 at 05:48:28PM +0000, Stefan Hajnoczi wrote:
> The vhost_scsi example application negotiates the
> VIRTIO_RING_F_EVENT_IDX feature bit but does not honor it when accessing
> vrings.
>
> In particular, commit e37ff954405addb8ea422426a2d162d00dcad196 ("vhost:
> support virtqueue interrupt/notification suppression") broke vring call
> because vq->last_used_idx is never updated by vhost_scsi. The
> vq->last_used_idx field is not even available via the librte_vhost
> public API, so VIRTIO_RING_F_EVENT_IDX is currently only usable by the
> built-in virtio_net.c driver in librte_vhost.
>
> This patch drops VIRTIO_RING_F_EVENT_IDX from vhost_scsi so that vring
> call works again.
>
> Cc: Changpeng Liu <changpeng.liu@intel.com>
> Cc: Junjie Chen <junjie.j.chen@intel.com>
> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
Acked-by: Yuanhan Liu <yliu@fridaylinux.org>
Thanks.
--yliu
> ---
> examples/vhost_scsi/vhost_scsi.c | 1 -
> 1 file changed, 1 deletion(-)
>
> diff --git a/examples/vhost_scsi/vhost_scsi.c b/examples/vhost_scsi/vhost_scsi.c
> index da01ad378..3cb4383e9 100644
> --- a/examples/vhost_scsi/vhost_scsi.c
> +++ b/examples/vhost_scsi/vhost_scsi.c
> @@ -21,7 +21,6 @@
> #include "scsi_spec.h"
>
> #define VIRTIO_SCSI_FEATURES ((1 << VIRTIO_F_NOTIFY_ON_EMPTY) |\
> - (1 << VIRTIO_RING_F_EVENT_IDX) |\
> (1 << VIRTIO_SCSI_F_INOUT) |\
> (1 << VIRTIO_SCSI_F_CHANGE))
>
> --
> 2.14.3
^ permalink raw reply [flat|nested] 4+ messages in thread
* Re: [dpdk-dev] [PATCH] examples/vhost_scsi: drop unimplemented EVENT_IDX feature bit
2018-02-01 14:47 ` Yuanhan Liu
@ 2018-02-05 14:21 ` Ferruh Yigit
0 siblings, 0 replies; 4+ messages in thread
From: Ferruh Yigit @ 2018-02-05 14:21 UTC (permalink / raw)
To: Yuanhan Liu, Stefan Hajnoczi, Thomas Monjalon
Cc: dev, Junjie Chen, Changpeng Liu, Maxime Coquelin
On 2/1/2018 2:47 PM, Yuanhan Liu wrote:
> On Wed, Jan 31, 2018 at 05:48:28PM +0000, Stefan Hajnoczi wrote:
>> The vhost_scsi example application negotiates the
>> VIRTIO_RING_F_EVENT_IDX feature bit but does not honor it when accessing
>> vrings.
>>
>> In particular, commit e37ff954405addb8ea422426a2d162d00dcad196 ("vhost:
>> support virtqueue interrupt/notification suppression") broke vring call
>> because vq->last_used_idx is never updated by vhost_scsi. The
>> vq->last_used_idx field is not even available via the librte_vhost
>> public API, so VIRTIO_RING_F_EVENT_IDX is currently only usable by the
>> built-in virtio_net.c driver in librte_vhost.
>>
>> This patch drops VIRTIO_RING_F_EVENT_IDX from vhost_scsi so that vring
>> call works again.
>>
>> Cc: Changpeng Liu <changpeng.liu@intel.com>
>> Cc: Junjie Chen <junjie.j.chen@intel.com>
>> Signed-off-by: Stefan Hajnoczi <stefanha@redhat.com>
>
> Acked-by: Yuanhan Liu <yliu@fridaylinux.org>
Applied to dpdk-next-net/master, thanks.
^ permalink raw reply [flat|nested] 4+ messages in thread
end of thread, other threads:[~2018-02-05 14:21 UTC | newest]
Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2018-01-31 17:48 [dpdk-dev] [PATCH] examples/vhost_scsi: drop unimplemented EVENT_IDX feature bit Stefan Hajnoczi
2018-02-01 0:29 ` Liu, Changpeng
2018-02-01 14:47 ` Yuanhan Liu
2018-02-05 14:21 ` Ferruh Yigit
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).