Received: by 2002:a05:7412:1e0b:b0:fc:a2b0:25d7 with SMTP id kr11csp142539rdb; Wed, 14 Feb 2024 16:00:51 -0800 (PST) X-Forwarded-Encrypted: i=3; AJvYcCUn4JsFGSLYAqo2qtgcEzDJhy+Yo1ogtp2ah0kNNhS1degCBMsXBkLMF07TFeM2EmofNER79ncBzXADMmi8vyHri+ma0Grqt6cuY3mNJg== X-Google-Smtp-Source: AGHT+IFArKXjet6SFOu1tI35Th+kgBA92SCPWBcxQqB+xCN4vkOZ1fxvhWbnwVmgCOmn4kSSH6oh X-Received: by 2002:a05:6a20:9f8c:b0:19c:b457:fb8 with SMTP id mm12-20020a056a209f8c00b0019cb4570fb8mr382347pzb.51.1707955250693; Wed, 14 Feb 2024 16:00:50 -0800 (PST) ARC-Seal: i=2; a=rsa-sha256; t=1707955250; cv=pass; d=google.com; s=arc-20160816; b=Ju7vmH6IhlUv81BJV27wvG05/FKMU67tmSd5QfC5YpjLLceC08h5+2ThBOKivGX7jY 6gMsCT3gEm6Z9LMjODb7BkxudX1eXV+Nqms9ay5TY3DAHk/1FjXhtAzon9LOtGTV6i5v e+g4o3B2o++iTpCzQuUU+cEJwfxyaykYQs+7JDTbWjCvgUOhP37b+4JeL/Yzz6wJGFy4 NaVT53zw080K99YN3dmlHf0UsudBZSguw4srIjMFSjaca8uoG6DhRabzhk4he7Tya7GP vQTw5jHggHLWy9eZURmDsr0IR6fmzUJeNgA3HktIKYapuEZFQiqBgklACrdP5QQma80v uHog== ARC-Message-Signature: i=2; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=in-reply-to:content-disposition:mime-version:list-unsubscribe :list-subscribe:list-id:precedence:references:message-id:subject:cc :to:from:date:dkim-signature; bh=pRq8hdUlNNQTRljRjmVQzWCVIKgntb3TbaXyJ2JQScs=; fh=OUpgHz8gu+EFyREjScBnwgXxe9p5hHef04jJGlkpTWE=; b=BzuOrpA8K028+rOGSHFu9WPAWlBLgv87++j4bD/06i50ZzFEmO/wo2PwL3v2CiEC5j UnKa6o/LX7shipTYoRN3Ys9cImjZUTrtCqVxTXQSHpUNmFLTSzOvTzMWoaIR40RPxUnO T6SAeljBB2bXNFkx5HE5Lb+Z5hEzFIu0xcT7a2zF7QAnoGND7PVTG953NwIa2fm3nLrn 2AZRufjKtuBXrX1tz18wwFX/0Ihu5js2D6lYFE280ALwGpBg1rGUFTPje8rkfeeVZ6gO kwpKPNWgk8LI8FAd52eTrmdqwpdZIO+87V2124k3B+3ftqBbhyQ1FQbV0ECHf9HmDz4n HkUw==; dara=google.com ARC-Authentication-Results: i=2; mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Cv08SZH+; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-crypto+bounces-2065-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-crypto+bounces-2065-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from sy.mirrors.kernel.org (sy.mirrors.kernel.org. [147.75.48.161]) by mx.google.com with ESMTPS id 7-20020a630107000000b005d8e379746asi11829pgb.630.2024.02.14.16.00.50 for (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Wed, 14 Feb 2024 16:00:50 -0800 (PST) Received-SPF: pass (google.com: domain of linux-crypto+bounces-2065-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) client-ip=147.75.48.161; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=k20201202 header.b=Cv08SZH+; arc=pass (i=1 dkim=pass dkdomain=kernel.org); spf=pass (google.com: domain of linux-crypto+bounces-2065-linux.lists.archive=gmail.com@vger.kernel.org designates 147.75.48.161 as permitted sender) smtp.mailfrom="linux-crypto+bounces-2065-linux.lists.archive=gmail.com@vger.kernel.org"; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: from smtp.subspace.kernel.org (wormhole.subspace.kernel.org [52.25.139.140]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by sy.mirrors.kernel.org (Postfix) with ESMTPS id 8A05DB24385 for ; Wed, 14 Feb 2024 23:35:32 +0000 (UTC) Received: from localhost.localdomain (localhost.localdomain [127.0.0.1]) by smtp.subspace.kernel.org (Postfix) with ESMTP id DB5A41420C5; Wed, 14 Feb 2024 23:35:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b="Cv08SZH+" X-Original-To: linux-crypto@vger.kernel.org Received: from smtp.kernel.org (aws-us-west-2-korg-mail-1.web.codeaurora.org [10.30.226.201]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by smtp.subspace.kernel.org (Postfix) with ESMTPS id 9B33E1420BD for ; Wed, 14 Feb 2024 23:35:19 +0000 (UTC) Authentication-Results: smtp.subspace.kernel.org; arc=none smtp.client-ip=10.30.226.201 ARC-Seal:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707953719; cv=none; b=ACiQdss4GyckchDuiqMmKM7mEyJd/2HwQBpvKH4ZRz5HnAkh2zi3qCbRsavqWgtRabQNvGQG4Gw5Kdn2BwT7ZUZN2DRTutvNJPkiXXhkNYL6PXuMSsvLTqiLSRhqxXdUXbus9Fvo6kx444eAcOl2y6ltRGCwIEvD0odwv3hXjv0= ARC-Message-Signature:i=1; a=rsa-sha256; d=subspace.kernel.org; s=arc-20240116; t=1707953719; c=relaxed/simple; bh=lAxBWrdhb4LJ6Gw3eRCtWSu9qxq/Tlk/O6tFLzdiXmM=; h=Date:From:To:Cc:Subject:Message-ID:References:MIME-Version: Content-Type:Content-Disposition:In-Reply-To; b=Qm5mNK5VnGyGIPWECCMdBVt444EOFL2HgRtwPgL/ueJXZAL+2vCVdN+aQKrtnZAI8MHU21tyZ3QsmLKF4uTbej/pbnkyjEp9hvI20HFOKVT8V5NRpunH2nblGgMPKsbakNijUsJlV7HSIzevWnL3jhC8xufhoVj0BIjXagmEhNY= ARC-Authentication-Results:i=1; smtp.subspace.kernel.org; dkim=pass (2048-bit key) header.d=kernel.org header.i=@kernel.org header.b=Cv08SZH+; arc=none smtp.client-ip=10.30.226.201 Received: by smtp.kernel.org (Postfix) with ESMTPSA id 0E31CC43390; Wed, 14 Feb 2024 23:35:19 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=k20201202; t=1707953719; bh=lAxBWrdhb4LJ6Gw3eRCtWSu9qxq/Tlk/O6tFLzdiXmM=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=Cv08SZH+0LzNmqUTDqs4yUs+TEQFuEZUMQvtvaiscbb9IfskZEnT85sCF2b7YaLy3 PCnCXxlakKp9V+o7er57UOtBEh4Bjdl9JuykO13tmujiAo2DbdMX2OO1ZbCKrB8Ymg JoisG4ScIycSSo8pPDqkT5G9GQO14VCAD7yz62WXYQbFp9Pi2M7h3si4JxQuDsj8c3 XGael73XY1IFqt0bF3AVZUfxfUUWGsMktF1kjMLQDTjKgBOJENTDqgJtrJ4UL0+hjU 130O0W3OOk0joLYFp+yzlVENR5sU8fwV/H/QQOmXBH08oCb9OBRDVB/erO/AbfgACa hdcFpNsBS2pNA== Date: Wed, 14 Feb 2024 15:35:17 -0800 From: Eric Biggers To: Herbert Xu Cc: Linux Crypto Mailing List Subject: Re: [PATCH 00/15] crypto: Add twopass lskcipher for adiantum Message-ID: <20240214233517.GD1638@sol.localdomain> References: Precedence: bulk X-Mailing-List: linux-crypto@vger.kernel.org List-Id: List-Subscribe: List-Unsubscribe: MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: On Tue, Feb 13, 2024 at 05:04:25PM +0800, Herbert Xu wrote: > [PATCH 00/15] crypto: Add twopass lskcipher for adiantum Thanks. Can you include an explanation of the high-level context and goals for this work? It's still not clear to me. I'm guessing that the main goal is to get rid of the vaddr => scatterlist => vaddr round trip for software encryption/decryption, which hopefully will improve performance and make the API easier to use? And to do that, all software algorithms need to be converted to "lskcipher"? Will skcipher API users actually be able to convert to lskcipher, or will they be blocked by people expecting to be able to use hardware crypto accelerators? Would you accept lskcipher being used alongside skcipher? Previously you had said you don't want shash being used alongside ahash. I'd prefer there was a clear plan before merging a bunch of patches that leave everything in a half-finished state. By the way, note that hctr2 requires two passes too, as it's an SPRP like Adiantum. Also note that SPRPs in general may require more than two passes, though Adiantum and HCTR2 were designed to only need two (technically they have three passes, but two are combinable). It's fine to support only two passes if that's what's needed now; I just thought I'd mention that there's no guarantee that two passes will be enough forever. > In addition to converting adiantum, the underlying chacha algorithm > is also converted over to lskcipher. > > The algorithms cts + xts have been converted too to ensure that the > tailsize mechanism works properly for them. While doing this the > parameters for cts + xts have been modified so that blocksize is now > 1. This entails changing the paramters of all drivers that support > cts and/or xts. cts and xts have nothing to do with adiantum. So this further indicates that the scope of this work is broader than just "crypto: Add twopass lskcipher for adiantum" as suggested by the title. It would be good to have a sense for the direction of this work. What will be coming next? - Eric