From mboxrd@z Thu Jan 1 00:00:00 1970 From: Gleb Natapov Subject: Re: [PATCH] fix userspace irqchip. Date: Sun, 6 Sep 2009 16:19:52 +0300 Message-ID: <20090906131952.GD27325@redhat.com> References: <1252021260-28941-1-git-send-email-glommer@redhat.com> <20090906085003.GB27325@redhat.com> <5d6222a80909060534m5395c75l47ca2e6841b11a04@mail.gmail.com> Mime-Version: 1.0 Content-Type: text/plain; charset=koi8-r Content-Transfer-Encoding: QUOTED-PRINTABLE Cc: Glauber Costa , kvm@vger.kernel.org, avi@redhat.com To: Glauber Costa Return-path: Received: from mx1.redhat.com ([209.132.183.28]:60836 "EHLO mx1.redhat.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1757838AbZIFNTx convert rfc822-to-8bit (ORCPT ); Sun, 6 Sep 2009 09:19:53 -0400 Content-Disposition: inline In-Reply-To: <5d6222a80909060534m5395c75l47ca2e6841b11a04@mail.gmail.com> Sender: kvm-owner@vger.kernel.org List-ID: On Sun, Sep 06, 2009 at 09:34:38AM -0300, Glauber Costa wrote: > On Sun, Sep 6, 2009 at 5:50 AM, Gleb Natapov wrote: > > On Thu, Sep 03, 2009 at 07:41:00PM -0400, Glauber Costa wrote: > >> It is broken since main loop reorganization. (6185d8b6) > >> > > What is broken? Boots WindowsXp for me here. >=20 > Fedora guests don't boot. >=20 Which one? I tested F10 live cd and F11 beta (both 32 bit). They work fine here with userspace irq chip. > >> Problem is that we, the emulator, has nothing to do with the CPU f= lags. has_work() > >> should not depend on that at all. > > IF_MASK flags is set into env->eflags on each exit by function just > > above kvm_arch_has_work() and contains valid and relevant informati= on. > > The check your are removing should be there. It ensures that interr= upts > > are ignored if they are blocked by vcpu. > > > >> > >> Signed-off-by: Glauber Costa > >> CC: Gleb Natapov > >> --- > >> =9Aqemu-kvm-x86.c | =9A =9A5 ++--- > >> =9A1 files changed, 2 insertions(+), 3 deletions(-) > >> > >> diff --git a/qemu-kvm-x86.c b/qemu-kvm-x86.c > >> index f80d82b..66ed6b5 100644 > >> --- a/qemu-kvm-x86.c > >> +++ b/qemu-kvm-x86.c > >> @@ -1393,9 +1393,8 @@ void kvm_arch_post_kvm_run(void *opaque, CPU= State *env) > >> > >> =9Aint kvm_arch_has_work(CPUState *env) > >> =9A{ > >> - =9A =9Aif (((env->interrupt_request & CPU_INTERRUPT_HARD) && > >> - =9A =9A =9A(env->eflags & IF_MASK)) || > >> - =9A =9A (env->interrupt_request & CPU_INTERRUPT_NMI)) > >> + =9A =9Aif (((env->interrupt_request & CPU_INTERRUPT_HARD) || > >> + =9A =9A (env->interrupt_request & CPU_INTERRUPT_NMI))) > >> =9A =9A =9A return 1; > >> =9A =9A =9Areturn 0; > >> =9A} > >> -- > >> 1.6.2.2 > > > > -- > > =9A =9A =9A =9A =9A =9A =9A =9A =9A =9A =9A =9AGleb. > > -- > > To unsubscribe from this list: send the line "unsubscribe kvm" in > > the body of a message to majordomo@vger.kernel.org > > More majordomo info at =9Ahttp://vger.kernel.org/majordomo-info.htm= l > > >=20 >=20 >=20 > --=20 > Glauber Costa. > "Free as in Freedom" > http://glommer.net >=20 > "The less confident you are, the more serious you have to act." -- Gleb.