Re: [PATCH 3/4] KVM: PPC: Add support for IOMMU in-kernel handling

2013-06-16 Thread Benjamin Herrenschmidt
On Sun, 2013-06-16 at 21:13 -0600, Alex Williamson wrote: > IOMMU groups themselves don't provide security, they're accessed by > interfaces like VFIO, which provide the security. Given a brief look, I > agree, this looks like a possible backdoor. The typical VFIO way to > handle this would be t

Re: [PATCH 3/4] KVM: PPC: Add support for IOMMU in-kernel handling

2013-06-16 Thread Alex Williamson
On Mon, 2013-06-17 at 08:39 +1000, Benjamin Herrenschmidt wrote: > On Wed, 2013-06-05 at 16:11 +1000, Alexey Kardashevskiy wrote: > > +long kvm_vm_ioctl_create_spapr_tce_iommu(struct kvm *kvm, > > + struct kvm_create_spapr_tce_iommu *args) > > +{ > > + struct kvmppc_spapr_tce_ta

Re: [PATCH 3/4] KVM: PPC: Add support for IOMMU in-kernel handling

2013-06-16 Thread Benjamin Herrenschmidt
On Wed, 2013-06-05 at 16:11 +1000, Alexey Kardashevskiy wrote: > +long kvm_vm_ioctl_create_spapr_tce_iommu(struct kvm *kvm, > + struct kvm_create_spapr_tce_iommu *args) > +{ > + struct kvmppc_spapr_tce_table *tt = NULL; > + struct iommu_group *grp; > + struct iommu_t

Re: [PATCH 3/4] KVM: PPC: Add support for IOMMU in-kernel handling

2013-06-16 Thread Alexander Graf
On 05.06.2013, at 08:11, Alexey Kardashevskiy wrote: > This allows the host kernel to handle H_PUT_TCE, H_PUT_TCE_INDIRECT > and H_STUFF_TCE requests without passing them to QEMU, which should > save time on switching to QEMU and back. > > Both real and virtual modes are supported - whenever the

Re: [PATCH 1/4] KVM: PPC: Add support for multiple-TCE hcalls

2013-06-16 Thread Alexander Graf
On 05.06.2013, at 08:11, Alexey Kardashevskiy wrote: > This adds real mode handlers for the H_PUT_TCE_INDIRECT and > H_STUFF_TCE hypercalls for QEMU emulated devices such as IBMVIO > devices or emulated PCI. These calls allow adding multiple entries > (up to 512) into the TCE table in one call w

[PATCH qom-cpu v2 01/29] kvm: Change kvm_cpu_synchronize_state() argument to CPUState

2013-06-16 Thread Andreas Färber
It no longer relies on CPUArchState since 20d695a. Reviewed-by: liguang Signed-off-by: Andreas Färber --- hw/ppc/spapr_rtas.c | 2 +- include/sysemu/kvm.h | 4 ++-- kvm-all.c| 4 +--- kvm-stub.c | 2 +- target-i386/kvm.c| 10 +- 5 files changed, 10 inserti

[PATCH qom-cpu v2 20/29] kvm: Change kvm_remove_all_breakpoints() argument to CPUState

2013-06-16 Thread Andreas Färber
Signed-off-by: Andreas Färber --- gdbstub.c| 2 +- include/sysemu/kvm.h | 2 +- kvm-all.c| 5 ++--- kvm-stub.c | 2 +- 4 files changed, 5 insertions(+), 6 deletions(-) diff --git a/gdbstub.c b/gdbstub.c index 3101a43..9e7f7a1 100644 --- a/gdbstub.c +++ b/gdbstub

[PATCH qom-cpu v2 11/29] kvm: Change kvm_cpu_exec() argument to CPUState

2013-06-16 Thread Andreas Färber
Signed-off-by: Andreas Färber --- cpus.c | 2 +- include/sysemu/kvm.h | 2 +- kvm-all.c| 3 +-- kvm-stub.c | 4 ++-- 4 files changed, 5 insertions(+), 6 deletions(-) diff --git a/cpus.c b/cpus.c index bbaf13c..47ab818 100644 --- a/cpus.c +++ b/cpus.c @@ -752,7

[PATCH qom-cpu v2 09/29] cpu: Turn cpu_dump_{state,statistics}() into CPUState hooks

2013-06-16 Thread Andreas Färber
Make cpustats monitor command available unconditionally. Signed-off-by: Andreas Färber --- bsd-user/main.c | 3 ++- cpus.c| 2 +- exec.c| 3 ++- include/exec/cpu-all.h| 10 -- include/qemu/log.h| 2 +-

[PATCH qom-cpu v2 07/29] kvm: Change kvm_set_signal_mask() argument to CPUState

2013-06-16 Thread Andreas Färber
CPUArchState is no longer needed. Signed-off-by: Andreas Färber --- cpus.c | 3 ++- include/sysemu/kvm.h | 2 +- kvm-all.c| 3 +-- kvm-stub.c | 2 +- 4 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cpus.c b/cpus.c index fe19962..fca5e1f 100644 -

[PATCH qom-cpu v2 10/29] kvm: Change kvm_handle_internal_error() argument to CPUState

2013-06-16 Thread Andreas Färber
Signed-off-by: Andreas Färber --- kvm-all.c | 6 ++ 1 file changed, 2 insertions(+), 4 deletions(-) diff --git a/kvm-all.c b/kvm-all.c index 1cd4573..1675311 100644 --- a/kvm-all.c +++ b/kvm-all.c @@ -1520,10 +1520,8 @@ static void kvm_handle_io(uint16_t port, void *data, int direction, int

[PATCH qom-cpu v2 02/29] kvm: Change cpu_synchronize_state() argument to CPUState

2013-06-16 Thread Andreas Färber
Change Monitor::mon_cpu to CPUState as well. In cpu_synchronize_all_states() use qemu_for_each_cpu() now. Reviewed-by: liguang Signed-off-by: Andreas Färber --- cpus.c | 8 gdbstub.c | 8 hw/i386/kvm/apic.c | 2 +- hw/i386/kvmvapic.c |

Re: [virt-tools-list] cache write back & barriers

2013-06-16 Thread Richard W.M. Jones
On Fri, Jun 14, 2013 at 12:53:04PM +0200, Stefan Hajnoczi wrote: > On Thu, Jun 13, 2013 at 10:47:32AM +0200, folkert wrote: > > Hi, > > > > > > In virt-manager I saw that there's the option for cache writeback for > > > > storage devices. > > > > I'm wondering: does this also make kvm to ignore wr

Re: [PATCH 28/31] mips/kvm: Only use KVM_COALESCED_MMIO_PAGE_OFFSET with KVM_MIPSTE

2013-06-16 Thread Ralf Baechle
On Fri, Jun 07, 2013 at 04:03:32PM -0700, David Daney wrote: > From: David Daney > > The forthcoming MIPSVZ code doesn't currently use this, so it must > only be enabled for KVM_MIPSTE. > > Signed-off-by: David Daney > --- > arch/mips/include/asm/kvm_host.h | 2 ++ > 1 file changed, 2 inserti

Re: [PATCH 00/31] KVM/MIPS: Implement hardware virtualization via the MIPS-VZ extensions.

2013-06-16 Thread Ralf Baechle
On Sun, Jun 09, 2013 at 04:23:51PM -0700, David Daney wrote: > Come to think of it, Emulating SGI hardware might be an interesting > case. There may be old IRIX systems and applications that could be > running low on real hardware. Some of those systems take up a whole > room and draw a lot of p

Re: [PATCH 29/31] mips/kvm: Add MIPSVZ support.

2013-06-16 Thread Ralf Baechle
Acked-by: Ralf Baechle Ralf -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 30/31] mips/kvm: Enable MIPSVZ in Kconfig/Makefile

2013-06-16 Thread Ralf Baechle
Acked-by: Ralf Baechle Ralf -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 27/31] mips/kvm: Gate the use of kvm_local_flush_tlb_all() by KVM_MIPSTE

2013-06-16 Thread Ralf Baechle
On Fri, Jun 07, 2013 at 04:03:31PM -0700, David Daney wrote: > From: David Daney > > Only the trap-and-emulate KVM code needs a Special tlb flusher. All > other configurations should use the regular version. > > Signed-off-by: David Daney > --- > arch/mips/include/asm/mmu_context.h | 2 +- >

Re: [PATCH 31/31] mips/kvm: Allow for upto 8 KVM vcpus per vm.

2013-06-16 Thread Ralf Baechle
Acked-by: Ralf Baechle Ralf -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 26/31] mips/kvm: Split up Kconfig and Makefile definitions in preperation for MIPSVZ.

2013-06-16 Thread Ralf Baechle
The Trademark guys (and readability in general) sould probably be happier if MIPSTE was spelled as MIPS_TE and for that matter, MIPZVZ as MIPS_VZ? Other than that, Acked-by: Ralf Baechle Ralf -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord.

Re: [PATCH 25/31] mips/kvm: Add some asm-offsets constants used by MIPSVZ.

2013-06-16 Thread Ralf Baechle
Patch looks ok but why not combine this patch with the previous one? Ralf -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 24/31] mips/kvm: Add thread_struct fields used by MIPSVZ hosts.

2013-06-16 Thread Ralf Baechle
Acked-by: Ralf Baechle Ralf -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 23/31] mips/kvm: Hook into CP unusable exception handler.

2013-06-16 Thread Ralf Baechle
On Fri, Jun 07, 2013 at 04:03:27PM -0700, David Daney wrote: > From: David Daney > > The MIPS VZ KVM code needs this to be able to manage the FPU. > > Signed-off-by: David Daney Looks good, Acked-by: Ralf Baechle . However I get cold shivers at the thought of SMTC FPU management with VZ, it

Re: [PATCH 22/31] mips/kvm: Split get_new_mmu_context into two parts.

2013-06-16 Thread Ralf Baechle
Acked-by: Ralf Baechle Ralf -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 21/31] mips/kvm: Allow set_except_vector() to be used from MIPSVZ code.

2013-06-16 Thread Ralf Baechle
On Fri, Jun 07, 2013 at 04:03:25PM -0700, David Daney wrote: > From: David Daney > > We need to move it out of __init so we don't have section mismatch problems. > > Signed-off-by: David Daney > --- > arch/mips/include/asm/uasm.h | 2 +- > arch/mips/kernel/traps.c | 2 +- > 2 files change

Re: [PATCH 20/31] mips/kvm: Hook into TLB fault handlers.

2013-06-16 Thread Ralf Baechle
Acked-by: Ralf Baechle Ralf -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html

Re: [PATCH 19/31] mips/kvm: Add host definitions for MIPS VZ based host.

2013-06-16 Thread Ralf Baechle
Acked-by: Ralf Baechle Ralf -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html