All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH] vdpa_sim_net: Offer VIRTIO_NET_F_STATUS
@ 2022-11-17 15:55 Eugenio Pérez
  2022-11-17 16:25   ` Stefano Garzarella
  2022-11-23 11:35 ` Lei Yang
  0 siblings, 2 replies; 4+ messages in thread
From: Eugenio Pérez @ 2022-11-17 15:55 UTC (permalink / raw)
  To: linux-kernel, mst, virtualization, Jason Wang, Stefano Garzarella

VIRTIO_NET_S_LINK_UP is already returned in config reads since vdpasim
creation, but the feature bit was not offered to the driver.

Tested modifying VIRTIO_NET_S_LINK_UP and different values of "status"
in qemu virtio-net options, using vhost_vdpa.

Not considering as a fix, because there should be no driver trusting in
this config read before the feature flag.

Signed-off-by: Eugenio Pérez <eperezma@redhat.com>
---
 drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 1 +
 1 file changed, 1 insertion(+)

diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
index c3cb225ea469..30cfcfcf97f7 100644
--- a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
+++ b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
@@ -27,6 +27,7 @@
 
 #define VDPASIM_NET_FEATURES	(VDPASIM_FEATURES | \
 				 (1ULL << VIRTIO_NET_F_MAC) | \
+				 (1ULL << VIRTIO_NET_F_STATUS) | \
 				 (1ULL << VIRTIO_NET_F_MTU) | \
 				 (1ULL << VIRTIO_NET_F_CTRL_VQ) | \
 				 (1ULL << VIRTIO_NET_F_CTRL_MAC_ADDR))
-- 
2.31.1


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

* Re: [PATCH] vdpa_sim_net: Offer VIRTIO_NET_F_STATUS
  2022-11-17 15:55 [PATCH] vdpa_sim_net: Offer VIRTIO_NET_F_STATUS Eugenio Pérez
@ 2022-11-17 16:25   ` Stefano Garzarella
  2022-11-23 11:35 ` Lei Yang
  1 sibling, 0 replies; 4+ messages in thread
From: Stefano Garzarella @ 2022-11-17 16:25 UTC (permalink / raw)
  To: Eugenio Pérez; +Cc: virtualization, linux-kernel, mst

On Thu, Nov 17, 2022 at 04:55:02PM +0100, Eugenio Pérez wrote:
>VIRTIO_NET_S_LINK_UP is already returned in config reads since vdpasim
>creation, but the feature bit was not offered to the driver.
>
>Tested modifying VIRTIO_NET_S_LINK_UP and different values of "status"
>in qemu virtio-net options, using vhost_vdpa.
>
>Not considering as a fix, because there should be no driver trusting in
>this config read before the feature flag.
>
>Signed-off-by: Eugenio Pérez <eperezma@redhat.com>
>---
> drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 1 +
> 1 file changed, 1 insertion(+)

Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>

_______________________________________________
Virtualization mailing list
Virtualization@lists.linux-foundation.org
https://lists.linuxfoundation.org/mailman/listinfo/virtualization

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

* Re: [PATCH] vdpa_sim_net: Offer VIRTIO_NET_F_STATUS
@ 2022-11-17 16:25   ` Stefano Garzarella
  0 siblings, 0 replies; 4+ messages in thread
From: Stefano Garzarella @ 2022-11-17 16:25 UTC (permalink / raw)
  To: Eugenio Pérez; +Cc: linux-kernel, mst, virtualization, Jason Wang

On Thu, Nov 17, 2022 at 04:55:02PM +0100, Eugenio Pérez wrote:
>VIRTIO_NET_S_LINK_UP is already returned in config reads since vdpasim
>creation, but the feature bit was not offered to the driver.
>
>Tested modifying VIRTIO_NET_S_LINK_UP and different values of "status"
>in qemu virtio-net options, using vhost_vdpa.
>
>Not considering as a fix, because there should be no driver trusting in
>this config read before the feature flag.
>
>Signed-off-by: Eugenio Pérez <eperezma@redhat.com>
>---
> drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 1 +
> 1 file changed, 1 insertion(+)

Reviewed-by: Stefano Garzarella <sgarzare@redhat.com>


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

* Re: [PATCH] vdpa_sim_net: Offer VIRTIO_NET_F_STATUS
  2022-11-17 15:55 [PATCH] vdpa_sim_net: Offer VIRTIO_NET_F_STATUS Eugenio Pérez
  2022-11-17 16:25   ` Stefano Garzarella
@ 2022-11-23 11:35 ` Lei Yang
  1 sibling, 0 replies; 4+ messages in thread
From: Lei Yang @ 2022-11-23 11:35 UTC (permalink / raw)
  To: Eugenio Pérez
  Cc: linux-kernel, mst, virtualization, Jason Wang, Stefano Garzarella

QE applied this path in the test environment, and did regression
testing with a vdpa simulator device; there are no new issues raised
by this patch.

Tested-by: Lei Yang <leiyang@redhat.com>

Eugenio Pérez <eperezma@redhat.com> 于2022年11月23日周三 18:36写道:
>
> VIRTIO_NET_S_LINK_UP is already returned in config reads since vdpasim
> creation, but the feature bit was not offered to the driver.
>
> Tested modifying VIRTIO_NET_S_LINK_UP and different values of "status"
> in qemu virtio-net options, using vhost_vdpa.
>
> Not considering as a fix, because there should be no driver trusting in
> this config read before the feature flag.
>
> Signed-off-by: Eugenio Pérez <eperezma@redhat.com>
> ---
>  drivers/vdpa/vdpa_sim/vdpa_sim_net.c | 1 +
>  1 file changed, 1 insertion(+)
>
> diff --git a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
> index c3cb225ea469..30cfcfcf97f7 100644
> --- a/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
> +++ b/drivers/vdpa/vdpa_sim/vdpa_sim_net.c
> @@ -27,6 +27,7 @@
>
>  #define VDPASIM_NET_FEATURES   (VDPASIM_FEATURES | \
>                                  (1ULL << VIRTIO_NET_F_MAC) | \
> +                                (1ULL << VIRTIO_NET_F_STATUS) | \
>                                  (1ULL << VIRTIO_NET_F_MTU) | \
>                                  (1ULL << VIRTIO_NET_F_CTRL_VQ) | \
>                                  (1ULL << VIRTIO_NET_F_CTRL_MAC_ADDR))
> --
> 2.31.1
>
>


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

end of thread, other threads:[~2022-11-23 11:37 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2022-11-17 15:55 [PATCH] vdpa_sim_net: Offer VIRTIO_NET_F_STATUS Eugenio Pérez
2022-11-17 16:25 ` Stefano Garzarella
2022-11-17 16:25   ` Stefano Garzarella
2022-11-23 11:35 ` Lei Yang

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.