From patchwork Tue Mar 1 09:02:11 2016 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?b?SsO8cmdlbiBHcm/Dnw==?= X-Patchwork-Id: 8463161 Return-Path: X-Original-To: patchwork-xen-devel@patchwork.kernel.org Delivered-To: patchwork-parsemail@patchwork2.web.kernel.org Received: from mail.kernel.org (mail.kernel.org [198.145.29.136]) by patchwork2.web.kernel.org (Postfix) with ESMTP id B9CE6C0553 for ; Tue, 1 Mar 2016 09:05:46 +0000 (UTC) Received: from mail.kernel.org (localhost [127.0.0.1]) by mail.kernel.org (Postfix) with ESMTP id E54872034C for ; Tue, 1 Mar 2016 09:05:44 +0000 (UTC) Received: from lists.xen.org (lists.xenproject.org [192.237.175.120]) (using TLSv1.2 with cipher AES128-GCM-SHA256 (128/128 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPS id 1A17B202C8 for ; Tue, 1 Mar 2016 09:05:44 +0000 (UTC) Received: from localhost ([127.0.0.1] helo=lists.xen.org) by lists.xen.org with esmtp (Exim 4.84) (envelope-from ) id 1aagCJ-0000ZD-9k; Tue, 01 Mar 2016 09:02:27 +0000 Received: from mail6.bemta3.messagelabs.com ([195.245.230.39]) by lists.xen.org with esmtp (Exim 4.84) (envelope-from ) id 1aagCI-0000Yv-B6 for xen-devel@lists.xen.org; Tue, 01 Mar 2016 09:02:26 +0000 Received: from [85.158.137.68] by server-9.bemta-3.messagelabs.com id 35/77-03814-1AA55D65; Tue, 01 Mar 2016 09:02:25 +0000 X-Env-Sender: jgross@suse.com X-Msg-Ref: server-11.tower-31.messagelabs.com!1456822944!25389726!1 X-Originating-IP: [195.135.220.15] X-SpamReason: No, hits=0.5 required=7.0 tests=BODY_RANDOM_LONG X-StarScan-Received: X-StarScan-Version: 7.35.1; banners=-,-,- X-VirusChecked: Checked Received: (qmail 61090 invoked from network); 1 Mar 2016 09:02:24 -0000 Received: from mx2.suse.de (HELO mx2.suse.de) (195.135.220.15) by server-11.tower-31.messagelabs.com with DHE-RSA-CAMELLIA256-SHA encrypted SMTP; 1 Mar 2016 09:02:24 -0000 X-Virus-Scanned: by amavisd-new at test-mx.suse.de Received: from relay2.suse.de (charybdis-ext.suse.de [195.135.220.254]) by mx2.suse.de (Postfix) with ESMTP id EF955AC32; Tue, 1 Mar 2016 09:02:23 +0000 (UTC) From: Juergen Gross To: xen-devel@lists.xen.org Date: Tue, 1 Mar 2016 10:02:11 +0100 Message-Id: <1456822933-25041-2-git-send-email-jgross@suse.com> X-Mailer: git-send-email 2.6.2 In-Reply-To: <1456822933-25041-1-git-send-email-jgross@suse.com> References: <1456822933-25041-1-git-send-email-jgross@suse.com> Cc: Juergen Gross , wei.liu2@citrix.com, stefano.stabellini@eu.citrix.com, george.dunlap@eu.citrix.com, andrew.cooper3@citrix.com, dario.faggioli@citrix.com, ian.jackson@eu.citrix.com, david.vrabel@citrix.com, jbeulich@suse.com Subject: [Xen-devel] [PATCH v2 1/3] xen: silence affinity messages on suspend/resume X-BeenThere: xen-devel@lists.xen.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: Xen developer discussion List-Unsubscribe: , List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Errors-To: xen-devel-bounces@lists.xen.org Sender: "Xen-devel" X-Spam-Status: No, score=-1.9 required=5.0 tests=BAYES_00, UNPARSEABLE_RELAY autolearn=unavailable version=3.3.1 X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on mail.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP When taking cpus offline for suspend or bringing them online on resume again the scheduler might issue debug messages when temporarily breaking vcpu affinity or restoring the original affinity settings. The resume message can be removed completely, while the message when breaking affinity should only be issued if the breakage is permanent. Suggested-by: Jan Beulich Signed-off-by: Juergen Gross Acked-by: Dario Faggioli --- xen/common/schedule.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/xen/common/schedule.c b/xen/common/schedule.c index 434dcfc..b0d4b18 100644 --- a/xen/common/schedule.c +++ b/xen/common/schedule.c @@ -615,7 +615,6 @@ void restore_vcpu_affinity(struct domain *d) if ( v->affinity_broken ) { - printk(XENLOG_DEBUG "Restoring affinity for %pv\n", v); cpumask_copy(v->cpu_hard_affinity, v->cpu_hard_affinity_saved); v->affinity_broken = 0; } @@ -670,14 +669,14 @@ int cpu_disable_scheduler(unsigned int cpu) if ( cpumask_empty(&online_affinity) && cpumask_test_cpu(cpu, v->cpu_hard_affinity) ) { - printk(XENLOG_DEBUG "Breaking affinity for %pv\n", v); - if (system_state == SYS_STATE_suspend) { cpumask_copy(v->cpu_hard_affinity_saved, v->cpu_hard_affinity); v->affinity_broken = 1; } + else + printk(XENLOG_DEBUG "Breaking affinity for %pv\n", v); cpumask_setall(v->cpu_hard_affinity); }