Received: by 2002:ac0:98c7:0:0:0:0:0 with SMTP id g7-v6csp4415495imd; Tue, 30 Oct 2018 01:18:39 -0700 (PDT) X-Google-Smtp-Source: AJdET5eA8ZXKtwYKrULfIZ+E8onnA3nJAojH+uo8cs3OTgL2Xy5T7+8dCf1DhhGSiiieqQnX80TW X-Received: by 2002:a63:af18:: with SMTP id w24mr17250041pge.385.1540887519742; Tue, 30 Oct 2018 01:18:39 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1540887519; cv=none; d=google.com; s=arc-20160816; b=rPx7DVKYgOH0w+WUvq4ly07sYdCC/zkA2P2P1+pNvl7R33be6lJ60uq39UgEoJNMov hOOyvhSGy0tggn/ZbQRMYH83Tor73Fq9IihhzPLPYYVZ9I72ZHZWzejv/xFGs4g5jH9R RmJKNnlYxy7SZhZFlYWfvYu+c6jiB11UXTuGsxEcu7zJsrh9aCYuEhsJqy0fMXid6uEY iXCS1JwXAeusTVRL49xhUasas4MTzMwjV8gpHCqKAeX/p+UMOhLjyvO1fhz9ClJvtVUt 61p6UIAYO955fMqZrWAzs7uQmLoseibn294D9iAuGsW2bXjbxLFCk5l+5P7zV5Ylo6LH i1/A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:user-agent:in-reply-to :content-disposition:mime-version:references:message-id:subject:cc :to:from:date; bh=xXsCEiusrSfnnJ866Bb+3fsP6EHt+FS6UNMRVLOGLog=; b=UPLBaZ9pKs4fHH/RNdH5FBijaBOlUwyRVIVoKW7+eiAonAOEJSP4TO0MJCyWrhobwJ pAKBBxDTaTleNCMgHNhCOuauORAXaENRbaE9nLe8/m9AXtV2GMA1uwIvfkrjCUJ6cIOH PLQ15ZEMD/7exxiF1PQsTcTFu8Xx3xIlL8OWYWOs1RNIGRaYbisuapx0PesLiNVQ5LGC jwaDNEcwqVXl4qY/7uMjVA1evR2eGflTmXhQltlpeRZjtNk1jmUGr4b3PNOdysdfoeup Q6WzHucXWvEp3jEYqFjbwUsx8ykheMSH9ammzZgZH6k2J6Fr2kRrpNPhxuUSJJ92D7Ep pacg== 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 v24-v6si22141233ply.158.2018.10.30.01.18.23; Tue, 30 Oct 2018 01:18:39 -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 S1726643AbeJ3RKG (ORCPT + 99 others); Tue, 30 Oct 2018 13:10:06 -0400 Received: from orcrist.hmeau.com ([104.223.48.154]:35434 "EHLO fornost.hmeau.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726172AbeJ3RKG (ORCPT ); Tue, 30 Oct 2018 13:10:06 -0400 Received: from gondolin.me.apana.org.au ([192.168.0.6] helo=gondolin.hengli.com.au) by fornost.hmeau.com with esmtps (Exim 4.89 #2 (Debian)) id 1gHPDQ-0002U4-Qz; Tue, 30 Oct 2018 19:17:32 +1100 Received: from herbert by gondolin.hengli.com.au with local (Exim 4.80) (envelope-from ) id 1gHPDI-0000kv-Ql; Tue, 30 Oct 2018 19:17:24 +1100 Date: Tue, 30 Oct 2018 19:17:24 +1100 From: Herbert Xu To: Eric Biggers Cc: Ard Biesheuvel , "open list:HARDWARE RANDOM NUMBER GENERATOR CORE" , linux-fscrypt@vger.kernel.org, linux-arm-kernel , Linux Kernel Mailing List , Paul Crowley , Greg Kaiser , Michael Halcrow , "Jason A . Donenfeld" , Samuel Neves , Tomer Ashur Subject: Re: [RFC PATCH v2 11/12] crypto: adiantum - add Adiantum support Message-ID: <20181030081724.GA2730@gondor.apana.org.au> References: <20181015175424.97147-1-ebiggers@kernel.org> <20181015175424.97147-12-ebiggers@kernel.org> <20181020071206.GE876@sol.localdomain> <20181024220614.GA13497@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20181024220614.GA13497@gmail.com> User-Agent: Mutt/1.5.21 (2010-09-15) Sender: linux-kernel-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-kernel@vger.kernel.org On Wed, Oct 24, 2018 at 03:06:17PM -0700, Eric Biggers wrote: > > The patch I've been using just exposes a file /proc/cryptobench (note: it maybe > should be made into a char device instead) to which you can write commands like: > > algtype=skcipher algname=adiantum(xchacha12,aes) keysize=32 bufsize=4096 niter=1000 > > Then userspace reads back the result: > > SUCCESS algname=adiantum(xchacha12,aes) driver_name=adiantum(xchacha12-software,aes-aesni,nhpoly1305-generic) measurement=0x30a5abd5776e0af enc_time=44831104 dec_time=38303077 > > It's then pretty straightforward to wrap this API in a userspace script that > does all the benchmarks you need, and formats the results nicely. > > For correctness testing there's also an option 'sgl_fuzz' that randomizes the > scatterlist division. > > Currently the patch is missing some features such as AEAD support, but at some > point I'd like to get it into a state where it can be included upstream. I completely agree that a new interface would be much better for tcrypt. However, we're trying to avoid using /proc for new APIs. So perhaps netlink would be a better choice given the existing configuration and stats APIs that already exist for it. Thanks, -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt