Re: [Qemu-devel] [PATCH v2 05/11] hw/arm/virt: GICv3 DT node with one or two redistributor regions

2018-06-20 Thread Auger Eric
Hi Laszlo, On 06/19/2018 09:02 PM, Ard Biesheuvel wrote: > On 19 June 2018 at 20:53, Laszlo Ersek wrote: >> Hi Eric, >> >> sorry about the late followup. I have one question (mainly for Ard): >> >> On 06/15/18 16:28, Eric Auger wrote: >>> This patch allows the creation of a GICv3 node with 1 or 2

Re: [Qemu-devel] [PATCH v2 01/11] linux-headers: Update to 4.18-rc0

2018-06-20 Thread Auger Eric
Hi Peter, On 06/20/2018 03:57 PM, Peter Maydell wrote: > On 15 June 2018 at 15:28, Eric Auger wrote: >> commit b357bf6023a948cf6a9472f07a1b0caac0e4f8e8 >> Merge tag 'for-linus' of git://git.kernel.org/pub/scm/virt/kvm/kvm >> >> Signed-off-by: Eric Auger > > What's 4.18-rc0? The upstream kernel d

Re: [Qemu-devel] [PATCH v2 01/11] linux-headers: Update to 4.18-rc0

2018-06-20 Thread Auger Eric
Hi Peter, On 06/20/2018 04:06 PM, Peter Maydell wrote: > On 20 June 2018 at 15:03, Auger Eric wrote: >> Hi Peter, >> On 06/20/2018 03:57 PM, Peter Maydell wrote: >>> On 15 June 2018 at 15:28, Eric Auger wrote: >>>> commit b357bf6023a948cf6a9472f07a1b0caac0

Re: [Qemu-devel] [PATCH v3 2/8] hw/misc/tz-mpc.c: Implement registers

2018-06-20 Thread Auger Eric
Hi Peter, On 06/20/2018 03:20 PM, Peter Maydell wrote: > Implement the missing registers for the TZ MPC. > > Signed-off-by: Peter Maydell > --- > include/hw/misc/tz-mpc.h | 10 +++ > hw/misc/tz-mpc.c | 142 +-- > 2 files changed, 148 insertions(+), 4

Re: [Qemu-devel] [PATCH v3 4/8] hw/misc/tz_mpc.c: Honour the BLK_LUT settings in translate

2018-06-20 Thread Auger Eric
Hi Peter, On 06/20/2018 03:20 PM, Peter Maydell wrote: > The final part of the Memory Protection Controller we need to > implement is actually using the BLK_LUT data programmed by the > guest to determine whether to block the transaction or not. > > Since this means we now change transaction mapp

Re: [Qemu-devel] [PATCH v2 3/4] hw/arm/smmuv3: IOTLB emulation

2018-06-21 Thread Auger Eric
Hi Peter, On 06/20/2018 06:07 PM, Peter Maydell wrote: > On 12 June 2018 at 09:08, Eric Auger wrote: >> We emulate a TLB cache of size SMMU_IOTLB_MAX_SIZE=256. >> It is implemented as a hash table whose key is a combination >> of the 16b asid and 48b IOVA (Jenkins hash). >> >> Entries are invalid

Re: [Qemu-devel] [PATCH v2 2/4] hw/arm/smmuv3: Cache/invalidate config data

2018-06-21 Thread Auger Eric
Hi Peter, On 06/20/2018 05:56 PM, Peter Maydell wrote: > On 12 June 2018 at 09:08, Eric Auger wrote: >> Let's cache config data to avoid fetching and parsing STE/CD >> structures on each translation. We invalidate them on data structure >> invalidation commands. >> >> We put in place a per-smmu m

Re: [Qemu-devel] [PATCH v2 2/4] hw/arm/smmuv3: Cache/invalidate config data

2018-06-21 Thread Auger Eric
Hi Peter, On 06/20/2018 06:10 PM, Peter Maydell wrote: > On 20 June 2018 at 16:56, Peter Maydell wrote: >> On 12 June 2018 at 09:08, Eric Auger wrote: >>> +smmuv3_config_cache_hit(uint32_t sid, uint32_t hits, uint32_t misses, >>> float perc) "Config cache HIT for sid %d (hits=%d, misses=%d, hit

Re: [Qemu-devel] [RFC 5/6] hw/arm/virt: support kvm_type property

2018-06-21 Thread Auger Eric
Hi David, On 06/20/2018 07:15 PM, Dr. David Alan Gilbert wrote: > * Eric Auger (eric.au...@redhat.com) wrote: >> The kvm-type property currently is used to pass >> a user parameter to KVM_CREATE_VM. This matches >> the way KVM/ARM expects to pass the max_vm_phys_shift >> parameter. >> >> This patc

Re: [Qemu-devel] [RFC 3/6] kvm: add kvm_get_max_vm_phys_shift

2018-06-21 Thread Auger Eric
Hi David, On 06/21/2018 02:37 AM, David Gibson wrote: > On Wed, Jun 20, 2018 at 03:07:30PM +0200, Eric Auger wrote: >> Add the kvm_get_max_vm_phys_shift() helper that returns the >> log of the maximum IPA size supported by KVM. This capability >> needs to be known to create the VM with a correct I

Re: [Qemu-devel] [PATCH v3 2/3] hw/arm/sysbus-fdt: Replace error_setg(&error_fatal) by error_report() + exit()

2018-06-21 Thread Auger Eric
Hi Philippe, On 06/21/2018 01:40 PM, Philippe Mathieu-Daudé wrote: > Use error_report() + exit() instead of error_setg(&error_fatal), > as suggested by the "qapi/error.h" documentation: > >Please don't error_setg(&error_fatal, ...), use error_report() and >exit(), because that's more obvio

Re: [Qemu-devel] [Questio] What the proper vfio NIC for emulation smmu?

2018-06-21 Thread Auger Eric
Hello Jia, On 06/22/2018 03:44 AM, Jia He wrote: > Hi Eric > I want to test your smmu emulation patchset with vfio-pci ethernet device. > Could you kindly give me the NIC type information. > In my test, there is vf probe error for menallox connect 4 NIC and TX Unit > hang error for Intel X540 NIC.

Re: [Qemu-devel] [PATCH v3 4/4] hw/arm/smmuv3: Add notifications on invalidation

2018-06-22 Thread Auger Eric
Hello Jia, On 06/22/2018 09:15 AM, Jia He wrote: > H > > On 6/21/2018 7:16 PM, Eric Auger Wrote: >> On TLB invalidation commands, let's call registered >> IOMMU notifiers. Those can only be UNMAP notifiers. >> SMMUv3 does not support notification on MAP (VFIO). >> >> This patch allows vhost use c

Re: [Qemu-devel] [PATCH v4 0/4] ARM SMMUv3: IOTLB Emulation and VHOST Support

2018-06-22 Thread Auger Eric
Hi, On 06/22/2018 01:11 PM, no-re...@patchew.org wrote: > Hi, > > This series failed docker-mingw@fedora build test. Please find the testing > commands and > their output below. If you have Docker installed, you can probably reproduce > it > locally. > > Type: series > Message-id: 1529653501-1

Re: [Qemu-devel] [PATCH v2 3/3] hw/arm/virt: Silence dtc /memory warning

2018-06-22 Thread Auger Eric
Hi Peter, On 06/22/2018 01:02 PM, Peter Maydell wrote: > On 18 June 2018 at 13:46, Eric Auger wrote: >> When running dtc on the guest /proc/device-tree we get the >> following warning: Warning (unit_address_vs_reg): Node /memory >> has a reg or ranges property, but no unit name". >> >> Let's fix

Re: [Qemu-devel] [PATCH v2 3/3] hw/arm/virt: Silence dtc /memory warning

2018-06-22 Thread Auger Eric
Hi Peter, On 06/22/2018 01:52 PM, Peter Maydell wrote: > On 22 June 2018 at 12:48, Auger Eric wrote: >> Hi Peter, >> >> On 06/22/2018 01:02 PM, Peter Maydell wrote: >>> This removes all nodes named "memory" or "memory@*", rather than >>>

Re: [Qemu-devel] [PATCH v4 0/4] ARM SMMUv3: IOTLB Emulation and VHOST Support

2018-06-22 Thread Auger Eric
Hi Peter, On 06/22/2018 02:06 PM, Peter Maydell wrote: > On 22 June 2018 at 12:33, Auger Eric wrote: > >>> /tmp/qemu-test/src/nbd/server.c: In function 'nbd_trip': >>> /tmp/qemu-test/src/nbd/server.c:1980:19: error: 'end' may be used >&

Re: [Qemu-devel] [PATCH] hw/arm/smmuv3: fix smmu emulation when guest smmu is in passthrough mode

2018-06-07 Thread Auger Eric
Hi Jia, On 06/07/2018 03:38 PM, Jia He wrote: > There is an exception when I passes iommu.passthrough=1 to guest's > kernel boot parameter(host QDF2400 kernel 4.17, guest kernel 4.14). > The guest will be hang when booting up. > > When guest smmu is in passthrough mode, entry.perm will not be ass

Re: [Qemu-devel] [PATCH] hw/arm/smmuv3: Fix translate error handling

2018-06-12 Thread Auger Eric
Hi, On 06/08/2018 08:57 AM, Eric Auger wrote: > From: Jia He > > In case the STE's config is "Bypass" we currently don't set the > IOMMUTLBEntry perm flags and the access does not succeed. Also > if the config is 0b0xx (Aborted/Reserved), decode_ste and > smmuv3_decode_config currently returns -

Re: [Qemu-devel] [PATCH] exec: Fix MAP_RAM for cached access

2018-06-12 Thread Auger Eric
Hi Peter, On 06/13/2018 05:15 AM, Peter Xu wrote: > On Tue, Jun 12, 2018 at 09:05:25PM +0200, Eric Auger wrote: >> When an IOMMUMemoryRegion is in front of a virtio device, >> address_space_cache_init does not set cache->ptr as the memory >> region is not RAM. However when the device performs an a

Re: [Qemu-devel] [PATCH v4 2/2] intel-iommu: start to use error_report_once

2018-06-13 Thread Auger Eric
Hi, On 06/13/2018 10:05 AM, Markus Armbruster wrote: > Peter Xu writes: > >> Replace existing trace_vtd_err() with error_report_once() then stderr >> will capture something if any of the error happens, meanwhile we don't >> suffer from any DDOS. Then remove the trace point. Since at it, >> prov

Re: [Qemu-devel] [PATCH] exec: Fix MAP_RAM for cached access

2018-06-13 Thread Auger Eric
Hi Paolo, On 06/13/2018 11:56 AM, Paolo Bonzini wrote: > On 12/06/2018 21:05, Eric Auger wrote: >> When an IOMMUMemoryRegion is in front of a virtio device, >> address_space_cache_init does not set cache->ptr as the memory >> region is not RAM. However when the device performs an access, >> we end

Re: [Qemu-devel] [PATCH v2] exec: Fix MAP_RAM for cached access

2018-06-13 Thread Auger Eric
Hi Paolo, On 06/13/2018 03:36 PM, Paolo Bonzini wrote: > On 13/06/2018 15:19, Eric Auger wrote: >> When an IOMMUMemoryRegion is in front of a virtio device, >> address_space_cache_init does not set cache->ptr as the memory >> region is not RAM. However when the device performs an access, >> we end

Re: [Qemu-devel] [PATCH v2] exec: Fix MAP_RAM for cached access

2018-06-13 Thread Auger Eric
Hi Paolo, On 06/13/2018 03:53 PM, Paolo Bonzini wrote: > On 13/06/2018 15:44, Auger Eric wrote: >>> Queuing this patch. I'm not sure how I missed this, I have actually >>> tested it with SMMU. >> no problem. Strange also I was the only one facing the issue. &

Re: [Qemu-devel] [PATCH 9/9] hw/arm/virt: Add virt-3.0 machine type

2018-06-13 Thread Auger Eric
Hi Laszlo, On 06/13/2018 11:05 PM, Laszlo Ersek wrote: > On 06/13/18 10:48, Eric Auger wrote: > >> PATCH: merge of ECAM and VCPU extension >> - Laszlo reviewed the ECAM changes but I dropped his R-b >> due to the squash > > Was there any particular reason why the previous patch set (with only

Re: [Qemu-devel] [PATCH v2] exec: Fix MAP_RAM for cached access

2018-06-14 Thread Auger Eric
Hi Peter, On 06/14/2018 03:52 AM, Peter Xu wrote: > On Wed, Jun 13, 2018 at 04:20:34PM +0200, Auger Eric wrote: >> Hi Paolo, >> >> On 06/13/2018 03:53 PM, Paolo Bonzini wrote: >>> On 13/06/2018 15:44, Auger Eric wrote: >>>>> Queuing this patch. I&

Re: [Qemu-devel] [PATCH 9/9] hw/arm/virt: Add virt-3.0 machine type

2018-06-14 Thread Auger Eric
Hi Laszlo, On 06/14/2018 10:56 AM, Laszlo Ersek wrote: > Hi Eric, > > On 06/14/18 08:27, Auger Eric wrote: >> Hi Laszlo, >> >> On 06/13/2018 11:05 PM, Laszlo Ersek wrote: >>> On 06/13/18 10:48, Eric Auger wrote: >>> >>>> PATCH: merge o

Re: [Qemu-devel] [PATCH 9/9] hw/arm/virt: Add virt-3.0 machine type

2018-06-14 Thread Auger Eric
Hi Dan, Laszlo, On 06/14/2018 10:59 AM, Daniel P. Berrangé wrote: > On Thu, Jun 14, 2018 at 10:56:20AM +0200, Laszlo Ersek wrote: >> Hi Eric, >> >> On 06/14/18 08:27, Auger Eric wrote: >>> Hi Laszlo, >>> >>> On 06/13/2018 11:05 PM, Laszlo Ersek

Re: [Qemu-devel] [PATCH 4/9] hw/intc/arm_gicv3_kvm: Get prepared to handle multiple redist regions

2018-06-14 Thread Auger Eric
Hi Drew, On 06/14/2018 03:39 PM, Andrew Jones wrote: > On Wed, Jun 13, 2018 at 10:48:38AM +0200, Eric Auger wrote: >> Let's check if KVM_VGIC_V3_ADDR_TYPE_REDIST_REGION is supported. >> If not, we check the number of redist region is equal to 1 and use the >> legacy KVM_VGIC_V3_ADDR_TYPE_REDIST at

Re: [Qemu-devel] [PATCH 3/9] hw/intc/arm_gicv3: Introduce redist-region-count array property

2018-06-14 Thread Auger Eric
Hi Drew, On 06/14/2018 03:32 PM, Andrew Jones wrote: > On Wed, Jun 13, 2018 at 10:48:37AM +0200, Eric Auger wrote: >> To prepare for multiple redistributor regions, we introduce >> an array of uint32_t properties that stores the redistributor >> count of each redistributor region. >> >> Non accele

Re: [Qemu-devel] [PATCH v2 05/13] hw/misc/tz-mpc.c: Implement the Arm TrustZone Memory Protection Controller

2018-06-14 Thread Auger Eric
Hi Peter, On 06/04/2018 05:29 PM, Peter Maydell wrote: > Implement the Arm TrustZone Memory Protection Controller, which sits > in front of RAM and allows secure software to configure it to either > pass through or reject transactions. > > We implement the MPC as a QEMU IOMMU, which will direct tr

Re: [Qemu-devel] [PATCH v2 06/13] hw/misc/tz-mpc.c: Implement registers

2018-06-14 Thread Auger Eric
Hi Peter, On 06/04/2018 05:29 PM, Peter Maydell wrote: > Implement the missing registers for the TZ MPC. > > Signed-off-by: Peter Maydell > --- > include/hw/misc/tz-mpc.h | 10 +++ > hw/misc/tz-mpc.c | 137 ++- > 2 files changed, 144 insertions(+), 3

Re: [Qemu-devel] [PATCH v2 06/13] hw/misc/tz-mpc.c: Implement registers

2018-06-14 Thread Auger Eric
Hi Peter, On 06/04/2018 05:29 PM, Peter Maydell wrote: > Implement the missing registers for the TZ MPC. > > Signed-off-by: Peter Maydell > --- > include/hw/misc/tz-mpc.h | 10 +++ > hw/misc/tz-mpc.c | 137 ++- > 2 files changed, 144 insertions(+), 3

Re: [Qemu-devel] [PATCH v2 07/13] hw/misc/tz-mpc.c: Implement correct blocked-access behaviour

2018-06-14 Thread Auger Eric
Hi Peter, On 06/04/2018 05:29 PM, Peter Maydell wrote: > The MPC is guest-configurable for whether blocked accesses: > * should be RAZ/WI or cause a bus error > * should generate an interrupt or not > > Implement this behaviour in the blocked-access handlers. > > Signed-off-by: Peter Maydell >

Re: [Qemu-devel] [PATCH v2 05/13] hw/misc/tz-mpc.c: Implement the Arm TrustZone Memory Protection Controller

2018-06-15 Thread Auger Eric
Hi Peter, On 06/04/2018 05:29 PM, Peter Maydell wrote: > Implement the Arm TrustZone Memory Protection Controller, which sits > in front of RAM and allows secure software to configure it to either > pass through or reject transactions. > > We implement the MPC as a QEMU IOMMU, which will direct t

Re: [Qemu-devel] [PATCH v2 06/13] hw/misc/tz-mpc.c: Implement registers

2018-06-15 Thread Auger Eric
Hi Peter, On 06/04/2018 05:29 PM, Peter Maydell wrote: > Implement the missing registers for the TZ MPC. > > Signed-off-by: Peter Maydell > --- > include/hw/misc/tz-mpc.h | 10 +++ > hw/misc/tz-mpc.c | 137 ++- > 2 files changed, 144 insertions(+), 3

Re: [Qemu-devel] [PATCH v2 08/13] hw/misc/tz_mpc.c: Honour the BLK_LUT settings in translate

2018-06-15 Thread Auger Eric
Hi Peter, On 06/04/2018 05:29 PM, Peter Maydell wrote: > The final part of the Memory Protection Controller we need to > implement is actually using the BLK_LUT data programmed by the > guest to determine whether to block the transaction or not. > > Since this means we now change transaction mapp

Re: [Qemu-devel] [Qemu-arm] [PATCH v7 05/20] hw/arm/smmuv3: Skeleton

2017-09-08 Thread Auger Eric
Hi Linu, On 08/09/2017 12:52, Linu Cherian wrote: > Hi Eric, > > On Fri Sep 01, 2017 at 07:21:08PM +0200, Eric Auger wrote: >> From: Prem Mallappa >> >> This patch implements a skeleton for the smmuv3 device. >> Datatypes and register definitions are introduced. The MMIO >> region, the interrupt

Re: [Qemu-devel] [Qemu-arm] [PATCH v7 00/20] ARM SMMUv3 Emulation Support

2017-09-11 Thread Auger Eric
Hi Linu, On 12/09/2017 08:18, Linu Cherian wrote: > Hi Eric, > > On Fri Sep 01, 2017 at 07:21:03PM +0200, Eric Auger wrote: >> This series implements the emulation code for ARM SMMUv3. >> >> Changes since v6: >> - DPDK testpmd now running on guest with 2 assigned VFs >> - Changed the instantiatio

Re: [Qemu-devel] [PATCH v4 2/4] hmp: fix "dump-quest-memory" segfault (arm)

2017-09-13 Thread Auger Eric
Hi Laurent, On 13/09/2017 16:20, Laurent Vivier wrote: > Running QEMU with > qemu-system-aarch64 -M none -nographic -m 256 > and executing > dump-guest-memory /dev/null 0 8192 > results in segfault > > Fix by checking if we have CPU, and exit with > error if there is no CPU: > > (qem

Re: [Qemu-devel] [Qemu-arm] [PATCH v7 13/20] hw/arm/smmuv3: Implement IOMMU memory region replay callback

2017-09-15 Thread Auger Eric
Hi Linu, On 14/09/2017 11:27, Linu Cherian wrote: > Hi Eric, > > On Fri Sep 01, 2017 at 07:21:16PM +0200, Eric Auger wrote: >> memory_region_iommu_replay() is used for VFIO integration. >> >> However its default implementation is not adapted to SMMUv3 >> IOMMU memory region. Indeed the input addr

Re: [Qemu-devel] [Qemu-arm] [PATCH v7 13/20] hw/arm/smmuv3: Implement IOMMU memory region replay callback

2017-09-15 Thread Auger Eric
Hi Tomasz, On 14/09/2017 16:43, Tomasz Nowicki wrote: > On 14.09.2017 16:31, Tomasz Nowicki wrote: >> Hi Eric, >> >> On 14.09.2017 11:27, Linu Cherian wrote: >>> Hi Eric, >>> >>> On Fri Sep 01, 2017 at 07:21:16PM +0200, Eric Auger wrote: memory_region_iommu_replay() is used for VFIO integrati

Re: [Qemu-devel] [Qemu-arm] [PATCH v7 13/20] hw/arm/smmuv3: Implement IOMMU memory region replay callback

2017-09-15 Thread Auger Eric
On 15/09/2017 09:30, Auger Eric wrote: > Hi Tomasz, > > On 14/09/2017 16:43, Tomasz Nowicki wrote: >> On 14.09.2017 16:31, Tomasz Nowicki wrote: >>> Hi Eric, >>> >>> On 14.09.2017 11:27, Linu Cherian wrote: >>>> Hi Eric, >>>&

Re: [Qemu-devel] [Qemu-arm] [PATCH v7 13/20] hw/arm/smmuv3: Implement IOMMU memory region replay callback

2017-09-15 Thread Auger Eric
Hi Tomasz, On 15/09/2017 12:42, tn wrote: > Hi Eric, > > On 15.09.2017 09:30, Auger Eric wrote: >> Hi Tomasz, >> >> On 14/09/2017 16:43, Tomasz Nowicki wrote: >>> On 14.09.2017 16:31, Tomasz Nowicki wrote: >>>> Hi Eric, >>>>

Re: [Qemu-devel] [Qemu-arm] [PATCH v7 13/20] hw/arm/smmuv3: Implement IOMMU memory region replay callback

2017-09-15 Thread Auger Eric
Hi, On 15/09/2017 12:42, tn wrote: > Hi Eric, > > On 15.09.2017 09:30, Auger Eric wrote: >> Hi Tomasz, >> >> On 14/09/2017 16:43, Tomasz Nowicki wrote: >>> On 14.09.2017 16:31, Tomasz Nowicki wrote: >>>> Hi Eric, >>>> >>>>

Re: [Qemu-devel] [PATCH v3 2/2] virtio-iommu: vfio integration with virtio-iommu

2017-09-18 Thread Auger Eric
Hi Bharat, On 21/08/2017 12:48, Bharat Bhushan wrote: > This RFC patch allows virtio-iommu protection for PCI > device-passthrough. > > MSI region is mapped by current version of virtio-iommu driver. > This uses VFIO extension of map/unmap notification when an area > of memory is mappedi/unmapped

Re: [Qemu-devel] [PATCH v3 2/2] virtio-iommu: vfio integration with virtio-iommu

2017-09-18 Thread Auger Eric
Hi Bharat, On 18/09/2017 09:47, Auger Eric wrote: > Hi Bharat, > > On 21/08/2017 12:48, Bharat Bhushan wrote: >> This RFC patch allows virtio-iommu protection for PCI >> device-passthrough. >> >> MSI region is mapped by current version of virtio-iommu driver. &

Re: [Qemu-devel] [PATCH v6 2/4] hw/intc/arm_gicv3_kvm: Implement get/put functions

2016-12-19 Thread Auger Eric
Hi Vijaya, On 23/11/2016 13:39, vijay.kil...@gmail.com wrote: > From: Vijaya Kumar K > > This actually implements pre_save and post_load methods for in-kernel > vGICv3. > > Signed-off-by: Pavel Fedin > Signed-off-by: Peter Maydell > [PMM: > * use decimal, not 0bnnn > * fixed typo in names o

Re: [Qemu-devel] [RFC 1/3] hw/intc/arm_gicv3_its: Don't abort on table save/restore

2017-10-17 Thread Auger Eric
Hi Peter, On 12/10/2017 13:54, Peter Maydell wrote: > On 27 September 2017 at 15:56, Eric Auger wrote: >> The ITS is not properly reset at the moment. It is possible the >> GITS_BASER.valid is set and the in-kernel ITS caches are not >> empty (list of devices, collections, LPIs) while data structu

Re: [Qemu-devel] kvm_set_phys_mem: assertion failed

2017-09-21 Thread Auger Eric
Hi David, On 20/09/2017 16:34, David Hildenbrand wrote: > On 20.09.2017 16:31, Gerd Hoffmann wrote: >> Hi, >> >>> Dropping from os section: >>> >>> >> type="pflash">/usr/share/edk2.git/ovmf-x64/OVMF_CODE-pure- >>> efi.fd >>> >> template="/usr/share/edk2.git/ovmf-x64/OVMF_VARS-pure- >>> efi.fd">/v

Re: [Qemu-devel] [Qemu-arm] [PATCH v4 0/5] virtio-iommu: VFIO integration

2017-09-27 Thread Auger Eric
Hi Linu, On 27/09/2017 10:30, Bharat Bhushan wrote: > Hi, > >> -Original Message- >> From: Linu Cherian [mailto:linuc.dec...@gmail.com] >> Sent: Wednesday, September 27, 2017 1:11 PM >> To: Bharat Bhushan >> Cc: eric.au...@redhat.com; eric.auger@gmail.com; >> peter.mayd...@linaro.org

Re: [Qemu-devel] [PATCH 1/1] mach-virt: Set VM's SMBIOS system version to mc->name

2017-09-27 Thread Auger Eric
Hi Wei, On 26/09/2017 18:52, Wei Huang wrote: > > > On 09/26/2017 10:37 AM, Andrew Jones wrote: >> On Tue, Sep 26, 2017 at 04:28:03PM +0100, Peter Maydell wrote: >>> On 26 September 2017 at 11:54, Andrew Jones wrote: On Fri, Sep 22, 2017 at 08:51:15AM -0500, Wei Huang wrote: > Instead

Re: [Qemu-devel] [Qemu-arm] [PATCH v4 0/5] virtio-iommu: VFIO integration

2017-09-27 Thread Auger Eric
Hi Linu, On 27/09/2017 11:21, Linu Cherian wrote: > On Wed Sep 27, 2017 at 10:55:07AM +0200, Auger Eric wrote: >> Hi Linu, >> >> On 27/09/2017 10:30, Bharat Bhushan wrote: >>> Hi, >>> >>>> -Original Message- >>>> From: Li

Re: [Qemu-devel] [RFC v4 00/16] VIRTIO-IOMMU device

2017-09-27 Thread Auger Eric
Hi Tomasz On 27/09/2017 13:07, Tomasz Nowicki wrote: > Hi Eric, > > Out of curiosity, I compared your SMMUv3 full emulation against > virtio-iommu. For virtio-net device behind the virtio-iommu I get 50% > performance of what I can get for SMMUv3 emulation. > > Do you have similar observations?

Re: [Qemu-devel] [RFC v4 10/16] virtio-iommu: Implement probe request

2017-09-27 Thread Auger Eric
Hi Tomasz, On 27/09/2017 12:53, Tomasz Nowicki wrote: > Hi Eric, > > On 19.09.2017 09:46, Eric Auger wrote: >> This patch implements the PROBE request. At the moment, >> no reserved regions are returned. >> >> At the moment reserved regions are stored per device. >> >> Signed-off-by: Eric Auger >

Re: [Qemu-devel] [RFC v4 10/16] virtio-iommu: Implement probe request

2017-09-27 Thread Auger Eric
Hi Bharat, On 27/09/2017 13:00, Bharat Bhushan wrote: > > >> -Original Message- >> From: Tomasz Nowicki [mailto:tnowi...@caviumnetworks.com] >> Sent: Wednesday, September 27, 2017 4:23 PM >> To: Eric Auger ; eric.auger@gmail.com; >> peter.mayd...@linaro.org; alex.william...@redhat.co

Re: [Qemu-devel] [Qemu-arm] [PATCH v7 00/20] ARM SMMUv3 Emulation Support

2017-09-28 Thread Auger Eric
Hi Linu, Peter, On 28/09/2017 09:13, Peter Xu wrote: > On Thu, Sep 28, 2017 at 12:13:12PM +0530, Linu Cherian wrote: >> Hi Eric, >> >> >> On Fri Sep 01, 2017 at 07:21:03PM +0200, Eric Auger wrote: >>> This series implements the emulation code for ARM SMMUv3. >>> >>> Changes since v6: >>> - DPDK te

Re: [Qemu-devel] [PATCH v7 01/20] hw/arm/smmu-common: smmu base device and datatypes

2017-09-28 Thread Auger Eric
Hi Peter, On 27/09/2017 19:38, Peter Maydell wrote: > On 1 September 2017 at 10:21, Eric Auger wrote: >> The patch introduces the smmu base device and class for the ARM >> smmu. Devices for specific versions will be derived from this >> base device. >> >> We also introduce some important datatypes

Re: [Qemu-devel] [PATCH v6 0/8] vITS support

2016-09-22 Thread Auger Eric
Hi Peter, On 22/09/2016 16:08, Peter Maydell wrote: > On 9 September 2016 at 18:30, Eric Auger wrote: >> This series introduces support for in-kernel GICv3 ITS emulation. >> >> On dt guest the functionality is complete and was tested on Cavium ThunderX >> with virtio-net-pci and vhost-net. >> >>

Re: [Qemu-devel] [PATCH v6 4/8] kvm-all: Pass requester ID to MSI routing functions

2016-09-22 Thread Auger Eric
Hi Peter, On 22/09/2016 16:35, Peter Maydell wrote: > On 9 September 2016 at 18:30, Eric Auger wrote: >> From: Pavel Fedin >> >> Introduce global kvm_msi_use_devid flag and pass the device ID, >> if needed, while building the MSI route entry. Device IDs are >> required by the ARM GICv3 ITS (IRQ

Re: [Qemu-devel] [PATCH v6 5/8] hw/intc/arm_gicv3_its: Implement support for in-kernel ITS emulation

2016-09-22 Thread Auger Eric
Hi Peter, On 22/09/2016 17:03, Peter Maydell wrote: > On 9 September 2016 at 18:30, Eric Auger wrote: >> From: Pavel Fedin >> >> The ITS control frame is in-kernel emulated while accesses to the >> GITS_TRANSLATER are mediated through the KVM_SIGNAL_MSI ioctl (MSI >> direct MSI injection adverti

Re: [Qemu-devel] [PATCH v6 5/8] hw/intc/arm_gicv3_its: Implement support for in-kernel ITS emulation

2016-09-22 Thread Auger Eric
Hi Peter, On 22/09/2016 17:59, Peter Maydell wrote: > On 22 September 2016 at 16:53, Auger Eric wrote: >> Hi Peter, >> >> On 22/09/2016 17:03, Peter Maydell wrote: >>> Also, I think it would be simpler to just have kvm_its_send_msi() do >>> >&

Re: [Qemu-devel] [PATCH v2 9/9] [optional] arm: smmu-v3: ACPI IORT initial support

2016-09-23 Thread Auger Eric
Hi Prem, On 12/09/2016 22:42, Prem Mallappa wrote: > On Fri, Sep 9, 2016 at 8:54 PM, Auger Eric wrote: > >> Hi Prem, >> >> On 22/08/2016 18:17, Prem Mallappa wrote: >>> Added ACPI IORT tables, was needed for internal project purpose, but >>> posting h

Re: [Qemu-devel] [PATCH v2 9/9] [optional] arm: smmu-v3: ACPI IORT initial support

2016-09-23 Thread Auger Eric
Hi Prem, On 23/09/2016 16:07, Prem Mallappa wrote: > On Fri, Sep 23, 2016 at 6:40 PM, Auger Eric <mailto:eric.au...@redhat.com>> wrote: > > Hi Prem, > > On 12/09/2016 22:42, Prem Mallappa wrote: > > On Fri, Sep 9, 2016 at 8:54 PM, Auger Eric

Re: [Qemu-devel] [PATCH v2 1/9] log: Add new IOMMU type

2016-09-25 Thread Auger Eric
Hi Edgar, Prem, On 25/09/2016 16:58, Edgar E. Iglesias wrote: > On Tue, Sep 13, 2016 at 01:53:39AM +0530, Prem Mallappa wrote: >> On Fri, Sep 9, 2016 at 9:06 PM, Auger Eric wrote: >> >>> Hi Prem, >>> >>> Missing commit message >>> >>>

Re: [Qemu-devel] [PATCH v2 05/12] vfio/pci: Pass an error object to vfio_add_capabilities

2016-09-30 Thread Auger Eric
Hi Markus, On 22/09/2016 18:52, Markus Armbruster wrote: > Eric Auger writes: > >> Pass an error object to prepare for migration to VFIO-PCI realize. >> The error is cascaded downto vfio_add_std_cap and then vfio_msi(x)_setup, >> vfio_setup_pcie_cap. >> >> vfio_add_ext_cap does not return anythi

Re: [Qemu-devel] [PATCH v2 04/12] vfio/pci: Pass an error object to vfio_intx_enable

2016-09-30 Thread Auger Eric
Markus, On 22/09/2016 18:27, Markus Armbruster wrote: > Eric Auger writes: > >> Pass an error object to prepare for migration to VFIO-PCI realize. >> >> The error object is propagated downto vfio_intx_enable_kvm > > down to vfio_intx_enable_kvm(). > > (feel free to omit the () I automatically

Re: [Qemu-devel] [PATCH v2 09/12] vfio/pci: Conversion to realize

2016-09-30 Thread Auger Eric
Hi, On 22/09/2016 19:24, Markus Armbruster wrote: > Eric Auger writes: > >> This patch converts VFIO PCI to realize function. >> >> Also original initfn errors now are propagated using QEMU >> error objects. All errors are formatted with the same pattern: >> "vfio: %s: the error description" >>

Re: [Qemu-devel] [PATCH v2 02/12] vfio/pci: Pass an error object to vfio_populate_device

2016-09-30 Thread Auger Eric
Markus, On 22/09/2016 17:49, Markus Armbruster wrote: > Eric Auger writes: > >> Pass an error object to prepare for migration to VFIO-PCI realize. >> The returned value will be removed later on. >> >> The case where error recovery cannot be enabled is not converted into >> an error object but di

Re: [Qemu-devel] [PATCH v2 07/12] vfio: Pass an error object to vfio_get_group

2016-09-30 Thread Auger Eric
Hi Markus, On 22/09/2016 19:01, Markus Armbruster wrote: > Eric Auger writes: > >> Pass an error object to prepare for migration to VFIO-PCI realize. >> >> Signed-off-by: Eric Auger >> >> --- >> >> v2: creation >> --- >> hw/vfio/common.c | 20 +++- >> hw/vfio/pci.c

Re: [Qemu-devel] [PATCH v2 01/12] vfio/pci: Use local error object in vfio_initfn

2016-09-30 Thread Auger Eric
Hi Markus, On 22/09/2016 17:42, Markus Armbruster wrote: > Eric Auger writes: > >> To prepare for migration to realize, let's use a local error >> object in vfio_initfn. Also let's use the same error prefix for all >> error messages. >> >> On top of the 1-1 conversion, we start using a common er

Re: [Qemu-devel] [PATCH RFC 1/1] vfio/pci: Fix incorrect error message

2017-04-26 Thread Auger Eric
Hi Dong, On 25/04/2017 06:56, Dong Jia Shi wrote: > * Dong Jia Shi [2017-04-25 06:52:01 +0200]: > > Hey Alex, > > Please ignore the "RFC" tag in the subject. Sorry for the mistake. > >> When the "No host device provided" error occurs, the hint message >> that starts with "Use -vfio-pci," makes

Re: [Qemu-devel] [RFC v5 0/4] vITS save/restore

2017-04-26 Thread Auger Eric
Hi Brahmajyosyula, On 26/04/2017 13:18, Prakash B wrote: > Verified on Cavium ThunderX platform > Continousily migrated Guest more than 500 times b/w different hosts. > Please feel free to add Tested-by: Prakash, Brahmajyosyula > Many thanks for your testing efforts! Best Regards Eric > >

Re: [Qemu-devel] [PATCH v6 07/13] vfio/ccw: vfio based subchannel passthrough driver

2017-05-01 Thread Auger Eric
Hi Dong, On 28/04/2017 15:09, Dong Jia Shi wrote: > From: Xiao Feng Ren > > We use the IOMMU_TYPE1 of VFIO to realize the subchannels > passthrough, implement a vfio based subchannels passthrough > driver called "vfio-ccw". > > Support qemu parameters in the style of: > "-device vfio-ccw,sysfsd

Re: [Qemu-devel] [PATCH v6 06/13] s390x/css: device support for s390-ccw passthrough

2017-05-01 Thread Auger Eric
Hi Dong, On 28/04/2017 15:09, Dong Jia Shi wrote: > In order to support subchannels pass-through, we introduce a s390 > subchannel device called "s390-ccw" to hold the real subchannel info. > The s390-ccw devices inherit from the abstract CcwDevice which connect > to the existing virtual-css-bus.

Re: [Qemu-devel] [PATCH v6 08/13] vfio/ccw: get io region info

2017-05-01 Thread Auger Eric
Hi, On 28/04/2017 15:09, Dong Jia Shi wrote: > vfio-ccw provides an MMIO region for I/O operations. We fetch its > information via ioctls here, then we can use it performing I/O > instructions and retrieving I/O results later on. > > Signed-off-by: Dong Jia Shi > --- > hw/vfio/ccw.c | 52 ++

Re: [Qemu-devel] [PATCH v6 09/13] vfio/ccw: get irqs info and set the eventfd fd

2017-05-01 Thread Auger Eric
Hi, On 28/04/2017 15:09, Dong Jia Shi wrote: > vfio-ccw resorts to the eventfd mechanism to communicate with userspace. > We fetch the irqs info via the ioctl VFIO_DEVICE_GET_IRQ_INFO, > register a event notifier to get the eventfd fd which is sent > to kernel via the ioctl VFIO_DEVICE_SET_IRQS, th

Re: [Qemu-devel] [PATCH v6 06/13] s390x/css: device support for s390-ccw passthrough

2017-05-01 Thread Auger Eric
Hi Dong, On 28/04/2017 15:09, Dong Jia Shi wrote: > In order to support subchannels pass-through, we introduce a s390 > subchannel device called "s390-ccw" to hold the real subchannel info. > The s390-ccw devices inherit from the abstract CcwDevice which connect > to the existing virtual-css-bus.

Re: [Qemu-devel] [PATCH v6 06/13] s390x/css: device support for s390-ccw passthrough

2017-05-01 Thread Auger Eric
Hi Dong, On 01/05/2017 13:20, Auger Eric wrote: > Hi Dong, > > On 28/04/2017 15:09, Dong Jia Shi wrote: >> In order to support subchannels pass-through, we introduce a s390 >> subchannel device called "s390-ccw" to hold the real subchannel info. >> The s390-

Re: [Qemu-devel] [PATCH v6 10/13] s390x/css: introduce and realize ccw-request callback

2017-05-01 Thread Auger Eric
Hi Dong, On 28/04/2017 15:09, Dong Jia Shi wrote: > From: Xiao Feng Ren > > Introduce a new callback on subchannel to handle ccw-request. > Realize the callback in vfio-ccw device. Besides, resort to > the event notifier handler to handling the ccw-request results. > 1. Pread the I/O results via

Re: [Qemu-devel] [PATCH v6 07/13] vfio/ccw: vfio based subchannel passthrough driver

2017-05-01 Thread Auger Eric
Hi Dong, On 02/05/2017 07:07, Dong Jia Shi wrote: > * Auger Eric [2017-05-01 13:08:05 +0200]: > > Hi Eric, > > [...] > >>> diff --git a/hw/vfio/ccw.c b/hw/vfio/ccw.c >>> new file mode 100644 >>> index 000..cd4dfe8 >>> --- /dev/null &g

Re: [Qemu-devel] [Qemu-arm] [PATCH v3 0/2] virtio-iommu: VFIO integration

2017-08-29 Thread Auger Eric
Hi Linu, On 29/08/2017 19:06, Linu Cherian wrote: > Hi, > > On Mon Aug 21, 2017 at 04:18:52PM +0530, Bharat Bhushan wrote: >> This V3 version is mainly about rebasing on v3 version on Virtio-iommu device >> framework from Eric Augur and addresing review comments. >> >> This patch series allows PC

Re: [Qemu-devel] [PATCH RESEND v3 0/3] Generic PCIe host bridge INTx determination for INTx routing

2017-09-01 Thread Auger Eric
Hi, On 09/07/2017 23:02, Eric Auger wrote: > This series implements INTx to gsi routing for ARM VIRT/Gpex. This is > a respin of [1] which was lost in limbo. > > ARM virt uses GPEX PCIe bridge. This latter does not implement INTx > to GSI routing. PCIe/INTx assignment works but the consequence is

Re: [Qemu-devel] [PATCH v7 00/20] ARM SMMUv3 Emulation Support

2017-09-08 Thread Auger Eric
Hi Peter, On 07/09/2017 14:39, Peter Maydell wrote: > On 1 September 2017 at 18:21, Eric Auger wrote: >> This series implements the emulation code for ARM SMMUv3. >> >> Changes since v6: >> - DPDK testpmd now running on guest with 2 assigned VFs >> - Changed the instantiation method: add the foll

Re: [Qemu-devel] [PATCH v7 00/20] ARM SMMUv3 Emulation Support

2017-09-08 Thread Auger Eric
Hi Michael, On 08/09/2017 07:47, Michael S. Tsirkin wrote: > On Fri, Sep 01, 2017 at 07:21:03PM +0200, Eric Auger wrote: >> This series implements the emulation code for ARM SMMUv3. > > Can you add some code to block using vfio with this > until patches 19+20 are ready? Sure. Thanks Eric > Then

Re: [Qemu-devel] [RFC PATCH v3 0/5] vITS support

2016-06-27 Thread Auger Eric
Dear all, On 24/11/2015 11:13, Pavel Fedin wrote: > This series introduces support for in-kernel GICv3 ITS emulation. > It is based on kernel API which is not released yet, therefore i post > it as an RFC. > > Kernel patch sets which implement this functionality are: > - [PATCH v3 00/16] KVM: arm

Re: [Qemu-devel] [RFC PATCH v3 0/5] vITS support

2016-06-28 Thread Auger Eric
Hi Christoffer, On 28/06/2016 10:25, Christoffer Dall wrote: > On Tue, Jun 28, 2016 at 8:41 AM, Auger Eric wrote: >> Dear all, >> >> On 24/11/2015 11:13, Pavel Fedin wrote: >>> This series introduces support for in-kernel GICv3 ITS emulation. >>> It is ba

Re: [Qemu-devel] [PATCH] hw/intc/arm_gicv3_its: Fix the VM termination in vm_change_state_handler()

2017-11-05 Thread Auger Eric
Hi Shanker, On 03/11/2017 13:37, Shanker Donthineni wrote: > The commit cddafd8f353d ("hw/intc/arm_gicv3_its: Implement state save > /restore") breaks the backward compatibility with the older kernels > where vITS save/restore support is not available. The vmstate function > vm_change_state_handle

Re: [Qemu-devel] [RFC v2 1/4] hw/intc/arm_gicv3_its: Don't abort on table save failure

2017-11-06 Thread Auger Eric
Hi Peter, On 02/11/2017 13:53, Peter Maydell wrote: > On 23 October 2017 at 16:35, Eric Auger wrote: >> The ITS is not fully properly reset at the moment. Caches are >> not emptied. >> >> After a reset, in case we attempt to save the state before >> the bound devices have registered their MSIs an

Re: [Qemu-devel] [PATCH v7 15/20] hw/arm/sysbus-fdt: Pass the VirtMachineState to the node creation functions

2017-11-13 Thread Auger Eric
Hi Peter, On 09/10/2017 19:47, Peter Maydell wrote: > On 1 September 2017 at 18:21, Eric Auger wrote: >> The VirtMachineState contains some dt phandles that will be used >> in some node creation functions. For instance we plan to use the >> PCI host controller phandle in the smmu node creation fu

Re: [Qemu-devel] [PATCH v7 15/20] hw/arm/sysbus-fdt: Pass the VirtMachineState to the node creation functions

2017-11-13 Thread Auger Eric
Hi Peter, On 13/11/2017 14:08, Peter Maydell wrote: > On 13 November 2017 at 13:00, Auger Eric wrote: >> On 09/10/2017 19:47, Peter Maydell wrote: >>> More generally, why is sysbus-fdt involved in this at all? >>> I expected that instantiating and wiring up the SMMU

Re: [Qemu-devel] [PATCH v7 15/20] hw/arm/sysbus-fdt: Pass the VirtMachineState to the node creation functions

2017-11-13 Thread Auger Eric
Hi, On 13/11/2017 14:44, Peter Maydell wrote: > On 13 November 2017 at 13:37, Auger Eric wrote: >> On 13/11/2017 14:08, Peter Maydell wrote: >>> Not being able to conveniently wire up a sysbus device on the >>> command line or pass it options are general problems. I do

Re: [Qemu-devel] [RFC 0/5] arm: Exclude reserved memory regions of iommu to avoid

2017-11-13 Thread Auger Eric
Hello Zhu, On 13/11/2017 13:29, zhuyi...@huawei.com wrote: > From: Zhu Yijun > > With kernel 4.11, iommu/smmu will populate the MSI IOVA reserved window and > PCI reserved window which has to be excluded from Guest iova allocations. > > And on certain HiSilicon platforms (hip06/hip07), the GIC

Re: [Qemu-devel] [RESEND PATCH 2/6] memory: introduce AddressSpaceOps and IOMMUObject

2017-11-14 Thread Auger Eric
Hi Yi L, On 13/11/2017 10:58, Liu, Yi L wrote: > On Mon, Nov 13, 2017 at 04:56:01PM +1100, David Gibson wrote: >> On Fri, Nov 03, 2017 at 08:01:52PM +0800, Liu, Yi L wrote: >>> From: Peter Xu >>> >>> AddressSpaceOps is similar to MemoryRegionOps, it's just for address >>> spaces to store arch-spe

Re: [Qemu-devel] [RESEND PATCH 2/6] memory: introduce AddressSpaceOps and IOMMUObject

2017-11-14 Thread Auger Eric
Hi Yi L, On 03/11/2017 13:01, Liu, Yi L wrote: > From: Peter Xu > > AddressSpaceOps is similar to MemoryRegionOps, it's just for address > spaces to store arch-specific hooks. > > The first hook I would like to introduce is iommu_get(). Return an > IOMMUObject behind the AddressSpace. David ha

Re: [Qemu-devel] [RESEND PATCH 5/6] vfio/pci: add notify framework based on IOMMUObject

2017-11-14 Thread Auger Eric
Hi Yi L, On 03/11/2017 13:01, Liu, Yi L wrote: > This patch introduce a notify framework for IOMMUObject.iommu_notifiers. > Introduce VFIOGuestIOMMUObject is to link VFIO Container and the new > IOMMUObject notififiers. notifiers > > VFIOGuestIOMMUObject instance is allocated when device is assig

Re: [Qemu-devel] [PATCH v9 04/14] hw/arm/smmuv3: Skeleton

2018-03-09 Thread Auger Eric
Hi Peter, On 08/03/18 15:27, Peter Maydell wrote: > On 17 February 2018 at 18:46, Eric Auger wrote: >> From: Prem Mallappa >> >> This patch implements a skeleton for the smmuv3 device. >> Datatypes and register definitions are introduced. The MMIO >> region, the interrupts and the queue are init

Re: [Qemu-devel] [PATCH v9 04/14] hw/arm/smmuv3: Skeleton

2018-03-09 Thread Auger Eric
Hi Peter, On 09/03/18 14:37, Peter Maydell wrote: > On 9 March 2018 at 13:19, Auger Eric wrote: >> On 08/03/18 15:27, Peter Maydell wrote: >>> Consider specifically catching 8-byte accesses to non-64-bit registers? >>> This is CONSTRAINED UNPREDICTABLE (see spec sectio

Re: [Qemu-devel] [PATCH v9 05/14] hw/arm/smmuv3: Wired IRQ and GERROR helpers

2018-03-09 Thread Auger Eric
Hi Peter, On 08/03/18 18:49, Peter Maydell wrote: > On 17 February 2018 at 18:46, Eric Auger wrote: >> We introduce some helpers to handle wired IRQs and especially >> GERROR interrupt. SMMU writes GERROR register on GERROR event >> and SW acks GERROR interrupts by setting GERRORn. >> >> The Wire

Re: [Qemu-devel] [PATCH v9 05/14] hw/arm/smmuv3: Wired IRQ and GERROR helpers

2018-03-09 Thread Auger Eric
Hi Peter, On 09/03/18 15:18, Peter Maydell wrote: > On 9 March 2018 at 14:03, Auger Eric wrote: >> On 08/03/18 18:49, Peter Maydell wrote: >>>> +#define smmuv3_eventq_irq_enabled(s) \ >>>> +(FIELD_EX32(s->irq_ctrl, IR

<    1   2   3   4   5   6   7   8   9   10   >