From: Herbert Xu Subject: Re: [RFC v2 2/3] crypto: Introduce CRYPTO_ALG_BULK flag Date: Fri, 3 Jun 2016 18:09:51 +0800 Message-ID: <20160603100951.GA31382@gondor.apana.org.au> References: <47e9ddd8c9ea9ad9e29c8cb027d19d8459ea1479.1464346333.git.baolin.wang@linaro.org> <20160602082606.GA15226@gondor.apana.org.au> <20160603065146.GA29953@gondor.apana.org.au> <20160603075435.GA30149@gondor.apana.org.au> <20160603082152.GA30551@gondor.apana.org.au> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Cc: Jens Axboe , Alasdair G Kergon , Mike Snitzer , "open list:DEVICE-MAPPER (LVM)" , David Miller , Eric Biggers , Joonsoo Kim , tadeusz.struk@intel.com, smueller@chronox.de, Masanari Iida , Shaohua Li , Dan Williams , "Martin K. Petersen" , Sagi Grimberg , Kent Overstreet , Keith Busch , Tejun Heo , Ming Lei , Mark Brown , Arnd Bergmann , linux-crypto@vger.kernel.org, linux-block@vger.kernel.org, "open list:SOFTWARE RAID (Multiple Disks) SUPPORT" , LKML Return-path: Received: from helcar.hengli.com.au ([209.40.204.226]:57501 "EHLO helcar.hengli.com.au" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1751808AbcFCKKk (ORCPT ); Fri, 3 Jun 2016 06:10:40 -0400 Content-Disposition: inline In-Reply-To: Sender: linux-crypto-owner@vger.kernel.org List-ID: On Fri, Jun 03, 2016 at 05:23:59PM +0800, Baolin Wang wrote: > > Assuming one 64K size bio coming, we can map the whole bio with one sg > table in crypt_convert_bulk_block() function. But if we send this bulk > request to crypto layer, we should divide the bulk request into small > requests, and each small request should be one sector size (512 bytes) > with assuming the correct IV, but we need to allocate small requests > memory for the division, which will not good for IO mapping, and how > each small request connect to dm-crypt (how to notify the request is > done?)? Why won't it be good? The actual AES block size is 16 and yet we have no trouble when you feed it a block of 512 bytes. Cheers, -- Email: Herbert Xu Home Page: http://gondor.apana.org.au/~herbert/ PGP Key: http://gondor.apana.org.au/~herbert/pubkey.txt