From patchwork Sat Jan 5 16:58:50 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: "Paul E. McKenney" X-Patchwork-Id: 13814 Return-Path: X-Original-To: patchwork@peony.canonical.com Delivered-To: patchwork@peony.canonical.com Received: from fiordland.canonical.com (fiordland.canonical.com [91.189.94.145]) by peony.canonical.com (Postfix) with ESMTP id 0AA7623E33 for ; Sat, 5 Jan 2013 16:59:29 +0000 (UTC) Received: from mail-vb0-f44.google.com (mail-vb0-f44.google.com [209.85.212.44]) by fiordland.canonical.com (Postfix) with ESMTP id BC1E1A191B4 for ; Sat, 5 Jan 2013 16:59:28 +0000 (UTC) Received: by mail-vb0-f44.google.com with SMTP id fc26so17620275vbb.31 for ; Sat, 05 Jan 2013 08:59:28 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:x-forwarded-to:x-forwarded-for:delivered-to:x-received :received-spf:from:to:cc:subject:date:message-id:x-mailer :in-reply-to:references:x-content-scanned:x-cbid:x-gm-message-state; bh=nTLHBQIVWvN8EMsTeX5ks/UflEgIcWqSD4XKyvFA0Bg=; b=ozpDO+PtxCUoARK7yOCgqaVguEhu63Se8kDpTNyAbjmypLnbRLSOQJ2fhrEWIoPnLa gO+6sa23VHuBRITmoxvrd1IIXckw6fA5xiQ23olXEDoqXRN8N9D1hBE8ZMS8Zd2NXH5y r/9GlkoqOgVjx65o98aWZipfDPd6U2+mf8qjRN56B1N6cK2x5GpH1X6OVtpoYpoD2wji h/KK5s0/K9hImmwT6Dn8/ohZbfkfvS61TBlIp42CVBR84XEzoBCnMy4b/CUxu5uknJAW QmG6cm2sHGFnq2m0yT/eCKh2R9xPaNKEmLsLQUaPzXp9sT9OBXzUr1jTmx/er8qUBzgO CvaQ== X-Received: by 10.58.247.132 with SMTP id ye4mr82251222vec.9.1357405168286; Sat, 05 Jan 2013 08:59:28 -0800 (PST) X-Forwarded-To: linaro-patchwork@canonical.com X-Forwarded-For: patch@linaro.org linaro-patchwork@canonical.com Delivered-To: patches@linaro.org Received: by 10.58.145.101 with SMTP id st5csp16029veb; Sat, 5 Jan 2013 08:59:27 -0800 (PST) X-Received: by 10.50.33.147 with SMTP id r19mr1901584igi.73.1357405167581; Sat, 05 Jan 2013 08:59:27 -0800 (PST) Received: from e37.co.us.ibm.com (e37.co.us.ibm.com. [32.97.110.158]) by mx.google.com with ESMTPS id a10si2577996igl.68.2013.01.05.08.59.27 (version=TLSv1 cipher=RC4-SHA bits=128/128); Sat, 05 Jan 2013 08:59:27 -0800 (PST) Received-SPF: pass (google.com: domain of paulmck@linux.vnet.ibm.com designates 32.97.110.158 as permitted sender) client-ip=32.97.110.158; Authentication-Results: mx.google.com; spf=pass (google.com: domain of paulmck@linux.vnet.ibm.com designates 32.97.110.158 as permitted sender) smtp.mail=paulmck@linux.vnet.ibm.com Received: from /spool/local by e37.co.us.ibm.com with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted for from ; Sat, 5 Jan 2013 09:59:26 -0700 Received: from d03dlp03.boulder.ibm.com (9.17.202.179) by e37.co.us.ibm.com (192.168.1.137) with IBM ESMTP SMTP Gateway: Authorized Use Only! Violators will be prosecuted; Sat, 5 Jan 2013 09:59:11 -0700 Received: from d03relay05.boulder.ibm.com (d03relay05.boulder.ibm.com [9.17.195.107]) by d03dlp03.boulder.ibm.com (Postfix) with ESMTP id 0B76319D8041 for ; Sat, 5 Jan 2013 09:59:11 -0700 (MST) Received: from d03av02.boulder.ibm.com (d03av02.boulder.ibm.com [9.17.195.168]) by d03relay05.boulder.ibm.com (8.13.8/8.13.8/NCO v10.0) with ESMTP id r05GxAK5112260 for ; Sat, 5 Jan 2013 09:59:10 -0700 Received: from d03av02.boulder.ibm.com (loopback [127.0.0.1]) by d03av02.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVout) with ESMTP id r05Gx8oM009086 for ; Sat, 5 Jan 2013 09:59:10 -0700 Received: from paulmck-ThinkPad-W500 ([9.80.23.97]) by d03av02.boulder.ibm.com (8.14.4/8.13.1/NCO v10.0 AVin) with ESMTP id r05GwvWd008616; Sat, 5 Jan 2013 09:59:03 -0700 Received: by paulmck-ThinkPad-W500 (Postfix, from userid 1000) id 9A282E4768; Sat, 5 Jan 2013 08:58:52 -0800 (PST) From: "Paul E. McKenney" To: linux-kernel@vger.kernel.org Cc: mingo@elte.hu, laijs@cn.fujitsu.com, dipankar@in.ibm.com, akpm@linux-foundation.org, mathieu.desnoyers@polymtl.ca, josh@joshtriplett.org, niv@us.ibm.com, tglx@linutronix.de, peterz@infradead.org, rostedt@goodmis.org, Valdis.Kletnieks@vt.edu, dhowells@redhat.com, edumazet@google.com, darren@dvhart.com, fweisbec@gmail.com, sbw@mit.edu, patches@linaro.org, Paul Gortmaker , "Paul E. McKenney" Subject: [PATCH tip/core/urgent 1/2] rcu: Prevent soft-lockup complaints about no-CBs CPUs Date: Sat, 5 Jan 2013 08:58:50 -0800 Message-Id: <1357405131-13421-1-git-send-email-paulmck@linux.vnet.ibm.com> X-Mailer: git-send-email 1.7.8 In-Reply-To: <20130105165817.GA13260@linux.vnet.ibm.com> References: <20130105165817.GA13260@linux.vnet.ibm.com> X-Content-Scanned: Fidelis XPS MAILER x-cbid: 13010516-7408-0000-0000-00000B9504B3 X-Gm-Message-State: ALoCoQllXsBK175I5/CDA4RySSH2CZLM1rBCEu2n14KV4t8JGeoH9n9Vmjpe3ObuN13iA6Y1qAK0 From: Paul Gortmaker The wait_event() at the head of the rcu_nocb_kthread() can result in soft-lockup complaints if the CPU in question does not register RCU callbacks for an extended period. This commit therefore changes the wait_event() to a wait_event_interruptible(). Reported-by: Frederic Weisbecker Signed-off-by: Paul Gortmaker Signed-off-by: Paul E. McKenney --- kernel/rcutree_plugin.h | 3 ++- 1 files changed, 2 insertions(+), 1 deletions(-) diff --git a/kernel/rcutree_plugin.h b/kernel/rcutree_plugin.h index f6e5ec2..43dba2d 100644 --- a/kernel/rcutree_plugin.h +++ b/kernel/rcutree_plugin.h @@ -2366,10 +2366,11 @@ static int rcu_nocb_kthread(void *arg) for (;;) { /* If not polling, wait for next batch of callbacks. */ if (!rcu_nocb_poll) - wait_event(rdp->nocb_wq, rdp->nocb_head); + wait_event_interruptible(rdp->nocb_wq, rdp->nocb_head); list = ACCESS_ONCE(rdp->nocb_head); if (!list) { schedule_timeout_interruptible(1); + flush_signals(current); continue; }