From: Christian Borntraeger <borntraeger@de.ibm.com>
To: kvm-ia64@vger.kernel.org
Subject: Re: [PATCH] KVM: Clean up vm creation and release
Date: Tue, 09 Nov 2010 15:42:37 +0000 [thread overview]
Message-ID: <4CD96BED.5080504@de.ibm.com> (raw)
In-Reply-To: <4CD96195.2000708@siemens.com>
> diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c
> index 985d825..d8d1877 100644
> --- a/arch/s390/kvm/kvm-s390.c
> +++ b/arch/s390/kvm/kvm-s390.c
> @@ -164,24 +164,18 @@ long kvm_arch_vm_ioctl(struct file *filp,
> return r;
> }
>
> -struct kvm *kvm_arch_create_vm(void)
> +int kvm_arch_create_vm(struct kvm *kvm)
needs to be renamed to
kvm_arch_init_vm
[...]
> --- a/include/linux/kvm_host.h
> +++ b/include/linux/kvm_host.h
> @@ -441,7 +441,19 @@ int kvm_arch_vcpu_runnable(struct kvm_vcpu *vcpu);
>
> void kvm_free_physmem(struct kvm *kvm);
>
> -struct kvm *kvm_arch_create_vm(void);
> +#ifndef __KVM_HAVE_ARCH_VM_ALLOC
> +static inline struct kvm *kvm_arch_alloc_vm(void)
> +{
> + return kzalloc(sizeof(struct kvm), GFP_KERNEL);
I have not checked kvm.git but on Linux head we need
#include <linux/slab.h>
for kzalloc.
Christian
WARNING: multiple messages have this Message-ID (diff)
From: Christian Borntraeger <borntraeger@de.ibm.com>
To: Jan Kiszka <jan.kiszka-kv7WeFo6aLtBDgjK7y7TUQ@public.gmane.org>
Cc: Avi Kivity <avi-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>,
Marcelo Tosatti
<mtosatti-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>,
kvm <kvm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
kvm-ppc <kvm-ppc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
"kvm-ia64-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
<kvm-ia64-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
Alexander Graf <agraf-l3A5Bk7waGM@public.gmane.org>,
"Zhang,
Xiantao" <xiantao.zhang-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>,
Carsten Otte <cotte-tA70FqPdS9bQT0dZR+AlfA@public.gmane.org>,
linux-s390-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH] KVM: Clean up vm creation and release
Date: Tue, 09 Nov 2010 15:42:37 +0000 [thread overview]
Message-ID: <4CD96BED.5080504@de.ibm.com> (raw)
In-Reply-To: <4CD96195.2000708-kv7WeFo6aLtBDgjK7y7TUQ@public.gmane.org>
> diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c
> index 985d825..d8d1877 100644
> --- a/arch/s390/kvm/kvm-s390.c
> +++ b/arch/s390/kvm/kvm-s390.c
> @@ -164,24 +164,18 @@ long kvm_arch_vm_ioctl(struct file *filp,
> return r;
> }
>
> -struct kvm *kvm_arch_create_vm(void)
> +int kvm_arch_create_vm(struct kvm *kvm)
needs to be renamed to
kvm_arch_init_vm
[...]
> --- a/include/linux/kvm_host.h
> +++ b/include/linux/kvm_host.h
> @@ -441,7 +441,19 @@ int kvm_arch_vcpu_runnable(struct kvm_vcpu *vcpu);
>
> void kvm_free_physmem(struct kvm *kvm);
>
> -struct kvm *kvm_arch_create_vm(void);
> +#ifndef __KVM_HAVE_ARCH_VM_ALLOC
> +static inline struct kvm *kvm_arch_alloc_vm(void)
> +{
> + return kzalloc(sizeof(struct kvm), GFP_KERNEL);
I have not checked kvm.git but on Linux head we need
#include <linux/slab.h>
for kzalloc.
Christian
WARNING: multiple messages have this Message-ID (diff)
From: Christian Borntraeger <borntraeger-tA70FqPdS9bQT0dZR+AlfA@public.gmane.org>
To: Jan Kiszka <jan.kiszka-kv7WeFo6aLtBDgjK7y7TUQ@public.gmane.org>
Cc: Avi Kivity <avi-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>,
Marcelo Tosatti
<mtosatti-H+wXaHxf7aLQT0dZR+AlfA@public.gmane.org>,
kvm <kvm-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
kvm-ppc <kvm-ppc-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
"kvm-ia64-u79uwXL29TY76Z2rM5mHXA@public.gmane.org"
<kvm-ia64-u79uwXL29TY76Z2rM5mHXA@public.gmane.org>,
Alexander Graf <agraf-l3A5Bk7waGM@public.gmane.org>,
"Zhang,
Xiantao" <xiantao.zhang-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>,
Carsten Otte <cotte-tA70FqPdS9bQT0dZR+AlfA@public.gmane.org>,
linux-s390-u79uwXL29TY76Z2rM5mHXA@public.gmane.org
Subject: Re: [PATCH] KVM: Clean up vm creation and release
Date: Tue, 09 Nov 2010 16:42:37 +0100 [thread overview]
Message-ID: <4CD96BED.5080504@de.ibm.com> (raw)
In-Reply-To: <4CD96195.2000708-kv7WeFo6aLtBDgjK7y7TUQ@public.gmane.org>
> diff --git a/arch/s390/kvm/kvm-s390.c b/arch/s390/kvm/kvm-s390.c
> index 985d825..d8d1877 100644
> --- a/arch/s390/kvm/kvm-s390.c
> +++ b/arch/s390/kvm/kvm-s390.c
> @@ -164,24 +164,18 @@ long kvm_arch_vm_ioctl(struct file *filp,
> return r;
> }
>
> -struct kvm *kvm_arch_create_vm(void)
> +int kvm_arch_create_vm(struct kvm *kvm)
needs to be renamed to
kvm_arch_init_vm
[...]
> --- a/include/linux/kvm_host.h
> +++ b/include/linux/kvm_host.h
> @@ -441,7 +441,19 @@ int kvm_arch_vcpu_runnable(struct kvm_vcpu *vcpu);
>
> void kvm_free_physmem(struct kvm *kvm);
>
> -struct kvm *kvm_arch_create_vm(void);
> +#ifndef __KVM_HAVE_ARCH_VM_ALLOC
> +static inline struct kvm *kvm_arch_alloc_vm(void)
> +{
> + return kzalloc(sizeof(struct kvm), GFP_KERNEL);
I have not checked kvm.git but on Linux head we need
#include <linux/slab.h>
for kzalloc.
Christian
next prev parent reply other threads:[~2010-11-09 15:42 UTC|newest]
Thread overview: 6+ messages / expand[flat|nested] mbox.gz Atom feed top
2010-11-09 14:58 [PATCH] KVM: Clean up vm creation and release Jan Kiszka
2010-11-09 14:58 ` Jan Kiszka
2010-11-09 14:58 ` Jan Kiszka
2010-11-09 15:42 ` Christian Borntraeger [this message]
2010-11-09 15:42 ` Christian Borntraeger
2010-11-09 15:42 ` Christian Borntraeger
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=4CD96BED.5080504@de.ibm.com \
--to=borntraeger@de.ibm.com \
--cc=kvm-ia64@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
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.