From mboxrd@z Thu Jan 1 00:00:00 1970 From: Anthony Liguori Subject: Re: [PATCH] Guest stop notification Date: Tue, 29 Nov 2011 16:10:21 -0600 Message-ID: <4ED5584D.9010606@us.ibm.com> References: <1322602574-27072-1-git-send-email-emunson@mgebm.net> Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Cc: ryanh@linux.vnet.ibm.com, kvm@vger.kernel.org, mtosatti@redhat.com, linux-kernel@vger.kernel.org, qemu-devel@nongnu.org, avi@redhat.com To: Eric B Munson Return-path: In-Reply-To: <1322602574-27072-1-git-send-email-emunson@mgebm.net> List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: qemu-devel-bounces+gceq-qemu-devel=gmane.org@nongnu.org Sender: qemu-devel-bounces+gceq-qemu-devel=gmane.org@nongnu.org List-Id: kvm.vger.kernel.org On 11/29/2011 03:36 PM, Eric B Munson wrote: > Often when a guest is stopped from the qemu console, it will report spurious > soft lockup warnings on resume. There are kernel patches being discussed that > will give the host the ability to tell the guest that it is being stopped and > should ignore the soft lockup warning that generates. > > Signed-off-by: Eric B Munson Reviewed-by: Anthony Liguori Regards, Anthony Liguori > Cc: ryanh@linux.vnet.ibm.com > Cc: aliguori@us.ibm.com > Cc: mtosatti@redhat.com > Cc: avi@redhat.com > Cc: kvm@vger.kernel.org > Cc: linux-kernel@vger.kernel.org > --- > target-i386/kvm.c | 6 ++++++ > 1 files changed, 6 insertions(+), 0 deletions(-) > > diff --git a/target-i386/kvm.c b/target-i386/kvm.c > index 5bfc21f..defd364 100644 > --- a/target-i386/kvm.c > +++ b/target-i386/kvm.c > @@ -336,12 +336,18 @@ static int kvm_inject_mce_oldstyle(CPUState *env) > return 0; > } > > +static void kvm_put_guest_paused(CPUState *penv) > +{ > + kvm_vcpu_ioctl(penv, KVM_GUEST_PAUSED, 0); > +} > + > static void cpu_update_state(void *opaque, int running, RunState state) > { > CPUState *env = opaque; > > if (running) { > env->tsc_valid = false; > + kvm_put_guest_paused(env); > } > } > From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756883Ab1K2WMA (ORCPT ); Tue, 29 Nov 2011 17:12:00 -0500 Received: from e6.ny.us.ibm.com ([32.97.182.146]:39588 "EHLO e6.ny.us.ibm.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754775Ab1K2WL6 (ORCPT ); Tue, 29 Nov 2011 17:11:58 -0500 Message-ID: <4ED5584D.9010606@us.ibm.com> Date: Tue, 29 Nov 2011 16:10:21 -0600 From: Anthony Liguori User-Agent: Mozilla/5.0 (X11; U; Linux x86_64; en-US; rv:1.9.2.21) Gecko/20110831 Lightning/1.0b2 Thunderbird/3.1.13 MIME-Version: 1.0 To: Eric B Munson CC: qemu-devel@nongnu.org, ryanh@linux.vnet.ibm.com, mtosatti@redhat.com, avi@redhat.com, kvm@vger.kernel.org, linux-kernel@vger.kernel.org Subject: Re: [PATCH] Guest stop notification References: <1322602574-27072-1-git-send-email-emunson@mgebm.net> In-Reply-To: <1322602574-27072-1-git-send-email-emunson@mgebm.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit x-cbid: 11112922-1976-0000-0000-000007FD034E Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On 11/29/2011 03:36 PM, Eric B Munson wrote: > Often when a guest is stopped from the qemu console, it will report spurious > soft lockup warnings on resume. There are kernel patches being discussed that > will give the host the ability to tell the guest that it is being stopped and > should ignore the soft lockup warning that generates. > > Signed-off-by: Eric B Munson Reviewed-by: Anthony Liguori Regards, Anthony Liguori > Cc: ryanh@linux.vnet.ibm.com > Cc: aliguori@us.ibm.com > Cc: mtosatti@redhat.com > Cc: avi@redhat.com > Cc: kvm@vger.kernel.org > Cc: linux-kernel@vger.kernel.org > --- > target-i386/kvm.c | 6 ++++++ > 1 files changed, 6 insertions(+), 0 deletions(-) > > diff --git a/target-i386/kvm.c b/target-i386/kvm.c > index 5bfc21f..defd364 100644 > --- a/target-i386/kvm.c > +++ b/target-i386/kvm.c > @@ -336,12 +336,18 @@ static int kvm_inject_mce_oldstyle(CPUState *env) > return 0; > } > > +static void kvm_put_guest_paused(CPUState *penv) > +{ > + kvm_vcpu_ioctl(penv, KVM_GUEST_PAUSED, 0); > +} > + > static void cpu_update_state(void *opaque, int running, RunState state) > { > CPUState *env = opaque; > > if (running) { > env->tsc_valid = false; > + kvm_put_guest_paused(env); > } > } > From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from eggs.gnu.org ([140.186.70.92]:46567) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RVVtS-0005bI-TP for qemu-devel@nongnu.org; Tue, 29 Nov 2011 17:11:18 -0500 Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1RVVtO-0006TC-GL for qemu-devel@nongnu.org; Tue, 29 Nov 2011 17:11:14 -0500 Received: from e39.co.us.ibm.com ([32.97.110.160]:54767) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1RVVtO-0006Sb-B4 for qemu-devel@nongnu.org; Tue, 29 Nov 2011 17:11:10 -0500 Received: from /spool/local by e39.co.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Tue, 29 Nov 2011 15:11:05 -0700 Received: from d03av05.boulder.ibm.com (d03av05.boulder.ibm.com [9.17.195.85]) by d03relay01.boulder.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id pATMAohs070226 for ; Tue, 29 Nov 2011 15:10:52 -0700 Received: from d03av05.boulder.ibm.com (loopback [127.0.0.1]) by d03av05.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id pATMAoiA011042 for ; Tue, 29 Nov 2011 15:10:50 -0700 Message-ID: <4ED5584D.9010606@us.ibm.com> Date: Tue, 29 Nov 2011 16:10:21 -0600 From: Anthony Liguori MIME-Version: 1.0 References: <1322602574-27072-1-git-send-email-emunson@mgebm.net> In-Reply-To: <1322602574-27072-1-git-send-email-emunson@mgebm.net> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit Subject: Re: [Qemu-devel] [PATCH] Guest stop notification List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , To: Eric B Munson Cc: ryanh@linux.vnet.ibm.com, kvm@vger.kernel.org, mtosatti@redhat.com, linux-kernel@vger.kernel.org, qemu-devel@nongnu.org, avi@redhat.com On 11/29/2011 03:36 PM, Eric B Munson wrote: > Often when a guest is stopped from the qemu console, it will report spurious > soft lockup warnings on resume. There are kernel patches being discussed that > will give the host the ability to tell the guest that it is being stopped and > should ignore the soft lockup warning that generates. > > Signed-off-by: Eric B Munson Reviewed-by: Anthony Liguori Regards, Anthony Liguori > Cc: ryanh@linux.vnet.ibm.com > Cc: aliguori@us.ibm.com > Cc: mtosatti@redhat.com > Cc: avi@redhat.com > Cc: kvm@vger.kernel.org > Cc: linux-kernel@vger.kernel.org > --- > target-i386/kvm.c | 6 ++++++ > 1 files changed, 6 insertions(+), 0 deletions(-) > > diff --git a/target-i386/kvm.c b/target-i386/kvm.c > index 5bfc21f..defd364 100644 > --- a/target-i386/kvm.c > +++ b/target-i386/kvm.c > @@ -336,12 +336,18 @@ static int kvm_inject_mce_oldstyle(CPUState *env) > return 0; > } > > +static void kvm_put_guest_paused(CPUState *penv) > +{ > + kvm_vcpu_ioctl(penv, KVM_GUEST_PAUSED, 0); > +} > + > static void cpu_update_state(void *opaque, int running, RunState state) > { > CPUState *env = opaque; > > if (running) { > env->tsc_valid = false; > + kvm_put_guest_paused(env); > } > } >