From patchwork Thu Jul 16 11:26: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: 51170 Return-Path: X-Original-To: linaro@patches.linaro.org Delivered-To: linaro@patches.linaro.org Received: from mail-la0-f70.google.com (mail-la0-f70.google.com [209.85.215.70]) by ip-10-151-82-157.ec2.internal (Postfix) with ESMTPS id 8A43322A28 for ; Thu, 16 Jul 2015 11:33:38 +0000 (UTC) Received: by lagx9 with SMTP id x9sf17964236lag.2 for ; Thu, 16 Jul 2015 04:33:37 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20130820; h=x-gm-message-state:mime-version:delivered-to:from:to:cc:subject :date:message-id:in-reply-to:references:in-reply-to:references :sender:precedence:list-id:x-original-sender :x-original-authentication-results:mailing-list:list-post:list-help :list-archive:list-unsubscribe; bh=DEnNnI4KZLgyYZMYAWyvE6J5sLNX04HHyEAlkxlwspI=; b=eWzqDnqIeC67kN3SVnMrMlsWQfspb/i81MufxLY6+cUeMC0WxCcRe+/hG5sZcCTwl1 IhTJi2SQ9fn5jee2GoV8O+OJvN13168Yuq5RFpfnSSYTjXFJ4PCNDamWUNYz94d4lEzL RCRLz7nvfBqCFeklI1hLB9cqqKa8RuviJW3DFU0PjACIzMUO1sKDRC2x8ZNQWzwXXUDu wSVnmB5oKrLS0t0r5SOjYV/CpHD2Vnz0mKGWRlVBPxuoUqRC40ZTCzO6rxcItm6zMUSF hEkKEkKLIaeweNGTPgh9Wg9+j4ZJN7DnlB8sBp26u4PJU28sDjKaXa/gNLabvuPrxqpB YFxg== X-Gm-Message-State: ALoCoQki6Pqf3Wmn74NUXFZc0mi7UyvPeyXz7TV5lsD31DDsvflpzuPsY3wW53XV5IPUlw/qDXNx X-Received: by 10.112.85.69 with SMTP id f5mr4629462lbz.23.1437046417558; Thu, 16 Jul 2015 04:33:37 -0700 (PDT) MIME-Version: 1.0 X-BeenThere: patchwork-forward@linaro.org Received: by 10.152.163.65 with SMTP id yg1ls321179lab.26.gmail; Thu, 16 Jul 2015 04:33:37 -0700 (PDT) X-Received: by 10.113.4.105 with SMTP id cd9mr8974376lbd.106.1437046417117; Thu, 16 Jul 2015 04:33:37 -0700 (PDT) Received: from mail-lb0-f169.google.com (mail-lb0-f169.google.com. [209.85.217.169]) by mx.google.com with ESMTPS id j1si6728499lbc.15.2015.07.16.04.33.37 for (version=TLSv1.2 cipher=ECDHE-RSA-AES128-GCM-SHA256 bits=128/128); Thu, 16 Jul 2015 04:33:37 -0700 (PDT) Received-SPF: pass (google.com: domain of patch+caf_=patchwork-forward=linaro.org@linaro.org designates 209.85.217.169 as permitted sender) client-ip=209.85.217.169; Received: by lbbyj8 with SMTP id yj8so41881350lbb.0 for ; Thu, 16 Jul 2015 04:33:37 -0700 (PDT) X-Received: by 10.152.206.75 with SMTP id lm11mr8686070lac.41.1437046416981; Thu, 16 Jul 2015 04:33:36 -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 hn6csp194447lbb; Thu, 16 Jul 2015 04:33:35 -0700 (PDT) X-Received: by 10.66.123.106 with SMTP id lz10mr3272324pab.89.1437046412856; Thu, 16 Jul 2015 04:33:32 -0700 (PDT) Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id gj2si12485472pbc.240.2015.07.16.04.33.31; Thu, 16 Jul 2015 04:33:32 -0700 (PDT) Received-SPF: pass (google.com: best guess record for domain of linux-kernel-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 S1755606AbbGPLda (ORCPT + 27 others); Thu, 16 Jul 2015 07:33:30 -0400 Received: from mail-pd0-f172.google.com ([209.85.192.172]:35423 "EHLO mail-pd0-f172.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S932246AbbGPL2U (ORCPT ); Thu, 16 Jul 2015 07:28:20 -0400 Received: by pdrg1 with SMTP id g1so42881228pdr.2 for ; Thu, 16 Jul 2015 04:28:20 -0700 (PDT) X-Received: by 10.67.5.2 with SMTP id ci2mr17419906pad.97.1437046100312; Thu, 16 Jul 2015 04:28:20 -0700 (PDT) Received: from localhost ([122.171.186.190]) by smtp.gmail.com with ESMTPSA id i10sm7655135pdr.78.2015.07.16.04.28.18 (version=TLSv1.2 cipher=RC4-SHA bits=128/128); Thu, 16 Jul 2015 04:28:19 -0700 (PDT) From: Viresh Kumar To: Thomas Gleixner , Daniel Lezcano Cc: linaro-kernel@lists.linaro.org, linux-kernel@vger.kernel.org, Viresh Kumar , Jonas Bonn , linux@lists.openrisc.net Subject: [PATCH 12/23] openrisc/time: Migrate to new 'set-state' interface Date: Thu, 16 Jul 2015 16:56:24 +0530 Message-Id: <79cbd5e9e3b1847451c321363cbe36bf218ee72b.1437044517.git.viresh.kumar@linaro.org> X-Mailer: git-send-email 2.4.0 In-Reply-To: References: In-Reply-To: References: Sender: linux-kernel-owner@vger.kernel.org Precedence: list List-ID: X-Mailing-List: linux-kernel@vger.kernel.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.217.169 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 List-Post: , List-Help: , List-Archive: List-Unsubscribe: , Migrate openrisc 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. So, this patch doesn't provide any set-state callbacks. Cc: Jonas Bonn Cc: linux@lists.openrisc.net Signed-off-by: Viresh Kumar --- arch/openrisc/kernel/time.c | 24 ------------------------ 1 file changed, 24 deletions(-) diff --git a/arch/openrisc/kernel/time.c b/arch/openrisc/kernel/time.c index 7c52e9494a8d..50e970183dcd 100644 --- a/arch/openrisc/kernel/time.c +++ b/arch/openrisc/kernel/time.c @@ -48,29 +48,6 @@ static int openrisc_timer_set_next_event(unsigned long delta, return 0; } -static void openrisc_timer_set_mode(enum clock_event_mode mode, - struct clock_event_device *evt) -{ - switch (mode) { - case CLOCK_EVT_MODE_PERIODIC: - pr_debug(KERN_INFO "%s: periodic\n", __func__); - BUG(); - break; - case CLOCK_EVT_MODE_ONESHOT: - pr_debug(KERN_INFO "%s: oneshot\n", __func__); - break; - case CLOCK_EVT_MODE_UNUSED: - pr_debug(KERN_INFO "%s: unused\n", __func__); - break; - case CLOCK_EVT_MODE_SHUTDOWN: - pr_debug(KERN_INFO "%s: shutdown\n", __func__); - break; - case CLOCK_EVT_MODE_RESUME: - pr_debug(KERN_INFO "%s: resume\n", __func__); - break; - } -} - /* This is the clock event device based on the OR1K tick timer. * As the timer is being used as a continuous clock-source (required for HR * timers) we cannot enable the PERIODIC feature. The tick timer can run using @@ -82,7 +59,6 @@ static struct clock_event_device clockevent_openrisc_timer = { .features = CLOCK_EVT_FEAT_ONESHOT, .rating = 300, .set_next_event = openrisc_timer_set_next_event, - .set_mode = openrisc_timer_set_mode, }; static inline void timer_ack(void)