From patchwork Sat Mar 2 10:10:13 2013 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Lezcano X-Patchwork-Id: 2206611 Return-Path: X-Original-To: patchwork-linux-arm@patchwork.kernel.org Delivered-To: patchwork-process-083081@patchwork2.kernel.org Received: from merlin.infradead.org (merlin.infradead.org [205.233.59.134]) by patchwork2.kernel.org (Postfix) with ESMTP id D2CAFDF230 for ; Sat, 2 Mar 2013 10:13:32 +0000 (UTC) Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1UBjP8-0000yF-2r; Sat, 02 Mar 2013 10:10:58 +0000 Received: from mail-wi0-f173.google.com ([209.85.212.173]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1UBjOX-0000qY-3z for linux-arm-kernel@lists.infradead.org; Sat, 02 Mar 2013 10:10:23 +0000 Received: by mail-wi0-f173.google.com with SMTP id hq4so338040wib.6 for ; Sat, 02 Mar 2013 02:10:19 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=x-received:from:to:cc:subject:date:message-id:x-mailer:in-reply-to :references:x-gm-message-state; bh=/XoB0PFKOTBFWNf3ooYy/ZFPjSLXraUfQFIEb1ielxY=; b=AREOWzaaOD40nCvBi7aHSHL9rc91RA+nhExh0qvRldkeCKzQdNvvO6qts4ou1RLQAC T3iSQYkcgs15z62d1bXGkB5mNNRD65ICq0G+N3LMtLBsIC+i/P/bMsHBp5W/oOGJUwkR gG3DWVQsGEXKDCJVd2CkM23IADIDMpRisycT6jxrDVNtvDxYZWAUgaLiclTv3oST4C6j 4Cof7aSWA5ji9+2vYG6+nlmJbIHsuyWGun9KcsO6elN50fGw7gRr0Ss5a0dnZcOb0LAZ ThK3NfAan2kheCyIlY+/97W5Uv/8kt/gGIa7A02VCG6iTy/0r5eIknbt3mXIDzXk0y+k 78Bg== X-Received: by 10.194.60.195 with SMTP id j3mr22170579wjr.33.1362219019463; Sat, 02 Mar 2013 02:10:19 -0800 (PST) Received: from mai.home (AToulouse-654-1-336-203.w86-199.abo.wanadoo.fr. [86.199.223.203]) by mx.google.com with ESMTPS id cf8sm2519888wib.1.2013.03.02.02.10.17 (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sat, 02 Mar 2013 02:10:18 -0800 (PST) From: Daniel Lezcano To: john.stultz@linaro.org, tglx@linutronix.de Subject: [PATCH 4/4][V2] ARM: timer-sp: Set dynamic irq affinity Date: Sat, 2 Mar 2013 11:10:13 +0100 Message-Id: <1362219013-18173-5-git-send-email-daniel.lezcano@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1362219013-18173-1-git-send-email-daniel.lezcano@linaro.org> References: <1362219013-18173-1-git-send-email-daniel.lezcano@linaro.org> X-Gm-Message-State: ALoCoQkxIuo2QpbVWg0viYKXDPSTDYPdilgCvQ0geDPprxwel0/9QGC2lNj10zRIm5ou/gFmpUpf X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20130302_051021_399586_33BAE3F4 X-CRM114-Status: GOOD ( 12.16 ) X-Spam-Score: -2.6 (--) X-Spam-Report: SpamAssassin version 3.3.2 on merlin.infradead.org summary: Content analysis details: (-2.6 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [209.85.212.173 listed in list.dnswl.org] -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: jacob.jun.pan@linux.intel.com, vincent.guittot@linaro.org, linus.walleij@stericsson.com, linux-pm@vger.kernel.org, viresh.kumar@linaro.org, patches@linaro.org, linux-kernel@vger.kernel.org, rickard.andersson@stericsson.com, linaro-kernel@lists.linaro.org, santosh.shilimkar@ti.com, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.15 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , MIME-Version: 1.0 Sender: "linux-arm-kernel" Errors-To: linux-arm-kernel-bounces+patchwork-linux-arm=patchwork.kernel.org@lists.infradead.org From: Viresh Kumar When a cpu goes to a deep idle state where its local timer is shutdown, it notifies the time frame work to use the broadcast timer instead. Unfortunately, the broadcast device could wake up any CPU, including an idle one which is not concerned by the wake up at all. This implies, in the worst case, an idle CPU will wake up to send an IPI to another idle cpu. This patch fixes this for ARM platforms using timer-sp, by setting CLOCK_EVT_FEAT_DYNIRQ feature. Signed-off-by: Viresh Kumar Signed-off-by: Daniel Lezcano Acked-by: Russell King --- arch/arm/common/timer-sp.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/arch/arm/common/timer-sp.c b/arch/arm/common/timer-sp.c index 9d2d3ba..ae3c0f9 100644 --- a/arch/arm/common/timer-sp.c +++ b/arch/arm/common/timer-sp.c @@ -158,7 +158,8 @@ static int sp804_set_next_event(unsigned long next, } static struct clock_event_device sp804_clockevent = { - .features = CLOCK_EVT_FEAT_PERIODIC | CLOCK_EVT_FEAT_ONESHOT, + .features = CLOCK_EVT_FEAT_PERIODIC | CLOCK_EVT_FEAT_ONESHOT | + CLOCK_EVT_FEAT_DYNIRQ, .set_mode = sp804_set_mode, .set_next_event = sp804_set_next_event, .rating = 300,