lkml.org 
[lkml]   [2019]   [Sep]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 02/17] KVM: monolithic: x86: convert the kvm_x86_ops methods to external functions
On Mon, Sep 23, 2019 at 12:19:30PM +0200, Paolo Bonzini wrote:
> On 20/09/19 23:24, Andrea Arcangeli wrote:
> > diff --git a/arch/x86/kvm/svm_ops.c b/arch/x86/kvm/svm_ops.c
> > new file mode 100644
> > index 000000000000..2aaabda92179
> > --- /dev/null
> > +++ b/arch/x86/kvm/svm_ops.c
> > @@ -0,0 +1,672 @@
> > +// SPDX-License-Identifier: GPL-2.0-only
> > +/*
> > + * arch/x86/kvm/svm_ops.c
> > + *
> > + * Copyright 2019 Red Hat, Inc.
> > + */
> > +
> > +int kvm_x86_ops_cpu_has_kvm_support(void)
> > +{
> > + return has_svm();
> > +}
>
> Can you just rename all the functions in vmx/ and svm.c, instead of
> adding forwarders?

I can do that, I thought this was cleaner as it still retained the
abstraction separated from the mixup of the rest of the vmx/svm code,
but it'll work the same by dropping the abstraction in kvm_ops.h and
just maintaining a common name between the svm.c and vmx.c files, gcc
already built it that way after all.

\
 
 \ /
  Last update: 2019-09-23 21:23    [W:0.084 / U:0.008 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site