From patchwork Thu Jun 18 10:54:24 2015 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Viresh Kumar X-Patchwork-Id: 50016 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-lb0-f199.google.com (mail-lb0-f199.google.com [209.85.217.199]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 52B68228CC for ; Thu, 18 Jun 2015 10:58:25 +0000 (UTC) Received: by lbbti3 with SMTP id ti3sf19623132lbb.1 for ; Thu, 18 Jun 2015 03:58:24 -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:in-reply-to:references:cc:precedence:list-id :list-unsubscribe:list-archive:list-post:list-help:list-subscribe :mime-version:content-type:content-transfer-encoding:sender :errors-to:x-original-sender:x-original-authentication-results :mailing-list; bh=e6uwNJGXcKj/EkTrlEDqa0GbPDd4X1VZmSazU6kKgaQ=; b=HMwQu0byS5PGzc36o/KcbzZ5+1EzFCOeL2tTLJBAYZq6dqBOuUrftkaQhuwQfxpx7b fVXYAh3YmH2/O2CdCUcSdpPru9hjiPW1SfVyFFWCSV20NIHaVwEONMAEHLEpHVrXIdvt KhqRo61Fs54Hwea49geYnS9/FchFeCYLrIegIxRKMXwQ1XybkuA+zUIlpKp4/XXPXHqY R2e9A2ny6FHtk4zPz+j55bbj+6CxxZNWtG44HjIYz8lkA5Ca87Vuk9qLHYw3EFT1jYqn LK212r9Fzmt72LRxym1LDKcsPGnet00jZuIbcRJrCXNju5W7CywgHuYHfpnyRn2yi86x wdJQ== X-Gm-Message-State: ALoCoQnUb3OM2vYj9PfJMmTMwh/MaGqR1INHiKahmgaZJKDOUWka/QCMoc/f61Me0dMyfnaY3kD8 X-Received: by 10.180.182.49 with SMTP id eb17mr24240954wic.2.1434625104333; Thu, 18 Jun 2015 03:58:24 -0700 (PDT) X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.163.65 with SMTP id yg1ls409822lab.26.gmail; Thu, 18 Jun 2015 03:58:24 -0700 (PDT) X-Received: by 10.152.8.168 with SMTP id s8mr12455026laa.116.1434625104179; Thu, 18 Jun 2015 03:58:24 -0700 (PDT) Received: from mail-la0-f52.google.com (mail-la0-f52.google.com. [209.85.215.52]) by mx.google.com with ESMTPS id dz10si6173547lac.88.2015.06.18.03.58.24 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 18 Jun 2015 03:58:24 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.215.52 as permitted sender) client-ip=209.85.215.52; Received: by labbc20 with SMTP id bc20so51823142lab.1 for ; Thu, 18 Jun 2015 03:58:24 -0700 (PDT) X-Received: by 10.112.222.133 with SMTP id qm5mr12515557lbc.86.1434625104040; Thu, 18 Jun 2015 03:58:24 -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.108.230 with SMTP id hn6csp1095798lbb; Thu, 18 Jun 2015 03:58:23 -0700 (PDT) X-Received: by 10.68.131.65 with SMTP id ok1mr20644780pbb.16.1434625098473; Thu, 18 Jun 2015 03:58:18 -0700 (PDT) Received: from bombadil.infradead.org (bombadil.infradead.org. [2001:1868:205::9]) by mx.google.com with ESMTPS id k5si10862812pdj.142.2015.06.18.03.58.17 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 18 Jun 2015 03:58:18 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-arm-kernel-bounces+patch=linaro.org@lists.infradead.org designates 2001:1868:205::9 as permitted sender) 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 1Z5XUp-0001CJ-Sz; Thu, 18 Jun 2015 10:56:35 +0000 Received: from mail-pa0-f44.google.com ([209.85.220.44]) by bombadil.infradead.org with esmtps (Exim 4.80.1 #2 (Red Hat Linux)) id 1Z5XUH-0000wY-3T for linux-arm-kernel@lists.infradead.org; Thu, 18 Jun 2015 10:56:02 +0000 Received: by pacyx8 with SMTP id yx8so59045121pac.2 for ; Thu, 18 Jun 2015 03:55:40 -0700 (PDT) X-Received: by 10.66.150.196 with SMTP id uk4mr20391337pab.54.1434624939971; Thu, 18 Jun 2015 03:55:39 -0700 (PDT) Received: from localhost ([122.167.70.98]) by mx.google.com with ESMTPSA id nz2sm7641008pbb.40.2015.06.18.03.55.38 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 18 Jun 2015 03:55:39 -0700 (PDT) From: Viresh Kumar To: Thomas Gleixner , Daniel Lezcano Subject: [PATCH 10/41] clocksource: metag_generic: Migrate to new 'set-state' interface Date: Thu, 18 Jun 2015 16:24:24 +0530 Message-Id: <9da54df749f74e796694880feeb60e450811727a.1434622147.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.4.0 In-Reply-To: References: In-Reply-To: References: X-CRM114-Version: 20100106-BlameMichelson ( TRE 0.8.0 (BSD) ) MR-646709E3 X-CRM114-CacheID: sfid-20150618_035601_213046_B3D86C01 X-CRM114-Status: UNSURE ( 9.97 ) X-CRM114-Notice: Please train this message. X-Spam-Score: -0.7 (/) X-Spam-Report: SpamAssassin version 3.4.0 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 [209.85.220.44 listed in list.dnswl.org] -0.0 RCVD_IN_MSPIKE_H2 RBL: Average reputation (+2) [209.85.220.44 listed in wl.mailspike.net] -0.0 SPF_PASS SPF: sender matches SPF record Cc: Viresh Kumar , James Hogan , linaro-kernel@lists.linaro.org, linux-kernel@vger.kernel.org, linux-arm-kernel@lists.infradead.org X-BeenThere: linux-arm-kernel@lists.infradead.org X-Mailman-Version: 2.1.18-1 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: viresh.kumar@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.215.52 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 Migrate metag_generic driver to the new 'set-state' interface provided by clockevents core, the earlier 'set-mode' interface is marked obsolete now. This also enables us to implement callbacks for new states of clockevent devices, for example: ONESHOT_STOPPED. We weren't doing anything in the ->set_mode() callback. Even the WARN() for periodic or unused modes isn't required anymore as the core is taking care of that now. So, this patch doesn't provide any set-state callbacks. Cc: James Hogan Signed-off-by: Viresh Kumar --- drivers/clocksource/metag_generic.c | 20 -------------------- 1 file changed, 20 deletions(-) diff --git a/drivers/clocksource/metag_generic.c b/drivers/clocksource/metag_generic.c index b7384b853e5a..bcd5c0d602a0 100644 --- a/drivers/clocksource/metag_generic.c +++ b/drivers/clocksource/metag_generic.c @@ -56,25 +56,6 @@ static int metag_timer_set_next_event(unsigned long delta, return 0; } -static void metag_timer_set_mode(enum clock_event_mode mode, - struct clock_event_device *evt) -{ - switch (mode) { - case CLOCK_EVT_MODE_ONESHOT: - case CLOCK_EVT_MODE_RESUME: - break; - - case CLOCK_EVT_MODE_SHUTDOWN: - /* We should disable the IRQ here */ - break; - - case CLOCK_EVT_MODE_PERIODIC: - case CLOCK_EVT_MODE_UNUSED: - WARN_ON(1); - break; - }; -} - static cycle_t metag_clocksource_read(struct clocksource *cs) { return __core_reg_get(TXTIMER); @@ -129,7 +110,6 @@ static void arch_timer_setup(unsigned int cpu) clk->rating = 200, clk->shift = 12, clk->irq = tbisig_map(TBID_SIGNUM_TRT), - clk->set_mode = metag_timer_set_mode, clk->set_next_event = metag_timer_set_next_event, clk->mult = div_sc(hwtimer_freq, NSEC_PER_SEC, clk->shift);