Re: [PATCH V4 4/5] virtio: introduce a vDPA based transport

2020-02-21 Thread Jason Wang
On 2020/2/20 下午11:19, Jason Gunthorpe wrote: On Thu, Feb 20, 2020 at 02:11:40PM +0800, Jason Wang wrote: +static int virtio_vdpa_probe(struct vdpa_device *vdpa) +{ + const struct vdpa_config_ops *ops = vdpa->config; + struct virtio_vdpa_device *vd_dev; + int ret = -EINVAL; + +

Re: [PATCH V4 4/5] virtio: introduce a vDPA based transport

2020-02-20 Thread Jason Gunthorpe
On Thu, Feb 20, 2020 at 02:11:40PM +0800, Jason Wang wrote: > +static int virtio_vdpa_probe(struct vdpa_device *vdpa) > +{ > + const struct vdpa_config_ops *ops = vdpa->config; > + struct virtio_vdpa_device *vd_dev; > + int ret = -EINVAL; > + > + vd_dev = kzalloc(sizeof(*vd_dev), GF

[PATCH V4 4/5] virtio: introduce a vDPA based transport

2020-02-19 Thread Jason Wang
This patch introduces a vDPA transport for virtio. This is used to use kernel virtio driver to drive the vDPA device that is capable of populating virtqueue directly. A new virtio-vdpa driver will be registered to the vDPA bus, when a new virtio-vdpa device is probed, it will register the device w