All of lore.kernel.org
 help / color / mirror / Atom feed
* [PATCH 3.9-rc1 0/3] KVM/ARM core fixes for 3.9-rc1
@ 2013-02-15 19:20 ` Marc Zyngier
  0 siblings, 0 replies; 8+ messages in thread
From: Marc Zyngier @ 2013-02-15 19:20 UTC (permalink / raw)
  To: c.dall; +Cc: kvmarm, kvm, linux-arm-kernel

Here's a number of patches to cope with the churn that occured in
kvm-next, and breaks the compilation in next-20130215.

No big deal, just regular breakage...

Tested on TC2.

Marc Zyngier (3):
  ARM: KVM: fix kvm_arch_{prepare,commit}_memory_region
  ARM: KVM: Rename KVM_MEMORY_SLOTS -> KVM_USER_MEM_SLOTS
  ARM: KVM: fix compilation after removal of user_alloc from struct
    kvm_memory_slot

 arch/arm/include/asm/kvm_host.h | 2 +-
 arch/arm/kvm/arm.c              | 4 ++--
 arch/arm/kvm/mmu.c              | 5 -----
 3 files changed, 3 insertions(+), 8 deletions(-)

-- 
1.8.1.2



^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PATCH 3.9-rc1 0/3] KVM/ARM core fixes for 3.9-rc1
@ 2013-02-15 19:20 ` Marc Zyngier
  0 siblings, 0 replies; 8+ messages in thread
From: Marc Zyngier @ 2013-02-15 19:20 UTC (permalink / raw)
  To: linux-arm-kernel

Here's a number of patches to cope with the churn that occured in
kvm-next, and breaks the compilation in next-20130215.

No big deal, just regular breakage...

Tested on TC2.

Marc Zyngier (3):
  ARM: KVM: fix kvm_arch_{prepare,commit}_memory_region
  ARM: KVM: Rename KVM_MEMORY_SLOTS -> KVM_USER_MEM_SLOTS
  ARM: KVM: fix compilation after removal of user_alloc from struct
    kvm_memory_slot

 arch/arm/include/asm/kvm_host.h | 2 +-
 arch/arm/kvm/arm.c              | 4 ++--
 arch/arm/kvm/mmu.c              | 5 -----
 3 files changed, 3 insertions(+), 8 deletions(-)

-- 
1.8.1.2

^ permalink raw reply	[flat|nested] 8+ messages in thread

* [PATCH 3.9-rc1 1/3] ARM: KVM: fix kvm_arch_{prepare,commit}_memory_region
  2013-02-15 19:20 ` Marc Zyngier
@ 2013-02-15 19:20   ` Marc Zyngier
  -1 siblings, 0 replies; 8+ messages in thread
From: Marc Zyngier @ 2013-02-15 19:20 UTC (permalink / raw)
  To: c.dall; +Cc: kvmarm, kvm, linux-arm-kernel

Commit f82a8cfe9 (KVM: struct kvm_memory_slot.user_alloc -> bool)
broke the ARM KVM port by changing the prototype of two global
functions.

Apply the same change to fix the compilation breakage.

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
---
 arch/arm/kvm/arm.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/kvm/arm.c b/arch/arm/kvm/arm.c
index 9ada554..5a93698 100644
--- a/arch/arm/kvm/arm.c
+++ b/arch/arm/kvm/arm.c
@@ -232,7 +232,7 @@ int kvm_arch_prepare_memory_region(struct kvm *kvm,
 				   struct kvm_memory_slot *memslot,
 				   struct kvm_memory_slot old,
 				   struct kvm_userspace_memory_region *mem,
-				   int user_alloc)
+				   bool user_alloc)
 {
 	return 0;
 }
@@ -240,7 +240,7 @@ int kvm_arch_prepare_memory_region(struct kvm *kvm,
 void kvm_arch_commit_memory_region(struct kvm *kvm,
 				   struct kvm_userspace_memory_region *mem,
 				   struct kvm_memory_slot old,
-				   int user_alloc)
+				   bool user_alloc)
 {
 }
 
-- 
1.8.1.2



^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH 3.9-rc1 1/3] ARM: KVM: fix kvm_arch_{prepare, commit}_memory_region
@ 2013-02-15 19:20   ` Marc Zyngier
  0 siblings, 0 replies; 8+ messages in thread
From: Marc Zyngier @ 2013-02-15 19:20 UTC (permalink / raw)
  To: linux-arm-kernel

Commit f82a8cfe9 (KVM: struct kvm_memory_slot.user_alloc -> bool)
broke the ARM KVM port by changing the prototype of two global
functions.

Apply the same change to fix the compilation breakage.

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
---
 arch/arm/kvm/arm.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

diff --git a/arch/arm/kvm/arm.c b/arch/arm/kvm/arm.c
index 9ada554..5a93698 100644
--- a/arch/arm/kvm/arm.c
+++ b/arch/arm/kvm/arm.c
@@ -232,7 +232,7 @@ int kvm_arch_prepare_memory_region(struct kvm *kvm,
 				   struct kvm_memory_slot *memslot,
 				   struct kvm_memory_slot old,
 				   struct kvm_userspace_memory_region *mem,
-				   int user_alloc)
+				   bool user_alloc)
 {
 	return 0;
 }
@@ -240,7 +240,7 @@ int kvm_arch_prepare_memory_region(struct kvm *kvm,
 void kvm_arch_commit_memory_region(struct kvm *kvm,
 				   struct kvm_userspace_memory_region *mem,
 				   struct kvm_memory_slot old,
-				   int user_alloc)
+				   bool user_alloc)
 {
 }
 
-- 
1.8.1.2

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH 3.9-rc1 2/3] ARM: KVM: Rename KVM_MEMORY_SLOTS -> KVM_USER_MEM_SLOTS
  2013-02-15 19:20 ` Marc Zyngier
@ 2013-02-15 19:20   ` Marc Zyngier
  -1 siblings, 0 replies; 8+ messages in thread
From: Marc Zyngier @ 2013-02-15 19:20 UTC (permalink / raw)
  To: c.dall; +Cc: kvmarm, kvm, linux-arm-kernel

Commit bbacc0c (KVM: Rename KVM_MEMORY_SLOTS -> KVM_USER_MEM_SLOTS)
broke KVM/ARM by changing a global #define.

Apply the same change to fix the compilation breakage.

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
---
 arch/arm/include/asm/kvm_host.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/include/asm/kvm_host.h b/arch/arm/include/asm/kvm_host.h
index dfe9886..d1736a5 100644
--- a/arch/arm/include/asm/kvm_host.h
+++ b/arch/arm/include/asm/kvm_host.h
@@ -26,7 +26,7 @@
 #include <asm/kvm_arch_timer.h>
 
 #define KVM_MAX_VCPUS CONFIG_KVM_ARM_MAX_VCPUS
-#define KVM_MEMORY_SLOTS 32
+#define KVM_USER_MEM_SLOTS 32
 #define KVM_PRIVATE_MEM_SLOTS 4
 #define KVM_COALESCED_MMIO_PAGE_OFFSET 1
 #define KVM_HAVE_ONE_REG
-- 
1.8.1.2



^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH 3.9-rc1 2/3] ARM: KVM: Rename KVM_MEMORY_SLOTS -> KVM_USER_MEM_SLOTS
@ 2013-02-15 19:20   ` Marc Zyngier
  0 siblings, 0 replies; 8+ messages in thread
From: Marc Zyngier @ 2013-02-15 19:20 UTC (permalink / raw)
  To: linux-arm-kernel

Commit bbacc0c (KVM: Rename KVM_MEMORY_SLOTS -> KVM_USER_MEM_SLOTS)
broke KVM/ARM by changing a global #define.

Apply the same change to fix the compilation breakage.

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
---
 arch/arm/include/asm/kvm_host.h | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/arch/arm/include/asm/kvm_host.h b/arch/arm/include/asm/kvm_host.h
index dfe9886..d1736a5 100644
--- a/arch/arm/include/asm/kvm_host.h
+++ b/arch/arm/include/asm/kvm_host.h
@@ -26,7 +26,7 @@
 #include <asm/kvm_arch_timer.h>
 
 #define KVM_MAX_VCPUS CONFIG_KVM_ARM_MAX_VCPUS
-#define KVM_MEMORY_SLOTS 32
+#define KVM_USER_MEM_SLOTS 32
 #define KVM_PRIVATE_MEM_SLOTS 4
 #define KVM_COALESCED_MMIO_PAGE_OFFSET 1
 #define KVM_HAVE_ONE_REG
-- 
1.8.1.2

^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH 3.9-rc1 3/3] ARM: KVM: fix compilation after removal of user_alloc from struct kvm_memory_slot
  2013-02-15 19:20 ` Marc Zyngier
@ 2013-02-15 19:20   ` Marc Zyngier
  -1 siblings, 0 replies; 8+ messages in thread
From: Marc Zyngier @ 2013-02-15 19:20 UTC (permalink / raw)
  To: c.dall; +Cc: kvmarm, kvm, linux-arm-kernel

Commit 7a905b1 (KVM: Remove user_alloc from struct kvm_memory_slot)
broke KVM/ARM by removing the user_alloc field from a public structure.

As we only used this field to alert the user that we didn't support
this operation mode, there is no harm in discarding this bit of code
without any remorse.

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
---
 arch/arm/kvm/mmu.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/arch/arm/kvm/mmu.c b/arch/arm/kvm/mmu.c
index f30e131..99e07c7 100644
--- a/arch/arm/kvm/mmu.c
+++ b/arch/arm/kvm/mmu.c
@@ -633,11 +633,6 @@ int kvm_handle_guest_abort(struct kvm_vcpu *vcpu, struct kvm_run *run)
 	}
 
 	memslot = gfn_to_memslot(vcpu->kvm, gfn);
-	if (!memslot->user_alloc) {
-		kvm_err("non user-alloc memslots not supported\n");
-		ret = -EINVAL;
-		goto out_unlock;
-	}
 
 	ret = user_mem_abort(vcpu, fault_ipa, gfn, memslot, fault_status);
 	if (ret == 0)
-- 
1.8.1.2



^ permalink raw reply related	[flat|nested] 8+ messages in thread

* [PATCH 3.9-rc1 3/3] ARM: KVM: fix compilation after removal of user_alloc from struct kvm_memory_slot
@ 2013-02-15 19:20   ` Marc Zyngier
  0 siblings, 0 replies; 8+ messages in thread
From: Marc Zyngier @ 2013-02-15 19:20 UTC (permalink / raw)
  To: linux-arm-kernel

Commit 7a905b1 (KVM: Remove user_alloc from struct kvm_memory_slot)
broke KVM/ARM by removing the user_alloc field from a public structure.

As we only used this field to alert the user that we didn't support
this operation mode, there is no harm in discarding this bit of code
without any remorse.

Signed-off-by: Marc Zyngier <marc.zyngier@arm.com>
---
 arch/arm/kvm/mmu.c | 5 -----
 1 file changed, 5 deletions(-)

diff --git a/arch/arm/kvm/mmu.c b/arch/arm/kvm/mmu.c
index f30e131..99e07c7 100644
--- a/arch/arm/kvm/mmu.c
+++ b/arch/arm/kvm/mmu.c
@@ -633,11 +633,6 @@ int kvm_handle_guest_abort(struct kvm_vcpu *vcpu, struct kvm_run *run)
 	}
 
 	memslot = gfn_to_memslot(vcpu->kvm, gfn);
-	if (!memslot->user_alloc) {
-		kvm_err("non user-alloc memslots not supported\n");
-		ret = -EINVAL;
-		goto out_unlock;
-	}
 
 	ret = user_mem_abort(vcpu, fault_ipa, gfn, memslot, fault_status);
 	if (ret == 0)
-- 
1.8.1.2

^ permalink raw reply related	[flat|nested] 8+ messages in thread

end of thread, other threads:[~2013-02-15 19:20 UTC | newest]

Thread overview: 8+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2013-02-15 19:20 [PATCH 3.9-rc1 0/3] KVM/ARM core fixes for 3.9-rc1 Marc Zyngier
2013-02-15 19:20 ` Marc Zyngier
2013-02-15 19:20 ` [PATCH 3.9-rc1 1/3] ARM: KVM: fix kvm_arch_{prepare,commit}_memory_region Marc Zyngier
2013-02-15 19:20   ` [PATCH 3.9-rc1 1/3] ARM: KVM: fix kvm_arch_{prepare, commit}_memory_region Marc Zyngier
2013-02-15 19:20 ` [PATCH 3.9-rc1 2/3] ARM: KVM: Rename KVM_MEMORY_SLOTS -> KVM_USER_MEM_SLOTS Marc Zyngier
2013-02-15 19:20   ` Marc Zyngier
2013-02-15 19:20 ` [PATCH 3.9-rc1 3/3] ARM: KVM: fix compilation after removal of user_alloc from struct kvm_memory_slot Marc Zyngier
2013-02-15 19:20   ` Marc Zyngier

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.