Re: [PATCH] iommu/virtio: Reject IOMMU page granule larger than PAGE_SIZE

2020-03-25 Thread Auger Eric
Hi Jean, On 3/18/20 12:40 PM, Jean-Philippe Brucker wrote: > We don't currently support IOMMUs with a page granule larger than the > system page size. The IOVA allocator has a BUG_ON() in this case, and > VFIO has a WARN_ON(). > > It might be possible to remove these obstacles if necessary. If

Re: [PATCH V8 9/9] virtio: Intel IFC VF driver for VDPA

2020-03-25 Thread Jason Wang
On 2020/3/25 下午8:34, Jason Gunthorpe wrote: On Wed, Mar 25, 2020 at 04:27:11PM +0800, Jason Wang wrote: +static int ifcvf_probe(struct pci_dev *pdev, const struct pci_device_id *id) +{ + struct device *dev = >dev; + struct ifcvf_adapter *adapter; + struct ifcvf_hw *vf; +

Re: [PATCH V8 5/9] vDPA: introduce vDPA bus

2020-03-25 Thread Jason Wang
On 2020/3/25 下午8:29, Jason Gunthorpe wrote: On Wed, Mar 25, 2020 at 04:27:07PM +0800, Jason Wang wrote: +struct vdpa_device *__vdpa_alloc_device(struct device *parent, + const struct vdpa_config_ops *config, + size_t

Re: [PATCH V8 5/9] vDPA: introduce vDPA bus

2020-03-25 Thread Jason Gunthorpe
On Wed, Mar 25, 2020 at 04:27:07PM +0800, Jason Wang wrote: > +struct vdpa_device *__vdpa_alloc_device(struct device *parent, > + const struct vdpa_config_ops *config, > + size_t size); > + > +#define

Re: [PATCH V8 9/9] virtio: Intel IFC VF driver for VDPA

2020-03-25 Thread Jason Gunthorpe
On Wed, Mar 25, 2020 at 04:27:11PM +0800, Jason Wang wrote: > +static int ifcvf_probe(struct pci_dev *pdev, const struct pci_device_id *id) > +{ > + struct device *dev = >dev; > + struct ifcvf_adapter *adapter; > + struct ifcvf_hw *vf; > + int ret, i; > + > + ret =

Re: [PATCH 05/70] x86/insn: Make inat-tables.c suitable for pre-decompression code

2020-03-25 Thread Borislav Petkov
+ Masami. On Thu, Mar 19, 2020 at 10:13:02AM +0100, Joerg Roedel wrote: > From: Joerg Roedel > > The inat-tables.c file has some arrays in it that contain pointers to > other arrays. These pointers need to be relocated when the kernel > image is moved to a different location. > > The

Re: [PATCH V7 7/8] vdpasim: vDPA device simulator

2020-03-25 Thread Jason Wang
On 2020/3/25 上午10:25, kbuild test robot wrote: I love your patch! Yet something to improve: [auto build test ERROR on vhost/linux-next] [also build test ERROR on linux/master linus/master v5.6-rc7 next-20200324] [if your patch is applied to the wrong git tree, please drop us a note to help

[PATCH V8 5/9] vDPA: introduce vDPA bus

2020-03-25 Thread Jason Wang
vDPA device is a device that uses a datapath which complies with the virtio specifications with vendor specific control path. vDPA devices can be both physically located on the hardware or emulated by software. vDPA hardware devices are usually implemented through PCIE with the following types: -

[PATCH V8 9/9] virtio: Intel IFC VF driver for VDPA

2020-03-25 Thread Jason Wang
From: Zhu Lingshan This commit introduced two layers to drive IFC VF: (1) ifcvf_base layer, which handles IFC VF NIC hardware operations and configurations. (2) ifcvf_main layer, which complies to VDPA bus framework, implemented device operations for VDPA bus, handles device probe,

[PATCH V8 0/9] vDPA support

2020-03-25 Thread Jason Wang
Hi all: This is an update version of vDPA support in kernel. vDPA device is a device that uses a datapath which complies with the virtio specifications with vendor specific control path. vDPA devices can be both physically located on the hardware or emulated by software. vDPA hardware devices

[PATCH V8 1/9] vhost: refine vhost and vringh kconfig

2020-03-25 Thread Jason Wang
Currently, CONFIG_VHOST depends on CONFIG_VIRTUALIZATION. But vhost is not necessarily for VM since it's a generic userspace and kernel communication protocol. Such dependency may prevent archs without virtualization support from using vhost. To solve this, a dedicated vhost menu is created under

[PATCH V8 2/9] vhost: allow per device message handler

2020-03-25 Thread Jason Wang
This patch allow device to register its own message handler during vhost_dev_init(). vDPA device will use it to implement its own DMA mapping logic. Signed-off-by: Jason Wang --- drivers/vhost/net.c | 3 ++- drivers/vhost/scsi.c | 2 +- drivers/vhost/vhost.c | 12 ++--

[PATCH V8 3/9] vhost: factor out IOTLB

2020-03-25 Thread Jason Wang
This patch factors out IOTLB into a dedicated module in order to be reused by other modules like vringh. User may choose to enable the automatic retiring by specifying VHOST_IOTLB_FLAG_RETIRE flag to fit for the case of vhost device IOTLB implementation. Signed-off-by: Jason Wang ---

[PATCH V8 4/9] vringh: IOTLB support

2020-03-25 Thread Jason Wang
This patch implements the third memory accessor for vringh besides current kernel and userspace accessors. This idea is to allow vringh to do the address translation through an IOTLB which is implemented via vhost_map interval tree. Users should setup and IOVA to PA mapping in this IOTLB. This

[PATCH V8 6/9] virtio: introduce a vDPA based transport

2020-03-25 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

[PATCH V8 7/9] vhost: introduce vDPA-based backend

2020-03-25 Thread Jason Wang
From: Tiwei Bie This patch introduces a vDPA-based vhost backend. This backend is built on top of the same interface defined in virtio-vDPA and provides a generic vhost interface for userspace to accelerate the virtio devices in guest. This backend is implemented as a vDPA device driver on top

[PATCH V8 8/9] vdpasim: vDPA device simulator

2020-03-25 Thread Jason Wang
This patch implements a software vDPA networking device. The datapath is implemented through vringh and workqueue. The device has an on-chip IOMMU which translates IOVA to PA. For kernel virtio drivers, vDPA simulator driver provides dma_ops. For vhost driers, set_map() methods of vdpa_config_ops

Re: arm64 kernel crash in bochs_get_edid_block() with QEMU '-device VGA'

2020-03-25 Thread Gerd Hoffmann
On Sat, Feb 15, 2020 at 01:11:45PM +0100, Juerg Haefliger wrote: > The QEMU default edid=off results in a kernel crash [1] on arm64 due > to commit [2]. To reproduce: Should be fixed in qemu 5.0-rc0 cheers, Gerd ___ Virtualization mailing list