From patchwork Thu Mar 1 16:33:34 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Thomas Gleixner X-Patchwork-Id: 10252007 Return-Path: Received: from mail.wl.linuxfoundation.org (pdx-wl-mail.web.codeaurora.org [172.30.200.125]) by pdx-korg-patchwork.web.codeaurora.org (Postfix) with ESMTP id CFC8E602B5 for ; Thu, 1 Mar 2018 16:52:54 +0000 (UTC) Received: from mail.wl.linuxfoundation.org (localhost [127.0.0.1]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id BF85228382 for ; Thu, 1 Mar 2018 16:52:54 +0000 (UTC) Received: by mail.wl.linuxfoundation.org (Postfix, from userid 486) id B455D283CF; Thu, 1 Mar 2018 16:52:54 +0000 (UTC) X-Spam-Checker-Version: SpamAssassin 3.3.1 (2010-03-16) on pdx-wl-mail.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-6.9 required=2.0 tests=BAYES_00,RCVD_IN_DNSWL_HI autolearn=ham version=3.3.1 Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.wl.linuxfoundation.org (Postfix) with ESMTP id 4B90728382 for ; Thu, 1 Mar 2018 16:52:54 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1033294AbeCAQw1 (ORCPT ); Thu, 1 Mar 2018 11:52:27 -0500 Received: from Galois.linutronix.de ([146.0.238.70]:51793 "EHLO Galois.linutronix.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1033014AbeCAQwY (ORCPT ); Thu, 1 Mar 2018 11:52:24 -0500 Received: from localhost ([127.0.0.1] helo=nanos.tec.linutronix.de) by Galois.linutronix.de with esmtp (Exim 4.80) (envelope-from ) id 1erRNV-0000Le-FR; Thu, 01 Mar 2018 17:48:21 +0100 Message-Id: <20180301165150.155899327@linutronix.de> User-Agent: quilt/0.63-1 Date: Thu, 01 Mar 2018 17:33:34 +0100 From: Thomas Gleixner To: LKML Cc: Linus Torvalds , Ingo Molnar , Peter Zijlstra , Steven Rostedt , John Stultz , Petr Mladek , Mark Salyzyn , Prarit Bhargava , Sergey Senozhatsky , Dmitry Torokhov , Kevin Easton , Michael Kerrisk , Jonathan Corbet , linux-input@vger.kernel.org Subject: [RFC/RFT patch 3/7] Input: evdev - Conflate clock MONOTONIC and BOOTTIME References: <20180301163331.987775783@linutronix.de> MIME-Version: 1.0 Content-Disposition: inline; filename=Input--evdev---Conflate-clock-MONOTONIC-and-BOOTTIME.patch Sender: linux-input-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-input@vger.kernel.org X-Virus-Scanned: ClamAV using ClamSMTP Now that clock MONOTONIC and BOOTTIME are indentical remove all the special casing. The user space visible interfaces still support both clocks. Signed-off-by: Thomas Gleixner Cc: Dmitry Torokhov Cc: linux-input@vger.kernel.org --- drivers/input/evdev.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) -- To unsubscribe from this list: send the line "unsubscribe linux-input" in the body of a message to majordomo@vger.kernel.org More majordomo info at http://vger.kernel.org/majordomo-info.html --- a/drivers/input/evdev.c +++ b/drivers/input/evdev.c @@ -31,7 +31,6 @@ enum evdev_clock_type { EV_CLK_REAL = 0, EV_CLK_MONO, - EV_CLK_BOOT, EV_CLK_MAX }; @@ -198,12 +197,10 @@ static int evdev_set_clk_type(struct evd case CLOCK_REALTIME: clk_type = EV_CLK_REAL; break; + case CLOCK_BOOTTIME: case CLOCK_MONOTONIC: clk_type = EV_CLK_MONO; break; - case CLOCK_BOOTTIME: - clk_type = EV_CLK_BOOT; - break; default: return -EINVAL; } @@ -314,8 +311,6 @@ static void evdev_events(struct input_ha ev_time[EV_CLK_MONO] = ktime_get(); ev_time[EV_CLK_REAL] = ktime_mono_to_real(ev_time[EV_CLK_MONO]); - ev_time[EV_CLK_BOOT] = ktime_mono_to_any(ev_time[EV_CLK_MONO], - TK_OFFS_BOOT); rcu_read_lock();