From patchwork Mon Jun 18 15:35:11 2018 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: Arnd Bergmann X-Patchwork-Id: 139028 Delivered-To: patch@linaro.org Received: by 2002:a2e:970d:0:0:0:0:0 with SMTP id r13-v6csp4095729lji; Mon, 18 Jun 2018 08:37:14 -0700 (PDT) X-Google-Smtp-Source: ADUXVKKDkP10ABTuaMrjQcVzhuGWamYniSTwKbrGsYfe5Ezw9htBzn2OrbGnwRbVvQ0ncA2YjPsB X-Received: by 2002:a65:4b04:: with SMTP id r4-v6mr11280631pgq.26.1529336234319; Mon, 18 Jun 2018 08:37:14 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1529336234; cv=none; d=google.com; s=arc-20160816; b=yKj24Wgme4SqnGXsePmcHtvKeGYpA92/KEb7TnNTNc8esj4OwSGG+vh4G/cO/DL58O En9LYCS6pTX/Q/6J8Sw/mX/jCqiRaEODKFC4y8EZZYe78T9ZoZnJSElfyStX1sg1uq2s sEc2zZNZLJa3yE1Oma08ITUK1t9Xjx5UVzmIlqeTcs6dJh89Mmd012fD7JDwl/v3S0VK iC4iDamiTTuh72x1UDg+HqsfXmNe5vr6eoMIo0+6KxybuV/y5CfPhsGl9PRwCMAJzFBj odYpac6Rj/0P4p82WfgG+4Vxiywy95v52fiSiDx40CjODIl2h6aIa3wbLVsphM0WO0bU Z8ZA== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:references:in-reply-to:message-id:date :subject:cc:to:from:arc-authentication-results; bh=YwUtwVR76CmKO7lPSswKcjroW1LaiWl9lQ5muifyaMA=; b=uz9OUB7tsgU9h8lTuEzjXT5+gvFkdhb1o3IGGuDSlIk91tAnUUX0iueltoigHWFYC8 AvwuQWpvMCGK2fzq+NeLkDrNtaJd2t2hPabqA85p1Zcg4WMfs700iUkdhM10ERmAdtOF w6gKz+lGQPvvdJSgcgO9erS9O6rpimeO7qHpXduWMkh4RL5t9/VAaihpPnYn9KDMayaO C+53qmeSyk9ziJjGTcrIZBlayek8wTQn+eE7paB4H3F4+NomqfGB/t9hKfsLLPbpcY7u /pO8OAb+2QiZVCxZ99Cto3Fz8vVbB6MxPWtnkKXZW0G0lS1qs/rpsUGsXsiYYAVNPZPy ReIA== ARC-Authentication-Results: i=1; mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id s1-v6si12571214pga.296.2018.06.18.08.37.13; Mon, 18 Jun 2018 08:37:14 -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; Authentication-Results: mx.google.com; spf=pass (google.com: best guess record for domain of linux-kernel-owner@vger.kernel.org designates 209.132.180.67 as permitted sender) smtp.mailfrom=linux-kernel-owner@vger.kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1755106AbeFRPhL (ORCPT + 30 others); Mon, 18 Jun 2018 11:37:11 -0400 Received: from mout.kundenserver.de ([212.227.17.13]:35565 "EHLO mout.kundenserver.de" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1754852AbeFRPhJ (ORCPT ); Mon, 18 Jun 2018 11:37:09 -0400 Received: from wuerfel.lan ([95.208.111.237]) by mrelayeu.kundenserver.de (mreue102 [212.227.15.145]) with ESMTPA (Nemesis) id 0MOjCA-1fXg1y3Ef8-0067iH; Mon, 18 Jun 2018 17:37:00 +0200 From: Arnd Bergmann To: Oded Gabbay , Alex Deucher , =?utf-8?q?Christian_K=C3=B6nig?= , "David (ChunMing) Zhou" Cc: y2038@lists.linaro.org, Arnd Bergmann , David Airlie , Felix Kuehling , Yong Zhao , Kent Russell , Shaoyun Liu , Philip Yang , Harish Kasiviswanathan , Andres Rodriguez , dri-devel@lists.freedesktop.org, amd-gfx@lists.freedesktop.org, linux-kernel@vger.kernel.org Subject: [PATCH 2/2] amdgpu: kfd: use modern ktime accessors Date: Mon, 18 Jun 2018 17:35:11 +0200 Message-Id: <20180618153649.2015346-2-arnd@arndb.de> X-Mailer: git-send-email 2.9.0 In-Reply-To: <20180618153649.2015346-1-arnd@arndb.de> References: <20180618153649.2015346-1-arnd@arndb.de> X-Provags-ID: V03:K1:db5AyKfnoApCkOjdUqSR4FofUO9/GgmgPAOirl2VzoUhMMbSo6t EAf2GFiSHkI+adSyeNgbB5KnCVG1fddyhyd8P69SkKT/KbEhNY5W5aqy5fgfqXlICKOezUb R3hT2GJPCD8aWjOrbmAdScldBnOmI11fg5BvN03QqrcnW8EpwIJO2YubU9dZxLAAQlNBuEQ noqlkbBJWrDF+52sA4H6A== X-UI-Out-Filterresults: notjunk:1; V01:K0:K5pE9ej9gxI=:m7gHveVMybd+mu/0BBmfVD C45wzSnVytJcPNU++6LJuS/pGphTd2xaL6GNhuWG1IP3RsXcfE9dJlpmV7Jt3/lFYbuNuiN5g bUDITVDz7D6XZuGWc2ysXStwWw0W9BkewJjn0iUKI0N+ZtG1xJ9hVkPpsAvByfJuGtc6TUEDk nRAjtXBe8EOScgQZ7Vt/YdKuyKUMpS1q1XLv27x+9G8PgHuOZkkn/L0E+JtPv1i20p5G+iVDv /umpn62qkppI9t8Tr/LPWIQaMAAkwllJYZ+R6oDLgGfSbMU0zxhCKXBLdnoWsGYnr0pgTnLP8 zX+h5dg1keRSDd6nRRaY/lqx6qYDExUuuu82djE9m/RosaPPTilOldZ8e6KRjcVSbi49/4bof xYkx6ndApU+pzHBexqZbkEiQhlKmb7snggkenYK/TtOAtK9fa4zBTO0F6h2IsDzFUsBgLBBWm DB/X+zQAm1kue1iq/eEOxlJGwnUdoVPebA1N03xaFKC4LZk3GApRs9oUq/rlO1Qx0AhG38EQs l8BnK2KdI0tksWrGvjFvEs281ksq1h7YhtKX8QoINrWOY8KBu3W627P/HNaRKVGH8V1Hfv5/+ iRg/hd0e+DJnULPDwZU6Gd+L1LwV1CKiY+qLFt/UxSeA7oV9gQfmaVxhGUJNU5yUuJ9PsODGw 7VeD10ybdhaoNiT+g6OJl4VvaPZhsyGQJZjp5o02pq9v2XNAXHJ2g23/nFK/DKhUOA48= Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org getrawmonotonic64() and get_monotonic_boottime64() are deprecated because of the nonstandard naming. The replacement functions ktime_get_raw_ns() and ktime_get_boot_ns() also simplify the callers. Signed-off-by: Arnd Bergmann --- drivers/gpu/drm/amd/amdkfd/kfd_chardev.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) -- 2.9.0 diff --git a/drivers/gpu/drm/amd/amdkfd/kfd_chardev.c b/drivers/gpu/drm/amd/amdkfd/kfd_chardev.c index f64c5551cdba..7e717716b90e 100644 --- a/drivers/gpu/drm/amd/amdkfd/kfd_chardev.c +++ b/drivers/gpu/drm/amd/amdkfd/kfd_chardev.c @@ -754,7 +754,6 @@ static int kfd_ioctl_get_clock_counters(struct file *filep, { struct kfd_ioctl_get_clock_counters_args *args = data; struct kfd_dev *dev; - struct timespec64 time; dev = kfd_device_by_id(args->gpu_id); if (dev) @@ -766,11 +765,8 @@ static int kfd_ioctl_get_clock_counters(struct file *filep, args->gpu_clock_counter = 0; /* No access to rdtsc. Using raw monotonic time */ - getrawmonotonic64(&time); - args->cpu_clock_counter = (uint64_t)timespec64_to_ns(&time); - - get_monotonic_boottime64(&time); - args->system_clock_counter = (uint64_t)timespec64_to_ns(&time); + args->cpu_clock_counter = ktime_get_raw_ns(); + args->system_clock_counter = ktime_get_boot_ns(); /* Since the counter is in nano-seconds we use 1GHz frequency */ args->system_clock_freq = 1000000000;