[PATCH] vhost: introduce mdev based hardware backend

2019-09-25 Thread Tiwei Bie
This patch introduces a mdev based hardware vhost backend. This backend is built on top of the same abstraction used in virtio-mdev and provides a generic vhost interface for userspace to accelerate the virtio devices in guest. This backend is implemented as a mdev device driver on top of the same

Re: [PATCH V2 6/8] mdev: introduce virtio device and its device ops

2019-09-25 Thread Jason Wang
On 2019/9/25 下午9:21, Michael S. Tsirkin wrote: On Wed, Sep 25, 2019 at 08:45:21PM +0800, Jason Wang wrote: On 2019/9/25 下午5:09, Tian, Kevin wrote: From: Jason Wang [mailto:jasow...@redhat.com] Sent: Tuesday, September 24, 2019 9:54 PM This patch implements basic support for mdev driver that s

RE: [PATCH V2 6/8] mdev: introduce virtio device and its device ops

2019-09-25 Thread Tian, Kevin
> From: Jason Wang > Sent: Wednesday, September 25, 2019 8:45 PM > > > On 2019/9/25 下午5:09, Tian, Kevin wrote: > >> From: Jason Wang [mailto:jasow...@redhat.com] > >> Sent: Tuesday, September 24, 2019 9:54 PM > >> > >> This patch implements basic support for mdev driver that supports > >> virtio

Re: [PATCH V2 5/8] mdev: introduce device specific ops

2019-09-25 Thread Alex Williamson
On Wed, 25 Sep 2019 10:11:00 -0400 Rob Miller wrote: > > > On Tue, 24 Sep 2019 21:53:29 +0800 > > > Jason Wang wrote: > > > > diff --git a/drivers/vfio/mdev/vfio_mdev.c > > > b/drivers/vfio/mdev/vfio_mdev.c > > > > index 891cf83a2d9a..95efa054442f 100644 > > > > --- a/drivers/vfio/mdev/vfio_m

Re: [PATCH V2 5/8] mdev: introduce device specific ops

2019-09-25 Thread Rob Miller via Virtualization
On Wed, Sep 25, 2019 at 4:52 AM Tian, Kevin wrote: > > From: Alex Williamson > > Sent: Wednesday, September 25, 2019 7:07 AM > > > > On Tue, 24 Sep 2019 21:53:29 +0800 > > Jason Wang wrote: > > > > > Currently, except for the create and remove, the rest of > > > mdev_parent_ops is designed for v

Re: [PATCH V2 6/8] mdev: introduce virtio device and its device ops

2019-09-25 Thread Michael S. Tsirkin
On Wed, Sep 25, 2019 at 08:45:21PM +0800, Jason Wang wrote: > > On 2019/9/25 下午5:09, Tian, Kevin wrote: > > > From: Jason Wang [mailto:jasow...@redhat.com] > > > Sent: Tuesday, September 24, 2019 9:54 PM > > > > > > This patch implements basic support for mdev driver that supports > > > virtio tr

Re: [PATCH V2 6/8] mdev: introduce virtio device and its device ops

2019-09-25 Thread Jason Wang
On 2019/9/25 下午5:09, Tian, Kevin wrote: From: Jason Wang [mailto:jasow...@redhat.com] Sent: Tuesday, September 24, 2019 9:54 PM This patch implements basic support for mdev driver that supports virtio transport for kernel virtio driver. Signed-off-by: Jason Wang --- include/linux/mdev.h

Re: [PATCH V2 0/8] mdev based hardware virtio offloading support

2019-09-25 Thread Jason Wang
On 2019/9/25 下午4:24, Tian, Kevin wrote: >> From: Jason Wang [mailto:jasow...@redhat.com] >> Sent: Tuesday, September 24, 2019 9:53 PM >> >> Hi all: >> >> There are hardware that can do virtio datapath offloading while having >> its own control path. This path tries to implement a mdev based >> uni

Re: [PATCH V2 2/8] mdev: class id support

2019-09-25 Thread Jason Wang
On 2019/9/25 下午4:28, Tian, Kevin wrote: >> From: Jason Wang >> Sent: Tuesday, September 24, 2019 9:53 PM >> >> Mdev bus only supports vfio driver right now, so it doesn't implement >> match method. But in the future, we may add drivers other than vfio, >> the first driver could be virtio-mdev. Thi

Re: [PATCH V2 6/8] mdev: introduce virtio device and its device ops

2019-09-25 Thread Jason Wang
On 2019/9/25 上午7:06, Alex Williamson wrote: > On Tue, 24 Sep 2019 21:53:30 +0800 > Jason Wang wrote: > >> This patch implements basic support for mdev driver that supports >> virtio transport for kernel virtio driver. >> >> Signed-off-by: Jason Wang >> --- >> include/linux/mdev.h| 2 +

Re: [PATCH V2 5/8] mdev: introduce device specific ops

2019-09-25 Thread Jason Wang
On 2019/9/25 上午7:06, Alex Williamson wrote: > On Tue, 24 Sep 2019 21:53:29 +0800 > Jason Wang wrote: > >> Currently, except for the create and remove, the rest of >> mdev_parent_ops is designed for vfio-mdev driver only and may not help >> for kernel mdev driver. With the help of class id, this p

Re: [PATCH V2 2/8] mdev: class id support

2019-09-25 Thread Jason Wang
On 2019/9/25 上午7:06, Alex Williamson wrote: > On Tue, 24 Sep 2019 21:53:26 +0800 > Jason Wang wrote: > >> Mdev bus only supports vfio driver right now, so it doesn't implement >> match method. But in the future, we may add drivers other than vfio, >> the first driver could be virtio-mdev. This me

Re: [PATCH 5/6] vringh: fix copy direction of vringh_iov_push_kern()

2019-09-25 Thread Jason Wang
On 2019/9/24 下午10:04, Alex Williamson wrote: > On Mon, 23 Sep 2019 12:00:41 -0400 > "Michael S. Tsirkin" wrote: > >> On Mon, Sep 23, 2019 at 09:45:59AM -0600, Alex Williamson wrote: >>> On Mon, 23 Sep 2019 21:03:30 +0800 >>> Jason Wang wrote: >>> We want to copy from iov to buf, so the d

RE: [PATCH V2 6/8] mdev: introduce virtio device and its device ops

2019-09-25 Thread Tian, Kevin
> From: Jason Wang [mailto:jasow...@redhat.com] > Sent: Tuesday, September 24, 2019 9:54 PM > > This patch implements basic support for mdev driver that supports > virtio transport for kernel virtio driver. > > Signed-off-by: Jason Wang > --- > include/linux/mdev.h| 2 + > include/lin

RE: [PATCH V2 5/8] mdev: introduce device specific ops

2019-09-25 Thread Tian, Kevin
> From: Alex Williamson > Sent: Wednesday, September 25, 2019 7:07 AM > > On Tue, 24 Sep 2019 21:53:29 +0800 > Jason Wang wrote: > > > Currently, except for the create and remove, the rest of > > mdev_parent_ops is designed for vfio-mdev driver only and may not help > > for kernel mdev driver. W

RE: [PATCH V2 2/8] mdev: class id support

2019-09-25 Thread Tian, Kevin
> From: Jason Wang > Sent: Tuesday, September 24, 2019 9:53 PM > > Mdev bus only supports vfio driver right now, so it doesn't implement > match method. But in the future, we may add drivers other than vfio, > the first driver could be virtio-mdev. This means we need to add > device class id suppo

RE: [PATCH V2 0/8] mdev based hardware virtio offloading support

2019-09-25 Thread Tian, Kevin
> From: Jason Wang [mailto:jasow...@redhat.com] > Sent: Tuesday, September 24, 2019 9:53 PM > > Hi all: > > There are hardware that can do virtio datapath offloading while having > its own control path. This path tries to implement a mdev based > unified API to support using kernel virtio driver