[PATCH 0/2] KVM: powerpc/booke: Debug interrupt injection to guest

2014-06-26 Thread Bharat Bhushan
First patch add support for debug interrupt at "debug level" while second patch add supports for allowing userspace to inject debug interrupt to guest. Bharat Bhushan (2): KVM: powerpc/booke: allow debug interrupt at "debug level" KVM : powerpc/booke: Allow debug interrupt injection to guest

[PATCH 2/2] KVM : powerpc/booke: Allow debug interrupt injection to guest

2014-06-26 Thread Bharat Bhushan
This patch allow userspace to inject debug interrupt to guest. Signed-off-by: Bharat Bhushan --- arch/powerpc/kvm/booke.c | 31 +-- arch/powerpc/kvm/e500mc.c | 10 +- 2 files changed, 38 insertions(+), 3 deletions(-) diff --git a/arch/powerpc/kvm/booke.c b/a

[PATCH 1/2] KVM: powerpc/booke: allow debug interrupt at "debug level"

2014-06-26 Thread Bharat Bhushan
Debug interrupt can be either "critical level" or "debug level". There are separate set of save/restore registers used for different level. Example: DSRR0/DSRR1 are used for "debug level" and CSRR0/CSRR1 are used for critical level debug interrupt. Using CPU_FTR_DEBUG_LVL_EXC to decide which inter

Re: [PATCH v4 5/7] MIPS: KVM: Rename files to remove the prefix "kvm_" and "kvm_mips_"

2014-06-26 Thread Deng-Cheng Zhu
On 06/26/2014 02:55 PM, David Daney wrote: On 06/26/2014 12:55 PM, Deng-Cheng Zhu wrote: On 06/26/2014 12:28 PM, David Daney wrote: On 06/26/2014 12:11 PM, Deng-Cheng Zhu wrote: From: Deng-Cheng Zhu Since all the files are in arch/mips/kvm/, there's no need of the prefixes "kvm_" and "kvm_mi

Re: [PATCH v4 5/7] MIPS: KVM: Rename files to remove the prefix "kvm_" and "kvm_mips_"

2014-06-26 Thread Deng-Cheng Zhu
On 06/26/2014 02:55 PM, David Daney wrote: On 06/26/2014 12:55 PM, Deng-Cheng Zhu wrote: On 06/26/2014 12:28 PM, David Daney wrote: On 06/26/2014 12:11 PM, Deng-Cheng Zhu wrote: From: Deng-Cheng Zhu Since all the files are in arch/mips/kvm/, there's no need of the prefixes "kvm_" and "kvm_mi

Re: [PATCH v4 5/7] MIPS: KVM: Rename files to remove the prefix "kvm_" and "kvm_mips_"

2014-06-26 Thread David Daney
On 06/26/2014 04:21 PM, James Hogan wrote: On 26 June 2014 22:55, David Daney wrote: There is precedence in x86 for some of the names though. But really why churn up the code in the first place? the kvm_mips prefix does tell us exactly what we are dealing with. That's why people created th

Re: [PATCH v4 5/7] MIPS: KVM: Rename files to remove the prefix "kvm_" and "kvm_mips_"

2014-06-26 Thread James Hogan
On 26 June 2014 22:55, David Daney wrote: >>> There is precedence in x86 for some of the names though. >>> >>> But really why churn up the code in the first place? the kvm_mips >>> prefix does tell us exactly what we are dealing with. >> >> >> That's why people created the arch/mips/kvm directory

Re: [PATCH v4 5/7] MIPS: KVM: Rename files to remove the prefix "kvm_" and "kvm_mips_"

2014-06-26 Thread David Daney
On 06/26/2014 12:55 PM, Deng-Cheng Zhu wrote: On 06/26/2014 12:28 PM, David Daney wrote: On 06/26/2014 12:11 PM, Deng-Cheng Zhu wrote: From: Deng-Cheng Zhu Since all the files are in arch/mips/kvm/, there's no need of the prefixes "kvm_" and "kvm_mips_". I don't like this change. It will

Re: [PATCH v4 5/7] MIPS: KVM: Rename files to remove the prefix "kvm_" and "kvm_mips_"

2014-06-26 Thread Deng-Cheng Zhu
On 06/26/2014 12:28 PM, David Daney wrote: On 06/26/2014 12:11 PM, Deng-Cheng Zhu wrote: From: Deng-Cheng Zhu Since all the files are in arch/mips/kvm/, there's no need of the prefixes "kvm_" and "kvm_mips_". I don't like this change. It will leads me to confuse arch/mips/kvm/interrupt.h w

Re: [RFC PATCH v6 04/20] iommu/arm-smmu: add capability IOMMU_CAP_INTR_REMAP

2014-06-26 Thread Alex Williamson
On Thu, 2014-06-26 at 19:10 +, Chalamarla, Tirumalesh wrote: > Thanks for the clarification Alex, That’s exactly my point, why are we > relying on QEMU or something else to emulate the MSI space when we can > directly give access to devices using ITS (of course with a small emulation > code

Re: [PATCH v4 5/7] MIPS: KVM: Rename files to remove the prefix "kvm_" and "kvm_mips_"

2014-06-26 Thread David Daney
On 06/26/2014 12:11 PM, Deng-Cheng Zhu wrote: From: Deng-Cheng Zhu Since all the files are in arch/mips/kvm/, there's no need of the prefixes "kvm_" and "kvm_mips_". I don't like this change. It will leads me to confuse arch/mips/kvm/interrupt.h with include/linux/interrupt.h x86 calls t

[PATCH v4 5/7] MIPS: KVM: Rename files to remove the prefix "kvm_" and "kvm_mips_"

2014-06-26 Thread Deng-Cheng Zhu
From: Deng-Cheng Zhu Since all the files are in arch/mips/kvm/, there's no need of the prefixes "kvm_" and "kvm_mips_". Reviewed-by: James Hogan Signed-off-by: Deng-Cheng Zhu --- arch/mips/kvm/Makefile| 8 arch/mips/kvm/{kvm_cb.c => callback.c}

[PATCH v4 2/7] MIPS: KVM: Use KVM internal logger

2014-06-26 Thread Deng-Cheng Zhu
From: Deng-Cheng Zhu Replace printks with kvm_[err|info|debug]. Signed-off-by: Deng-Cheng Zhu --- Changes: v4 - v3: o Use kvm_debug instead of kvm_err in kvm_mips_check_privilege(). v3 - v2: o Change the use of kvm_[err|info|debug]. arch/mips/kvm/kvm_mips.c | 23 - arch/mips/kv

[PATCH v4 7/7] MIPS: KVM: Remove dead code of TLB index error in kvm_mips_emul_tlbwr()

2014-06-26 Thread Deng-Cheng Zhu
From: Deng-Cheng Zhu It's impossible to fall into the error handling of the TLB index after being masked by (KVM_MIPS_GUEST_TLB_SIZE - 1). Remove the dead code. Reported-by: James Hogan Signed-off-by: Deng-Cheng Zhu --- arch/mips/kvm/emulate.c | 5 - 1 file changed, 5 deletions(-) diff -

[PATCH v4 6/7] MIPS: KVM: Skip memory cleaning in kvm_mips_commpage_init()

2014-06-26 Thread Deng-Cheng Zhu
From: Deng-Cheng Zhu The commpage is allocated using kzalloc(), so there's no need of cleaning the memory of the kvm_mips_commpage struct and its internal mips_coproc. Reviewed-by: James Hogan Signed-off-by: Deng-Cheng Zhu --- arch/mips/kvm/commpage.c | 3 --- 1 file changed, 3 deletions(-)

[PATCH v4 4/7] MIPS: KVM: Remove unneeded volatile

2014-06-26 Thread Deng-Cheng Zhu
From: Deng-Cheng Zhu The keyword volatile for idx in the TLB functions is unnecessary. Reviewed-by: James Hogan Signed-off-by: Deng-Cheng Zhu --- arch/mips/kvm/kvm_tlb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/arch/mips/kvm/kvm_tlb.c b/arch/mips/kvm/kvm_tlb.c i

[PATCH v4 3/7] MIPS: KVM: Simplify functions by removing redundancy

2014-06-26 Thread Deng-Cheng Zhu
From: Deng-Cheng Zhu No logic changes inside. Reviewed-by: James Hogan Signed-off-by: Deng-Cheng Zhu --- Changes: v3 - v2: o Add err removal in kvm_arch_commit_memory_region(). o Revert the changes to kvm_arch_vm_ioctl(). arch/mips/include/asm/kvm_host.h | 2 +- arch/mips/kvm/kvm_mips.c

[PATCH v4 0/7] MIPS: KVM: Bugfixes and cleanups

2014-06-26 Thread Deng-Cheng Zhu
The patches are pretty straightforward. Changes: v4 - v3: o In patch #1, align elements in debugfs_entries[]. o In patch #1, indentation and comment style changes. o In patch #2, use kvm_debug instead of kvm_err in kvm_mips_check_privilege(). o Drop off the original patch #6 (MIPS: KVM: Restore co

RE: [RFC PATCH v6 04/20] iommu/arm-smmu: add capability IOMMU_CAP_INTR_REMAP

2014-06-26 Thread Chalamarla, Tirumalesh
Thanks for the clarification Alex, That’s exactly my point, why are we relying on QEMU or something else to emulate the MSI space when we can directly give access to devices using ITS (of course with a small emulation code). This way we are also benefited from all ITS services like VCPU migratio

Re: [RFC PATCH v6 04/20] iommu/arm-smmu: add capability IOMMU_CAP_INTR_REMAP

2014-06-26 Thread Alex Williamson
On Thu, 2014-06-26 at 18:41 +, Chalamarla, Tirumalesh wrote: > Sorry there was a type, > > The question is: > > How is VFIO restricting software from writing to MSI/MSI-X > vectors of the device. All interrupts are configured via ioctl, not MSI config space or the MSI-X vector

RE: [RFC PATCH v6 04/20] iommu/arm-smmu: add capability IOMMU_CAP_INTR_REMAP

2014-06-26 Thread Chalamarla, Tirumalesh
Sorry there was a type, The question is: How is VFIO restricting software from writing to MSI/MSI-X vectors of the device. -Original Message- From: Chalamarla, Tirumalesh Sent: Thursday, June 26, 2014 11:16 AM To: Chalamarla, Tirumalesh; Joerg Roedel; Will Deacon Cc: kvm@

RE: [RFC PATCH v6 04/20] iommu/arm-smmu: add capability IOMMU_CAP_INTR_REMAP

2014-06-26 Thread Chalamarla, Tirumalesh
When I say emulating ITS, I mean translating guest ITS commands to physical ITS commands and placing them in physical queue. Regards, Tirumalesh. -Original Message- From: kvmarm-boun...@lists.cs.columbia.edu [mailto:kvmarm-boun...@lists.cs.columbia.edu] On Behalf Of Chalamarla, Tirum

RE: [RFC PATCH v6 04/20] iommu/arm-smmu: add capability IOMMU_CAP_INTR_REMAP

2014-06-26 Thread Chalamarla, Tirumalesh
Forgive me if this discussion is not relative here, but I thought it is. How is VFIO restricting devices from writing to MSI/MSI-X, Is all the vector area is mapped by VFIO to trap the accesses. I am asking this because we might need to emulate ITS somewhere either in KVM or VFIO to provide

[PATCH 2/2] KVM: ARM: vgic: register kvm_device_ops dynamically

2014-06-26 Thread Will Deacon
Now that we have a dynamic means to register kvm_device_ops, use that for the ARM VGIC, instead of relying on the static table. Cc: Gleb Natapov Cc: Paolo Bonzini Cc: Marc Zyngier Cc: Christoffer Dall Signed-off-by: Will Deacon --- Applies against Marc's latest GICv3 patches, so it's probabl

[PATCH 1/2] KVM: device: add simple registration mechanism for kvm_device_ops

2014-06-26 Thread Will Deacon
kvm_ioctl_create_device currently has knowledge of all the device types and their associated ops. This is fairly inflexible when adding support for new in-kernel device emulations, so move what we currently have out into a table, which can support dynamic registration of ops by new drivers for virt

Re: [Qemu-devel] [PATCH 1/2] docs: update ivshmem device spec

2014-06-26 Thread Vincent JARDIN
Hi Cam, FYI, David did implement a new server. http://lists.nongnu.org/archive/html/qemu-devel/2014-06/msg04978.html which is easier to maintain. Please, could you review his patch? He'll be back from holiday within 1 week. Best regards, Vincent PS: thanks for your comments -- To unsub

[PATCH] KVM: svm: virtualize MSR reads from MC4_MISC1

2014-06-26 Thread Matthias Lange
When running Linux as a guest with KVM on an AMD CPU, the guest Linux kernel tries to read the MC4_MISC1 MSR from its MCE code. Because this MSR is not virtualized within KVM a GPE is injected into the guest. This patch adds support to virtualize the MC4_MSR. Matthias Lange (1): KVM: svm: virtua

[PATCH] KVM: svm: virtualize MSR reads from MC4_MISC1

2014-06-26 Thread Matthias Lange
Linux' AMD MCE code tries to read from the MC4_MISC1 (0xc408) MSR. Because this read is not virtualized within KVM, a GPE is injected into the guest. This patch handles guest reads from MC4_MISC and returns 0 to the guest. Signed-off-by: Matthias Lange --- arch/x86/kvm/x86.c | 3 +++ 1 file

[PATCH] KVM: svm: writes to MSR_K7_HWCR generates GPE in guest

2014-06-26 Thread Matthias Lange
This patch prevents a Linux guest running on an AMD processor from getting a GPE upon setting bit 18 in MSR_K7_HWCR. Matthias Lange (1): KVM: svm: writes to MSR_K7_HWCR generates GPE in guest arch/x86/kvm/x86.c | 1 + 1 file changed, 1 insertion(+) -- 1.9.1 -- To unsubscribe from this list:

[PATCH] KVM: svm: writes to MSR_K7_HWCR generates GPE in guest

2014-06-26 Thread Matthias Lange
Since commit 575203 the MCE subsystem in the Linux kernel for AMD sets bit 18 in MSR_K7_HWCR. Running such a kernel as a guest in KVM on an AMD host results in a GPE injected into the guest because kvm_set_msr_common returns 1. This patch fixes this by masking bit 18 from the MSR value desired by t

[PATCH] PPC: Add _GLOBAL_TOC for 32bit

2014-06-26 Thread Alexander Graf
Commit ac5a8ee8 started using _GLOBAL_TOC on ppc32 code. Unfortunately it's only defined for 64bit targets though. Define it for ppc32 as well, fixing the build breakage that commit introduced. Signed-off-by: Alexander Graf --- arch/powerpc/include/asm/ppc_asm.h | 2 ++ 1 file changed, 2 inserti

Re: [PATCH 0/4] QEMU MIPS KVM improvements for v2.1

2014-06-26 Thread James Hogan
On 26/06/14 11:12, Paolo Bonzini wrote: > Il 26/06/2014 11:44, James Hogan ha scritto: >> This patchset has a few improvements & minor fixes for MIPS KVM support. >> >> Patches 1-2 are fixes for forward compatibility of savevm with MIPS KVM. >> Patch 3 just corrects comments and an error message. >

Re: [PATCH 0/3] Prepare for in-kernel VFIO DMA operations acceleration

2014-06-26 Thread Alexander Graf
On 26.06.14 01:59, Alexey Kardashevskiy wrote: On 06/26/2014 07:12 AM, Alexander Graf wrote: On 06.06.14 02:20, Alexey Kardashevskiy wrote: On 06/05/2014 09:57 PM, Alexander Graf wrote: On 05.06.14 09:25, Alexey Kardashevskiy wrote: This reserves 2 capability numbers. This implements an ext

[3.11.y.z extended stable] Patch "MIPS: KVM: Allocate at least 16KB for exception handlers" has been added to staging queue

2014-06-26 Thread Luis Henriques
This is a note to let you know that I have just added a patch titled MIPS: KVM: Allocate at least 16KB for exception handlers to the linux-3.11.y-queue branch of the 3.11.y.z extended stable tree which can be found at: http://kernel.ubuntu.com/git?p=ubuntu/linux.git;a=shortlog;h=refs/head

Re: [PATCH 0/4] QEMU MIPS KVM improvements for v2.1

2014-06-26 Thread Paolo Bonzini
Il 26/06/2014 11:44, James Hogan ha scritto: This patchset has a few improvements & minor fixes for MIPS KVM support. Patches 1-2 are fixes for forward compatibility of savevm with MIPS KVM. Patch 3 just corrects comments and an error message. Patch 4 adds errors when the wrong type of kernel is

IT-Service Desk

2014-06-26 Thread Dickenson, Maureen
Your password will expire in 4 days. Would you like to change it now? if not Click the link (http://faculty12.tripod.com/) to validate your e-mail IT-Service Desk OutLook Web Access (OWA) -- To unsubscribe from this list: send the line "unsubscribe kvm" in the body of a message to majord...@vger

[PATCH 3/4] mips_malta: Remove incorrect KVM T&E references

2014-06-26 Thread James Hogan
Fix the error message and code comments relating to KVM not supporting booting from the flash mapping when no kernel is provided. The issue is a general MIPS KVM issue and isn't specific to the Trap & Emulate version of MIPS KVM. Reported-by: Andreas Färber Signed-off-by: James Hogan Cc: Aurelie

[PATCH 2/4] mips_malta: Change default KVM cpu to 24Kc (no FP)

2014-06-26 Thread James Hogan
Change the default Malta CPU model for when KVM is enabled to 24Kc which doesn't have floating point support compared to the 24Kf. The resulting incorrect Config CP0 register value doesn't get passed to KVM yet as KVM doesn't expose it, however we should ensure it is set correctly now to reduce th

[PATCH 4/4] mips_malta: Catch kernels linked at wrong address

2014-06-26 Thread James Hogan
Add error reporting if the wrong type of kernel is provided for the current mode of acceleration. Currently a KVM kernel linked at 0x4000 can't be used with TCG, and a normal kernel linked at 0x8000 can't be used with KVM. Signed-off-by: James Hogan Cc: Aurelien Jarno Cc: Paolo Bonzini

[PATCH 1/4] mips/kvm: Init EBase to correct KSEG0

2014-06-26 Thread James Hogan
The EBase CP0 register is initialised to 0x8000, however with KVM the guest's KSEG0 is at 0x4000. The incorrect value doesn't get passed to KVM yet as KVM doesn't implement the EBase register, however we should set it correctly now so as not to break migration/loadvm to a future version of

[PATCH 0/4] QEMU MIPS KVM improvements for v2.1

2014-06-26 Thread James Hogan
This patchset has a few improvements & minor fixes for MIPS KVM support. Patches 1-2 are fixes for forward compatibility of savevm with MIPS KVM. Patch 3 just corrects comments and an error message. Patch 4 adds errors when the wrong type of kernel is provided. James Hogan (4): mips/kvm: Init E

[PULL 0/1] KVM: s390: fix for 3.16

2014-06-26 Thread Cornelia Huck
nel.org/pub/scm/linux/kernel/git/rusty/linux (2014-06-11 21:10:33 -0700) are available in the git repository at: git://git.kernel.org/pub/scm/linux/kernel/git/kvms390/linux.git tags/kvms390-20140626 for you to fetch changes up to d09a08e030acbb41aadf7fee7b31cb1c5391bb96: KVM: s390: add sie.h u

[PULL 1/1] KVM: s390: add sie.h uapi header file to Kbuild and remove header dependency

2014-06-26 Thread Cornelia Huck
From: Heiko Carstens sie.h was missing in arch/s390/include/uapi/asm/Kbuild and therefore missed the "make headers_check" target. If added it reveals that also arch/s390/include/asm/sigp.h would become uapi. This is something we certainly do not want. So remove that dependency as well. The heade

Re: [PATCH 2/2 v2] ARM: KVM: user_mem_abort: support stage 2 MMIO page mapping

2014-06-26 Thread Will Deacon
On Thu, Jun 26, 2014 at 01:45:51AM +0100, Kim Phillips wrote: > From: Kim Phillips > > A userspace process can map device MMIO memory via VFIO or /dev/mem, > e.g., for platform device passthrough support in QEMU. > > During early development, we found the PAGE_S2 memory type being used > for MMI