Return-Path: Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932615AbbD0Kd0 (ORCPT ); Mon, 27 Apr 2015 06:33:26 -0400 Received: from smtp.citrix.com ([66.165.176.89]:44972 "EHLO SMTP.CITRIX.COM" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932413AbbD0KdY (ORCPT ); Mon, 27 Apr 2015 06:33:24 -0400 X-IronPort-AV: E=Sophos;i="5.11,656,1422921600"; d="scan'208";a="256879853" Message-ID: <553E105C.6000606@citrix.com> Date: Mon, 27 Apr 2015 11:33:00 +0100 From: David Vrabel User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:31.0) Gecko/20100101 Icedove/31.4.0 MIME-Version: 1.0 To: Boris Ostrovsky , , CC: , Subject: Re: [Xen-devel] [PATCH] xen: Suspend ticks on all CPUs during suspend References: <1428519212-25524-1-git-send-email-boris.ostrovsky@oracle.com> In-Reply-To: <1428519212-25524-1-git-send-email-boris.ostrovsky@oracle.com> Content-Type: text/plain; charset="windows-1252" Content-Transfer-Encoding: 7bit X-DLP: MIA2 Sender: linux-kernel-owner@vger.kernel.org List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Content-Length: 1566 Lines: 40 On 08/04/15 19:53, Boris Ostrovsky wrote: > Commit 77e32c89a711 ("clockevents: Manage device's state separately for > the core") decouples clockevent device's modes from states. With this > change when a Xen guest tries to resume, it won't be calling its > set_mode op which needs to be done on each VCPU in order to make the > hypervisor aware that we are in oneshot mode. > > This happens because clockevents_tick_resume() (which is an intermediate > step of resuming ticks on a processor) no longer calls clockevents_set_state() > and because during suspend clockevent devices on all VCPUs (except for the > one doing the suspend) are left in ONESHOT state. As result, during resume > the clockevents state machine will assume that device is already where it > should be and doesn't need to be updated. > > To avoid this problem we should suspend ticks on all VCPUs during > suspend. Sorry for the delay in reviewing this. > diff --git a/drivers/xen/manage.c b/drivers/xen/manage.c > index bf19407..2fd9fe8 100644 > --- a/drivers/xen/manage.c > +++ b/drivers/xen/manage.c > @@ -131,6 +131,8 @@ static void do_suspend(void) > goto out_resume; > } > > + xen_arch_suspend(); > + > si.cancelled = 1; xen_arch_resume() is only called when !si.cancelled but you call xen_arch_suspend() unconditionally. David -- To unsubscribe from this list: send the line "unsubscribe linux-kernel" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html Please read the FAQ at http://www.tux.org/lkml/