From patchwork Fri Feb 14 10:29:30 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Linus Walleij X-Patchwork-Id: 24621 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-vc0-f199.google.com (mail-vc0-f199.google.com [209.85.220.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id CF0EE203C4 for ; Fri, 14 Feb 2014 10:34:53 +0000 (UTC) Received: by mail-vc0-f199.google.com with SMTP id hu8sf24948824vcb.2 for ; Fri, 14 Feb 2014 02:34:52 -0800 (PST) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:delivered-to:from:to:subject:date:message-id :in-reply-to:references:cc:precedence:list-id:list-unsubscribe :list-archive:list-post:list-help:list-subscribe:mime-version:sender :errors-to:x-original-sender:x-original-authentication-results :mailing-list:content-type:content-transfer-encoding; bh=kLwnRvwBck8QSpOD37mNc1aXIV9iD2NUFZOpKOKCJnM=; b=N5h8lLufNmPTPvQRyn89o+SO4DYLIr6KpC4TE0wJdua+VZztqMMyHafqdFQbLInqPz xsltvEEYg0wIFJr2ePuBnPilowlMXx+KbEB46DvMNoIXRr5jh3nwDVp8TSrc6/J2PYtU tEvkMa3bTvNHKYcvdm14ju83f6AfdPKYB9mP4IVCfbxT+hPvFMNILp2+RTeNNObLCHdY i1snudy8jvRXRxahjv35i5+ZA96vTtNIaOBUecxgPyTz2JOFYFueVZKxOieP+O3yXErM LOgQh2xjhJEgilKORyrEIGXRvqQkCK6OxmsyjCDTKNoO85v2R7oF5SzlOF338d9KvHrT L65Q== X-Gm-Message-State: ALoCoQk7zXbvSYpg5H4xJvkO5EZDCxShqHFCKAbrHacpto/RTJ8aw5NZv6StWeoa8yL8PJ93Ai+s X-Received: by 10.236.180.2 with SMTP id i2mr2232693yhm.4.1392374092448; Fri, 14 Feb 2014 02:34:52 -0800 (PST) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.51.130 with SMTP id u2ls33287qga.34.gmail; Fri, 14 Feb 2014 02:34:52 -0800 (PST) X-Received: by 10.52.251.232 with SMTP id zn8mr527078vdc.41.1392374092347; Fri, 14 Feb 2014 02:34:52 -0800 (PST) Received: from mail-ve0-f170.google.com (mail-ve0-f170.google.com [209.85.128.170]) by mx.google.com with ESMTPS id y3si1780447vdo.32.2014.02.14.02.34.52 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 14 Feb 2014 02:34:52 -0800 (PST) Received-SPF: neutral (google.com: 209.85.128.170 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) client-ip=209.85.128.170; Received: by mail-ve0-f170.google.com with SMTP id cz12so9784232veb.29 for ; Fri, 14 Feb 2014 02:34:52 -0800 (PST) X-Received: by 10.52.246.42 with SMTP id xt10mr4059354vdc.9.1392374092129; Fri, 14 Feb 2014 02:34:52 -0800 (PST) X-Forwarded-To: patchwork-forward@linaro.org X-Forwarded-For: patch@linaro.org patchwork-forward@linaro.org Delivered-To: patch@linaro.org Received: by 10.220.174.196 with SMTP id u4csp98113vcz; Fri, 14 Feb 2014 02:34:51 -0800 (PST) X-Received: by 10.180.13.33 with SMTP id e1mr1609330wic.38.1392374090982; Fri, 14 Feb 2014 02:34:50 -0800 (PST) Received: from casper.infradead.org (casper.infradead.org. [2001:770:15f::2]) by mx.google.com with ESMTPS id dc3si778855wib.49.2014.02.14.02.34.50 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 14 Feb 2014 02:34:50 -0800 (PST) Received-SPF: pass (google.com: domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 2001:770:15f::2 as permitted sender) client-ip=2001:770:15f::2; Received: from merlin.infradead.org ([2001:4978:20e::2]) by casper.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1WEG44-0008Hx-18; Fri, 14 Feb 2014 10:32:13 +0000 Received: from localhost ([::1] helo=merlin.infradead.org) by merlin.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1WEG3U-0004m2-1l; Fri, 14 Feb 2014 10:31:36 +0000 Received: from mail-wi0-f180.google.com ([209.85.212.180]) by merlin.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1WEG2V-0004c8-EF for linux-arm-kernel@lists.infradead.org; Fri, 14 Feb 2014 10:30:40 +0000 Received: by mail-wi0-f180.google.com with SMTP id hm4so311029wib.7 for ; Fri, 14 Feb 2014 02:30:08 -0800 (PST) X-Received: by 10.180.89.225 with SMTP id br1mr1590507wib.38.1392373808566; Fri, 14 Feb 2014 02:30:08 -0800 (PST) Received: from localhost.localdomain ([85.235.11.236]) by mx.google.com with ESMTPSA id t6sm3227388wix.4.2014.02.14.02.30.07 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 14 Feb 2014 02:30:07 -0800 (PST) From: Linus Walleij To: linux-arm-kernel@lists.infradead.org, Will Deacon , Jonathan Austin Subject: [PATCH 5/6] ARM: integrator: register sched_clock directly Date: Fri, 14 Feb 2014 11:29:30 +0100 Message-Id: <1392373771-17303-6-git-send-email-linus.walleij@linaro.org> X-Mailer: git-send-email 1.8.5.3 In-Reply-To: <1392373771-17303-1-git-send-email-linus.walleij@linaro.org> References: <1392373771-17303-1-git-send-email-linus.walleij@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140214_053035_781557_3F1B5C2F X-CRM114-Status: GOOD ( 12.00 ) 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.180 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record -1.9 BAYES_00 BODY: Bayes spam probability is 0 to 1% [score: 0.0000] Cc: Linus Walleij , Russell King , Arnd Bergmann 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+patch=linaro.org@lists.infradead.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: linus.walleij@linaro.org X-Original-Authentication-Results: mx.google.com; spf=neutral (google.com: 209.85.128.170 is neither permitted nor denied by best guess record for domain of patch+caf_=patchwork-forward=linaro.org@linaro.org) smtp.mail=patch+caf_=patchwork-forward=linaro.org@linaro.org Mailing-list: list patchwork-forward@linaro.org; contact patchwork-forward+owners@linaro.org X-Google-Group-Id: 836684582541 The detour through plat-versatile/sched-clock.c is hard to migrate to multiplatform set-up and it's very little code being duplicated so let's just inline the sched_clock registration and cut one more dependency to plat-versatile. This also makes this sched_clock implementation compulsory. Cc: Will Deacon Cc: Jonathan Austin Cc: Russell King Signed-off-by: Linus Walleij --- arch/arm/mach-integrator/integrator_cp.c | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/arch/arm/mach-integrator/integrator_cp.c b/arch/arm/mach-integrator/integrator_cp.c index c97ab88897cf..a938242b0c95 100644 --- a/arch/arm/mach-integrator/integrator_cp.c +++ b/arch/arm/mach-integrator/integrator_cp.c @@ -27,6 +27,7 @@ #include #include #include +#include #include #include @@ -36,7 +37,6 @@ #include #include -#include #include "hardware.h" #include "cm.h" @@ -225,11 +225,14 @@ static struct clcd_board clcd_data = { #define REFCOUNTER (__io_address(INTEGRATOR_HDR_BASE) + 0x28) +static u64 notrace intcp_read_sched_clock(void) +{ + return readl(REFCOUNTER); +} + static void __init intcp_init_early(void) { -#ifdef CONFIG_PLAT_VERSATILE_SCHED_CLOCK - versatile_sched_clock_init(REFCOUNTER, 24000000); -#endif + sched_clock_register(intcp_read_sched_clock, 32, 24000000); } static const struct of_device_id fpga_irq_of_match[] __initconst = {