public inbox for kvm@vger.kernel.org
 help / color / mirror / Atom feed
From: Avi Kivity <avi-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
To: "Yang, Sheng" <sheng.yang-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: Re: [PATCH 2/2] kvm: libkvm/qemu: Support in-kernel PIT model
Date: Mon, 28 Jan 2008 14:00:53 +0200	[thread overview]
Message-ID: <479DC3F5.8010703@qumranet.com> (raw)
In-Reply-To: <200801281446.30147.sheng.yang-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>

Yang, Sheng wrote:
> +void kvm_create_pit(kvm_context_t kvm)
> +{
> +	int r;
> +
> +	if (!kvm->no_pit_creation) {
> +		r = ioctl(kvm->fd, KVM_CHECK_EXTENSION, KVM_CAP_PIT);
> +		if (r > 0) {
> +			r = ioctl(kvm->vm_fd, KVM_CREATE_PIT);
> +			if (r < 0)
> +				printf("Create kernel PIC irqchip failed\n");
> +		}
> +	}
> +}
>
>   

Need to protect this with #ifdef KVM_CAP_PIT to support compilation with 
older kernels.  If support is not available, qemu should fall back to 
userspace pit.

Please separate the qemu and libkvm parts.


-- 
error compiling committee.c: too many arguments to function


-------------------------------------------------------------------------
This SF.net email is sponsored by: Microsoft
Defy all challenges. Microsoft(R) Visual Studio 2008.
http://clk.atdmt.com/MRT/go/vse0120000070mrt/direct/01/

      parent reply	other threads:[~2008-01-28 12:00 UTC|newest]

Thread overview: 2+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2008-01-28  6:46 [PATCH 2/2] kvm: libkvm/qemu: Support in-kernel PIT model Yang, Sheng
     [not found] ` <200801281446.30147.sheng.yang-ral2JQCrhuEAvxtiuMwx3w@public.gmane.org>
2008-01-28 12:00   ` Avi Kivity [this message]

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=479DC3F5.8010703@qumranet.com \
    --to=avi-atkuwr5tajbwk0htik3j/w@public.gmane.org \
    --cc=kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org \
    --cc=sheng.yang-ral2JQCrhuEAvxtiuMwx3w@public.gmane.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 a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox