* [Qemu-devel] Fix build breakage to kvm on ppc
@ 2011-02-28 10:49 David Gibson
2011-02-28 21:18 ` [Qemu-devel] " Jan Kiszka
0 siblings, 1 reply; 2+ messages in thread
From: David Gibson @ 2011-02-28 10:49 UTC (permalink / raw)
To: agraf, qemu-devel
Recent changes to the generic kvm support code broke compile of kvm
for ppc. The patch below fixes the errors by adjusting types in the
ppc code, and adding a missing #ifdef.
Please apply.
Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
---
kvm-all.c | 2 ++
target-ppc/kvm.c | 6 +++---
2 files changed, 5 insertions(+), 3 deletions(-)
diff --git a/kvm-all.c b/kvm-all.c
index e6a7de4..fb44e2e 100644
--- a/kvm-all.c
+++ b/kvm-all.c
@@ -998,7 +998,9 @@ int kvm_cpu_exec(CPUState *env)
}
ret = EXCP_INTERRUPT;
+#ifdef KVM_CAP_SET_GUEST_DEBUG
out:
+#endif /* KVM_CAP_SET_GUEST_DEBUG */
env->exit_request = 0;
cpu_single_env = NULL;
return ret;
diff --git a/target-ppc/kvm.c b/target-ppc/kvm.c
index 04b94a3..4fa1be3 100644
--- a/target-ppc/kvm.c
+++ b/target-ppc/kvm.c
@@ -223,7 +223,7 @@ int kvmppc_set_interrupt(CPUState *env, int irq, int level)
#define PPC_INPUT_INT PPC6xx_INPUT_INT
#endif
-int kvm_arch_pre_run(CPUState *env, struct kvm_run *run)
+void kvm_arch_pre_run(CPUState *env, struct kvm_run *run)
{
int r;
unsigned irq;
@@ -254,15 +254,15 @@ int kvm_arch_pre_run(CPUState *env, struct kvm_run *run)
/* We don't know if there are more interrupts pending after this. However,
* the guest will return to userspace in the course of handling this one
* anyways, so we will get a chance to deliver the rest. */
- return 0;
}
void kvm_arch_post_run(CPUState *env, struct kvm_run *run)
{
}
-void kvm_arch_process_irqchip_events(CPUState *env)
+int kvm_arch_process_irqchip_events(CPUState *env)
{
+ return 0;
}
static int kvmppc_handle_halt(CPUState *env)
--
David Gibson | I'll have my music baroque, and my code
david AT gibson.dropbear.id.au | minimalist, thank you. NOT _the_ _other_
| _way_ _around_!
http://www.ozlabs.org/~dgibson
^ permalink raw reply related [flat|nested] 2+ messages in thread
* [Qemu-devel] Re: Fix build breakage to kvm on ppc
2011-02-28 10:49 [Qemu-devel] Fix build breakage to kvm on ppc David Gibson
@ 2011-02-28 21:18 ` Jan Kiszka
0 siblings, 0 replies; 2+ messages in thread
From: Jan Kiszka @ 2011-02-28 21:18 UTC (permalink / raw)
To: David Gibson; +Cc: agraf, qemu-devel
[-- Attachment #1: Type: text/plain, Size: 2137 bytes --]
On 2011-02-28 11:49, David Gibson wrote:
> Recent changes to the generic kvm support code broke compile of kvm
> for ppc. The patch below fixes the errors by adjusting types in the
> ppc code, and adding a missing #ifdef.
>
> Please apply.
>
> Signed-off-by: David Gibson <david@gibson.dropbear.id.au>
>
> ---
> kvm-all.c | 2 ++
> target-ppc/kvm.c | 6 +++---
> 2 files changed, 5 insertions(+), 3 deletions(-)
>
> diff --git a/kvm-all.c b/kvm-all.c
> index e6a7de4..fb44e2e 100644
> --- a/kvm-all.c
> +++ b/kvm-all.c
> @@ -998,7 +998,9 @@ int kvm_cpu_exec(CPUState *env)
> }
> ret = EXCP_INTERRUPT;
>
> +#ifdef KVM_CAP_SET_GUEST_DEBUG
> out:
> +#endif /* KVM_CAP_SET_GUEST_DEBUG */
Yeah, another non-x86 breakage. But this made me think about the main
loop again, and the result will move any related reasons for the #ifdef
into arch code.
> env->exit_request = 0;
> cpu_single_env = NULL;
> return ret;
> diff --git a/target-ppc/kvm.c b/target-ppc/kvm.c
> index 04b94a3..4fa1be3 100644
> --- a/target-ppc/kvm.c
> +++ b/target-ppc/kvm.c
> @@ -223,7 +223,7 @@ int kvmppc_set_interrupt(CPUState *env, int irq, int level)
> #define PPC_INPUT_INT PPC6xx_INPUT_INT
> #endif
>
> -int kvm_arch_pre_run(CPUState *env, struct kvm_run *run)
> +void kvm_arch_pre_run(CPUState *env, struct kvm_run *run)
> {
> int r;
> unsigned irq;
> @@ -254,15 +254,15 @@ int kvm_arch_pre_run(CPUState *env, struct kvm_run *run)
> /* We don't know if there are more interrupts pending after this. However,
> * the guest will return to userspace in the course of handling this one
> * anyways, so we will get a chance to deliver the rest. */
> - return 0;
> }
>
> void kvm_arch_post_run(CPUState *env, struct kvm_run *run)
> {
> }
>
> -void kvm_arch_process_irqchip_events(CPUState *env)
> +int kvm_arch_process_irqchip_events(CPUState *env)
> {
> + return 0;
> }
>
> static int kvmppc_handle_halt(CPUState *env)
>
That other fix is already filed for uq/master.
Thanks for reporting,
Jan
[-- Attachment #2: OpenPGP digital signature --]
[-- Type: application/pgp-signature, Size: 259 bytes --]
^ permalink raw reply [flat|nested] 2+ messages in thread
end of thread, other threads:[~2011-02-28 21:18 UTC | newest]
Thread overview: 2+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2011-02-28 10:49 [Qemu-devel] Fix build breakage to kvm on ppc David Gibson
2011-02-28 21:18 ` [Qemu-devel] " Jan Kiszka
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.