From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: X-Spam-Checker-Version: SpamAssassin 3.4.0 (2014-02-07) on aws-us-west-2-korg-lkml-1.web.codeaurora.org X-Spam-Level: X-Spam-Status: No, score=-2.2 required=3.0 tests=HEADER_FROM_DIFFERENT_DOMAINS, MAILING_LIST_MULTI,SPF_HELO_NONE,SPF_PASS,URIBL_BLOCKED,USER_AGENT_SANE_1 autolearn=no autolearn_force=no version=3.4.0 Received: from mail.kernel.org (mail.kernel.org [198.145.29.99]) by smtp.lore.kernel.org (Postfix) with ESMTP id BAE6AC4360C for ; Fri, 27 Sep 2019 10:11:55 +0000 (UTC) Received: from vger.kernel.org (vger.kernel.org [209.132.180.67]) by mail.kernel.org (Postfix) with ESMTP id 898D7217D9 for ; Fri, 27 Sep 2019 10:11:55 +0000 (UTC) Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1725882AbfI0KLy (ORCPT ); Fri, 27 Sep 2019 06:11:54 -0400 Received: from helcar.hmeau.com ([216.24.177.18]:40790 "EHLO fornost.hmeau.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1725946AbfI0KLy (ORCPT ); Fri, 27 Sep 2019 06:11:54 -0400 Received: from gwarestrin.arnor.me.apana.org.au ([192.168.0.7]) by fornost.hmeau.com with smtp (Exim 4.89 #2 (Debian)) id 1iDnDs-0007V8-NH; Fri, 27 Sep 2019 20:11:37 +1000 Received: by gwarestrin.arnor.me.apana.org.au (sSMTP sendmail emulation); Fri, 27 Sep 2019 20:11:24 +1000 Date: Fri, 27 Sep 2019 20:11:24 +1000 From: Herbert Xu To: Pascal Van Leeuwen Cc: Linus Torvalds , Ard Biesheuvel , Linux Crypto Mailing List , Linux ARM , David Miller , Greg KH , "Jason A . Donenfeld" , Samuel Neves , Dan Carpenter , Arnd Bergmann , Eric Biggers , Andy Lutomirski , Will Deacon , Marc Zyngier , Catalin Marinas Subject: Re: [RFC PATCH 18/18] net: wireguard - switch to crypto API for packet encryption Message-ID: <20190927101124.GA15588@gondor.apana.org.au> References: <20190925161255.1871-1-ard.biesheuvel@linaro.org> <20190925161255.1871-19-ard.biesheuvel@linaro.org> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.10.1 (2018-07-13) Sender: linux-crypto-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-crypto@vger.kernel.org On Fri, Sep 27, 2019 at 09:58:14AM +0000, Pascal Van Leeuwen wrote: > > But I can see the appeal of getting a "done" response on the _encrypt()/ > _decrypt() call and then being able to immediately continue processing > the result data and having the async response handling separated off. This is how it works today. If your request can be fulfilled right away, you will get a return value other than EINPROGRESS and you just carry on, the completion callback never happens in this case. aesni-intel makes heavy use of this. In most cases it is sync. It only goes async when the FPU is not available. Cheers, -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt