From patchwork Fri May 23 10:30:54 2014 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Daniel Lezcano X-Patchwork-Id: 30715 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-ob0-f200.google.com (mail-ob0-f200.google.com [209.85.214.200]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 4DC3D20369 for ; Fri, 23 May 2014 10:36:14 +0000 (UTC) Received: by mail-ob0-f200.google.com with SMTP id wo20sf21307425obc.3 for ; Fri, 23 May 2014 03:36:13 -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: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=zyIIh9eBwoHzjMXVAOH9jpYUNVuayxdWRxHgvWqpOgc=; b=ULT9V8H/HXa0RZZ2f/KGWprDZ+3WSJZvOHsjj/TeWfE2gkTY3qaN/4PYLAmE9tNq3Y kYv9OCfqpf9UqbdFbF/gcTT4apD7nj20mQJCk1DRVmLkgULIFuvBHlFQrHAqyUsbFS0J lWR+eGILEhh1qBocLfcZPYlbo++xTB687om8jHQeFHmgIvKVg9yYNemWokpcHz7SRvSZ bUJphNa4mlthsx7xlINUG2dBjoEZOw8MjYFwKSAqKgy0V9ueV+Lx+KJs56PIBrkjIr49 jru8nGdXrdNpAwISC985Nd4aDe3jvYX1nPI4LnCPxmYlq2131aGttlbgscELgfAz+WU6 nqvw== X-Gm-Message-State: ALoCoQnB/TBeswkRDX+Ctox1hcBx2LjX6mxG3FTbm4ED0Dzx05zOOsBoVfEYjPCx/hgYTbR9C1MK X-Received: by 10.182.33.66 with SMTP id p2mr1846751obi.8.1400841373768; Fri, 23 May 2014 03:36:13 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.140.95.232 with SMTP id i95ls1714933qge.7.gmail; Fri, 23 May 2014 03:36:13 -0700 (PDT) X-Received: by 10.220.105.4 with SMTP id r4mr3370887vco.27.1400841373668; Fri, 23 May 2014 03:36:13 -0700 (PDT) Received: from mail-vc0-f173.google.com (mail-vc0-f173.google.com [209.85.220.173]) by mx.google.com with ESMTPS id ee6si1375749vec.94.2014.05.23.03.36.13 for (version=TLSv1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 23 May 2014 03:36:13 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.173 as permitted sender) client-ip=209.85.220.173; Received: by mail-vc0-f173.google.com with SMTP id il7so5921526vcb.4 for ; Fri, 23 May 2014 03:36:13 -0700 (PDT) X-Received: by 10.58.185.165 with SMTP id fd5mr361020vec.41.1400841373584; Fri, 23 May 2014 03:36:13 -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.220.221.72 with SMTP id ib8csp20050vcb; Fri, 23 May 2014 03:36:13 -0700 (PDT) X-Received: by 10.140.41.75 with SMTP id y69mr4920506qgy.34.1400841373172; Fri, 23 May 2014 03:36:13 -0700 (PDT) Received: from bombadil.infradead.org (bombadil.infradead.org. [2001:1868:205::9]) by mx.google.com with ESMTPS id ic4si2954329qcb.13.2014.05.23.03.36.13 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Fri, 23 May 2014 03:36:13 -0700 (PDT) Received-SPF: none (google.com: linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org does not designate permitted sender hosts) client-ip=2001:1868:205::9; Received: from localhost ([127.0.0.1] helo=bombadil.infradead.org) by bombadil.infradead.org with esmtp (Exim 4.80.1 #2 (Red Hat Linux)) id 1Wnmnu-0002dB-3c; Fri, 23 May 2014 10:34:22 +0000 Received: from mail-wg0-f52.google.com ([74.125.82.52]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1Wnmlm-0001EJ-Ee for linux-arm-kernel@lists.infradead.org; Fri, 23 May 2014 10:32:11 +0000 Received: by mail-wg0-f52.google.com with SMTP id l18so4576290wgh.11 for ; Fri, 23 May 2014 03:31:53 -0700 (PDT) X-Received: by 10.180.182.19 with SMTP id ea19mr2528440wic.14.1400841113526; Fri, 23 May 2014 03:31:53 -0700 (PDT) Received: from localhost.localdomain (AToulouse-654-1-404-187.w82-125.abo.wanadoo.fr. [82.125.3.187]) by mx.google.com with ESMTPSA id s9sm2200908wix.13.2014.05.23.03.31.52 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Fri, 23 May 2014 03:31:52 -0700 (PDT) From: Daniel Lezcano To: tglx@linutronix.de, mingo@kernel.org Subject: [PATCH 14/71] clocksource: sh_cmt: Hardcode CMT clock event rating to 125 Date: Fri, 23 May 2014 12:30:54 +0200 Message-Id: <1400841111-6683-14-git-send-email-daniel.lezcano@linaro.org> X-Mailer: git-send-email 1.7.9.5 In-Reply-To: <1400841111-6683-1-git-send-email-daniel.lezcano@linaro.org> References: <537F214C.8000700@linaro.org> <1400841111-6683-1-git-send-email-daniel.lezcano@linaro.org> X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20140523_033210_645045_29A46E60 X-CRM114-Status: GOOD ( 13.34 ) X-Spam-Score: -0.7 (/) X-Spam-Report: SpamAssassin version 3.3.2 on bombadil.infradead.org summary: Content analysis details: (-0.7 points) pts rule name description ---- ---------------------- -------------------------------------------------- -0.7 RCVD_IN_DNSWL_LOW RBL: Sender listed at http://www.dnswl.org/, low trust [74.125.82.52 listed in list.dnswl.org] -0.0 SPF_PASS SPF: sender matches SPF record Cc: linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org 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: daniel.lezcano@linaro.org X-Original-Authentication-Results: mx.google.com; spf=pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.220.173 as permitted sender) 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 From: Laurent Pinchart All boards use or should use a clock event rating of 125 for the CMT, hardcode it in the driver. Signed-off-by: Laurent Pinchart --- drivers/clocksource/sh_cmt.c | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/drivers/clocksource/sh_cmt.c b/drivers/clocksource/sh_cmt.c index 926abe2..75b1f83 100644 --- a/drivers/clocksource/sh_cmt.c +++ b/drivers/clocksource/sh_cmt.c @@ -768,14 +768,14 @@ static void sh_cmt_clock_event_resume(struct clock_event_device *ced) } static void sh_cmt_register_clockevent(struct sh_cmt_channel *ch, - const char *name, unsigned long rating) + const char *name) { struct clock_event_device *ced = &ch->ced; ced->name = name; ced->features = CLOCK_EVT_FEAT_PERIODIC; ced->features |= CLOCK_EVT_FEAT_ONESHOT; - ced->rating = rating; + ced->rating = 125; ced->cpumask = cpu_possible_mask; ced->set_next_event = sh_cmt_clock_event_next; ced->set_mode = sh_cmt_clock_event_mode; @@ -788,11 +788,10 @@ static void sh_cmt_register_clockevent(struct sh_cmt_channel *ch, } static int sh_cmt_register(struct sh_cmt_channel *ch, const char *name, - unsigned long clockevent_rating, - unsigned long clocksource_rating) + bool clockevent, unsigned long clocksource_rating) { - if (clockevent_rating) - sh_cmt_register_clockevent(ch, name, clockevent_rating); + if (clockevent) + sh_cmt_register_clockevent(ch, name); if (clocksource_rating) sh_cmt_register_clocksource(ch, name, clocksource_rating); @@ -827,7 +826,7 @@ static int sh_cmt_setup_channel(struct sh_cmt_channel *ch, unsigned int index, raw_spin_lock_init(&ch->lock); ret = sh_cmt_register(ch, dev_name(&cmt->pdev->dev), - cfg->clockevent_rating, + cfg->clockevent_rating != 0, cfg->clocksource_rating); if (ret) { dev_err(&cmt->pdev->dev, "ch%u: registration failed\n",