diff mbox series

[v5,31/36] spapr/xive: export the spapr_xive_kvm_init() routine

Message ID 20181116105729.23240-32-clg@kaod.org (mailing list archive)
State New, archived
Headers show
Series ppc: support for the XIVE interrupt controller (POWER9) | expand

Commit Message

Cédric Le Goater Nov. 16, 2018, 10:57 a.m. UTC
We will need it to initialize the KVM XIVE device globally from the
machine when the XIVE interrupt mode is selected.

Signed-off-by: Cédric Le Goater <clg@kaod.org>
---
 include/hw/ppc/spapr_xive.h | 2 ++
 hw/intc/spapr_xive_kvm.c    | 2 +-
 2 files changed, 3 insertions(+), 1 deletion(-)

Comments

David Gibson Nov. 29, 2018, 4:11 a.m. UTC | #1
On Fri, Nov 16, 2018 at 11:57:24AM +0100, Cédric Le Goater wrote:
> We will need it to initialize the KVM XIVE device globally from the
> machine when the XIVE interrupt mode is selected.
> 
> Signed-off-by: Cédric Le Goater <clg@kaod.org>

This is so trivial, I think it's better to fold it into the patch
which uses it.

> ---
>  include/hw/ppc/spapr_xive.h | 2 ++
>  hw/intc/spapr_xive_kvm.c    | 2 +-
>  2 files changed, 3 insertions(+), 1 deletion(-)
> 
> diff --git a/include/hw/ppc/spapr_xive.h b/include/hw/ppc/spapr_xive.h
> index fa7f3d7718da..1d134a681326 100644
> --- a/include/hw/ppc/spapr_xive.h
> +++ b/include/hw/ppc/spapr_xive.h
> @@ -107,4 +107,6 @@ void spapr_xive_mmio_map(sPAPRXive *xive);
>  #define TYPE_XIVE_TCTX_KVM   "xive-tctx-kvm"
>  #define XIVE_TCTX_KVM(obj)   OBJECT_CHECK(XiveTCTX, (obj), TYPE_XIVE_TCTX_KVM)
>  
> +void spapr_xive_kvm_init(sPAPRXive *xive, Error **errp);
> +
>  #endif /* PPC_SPAPR_XIVE_H */
> diff --git a/hw/intc/spapr_xive_kvm.c b/hw/intc/spapr_xive_kvm.c
> index b9fee4ea240f..cb2aa6e81274 100644
> --- a/hw/intc/spapr_xive_kvm.c
> +++ b/hw/intc/spapr_xive_kvm.c
> @@ -809,7 +809,7 @@ static void spapr_xive_kvm_instance_init(Object *obj)
>                                NULL);
>  }
>  
> -static void spapr_xive_kvm_init(sPAPRXive *xive, Error **errp)
> +void spapr_xive_kvm_init(sPAPRXive *xive, Error **errp)
>  {
>      Error *local_err = NULL;
>      size_t tima_len;
diff mbox series

Patch

diff --git a/include/hw/ppc/spapr_xive.h b/include/hw/ppc/spapr_xive.h
index fa7f3d7718da..1d134a681326 100644
--- a/include/hw/ppc/spapr_xive.h
+++ b/include/hw/ppc/spapr_xive.h
@@ -107,4 +107,6 @@  void spapr_xive_mmio_map(sPAPRXive *xive);
 #define TYPE_XIVE_TCTX_KVM   "xive-tctx-kvm"
 #define XIVE_TCTX_KVM(obj)   OBJECT_CHECK(XiveTCTX, (obj), TYPE_XIVE_TCTX_KVM)
 
+void spapr_xive_kvm_init(sPAPRXive *xive, Error **errp);
+
 #endif /* PPC_SPAPR_XIVE_H */
diff --git a/hw/intc/spapr_xive_kvm.c b/hw/intc/spapr_xive_kvm.c
index b9fee4ea240f..cb2aa6e81274 100644
--- a/hw/intc/spapr_xive_kvm.c
+++ b/hw/intc/spapr_xive_kvm.c
@@ -809,7 +809,7 @@  static void spapr_xive_kvm_instance_init(Object *obj)
                               NULL);
 }
 
-static void spapr_xive_kvm_init(sPAPRXive *xive, Error **errp)
+void spapr_xive_kvm_init(sPAPRXive *xive, Error **errp)
 {
     Error *local_err = NULL;
     size_t tima_len;