Received: by 2002:a05:6a10:17d3:0:0:0:0 with SMTP id hz19csp577772pxb; Fri, 16 Apr 2021 12:41:44 -0700 (PDT) X-Google-Smtp-Source: ABdhPJw8FlEMNEJwaXg6Y3ZjcqLCOkp0tCI5BetxRD7VuUp6hg4o+vkNYcD4YPFs901atMpNmjec X-Received: by 2002:a17:906:1c8f:: with SMTP id g15mr9744404ejh.20.1618602104229; Fri, 16 Apr 2021 12:41:44 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1618602104; cv=none; d=google.com; s=arc-20160816; b=tAShUCubgzXRlZqFv2qH/hz0mKpOqN2mkmmWq6JyMm4o8rMp4XZIACvQqwjDcyAvsj d0rn5+RMrGjW4sQGw8TUQV9FojH8BF4eacwJc9sEXL0rpAbuZfnObp6Tu6pKSds4j976 oEpbIr2Z2uR0ae56lHfOvfWT91pSKk+ZG+WP+Kg1uELffAn4esRgcTacE7MBcKQszb34 triKsfuNTRkxLtlYqC4TngaZS72sJDtYO4hlN6J0zLSjZA/UhF8R2rA/4Q9qZ4/G6nYa lJlb1Y8ANnojuZ39wOXWfDwZt8GvlCVPNIZabOwTSwX2K8UjtbgluCOfrBpTVf4Pocvk hd5Q== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:content-transfer-encoding:robot-unsubscribe :robot-id:message-id:mime-version:references:in-reply-to:cc:subject :to:reply-to:sender:from:dkim-signature:dkim-signature:date; bh=RXeDpHhm+Qn3xDVhJ5riLOB/Nu6pLzHS8NqwHThHcGY=; b=qt9Tj+B7SiXoF3onBFBbIc1p580SyxTzK+RmedgMLAi8pvIJYrnHa56FAAJwr5m9pl EEbuHaRI0ichdNyo180iDW2/CHoVkS+jNuskltNMFb3hKO5u3vzqf0a80MB/ssOwTlVS 9Uy/k6ZtoaQLpZDPWvRRJcIyYu+O/lHHjv3FjRgCGUW8XY6AFaj26vQ581Pi/ZrBE5AK IpyuqW0uNenYmrjx8mmvhH8lP5DqOYPTsJQ0eMOuQqhTGvHKxUNtZ881ph9T1Mw8RLWV pxsIaynqvS4lUvtkhfC8evCZ/Med2GSp5HFGCZnqaSVVnxYu24UECGxbiaVdUu/xYlaW re6g== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=PgGIwTz+; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id w5si2543344ejv.631.2021.04.16.12.41.21; Fri, 16 Apr 2021 12:41:44 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@linutronix.de header.s=2020 header.b=PgGIwTz+; dkim=neutral (no key) header.i=@linutronix.de; spf=pass (google.com: domain of linux-kernel-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=linutronix.de Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S241297AbhDPTI0 (ORCPT + 99 others); Fri, 16 Apr 2021 15:08:26 -0400 Received: from Galois.linutronix.de ([193.142.43.55]:59306 "EHLO galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S234898AbhDPTIZ (ORCPT ); Fri, 16 Apr 2021 15:08:25 -0400 Date: Fri, 16 Apr 2021 19:07:56 -0000 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020; t=1618600079; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=RXeDpHhm+Qn3xDVhJ5riLOB/Nu6pLzHS8NqwHThHcGY=; b=PgGIwTz+NfLgme/GJ0yZtgNNqPkD5dtvgq4h9hN+OT88dtvHG+WIaRAyRzNAqRjR+i6hSo SX8Qjd3IbLmuawZz2R18HXBKCZVLTzBY7u0dp0nFx597odxLOUkIUJjW3b1oRuqGWGxjdR yqiI6UbdBY8HD4NhV6C/d18RDEzdBZJ0IfMcIMcHA8bakDX0D9mmibUHf9jZvkWJbCXgeK k2ObHG0XAyPUMgJ/uQvuhm06C7TqEJIGhgDo9QY5LQEaBBM7QTzNdpGmDIXhFqeUc3mxSE RntRdkRAKwrtIAdzJrbzAM6OBH5oSdpe4WhZFHqojtiWA2QRFzdoTBLJiH8oGw== DKIM-Signature: v=1; a=ed25519-sha256; c=relaxed/relaxed; d=linutronix.de; s=2020e; t=1618600079; h=from:from:sender:sender:reply-to:reply-to:subject:subject:date:date: message-id:message-id:to:to:cc:cc:mime-version:mime-version: content-type:content-type: content-transfer-encoding:content-transfer-encoding: in-reply-to:in-reply-to:references:references; bh=RXeDpHhm+Qn3xDVhJ5riLOB/Nu6pLzHS8NqwHThHcGY=; b=/NSUdsD7Yc15Hj/Syis51bLF2Kv1Se9NBti+YgN6VcSsJHyQggCZSuVODx+yeS5sx4ySI0 4nb15Eiq31hJAsAA== From: "tip-bot2 for Marc Kleine-Budde" Sender: tip-bot2@linutronix.de Reply-to: linux-kernel@vger.kernel.org To: linux-tip-commits@vger.kernel.org Subject: [tip: timers/core] time/timecounter: Mark 1st argument of timecounter_cyc2time() as const Cc: "Marc Kleine-Budde" , Thomas Gleixner , x86@kernel.org, linux-kernel@vger.kernel.org In-Reply-To: <20210303103544.994855-1-mkl@pengutronix.de> References: <20210303103544.994855-1-mkl@pengutronix.de> MIME-Version: 1.0 Message-ID: <161860007673.29796.3934141418916152456.tip-bot2@tip-bot2> Robot-ID: Robot-Unsubscribe: Contact to get blacklisted from these emails Content-Type: text/plain; charset="utf-8" Content-Transfer-Encoding: 7bit Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org The following commit has been merged into the timers/core branch of tip: Commit-ID: 07ff4aed015c564d03fd518d2fb54e5e6948903c Gitweb: https://git.kernel.org/tip/07ff4aed015c564d03fd518d2fb54e5e6948903c Author: Marc Kleine-Budde AuthorDate: Wed, 03 Mar 2021 11:35:44 +01:00 Committer: Thomas Gleixner CommitterDate: Fri, 16 Apr 2021 21:03:50 +02:00 time/timecounter: Mark 1st argument of timecounter_cyc2time() as const The timecounter is not modified in this function. Mark it as const. Signed-off-by: Marc Kleine-Budde Signed-off-by: Thomas Gleixner Link: https://lore.kernel.org/r/20210303103544.994855-1-mkl@pengutronix.de --- include/linux/timecounter.h | 2 +- kernel/time/timecounter.c | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/include/linux/timecounter.h b/include/linux/timecounter.h index 754b74a..c6540ce 100644 --- a/include/linux/timecounter.h +++ b/include/linux/timecounter.h @@ -124,7 +124,7 @@ extern u64 timecounter_read(struct timecounter *tc); * This allows conversion of cycle counter values which were generated * in the past. */ -extern u64 timecounter_cyc2time(struct timecounter *tc, +extern u64 timecounter_cyc2time(const struct timecounter *tc, u64 cycle_tstamp); #endif diff --git a/kernel/time/timecounter.c b/kernel/time/timecounter.c index 85b98e7..e628528 100644 --- a/kernel/time/timecounter.c +++ b/kernel/time/timecounter.c @@ -76,7 +76,7 @@ static u64 cc_cyc2ns_backwards(const struct cyclecounter *cc, return ns; } -u64 timecounter_cyc2time(struct timecounter *tc, +u64 timecounter_cyc2time(const struct timecounter *tc, u64 cycle_tstamp) { u64 delta = (cycle_tstamp - tc->cycle_last) & tc->cc->mask;