From: Avi Kivity <avi-atKUWr5tajBWk0Htik3J/w@public.gmane.org>
To: Gregory Haskins <ghaskins-Et1tbQHTxzrQT0dZR+AlfA@public.gmane.org>
Cc: kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@public.gmane.org
Subject: Re: [PATCH] KVM-USER: Fix for CPU interrupts in QEMU
Date: Sun, 15 Jul 2007 10:39:24 +0300 [thread overview]
Message-ID: <4699CF2C.1060702@qumranet.com> (raw)
In-Reply-To: <20070712151200.7060.91407.stgit-5CR4LY5GPkvLDviKLk5550HKjMygAv58XqFh9Ls21Oc@public.gmane.org>
Gregory Haskins wrote:
> QEMU-KVM has a bug where the interruptibility of the CPU is predicated on
> pending interrupts. If the reason that a CPU is interrupted is because we
> need to inject interrupts, the current code will just keep looping and miss
> the event window.
>
> This doesnt seem to cause problems with in-trunk KVM. However, once we turn
> on in-kernel HALTING, QEMU starts to have some serious problems that were
> attributed to this bug.
>
> Signed-off-by: Gregory Haskins <ghaskins-Et1tbQHTxzrQT0dZR+AlfA@public.gmane.org>
> ---
>
> qemu/qemu-kvm.c | 5 +----
> 1 files changed, 1 insertions(+), 4 deletions(-)
>
> diff --git a/qemu/qemu-kvm.c b/qemu/qemu-kvm.c
> index 1849997..5b5c739 100644
> --- a/qemu/qemu-kvm.c
> +++ b/qemu/qemu-kvm.c
> @@ -452,11 +452,8 @@ void kvm_save_registers(CPUState *env)
> int kvm_cpu_exec(CPUState *env)
> {
> int r;
> - int pending = (!env->ready_for_interrupt_injection ||
> - ((env->interrupt_request & CPU_INTERRUPT_HARD) &&
> - (env->eflags & IF_MASK)));
>
> - if (!pending && (env->interrupt_request & CPU_INTERRUPT_EXIT)) {
> + if (env->interrupt_request & CPU_INTERRUPT_EXIT) {
> env->interrupt_request &= ~CPU_INTERRUPT_EXIT;
> env->exception_index = EXCP_INTERRUPT;
> cpu_loop_exit();
>
>
When applied to current HEAD, this doesn't work. Booting windows or
Linux, quite soon during boot everything freezes.
--
error compiling committee.c: too many arguments to function
-------------------------------------------------------------------------
This SF.net email is sponsored by DB2 Express
Download DB2 Express C - the FREE version of DB2 express and take
control of your XML. No limits. Just data. Click to get it now.
http://sourceforge.net/powerbar/db2/
next prev parent reply other threads:[~2007-07-15 7:39 UTC|newest]
Thread overview: 7+ messages / expand[flat|nested] mbox.gz Atom feed top
2007-07-12 15:12 [PATCH] KVM-USER: Fix for CPU interrupts in QEMU Gregory Haskins
[not found] ` <20070712151200.7060.91407.stgit-5CR4LY5GPkvLDviKLk5550HKjMygAv58XqFh9Ls21Oc@public.gmane.org>
2007-07-12 15:39 ` Dong, Eddie
2007-07-15 7:39 ` Avi Kivity [this message]
-- strict thread matches above, loose matches on Subject: below --
2007-07-12 15:48 Gregory Haskins
[not found] ` <469615120200005A0002769E-Igcdv/6uVdMHoYOw/+koYqIwWpluYiW7@public.gmane.org>
2007-07-12 16:04 ` Dong, Eddie
[not found] ` <10EA09EFD8728347A513008B6B0DA77A01C24C4A-wq7ZOvIWXbNpB2pF5aRoyrfspsVTdybXVpNB7YpNyf8@public.gmane.org>
2007-07-14 6:43 ` Avi Kivity
2007-07-16 18:07 Gregory Haskins
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=4699CF2C.1060702@qumranet.com \
--to=avi-atkuwr5tajbwk0htik3j/w@public.gmane.org \
--cc=ghaskins-Et1tbQHTxzrQT0dZR+AlfA@public.gmane.org \
--cc=kvm-devel-5NWGOfrQmneRv+LV9MX5uipxlwaOVQ5f@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 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.