From patchwork Wed Dec 23 11:29:13 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 58974 Delivered-To: patch@linaro.org Received: by 10.112.89.199 with SMTP id bq7csp3796272lbb; Wed, 23 Dec 2015 03:29:40 -0800 (PST) X-Received: by 10.66.101.36 with SMTP id fd4mr43764718pab.76.1450870179991; Wed, 23 Dec 2015 03:29:39 -0800 (PST) Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l85si25863333pfi.176.2015.12.23.03.29.39; Wed, 23 Dec 2015 03:29:39 -0800 (PST) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dkim=neutral (body hash did not verify) header.i=@linaro.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1756607AbbLWL3f (ORCPT + 29 others); Wed, 23 Dec 2015 06:29:35 -0500 Received: from mail-pa0-f54.google.com ([209.85.220.54]:36734 "EHLO mail-pa0-f54.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1756546AbbLWL3b (ORCPT ); Wed, 23 Dec 2015 06:29:31 -0500 Received: by mail-pa0-f54.google.com with SMTP id q3so111383564pav.3 for ; Wed, 23 Dec 2015 03:29:31 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linaro.org; s=google; h=from:to:cc:subject:date:message-id:in-reply-to:references :in-reply-to:references; bh=pDwNPSqY4y1Gukvz/4avhRtNJnWA/FqN1e5AbsaQC/A=; b=Wl6O4GZuduD7Adzr7e5I3nuhQG5+s4A/SWHCJCcYyMRpglkOeHYwTsG/NR9b4PEM5Y XIZHna6m3ZnHxPg4WXuzysRvJhOo7bhQposCvnRMrbl4QjABmGPieJAdqdBdxNoacSI9 suG7cU24amMfhT9R39Z6G0TrXifKSZosN5le0= X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references:in-reply-to:references; bh=pDwNPSqY4y1Gukvz/4avhRtNJnWA/FqN1e5AbsaQC/A=; b=SwNhTmzbDbZAUvoLSh3zUTmiB4RUjftfkW+cu62/3EeipGEllY/KudgnB1ioLNnoCp VFSNjp1t7E+5XJlv+hxwPDZ53jur01o6y9Xk+SDM90GjbcIbF1+wqjQZgWb4DPyWC/Sh xV4orMn3AaTTf5h5tXWmTyKGJLVflPqBLMV4NSyz9NpdQARfPc7Zz9P7ZHJqNzaQwtIt 5Vl0loUFLNNQCPAZgLCz/Wa4dVTYu5pkb69e8u1+rwvGwqYUY3pNKHytdD0YADEqcHRb 2L/NsX2+3h84lhyt06YUuHZu8zewJZkJj+ugfMTzV7iZXlFElFQAgI3uMUVRexc1vtVB NycA== X-Gm-Message-State: ALoCoQnid/EYxBXla831oBSYvD05HKT/iZAQx8CxXfawEy7wRxx4OMdie9/O/73WuZRSAMixpIH/C2ucx7pBN+tp0LQgBJhJWA== X-Received: by 10.66.164.70 with SMTP id yo6mr43163764pab.36.1450870170752; Wed, 23 Dec 2015 03:29:30 -0800 (PST) Received: from localhost ([122.171.29.67]) by smtp.gmail.com with ESMTPSA id c1sm52224994pas.1.2015.12.23.03.29.29 (version=TLS1_2 cipher=AES128-SHA bits=128/128); Wed, 23 Dec 2015 03:29:30 -0800 (PST) From: Viresh Kumar To: Daniel Lezcano , Thomas Gleixner Cc: linaro-kernel@lists.linaro.org, linux-kernel@vger.kernel.org, Viresh Kumar , kernel@stlinux.com (open list:ARM/STI ARCHITECTURE), linux-arm-kernel@lists.infradead.org (moderated list:ARM/STI ARCHITECTURE), Maxime Coquelin , Patrice Chotard , Srinivas Kandagatla Subject: [PATCH 2/3] clockevents/arm_global_timer: Implement ->set_state_oneshot_stopped() Date: Wed, 23 Dec 2015 16:59:13 +0530 Message-Id: X-Mailer: git-send-email 2.7.0.rc1.186.g94414c4 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org set_state_oneshot_stopped() is called by the clkevt core, when the next event is required at an expiry time of 'KTIME_MAX'. This normally happens with NO_HZ_{IDLE|FULL} in both LOWRES/HIGHRES modes. This patch makes the clockevent device to stop on such an event, to avoid spurious interrupts, as explained by: commit 8fff52fd5093 ("clockevents: Introduce CLOCK_EVT_STATE_ONESHOT_STOPPED state"). Signed-off-by: Viresh Kumar --- drivers/clocksource/arm_global_timer.c | 1 + 1 file changed, 1 insertion(+) -- 2.7.0.rc1.186.g94414c4 -- 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/ diff --git a/drivers/clocksource/arm_global_timer.c b/drivers/clocksource/arm_global_timer.c index a2cb6fae9295..801cfe5833c1 100644 --- a/drivers/clocksource/arm_global_timer.c +++ b/drivers/clocksource/arm_global_timer.c @@ -174,6 +174,7 @@ static int gt_clockevents_init(struct clock_event_device *clk) clk->set_state_shutdown = gt_clockevent_shutdown; clk->set_state_periodic = gt_clockevent_set_periodic; clk->set_state_oneshot = gt_clockevent_shutdown; + clk->set_state_oneshot_stopped = gt_clockevent_shutdown; clk->set_next_event = gt_clockevent_set_next_event; clk->cpumask = cpumask_of(cpu); clk->rating = 300;