Received: by 2002:ac0:a679:0:0:0:0:0 with SMTP id p54csp329341imp; Wed, 20 Feb 2019 00:42:17 -0800 (PST) X-Received: by 2002:a17:902:bb89:: with SMTP id m9mr35181490pls.320.1550651897303; Wed, 20 Feb 2019 00:38:17 -0800 (PST) X-Google-Smtp-Source: AHgI3IbXTRSM4eHUmXCZ5LNOSEG55Gaaf+XXuPVF31SZLrUfLv6DHFaPqSm/DJzbvdRM1v5/NRAv X-Received: by 2002:a17:902:bb89:: with SMTP id m9mr35181448pls.320.1550651896563; Wed, 20 Feb 2019 00:38:16 -0800 (PST) ARC-Seal: i=1; a=rsa-sha256; t=1550651896; cv=none; d=google.com; s=arc-20160816; b=H5zH4hFgLpdu/5Zr2vqvr1KZ9PDECF4MFxMHd3akr7FWNUkEqfN2DjziTz/5OVHL53 JcypMZPFwRVLUYFLxrrVLE6VDzGfrg3dQGnZi4Omrk0/msFD0Jx4a/jm6c/LhyX6XqV9 QlVKsNjYCLzYCNvdiamFgKlqFsZNcXTX467g9U64DWilZnOoG4HwyyRGRZR5e2Py0nj3 Zvoi0zGDSkpprjjBXbqy5vQtZXkyyA7K/WMvOQsqwLTpHFywsmRmLc0UuQBl/kOPH7TU GtzZ3x4GLrVpUuYG+hJY0n2Y8ww58L9I5tgiKhYIeID+keGu1P3W+tTexPw9AMkEejn2 xFzg== 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:dkim-signature; bh=ieZaSsrV/WeKWZta4n3OTgkHAop3JCEPGBBBuAwt6D4=; b=ww2Q9fyXmDdrKUb1jDsFxX9K+aj6KN29EHBYu9IlKi/SpBHNbp4mNEe69vF2YTMk2B m3y4v96S0kWmc3jdF9YL1Pg0nwleY1PqVAqpI9vB1i/j+1pnUh64gtXyfzSOxHiuNFEw cvDpmX2PAQvczugtfuBbJ8Xpcbr8Qxc/sX2UZAtm01nlzisGF3njUdzzCLAIZvFNijuc TF1npdzSnVaMcnJLh8SvlrniNaGRyjyTY/gXB/ykm1QtyE7olcwrUx7hUtTzy2x4owEH VtTf9lUEUnQX9DmQUWFabqciLVmPl9GUUL5CbCx9SLsn3JDYRr5r0ex5ld2APdrs7N/5 TNZQ== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@gmail.com header.s=20161025 header.b=oupRNNI7; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Return-Path: Received: from vger.kernel.org (vger.kernel.org. [209.132.180.67]) by mx.google.com with ESMTP id l68si20213878plb.90.2019.02.20.00.38.01; Wed, 20 Feb 2019 00:38:16 -0800 (PST) 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; dkim=pass header.i=@gmail.com header.s=20161025 header.b=oupRNNI7; 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; dmarc=pass (p=NONE sp=QUARANTINE dis=NONE) header.from=gmail.com Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1726481AbfBTIhZ (ORCPT + 99 others); Wed, 20 Feb 2019 03:37:25 -0500 Received: from mail-lj1-f193.google.com ([209.85.208.193]:34811 "EHLO mail-lj1-f193.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726217AbfBTIhW (ORCPT ); Wed, 20 Feb 2019 03:37:22 -0500 Received: by mail-lj1-f193.google.com with SMTP id l5so16648725lje.1 for ; Wed, 20 Feb 2019 00:37:20 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20161025; h=from:to:cc:subject:date:message-id:in-reply-to:references; bh=ieZaSsrV/WeKWZta4n3OTgkHAop3JCEPGBBBuAwt6D4=; b=oupRNNI7IYOC0noJTA7Rop3i/ZKkB2Y83RMJ9NIFj3wgBAxKrnjoVJ6GVbs3cknTHD X/ceeZfeBWXfpRjiQafO5LgrNRdluOxbcGahc2V/1KCO/f2XMnHOs9cwkCYpWvMH+5sr FjXVetWiV3q3xGYTAg4OvkjNWCW7mXTrwWVsSIMODBwp9AixsllEYbjlQr80Md1UoBqV gMUP9X84HRRSBIKfSfjsCIBpOj7qaJUTyYgMMJ6kjVtfzO5lMmQXKRRhhkNtDzYOX4Mf M2J8ZmJB5GvmcJk7F34yiNO1pjKeLATn0nB/af31+GEqj4RFtixieFBfcGq7bYfVWshx pDzQ== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20161025; h=x-gm-message-state:from:to:cc:subject:date:message-id:in-reply-to :references; bh=ieZaSsrV/WeKWZta4n3OTgkHAop3JCEPGBBBuAwt6D4=; b=TS85Y7xaYokMXYc2MdPgptaAcpyAPbBsbEGlk6mR64wJzmARgE6Qe5dQ5lEuj2Uw8m 3WUXBHdYF8fnlLGj88vUlhbkIKvc4Givsnud8/dmY64gbCEH/4czn1Gnjtc8yKu5UbRU wP+FFH/LnYjY/I/uvQng5Y1eIIoN0P4J9VHrVG4jOCNqO7T28ScIep8O32n9B0yhF7Xc icjRLQwhPIUX+wFrs8vRsGiaOl7A4kX9+znkPt29oIEv8OkU3P+61JBl6N6PVB/2OFqp D2VLX8SsFAYkMPm0ZrfFAOgyZYrxQeMMEkkOM50u1Nv+XeaqUFO+cD9AFAwN7VPXvJFf Oz3g== X-Gm-Message-State: AHQUAuZ1BgHfdyCSU9vE3+PjNzIF5cOrLsjdFEwJkW+Ak1Xu1AXFNvx6 MzVSPF60O/qgovmqNJSXxLU= X-Received: by 2002:a2e:90cd:: with SMTP id o13mr10581597ljg.153.1550651839991; Wed, 20 Feb 2019 00:37:19 -0800 (PST) Received: from localhost ([188.162.52.148]) by smtp.gmail.com with ESMTPSA id l20sm3016785ljb.24.2019.02.20.00.37.18 (version=TLS1_2 cipher=ECDHE-RSA-CHACHA20-POLY1305 bits=256/256); Wed, 20 Feb 2019 00:37:19 -0800 (PST) From: Yury Norov X-Google-Original-From: Yury Norov To: Andrew Morton , Andy Shevchenko , Arnd Bergmann , Dmitry Torokhov , Kees Cook , Matthew Wilcox , Michael Ellerman , Rasmus Villemoes , Tetsuo Handa Cc: Yury Norov , linux-kernel@vger.kernel.org, Yury Norov Subject: [PATCH 4/6] lib/test_bitmap: switch test_bitmap_parselist to ktime_get() Date: Wed, 20 Feb 2019 11:37:03 +0300 Message-Id: <20190220083705.14050-5-ynorov@marvell.com> X-Mailer: git-send-email 2.17.1 In-Reply-To: <20190220083705.14050-1-ynorov@marvell.com> References: <20190220083705.14050-1-ynorov@marvell.com> Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org test_bitmap_parselist currently uses get_cycles which is not implemented on some platforms, so use ktime_get() instead. Signed-off-by: Yury Norov --- lib/test_bitmap.c | 9 ++++----- 1 file changed, 4 insertions(+), 5 deletions(-) diff --git a/lib/test_bitmap.c b/lib/test_bitmap.c index 6cd7d0740005..b06e0fd3811b 100644 --- a/lib/test_bitmap.c +++ b/lib/test_bitmap.c @@ -266,15 +266,15 @@ static void __init test_bitmap_parselist(void) { int i; int err; - cycles_t cycles; + ktime_t time; DECLARE_BITMAP(bmap, 2048); for (i = 0; i < ARRAY_SIZE(parselist_tests); i++) { #define ptest parselist_tests[i] - cycles = get_cycles(); + time = ktime_get(); err = bitmap_parselist(ptest.in, bmap, ptest.nbits); - cycles = get_cycles() - cycles; + time = ktime_get() - time; if (err != ptest.errno) { pr_err("test %d: input is %s, errno is %d, expected %d\n", @@ -291,8 +291,7 @@ static void __init test_bitmap_parselist(void) if (ptest.flags & PARSE_TIME) pr_err("test %d: input is '%s' OK, Time: %llu\n", - i, ptest.in, - (unsigned long long)cycles); + i, ptest.in, time); } } -- 2.17.1