qemu-devel.nongnu.org archive mirror
 help / color / mirror / Atom feed
* [Qemu-devel] [PATCH] Fix build of kvm-all.c when no KVM_CAP_IRQ_ROUTING
@ 2012-06-05  7:16 Jens Freimann
  2012-06-05 23:48 ` Andreas Färber
  0 siblings, 1 reply; 2+ messages in thread
From: Jens Freimann @ 2012-06-05  7:16 UTC (permalink / raw)
  To: qemu-devel; +Cc: Jens Freimann

In kvm-all.c an #ifdef KVM_CAP_IRQ_ROUTING was missing in two
places which broke the build when this capability is not enabled.
Found when building the s390-softmmu target.

Signed-off-by: Jens Freimann <jfrei@linux.vnet.ibm.com>
---
 kvm-all.c |    4 ++++
 1 file changed, 4 insertions(+)

diff --git a/kvm-all.c b/kvm-all.c
index 489ee53..95634ef 100644
--- a/kvm-all.c
+++ b/kvm-all.c
@@ -62,10 +62,12 @@ typedef struct KVMSlot
 
 typedef struct kvm_dirty_log KVMDirtyLog;
 
+#ifdef KVM_CAP_IRQ_ROUTING
 typedef struct KVMMSIRoute {
     struct kvm_irq_routing_entry kroute;
     QTAILQ_ENTRY(KVMMSIRoute) entry;
 } KVMMSIRoute;
+#endif
 
 struct KVMState
 {
@@ -1286,7 +1288,9 @@ int kvm_init(void)
     s->pit_state2 = kvm_check_extension(s, KVM_CAP_PIT_STATE2);
 #endif
 
+#ifdef KVM_CAP_IRQ_ROUTING
     s->direct_msi = (kvm_check_extension(s, KVM_CAP_SIGNAL_MSI) > 0);
+#endif
 
     ret = kvm_arch_init(s);
     if (ret < 0) {
-- 
1.7.10.4

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

* Re: [Qemu-devel] [PATCH] Fix build of kvm-all.c when no KVM_CAP_IRQ_ROUTING
  2012-06-05  7:16 [Qemu-devel] [PATCH] Fix build of kvm-all.c when no KVM_CAP_IRQ_ROUTING Jens Freimann
@ 2012-06-05 23:48 ` Andreas Färber
  0 siblings, 0 replies; 2+ messages in thread
From: Andreas Färber @ 2012-06-05 23:48 UTC (permalink / raw)
  To: Jens Freimann; +Cc: Jan Kiszka, qemu-devel

Am 05.06.2012 09:16, schrieb Jens Freimann:
> In kvm-all.c an #ifdef KVM_CAP_IRQ_ROUTING was missing in two
> places which broke the build when this capability is not enabled.
> Found when building the s390-softmmu target.
> 
> Signed-off-by: Jens Freimann <jfrei@linux.vnet.ibm.com>

A patch by Jan moves the first chunk instead and fixes another issue as
well in v2. Cc'ing Jan to verify.

Andreas

> ---
>  kvm-all.c |    4 ++++
>  1 file changed, 4 insertions(+)
> 
> diff --git a/kvm-all.c b/kvm-all.c
> index 489ee53..95634ef 100644
> --- a/kvm-all.c
> +++ b/kvm-all.c
> @@ -62,10 +62,12 @@ typedef struct KVMSlot
>  
>  typedef struct kvm_dirty_log KVMDirtyLog;
>  
> +#ifdef KVM_CAP_IRQ_ROUTING
>  typedef struct KVMMSIRoute {
>      struct kvm_irq_routing_entry kroute;
>      QTAILQ_ENTRY(KVMMSIRoute) entry;
>  } KVMMSIRoute;
> +#endif
>  
>  struct KVMState
>  {
> @@ -1286,7 +1288,9 @@ int kvm_init(void)
>      s->pit_state2 = kvm_check_extension(s, KVM_CAP_PIT_STATE2);
>  #endif
>  
> +#ifdef KVM_CAP_IRQ_ROUTING
>      s->direct_msi = (kvm_check_extension(s, KVM_CAP_SIGNAL_MSI) > 0);
> +#endif
>  
>      ret = kvm_arch_init(s);
>      if (ret < 0) {

-- 
SUSE LINUX Products GmbH, Maxfeldstr. 5, 90409 Nürnberg, Germany
GF: Jeff Hawn, Jennifer Guild, Felix Imendörffer; HRB 16746 AG Nürnberg

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

end of thread, other threads:[~2012-06-05 23:54 UTC | newest]

Thread overview: 2+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2012-06-05  7:16 [Qemu-devel] [PATCH] Fix build of kvm-all.c when no KVM_CAP_IRQ_ROUTING Jens Freimann
2012-06-05 23:48 ` Andreas Färber

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).