lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [<thread-prev] [day] [month] [year] [list]
Date:   Sun, 6 Jun 2021 09:31:10 +0300
From:   Eli Cohen <elic@...dia.com>
To:     Jason Wang <jasowang@...hat.com>
CC:     <mst@...hat.com>, <virtualization@...ts.linux-foundation.org>,
        <linux-kernel@...r.kernel.org>, <parav@...dia.com>
Subject: Re: [PATCH] vdpa: mandate 1.0 device

On Fri, Jun 04, 2021 at 01:02:51PM +0800, Jason Wang wrote:
> This patch mandates 1.0 for vDPA devices. The plan is never to support
> transitional devices for vDPA devices in the future.
> 
> The reasons are:
> 
> - To have the semantic of normative statement in the virtio spec and
>   eliminate the burden of transitional device for both vDPA bus and
>   vDPA parent
> - Eliminate the efforts for dealing with endian conversion in the
>   management tool
> - Mandate vDPA vendor to ship modern device instead of transitional
>   device which is easily broken and unsafe
> - Transitional device never work since the first day of vDPA
Transitional devices never worked...

Reviewed-by: Eli Cohen <elic@...dia.com>

> 
> Signed-off-by: Jason Wang <jasowang@...hat.com>
> ---
>  include/linux/vdpa.h | 6 ++++++
>  1 file changed, 6 insertions(+)
> 
> diff --git a/include/linux/vdpa.h b/include/linux/vdpa.h
> index f311d227aa1b..11dd05b805a7 100644
> --- a/include/linux/vdpa.h
> +++ b/include/linux/vdpa.h
> @@ -6,6 +6,7 @@
>  #include <linux/device.h>
>  #include <linux/interrupt.h>
>  #include <linux/vhost_iotlb.h>
> +#include <uapi/linux/virtio_config.h>
>  
>  /**
>   * struct vdpa_calllback - vDPA callback definition.
> @@ -328,6 +329,11 @@ static inline int vdpa_set_features(struct vdpa_device *vdev, u64 features)
>  {
>          const struct vdpa_config_ops *ops = vdev->config;
>  
> +        /* Mandating 1.0 to have semantics of normative statements in
> +         * the spec. */
> +        if (!(features & BIT_ULL(VIRTIO_F_VERSION_1)))
> +		return -EINVAL;
> +
>  	vdev->features_valid = true;
>          return ops->set_features(vdev, features);
>  }
> -- 
> 2.25.1
> 

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ