From patchwork Fri Oct 16 16:22:02 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Felipe Balbi X-Patchwork-Id: 55136 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f197.google.com (mail-lb0-f197.google.com [209.85.217.197]) by patches.linaro.org (Postfix) with ESMTPS id 3D2DD22FFA for ; Fri, 16 Oct 2015 16:23:18 +0000 (UTC) Received: by lbcao8 with SMTP id ao8sf26160933lbc.1 for ; Fri, 16 Oct 2015 09:23:17 -0700 (PDT) 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:cc:subject:date:message-id :in-reply-to:references:mime-version:content-type:sender:precedence :list-id:x-original-sender:x-original-authentication-results :mailing-list:list-post:list-help:list-archive:list-unsubscribe; bh=szzsUtwvMpwQfboSFJF9dLOdk9IhJa1B3vG88hQTnp8=; b=WKqfISf9ITsXFUYHAcFi8AKuWtBb/mrQb5W01pRR4+S1DDksEhedHV6LzFyvb/VJPK NBcOxqRtP9eBiqLjMx5zWNE6Pa96Y0V3k/FT1///aw0aeIUcBOQjQ3duqHboYH3mnOWY FJMziXs6l4qWsuiW8RkJdQfmlJWjnkp53WxaoRIkVZf9t+f8hP2DBaGBRfBNe1ueuIHT VgO09TgKPtK/t1q4B3Z7erBXaFO/JqyIrPv4bnWjsIXI3AmefZSU/ydn93pld0KojgAa bt/cL4G+acp5ycegMylc402TSPffFADj/8OSvGGQZtLb0qRJd/bj1WV2Vd90LMjZaLdL KgGQ== X-Gm-Message-State: ALoCoQmP29rK88Ib4xnq4MCHoWP++SuYAv5vwuzJSOQaAiI3jPDgymQrkjAAnIuRZoI+1ZvFJb+w X-Received: by 10.112.159.4 with SMTP id wy4mr3849925lbb.15.1445012597131; Fri, 16 Oct 2015 09:23:17 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.25.207.70 with SMTP id f67ls316747lfg.78.gmail; Fri, 16 Oct 2015 09:23:16 -0700 (PDT) X-Received: by 10.25.156.130 with SMTP id f124mr5777384lfe.46.1445012596853; Fri, 16 Oct 2015 09:23:16 -0700 (PDT) Received: from mail-lf0-f44.google.com (mail-lf0-f44.google.com. [209.85.215.44]) by mx.google.com with ESMTPS id y191si13362691lfd.174.2015.10.16.09.23.16 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 16 Oct 2015 09:23:16 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.44 as permitted sender) client-ip=209.85.215.44; Received: by lfeh64 with SMTP id h64so78770602lfe.3 for ; Fri, 16 Oct 2015 09:23:16 -0700 (PDT) X-Received: by 10.25.38.9 with SMTP id m9mr5672656lfm.112.1445012596727; Fri, 16 Oct 2015 09:23:16 -0700 (PDT) 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.112.59.35 with SMTP id w3csp17463lbq; Fri, 16 Oct 2015 09:23:15 -0700 (PDT) X-Received: by 10.107.7.86 with SMTP id 83mr19762854ioh.48.1445012585621; Fri, 16 Oct 2015 09:23:05 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id q5si7498418ioi.175.2015.10.16.09.23.05; Fri, 16 Oct 2015 09:23:05 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-omap-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) client-ip=209.132.180.67; Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S932611AbbJPQXC (ORCPT + 5 others); Fri, 16 Oct 2015 12:23:02 -0400 Received: from comal.ext.ti.com ([198.47.26.152]:53762 "EHLO comal.ext.ti.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932469AbbJPQXA (ORCPT ); Fri, 16 Oct 2015 12:23:00 -0400 Received: from dlelxv90.itg.ti.com ([172.17.2.17]) by comal.ext.ti.com (8.13.7/8.13.7) with ESMTP id t9GGMFJD020335; Fri, 16 Oct 2015 11:22:15 -0500 Received: from DLEE70.ent.ti.com (dlemailx.itg.ti.com [157.170.170.113]) by dlelxv90.itg.ti.com (8.14.3/8.13.8) with ESMTP id t9GGMFGq031659; Fri, 16 Oct 2015 11:22:15 -0500 Received: from dflp33.itg.ti.com (10.64.6.16) by DLEE70.ent.ti.com (157.170.170.113) with Microsoft SMTP Server id 14.3.224.2; Fri, 16 Oct 2015 11:22:15 -0500 Received: from localhost (ileax41-snat.itg.ti.com [10.172.224.153]) by dflp33.itg.ti.com (8.14.3/8.13.8) with ESMTP id t9GGME5R022878; Fri, 16 Oct 2015 11:22:15 -0500 From: Felipe Balbi To: Tony Lindgren CC: Linux OMAP Mailing List , Linux ARM Kernel Mailing List , Felipe Balbi Subject: [PATCH 03/11] arm: omap2: timer: add a gptimer argument to sync32k_timer_init() Date: Fri, 16 Oct 2015 11:22:02 -0500 Message-ID: <1445012530-14126-4-git-send-email-balbi@ti.com> X-Mailer: git-send-email 2.5.3 In-Reply-To: <1445012530-14126-1-git-send-email-balbi@ti.com> References: <1445012530-14126-1-git-send-email-balbi@ti.com> MIME-Version: 1.0 Sender: linux-omap-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-omap@vger.kernel.org X-Removed-Original-Auth: Dkim didn't pass. X-Original-Sender: balbi@ti.com X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.44 as permitted sender) smtp.mailfrom=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 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , as it turns out, __omap_gptimer_init() and __omap_sync32k_timer_init() are essentially the same thing, but __omap_gptimer_init() wants to always use gptimer. Instead of forcing all those devices to pass a use_gptimer cmdline argument, we add a new function argument to __omap_sync32k_timer_init() in preparation to deleting __omap_gptimer_init(). On a follow-up patch, we will remove uses of __omap_gptimer_init() and replace them with __omap_sync32k_timer_init() and pass the last argument as true. Signed-off-by: Felipe Balbi --- arch/arm/mach-omap2/timer.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/arch/arm/mach-omap2/timer.c b/arch/arm/mach-omap2/timer.c index 23e58ea6a171..f53ed049d710 100644 --- a/arch/arm/mach-omap2/timer.c +++ b/arch/arm/mach-omap2/timer.c @@ -604,14 +604,14 @@ static void __init __omap_gptimer_init(int clkev_nr, const char *clkev_src, static void __init __omap_sync32k_timer_init(int clkev_nr, const char *clkev_src, const char *clkev_prop, int clksrc_nr, const char *clksrc_src, - const char *clksrc_prop) + const char *clksrc_prop, bool gptimer) { omap_clk_init(); omap_dmtimer_init(); omap2_gp_clockevent_init(clkev_nr, clkev_src, clkev_prop); /* Enable the use of clocksource="gp_timer" kernel parameter */ - if (use_gptimer_clksrc) + if (use_gptimer_clksrc || gptimer) omap2_gptimer_clocksource_init(clksrc_nr, clksrc_src, clksrc_prop); else @@ -622,7 +622,7 @@ static void __init __omap_sync32k_timer_init(int clkev_nr, const char *clkev_src void __init omap2_sync32k_timer_init(void) { __omap_sync32k_timer_init(1, "timer_32k_ck", "ti,timer-alwon", - 2, "timer_sys_ck", NULL); + 2, "timer_sys_ck", NULL, false); } #endif /* CONFIG_ARCH_OMAP2 */ @@ -630,13 +630,13 @@ void __init omap2_sync32k_timer_init(void) void __init omap3_sync32k_timer_init(void) { __omap_sync32k_timer_init(1, "timer_32k_ck", "ti,timer-alwon", - 2, "timer_sys_ck", NULL); + 2, "timer_sys_ck", NULL, false); } void __init omap3_secure_sync32k_timer_init(void) { __omap_sync32k_timer_init(12, "secure_32k_fck", "ti,timer-secure", - 2, "timer_sys_ck", NULL); + 2, "timer_sys_ck", NULL, false); } #endif /* CONFIG_ARCH_OMAP3 */ @@ -653,7 +653,7 @@ void __init omap3_gptimer_timer_init(void) static void __init omap4_sync32k_timer_init(void) { __omap_sync32k_timer_init(1, "timer_32k_ck", "ti,timer-alwon", - 2, "sys_clkin_ck", NULL); + 2, "sys_clkin_ck", NULL, false); } void __init omap4_local_timer_init(void)