On Friday, January 12, 2018 6:38 PM, Stefan Hajnoczi wrote: > On Fri, Jan 12, 2018 at 02:44:00PM +0800, Wei Wang wrote: > > On 01/11/2018 05:56 PM, Stefan Hajnoczi wrote: > > > On Thu, Jan 11, 2018 at 6:31 AM, Wei Wang <wei.w.w...@intel.com> > wrote: > > > > On 01/11/2018 12:14 AM, Stefan Hajnoczi wrote: > > > I expect vhost-pci to require fewer code changes. If you judge "simpler" just > by the patch count or size, then vhost-pci will win. > > The reason for that is virtio-vhost-user integrates with librte_vhost. > This requires refactoring librte_vhost to support multiple transports. >
I think the driver having more code is fine. The device part is what will go into the spec, and people have the freedom to implement their own driver (either the dpdk or kernel driver) in the future, if they don't want the librte_vhost based one. So, for the first version, I think it would be better to not make the device full-featured (e.g. pass through as little messages as possible), this would give users a chance to get a device and driver with the least lines of code. > I think the virtio-vhost-user end result is worth it though: vhost devices > like > examples/vhost/ and examples/vhost/scsi/ will work with both AF_UNIX and > virtio-vhost-user. This makes it simpler for users and vhost device > developers - you only have one implementation of net, scsi, blk, etc devices. For the driver part, isn't it that net, scsi, blk will have their own separate implementation on top of the common libret_vhost? Best, Wei