Message ID | 20181219191756.57973-16-mimu@linux.ibm.com (mailing list archive) |
---|---|
State | New, archived |
Headers | show |
Series | KVM: s390: make use of the GIB | expand |
On 19/12/2018 20:17, Michael Mueller wrote: > By initializing the GIB, it will be used by the kvm host. > > Signed-off-by: Michael Mueller <mimu@linux.ibm.com> > --- > arch/s390/kvm/kvm-s390.c | 8 +++++++- > 1 file changed, 7 insertions(+), 1 deletion(-) > > diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c > index 2d10e175862c..777c8a87d81c 100644 > --- a/arch/s390/kvm/kvm-s390.c > +++ b/arch/s390/kvm/kvm-s390.c > @@ -428,16 +428,22 @@ int kvm_arch_init(void *opaque) > goto out_debug_unreg; > } > > + rc = kvm_s390_gib_init(GAL_ISC); > + if (rc) > + goto out_debug_unreg; > + Since it is the last introduced I have a preference to put the gib initialization after any existing initialization. it does not have influence them. > kvm_s390_cpu_feat_init(); > > /* Register floating interrupt controller interface. */ > rc = kvm_register_device_ops(&kvm_flic_ops, KVM_DEV_TYPE_FLIC); > if (rc) { > pr_err("Failed to register FLIC rc=%d\n", rc); > - goto out_debug_unreg; > + goto out_gib_destroy; It is not a big problem but would make the patch more smaller by gathering all changes. > } > return 0; > > +out_gib_destroy: > + kvm_s390_gib_destroy(); > out_debug_unreg: > debug_unregister(kvm_s390_dbf); > return rc; > with these changes. Reviewed-by: Pierre Morel<pmorel@linux.ibm.com>
On 02.01.19 18:45, Pierre Morel wrote: > On 19/12/2018 20:17, Michael Mueller wrote: >> By initializing the GIB, it will be used by the kvm host. >> >> Signed-off-by: Michael Mueller <mimu@linux.ibm.com> >> --- >> arch/s390/kvm/kvm-s390.c | 8 +++++++- >> 1 file changed, 7 insertions(+), 1 deletion(-) >> >> diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c >> index 2d10e175862c..777c8a87d81c 100644 >> --- a/arch/s390/kvm/kvm-s390.c >> +++ b/arch/s390/kvm/kvm-s390.c >> @@ -428,16 +428,22 @@ int kvm_arch_init(void *opaque) >> goto out_debug_unreg; >> } >> + rc = kvm_s390_gib_init(GAL_ISC); >> + if (rc) >> + goto out_debug_unreg; >> + > > Since it is the last introduced I have a preference to put the gib > initialization after any existing initialization. > it does not have influence them. > >> kvm_s390_cpu_feat_init(); >> /* Register floating interrupt controller interface. */ >> rc = kvm_register_device_ops(&kvm_flic_ops, KVM_DEV_TYPE_FLIC); >> if (rc) { >> pr_err("Failed to register FLIC rc=%d\n", rc); >> - goto out_debug_unreg; >> + goto out_gib_destroy; > > It is not a big problem but would make the patch more smaller by > gathering all changes. I will move that behind the FLIC registraion. > >> } >> return 0; >> +out_gib_destroy: >> + kvm_s390_gib_destroy(); >> out_debug_unreg: >> debug_unregister(kvm_s390_dbf); >> return rc; >> > > with these changes. > Reviewed-by: Pierre Morel<pmorel@linux.ibm.com> > > > >
diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c index 2d10e175862c..777c8a87d81c 100644 --- a/arch/s390/kvm/kvm-s390.c +++ b/arch/s390/kvm/kvm-s390.c @@ -428,16 +428,22 @@ int kvm_arch_init(void *opaque) goto out_debug_unreg; } + rc = kvm_s390_gib_init(GAL_ISC); + if (rc) + goto out_debug_unreg; + kvm_s390_cpu_feat_init(); /* Register floating interrupt controller interface. */ rc = kvm_register_device_ops(&kvm_flic_ops, KVM_DEV_TYPE_FLIC); if (rc) { pr_err("Failed to register FLIC rc=%d\n", rc); - goto out_debug_unreg; + goto out_gib_destroy; } return 0; +out_gib_destroy: + kvm_s390_gib_destroy(); out_debug_unreg: debug_unregister(kvm_s390_dbf); return rc;
By initializing the GIB, it will be used by the kvm host. Signed-off-by: Michael Mueller <mimu@linux.ibm.com> --- arch/s390/kvm/kvm-s390.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-)