Received: by 10.223.185.116 with SMTP id b49csp6151490wrg; Wed, 28 Feb 2018 05:00:47 -0800 (PST) X-Google-Smtp-Source: AH8x225vqEDWfUHP6ZG3zpRp8GLseQwAKOcJQUIHefNIgkyOkAR3je9NWIuapg+vSTDzvCyIl8Rm X-Received: by 2002:a17:902:b903:: with SMTP id bf3-v6mr18247614plb.316.1519822846927; Wed, 28 Feb 2018 05:00:46 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1519822846; cv=none; d=google.com; s=arc-20160816; b=nmq0n2tfcZLDLiH3ISlta061kEbNXoMRVFH1Zx1dP1Uaxz4QfYjxY4gA0NxE5+QWon G/hnlWex5iWzE8U5kRc34DMLeeCdBjfkMOfEGdQuKSersKKgumeMNBVzAnqw4LkP7kQQ 4u3CI71zJH/7N2vn5oIaONTTl4XgxY1DTUUWGBQY2MhlTMJgwjrLjlRRIiSE4K+SV8Jb uJwkscf4ndGO7AF6wG0wOFOa4JEx4U5nqW/ZjSIkzgvp0ckh5KCnl8D6YGficz5TOgXg c1GnZ5efwLoVkYwWR7zTmbNFnX1UabaPmmLd0iPe24WN2beT9WrVVgcg58Zd9aW7i+2E VNog== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:content-disposition :content-transfer-encoding:mime-version:robot-unsubscribe:robot-id :git-commit-id:subject:to:references:in-reply-to:reply-to:cc :message-id:from:date:arc-authentication-results; bh=5aFm2n3gsE0aZZ74NYwPIz9vxD8Fm1gGWPw455nsM+s=; b=L8AqQxtUh+tvEmaBgIrv3XQPS7VKhJszfY1IQIACovXaaCp6MPJA1hnQaQnVwnNhwK PCyM5L2B4DVcV+KhBtLXcLpfv2n4L5Caw0lp3CqgtsU3hNBTDlp+LZlJisgFiWOi17qD e6RPvcoFY2lTrrzB9K4R+AjJnZ6lafevzxUN3V9H8DTl+BnWnytzdKcLrKQSM33XT5+H esWrsURpQVOQ3hWVlsh9Q5uaPluN6gjy9lwsOdHJ63iu08tLS8WpfMu7aUeA1WXFpGty KplaokBhaoh7G4I/cYqyQw4Xxw2A4301KtpMAmYMKfkZn6iW1ZTHInPOunRk4de+DJKy 4jOg== ARC-Authentication-Results: i=1; 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 Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s19si988778pgo.626.2018.02.28.05.00.29; Wed, 28 Feb 2018 05:00:46 -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 Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932104AbeB1M7l (ORCPT + 99 others); Wed, 28 Feb 2018 07:59:41 -0500 Received: from terminus.zytor.com ([198.137.202.136]:41081 "EHLO terminus.zytor.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1752417AbeB1M7k (ORCPT ); Wed, 28 Feb 2018 07:59:40 -0500 Received: from terminus.zytor.com (localhost [127.0.0.1]) by terminus.zytor.com (8.15.2/8.15.2) with ESMTP id w1SCxVJf002084; Wed, 28 Feb 2018 04:59:31 -0800 Received: (from tipbot@localhost) by terminus.zytor.com (8.15.2/8.15.2/Submit) id w1SCxUs6002080; Wed, 28 Feb 2018 04:59:30 -0800 Date: Wed, 28 Feb 2018 04:59:30 -0800 X-Authentication-Warning: terminus.zytor.com: tipbot set sender to tipbot@zytor.com using -f From: tip-bot for Vineet Gupta Message-ID: Cc: vgupta@synopsys.com, tglx@linutronix.de, linux-kernel@vger.kernel.org, mingo@kernel.org, daniel.lezcano@linaro.org, Vineet.Gupta1@synopsys.com, hpa@zytor.com Reply-To: hpa@zytor.com, Vineet.Gupta1@synopsys.com, mingo@kernel.org, daniel.lezcano@linaro.org, linux-kernel@vger.kernel.org, tglx@linutronix.de, vgupta@synopsys.com In-Reply-To: <1519241491-12570-1-git-send-email-vgupta@synopsys.com> References: <1519241491-12570-1-git-send-email-vgupta@synopsys.com> To: linux-tip-commits@vger.kernel.org Subject: [tip:timers/urgent] clocksource/drivers/arc_timer: Update some comments Git-Commit-ID: a4f538573cd72e7961f4ec5eb13c171f5add58ec X-Mailer: tip-git-log-daemon Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails MIME-Version: 1.0 Content-Transfer-Encoding: 8bit Content-Type: text/plain; charset=UTF-8 Content-Disposition: inline X-Spam-Status: No, score=-2.9 required=5.0 tests=ALL_TRUSTED,BAYES_00 autolearn=ham autolearn_force=no version=3.4.1 X-Spam-Checker-Version: SpamAssassin 3.4.1 (2015-04-28) on terminus.zytor.com Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org Commit-ID: a4f538573cd72e7961f4ec5eb13c171f5add58ec Gitweb: https://git.kernel.org/tip/a4f538573cd72e7961f4ec5eb13c171f5add58ec Author: Vineet Gupta AuthorDate: Wed, 21 Feb 2018 11:31:31 -0800 Committer: Thomas Gleixner CommitDate: Wed, 28 Feb 2018 13:55:14 +0100 clocksource/drivers/arc_timer: Update some comments TIMER0 interrupt ACK is different for ARC700 and HS3x cores. This came to light in some internal discussions and it is nice to have this documented rather than digging up the PRM (Programmers Reference Manual). Signed-off-by: Vineet Gupta Signed-off-by: Thomas Gleixner Cc: Daniel Lezcano Cc: Vineet Gupta Cc: linux-snps-arc@lists.infradead.org Link: https://lkml.kernel.org/r/1519241491-12570-1-git-send-email-vgupta@synopsys.com --- drivers/clocksource/arc_timer.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) diff --git a/drivers/clocksource/arc_timer.c b/drivers/clocksource/arc_timer.c index 4927355f9cbe..471b428d8034 100644 --- a/drivers/clocksource/arc_timer.c +++ b/drivers/clocksource/arc_timer.c @@ -251,9 +251,14 @@ static irqreturn_t timer_irq_handler(int irq, void *dev_id) int irq_reenable = clockevent_state_periodic(evt); /* - * Any write to CTRL reg ACks the interrupt, we rewrite the - * Count when [N]ot [H]alted bit. - * And re-arm it if perioid by [I]nterrupt [E]nable bit + * 1. ACK the interrupt + * - For ARC700, any write to CTRL reg ACKs it, so just rewrite + * Count when [N]ot [H]alted bit. + * - For HS3x, it is a bit subtle. On taken count-down interrupt, + * IP bit [3] is set, which needs to be cleared for ACK'ing. + * The write below can only update the other two bits, hence + * explicitly clears IP bit + * 2. Re-arm interrupt if periodic by writing to IE bit [0] */ write_aux_reg(ARC_REG_TIMER0_CTRL, irq_reenable | TIMER_CTRL_NH);