From patchwork Thu Oct 11 01:00:40 2012 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Greg KH X-Patchwork-Id: 1578861 Return-Path: X-Original-To: patchwork-linux-parisc@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork1.kernel.org Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by patchwork1.kernel.org (Postfix) with ESMTP id A2CCB4025F for ; Thu, 11 Oct 2012 01:13:20 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S933005Ab2JKBMv (ORCPT ); Wed, 10 Oct 2012 21:12:51 -0400 Received: from out1-smtp.messagingengine.com ([66.111.4.25]:48984 "EHLO out1-smtp.messagingengine.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932990Ab2JKBMr (ORCPT ); Wed, 10 Oct 2012 21:12:47 -0400 Received: from compute2.internal (compute2.nyi.mail.srv.osa [10.202.2.42]) by gateway1.nyi.mail.srv.osa (Postfix) with ESMTP id D1A022086B; Wed, 10 Oct 2012 21:12:46 -0400 (EDT) Received: from frontend2.nyi.mail.srv.osa ([10.202.2.161]) by compute2.internal (MEProxy); Wed, 10 Oct 2012 21:12:46 -0400 DKIM-Signature: v=1; a=rsa-sha1; c=relaxed/relaxed; d= messagingengine.com; h=from:to:cc:subject:date:message-id :in-reply-to:references; s=smtpout; bh=bzvBcJngwAg3kmqF/RJB9s3ZG 04=; b=VPkLfyr6aEqX8ySr1ARnlVDpb70MY15Do5f19TjQer3EYNUGP5kqNOUt3 CKnr71c/7gpUOC44WL/d40V5AeNdMEj0cT+BoyBeC9xStysikSqJNXnv/YcoxV/M ijQVdUrm0ziuROg0Xfe0pjFj0NpjgyWkpvN+4OsnKuZPtmxPOo= X-Sasl-enc: ZYYP+W2EEZ3JpBvO3YxHZwvkW4i0yWSK0rLv3jYy/CKQ 1349917966 Received: from localhost (unknown [222.106.197.10]) by mail.messagingengine.com (Postfix) with ESMTPA id 242A74827BC; Wed, 10 Oct 2012 21:12:45 -0400 (EDT) From: Greg Kroah-Hartman To: linux-kernel@vger.kernel.org, stable@vger.kernel.org Cc: Greg Kroah-Hartman , alan@lxorguk.ukuu.org.uk, "Paul E. McKenney" , Frederic Weisbecker , "James E.J. Bottomley" , Helge Deller , Parisc , Josh Triplett Subject: [ 088/120] parisc: Add missing RCU idle APIs on idle loop Date: Thu, 11 Oct 2012 10:00:40 +0900 Message-Id: <20121011005842.879908847@linuxfoundation.org> X-Mailer: git-send-email 1.8.0.rc0.18.gf84667d In-Reply-To: <20121011005825.364610894@linuxfoundation.org> References: <20121011005825.364610894@linuxfoundation.org> User-Agent: quilt/0.60-2.1.2 Sender: linux-parisc-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-parisc@vger.kernel.org 3.4-stable review patch. If anyone has any objections, please let me know. ------------------ From: Frederic Weisbecker commit fbe752188d5589e7fcbb8e79824e560f77dccc92 upstream. In the old times, the whole idle task was considered as an RCU quiescent state. But as RCU became more and more successful overtime, some RCU read side critical section have been added even in the code of some architectures idle tasks, for tracing for example. So nowadays, rcu_idle_enter() and rcu_idle_exit() must be called by the architecture to tell RCU about the part in the idle loop that doesn't make use of rcu read side critical sections, typically the part that puts the CPU in low power mode. This is necessary for RCU to find the quiescent states in idle in order to complete grace periods. Add this missing pair of calls in the parisc's idle loop. Reported-by: Paul E. McKenney Signed-off-by: Frederic Weisbecker Cc: James E.J. Bottomley Cc: Helge Deller Cc: Parisc Signed-off-by: Paul E. McKenney Reviewed-by: Josh Triplett Signed-off-by: Greg Kroah-Hartman --- arch/parisc/kernel/process.c | 3 +++ 1 file changed, 3 insertions(+) -- To unsubscribe from this list: send the line "unsubscribe linux-parisc" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- a/arch/parisc/kernel/process.c +++ b/arch/parisc/kernel/process.c @@ -48,6 +48,7 @@ #include #include #include +#include #include #include @@ -69,8 +70,10 @@ void cpu_idle(void) /* endless idle loop with no priority at all */ while (1) { + rcu_idle_enter(); while (!need_resched()) barrier(); + rcu_idle_exit(); schedule_preempt_disabled(); check_pgt_cache(); }