Re: [PATCH v3] i386: Introduce ARAT CPU feature

2015-05-31 Thread Michael S. Tsirkin
On Mon, May 25, 2015 at 04:47:49PM +0200, Jan Kiszka wrote: From: Jan Kiszka jan.kis...@siemens.com ARAT signals that the APIC timer does not stop in power saving states. As our APICs are emulated, it's fine to expose this feature to guests, at least when asking for KVM host features or with

Re: [PATCH kernel v11 04/34] powerpc/iommu: Put IOMMU group explicitly

2015-05-31 Thread David Gibson
On Fri, May 29, 2015 at 06:44:28PM +1000, Alexey Kardashevskiy wrote: So far an iommu_table lifetime was the same as PE. Dynamic DMA windows will change this and iommu_free_table() will not always require the group to be released. This moves iommu_group_put() out of iommu_free_table().

Re: [PATCH kernel v11 01/34] powerpc/eeh/ioda2: Use device::iommu_group to check IOMMU group

2015-05-31 Thread David Gibson
On Fri, May 29, 2015 at 06:44:25PM +1000, Alexey Kardashevskiy wrote: This relies on the fact that a PCI device always has an IOMMU table which may not be the case when we get dynamic DMA windows so let's use more reliable check for IOMMU group here. As we do not rely on the table presence

Re: [PATCH kernel v11 03/34] powerpc/powernv/ioda: Clean up IOMMU group registration

2015-05-31 Thread David Gibson
On Fri, May 29, 2015 at 06:44:27PM +1000, Alexey Kardashevskiy wrote: The existing code has 3 calls to iommu_register_group() and all 3 branches actually cover all possible cases. This replaces 3 calls with one and moves the registration earlier; the latter will make more sense when we add

Re: [PATCH kernel v11 05/34] powerpc/iommu: Always release iommu_table in iommu_free_table()

2015-05-31 Thread David Gibson
On Fri, May 29, 2015 at 06:44:29PM +1000, Alexey Kardashevskiy wrote: At the moment iommu_free_table() only releases memory if the table was initialized for the platform code use, i.e. it had it_map initialized (which purpose is to track DMA memory space use). With dynamic DMA windows, we

Re: [PATCH kernel v11 02/34] powerpc/iommu/powernv: Get rid of set_iommu_table_base_and_group

2015-05-31 Thread David Gibson
On Fri, May 29, 2015 at 06:44:26PM +1000, Alexey Kardashevskiy wrote: The set_iommu_table_base_and_group() name suggests that the function sets table base and add a device to an IOMMU group. The actual purpose for table base setting is to put some reference into a device so later

Re: [PATCH kernel v11 16/34] powerpc/spapr: vfio: Replace iommu_table with iommu_table_group

2015-05-31 Thread David Gibson
On Fri, May 29, 2015 at 06:44:40PM +1000, Alexey Kardashevskiy wrote: Modern IBM POWERPC systems support multiple (currently two) TCE tables per IOMMU group (a.k.a. PE). This adds a iommu_table_group container for TCE tables. Right now just one table is supported. This defines

Re: [PATCH kernel v11 09/34] vfio: powerpc/spapr: Move locked_vm accounting to helpers

2015-05-31 Thread David Gibson
On Fri, May 29, 2015 at 06:44:33PM +1000, Alexey Kardashevskiy wrote: There moves locked pages accounting to helpers. Later they will be reused for Dynamic DMA windows (DDW). This reworks debug messages to show the current value and the limit. This stores the locked pages number in the

Re: [PATCH v2] arm/arm64: KVM: Properly account for guest CPU time

2015-05-31 Thread Christoffer Dall
Hi Mario, On Fri, May 29, 2015 at 03:34:47PM -0700, Mario Smarduch wrote: On 05/28/2015 11:49 AM, Christoffer Dall wrote: Until now we have been calling kvm_guest_exit after re-enabling interrupts when we come back from the guest, but this has the unfortunate effect that CPU time