Received: by 2002:a25:e74b:0:0:0:0:0 with SMTP id e72csp145591ybh; Mon, 20 Jul 2020 12:35:40 -0700 (PDT) X-Google-Smtp-Source: ABdhPJyWf6hJi7364VZjYgSD0sz09RlDKLyE3jtumML++uuw4agyXGpWPIxq7RsMNJP99ej6SGsU X-Received: by 2002:a17:906:d784:: with SMTP id pj4mr21378604ejb.405.1595273740372; Mon, 20 Jul 2020 12:35:40 -0700 (PDT) ARC-Seal: i=1; a=rsa-sha256; t=1595273740; cv=none; d=google.com; s=arc-20160816; b=RzVXXze3Ody4y667beUwLBa0j2CQnJsWvyVLq3wwlebNi47Z9ejTsgtIgBpJu+yLVP UY5U3dyA7/zDDUfs+S2Vys2dptQc0DDJsdPUBrte4AQE7b5fAxPMmJZqGAcFbkOeQ2u5 qlCRQ5/bdOEWmWm2fYCuldjpgrs3a0V81TKlBDgGYKfxMs9ayxg6LRvC/RQkLbEwxBnh ENwy8TSzDsSvT0Yq3pibNUh+3NFegQWT/C/EfTQ32RCDU13kJCzWOLjEuhDm2y9IJ7tJ +HJXL7QYy3Wk87lnGdwugYypubxqZA/C9nILKxeboZSRBCYW4I5WPzHhzaCzchnlT8jk d24A== ARC-Message-Signature: i=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=arc-20160816; h=list-id:precedence:sender:in-reply-to:content-disposition :mime-version:references:message-id:subject:cc:to:from:date :dkim-signature; bh=lA1+qC7QACb23R53MaCLPvkBM3lRFGEEvxB2LF7DgAw=; b=NBL8mjBXhbdyqkDIiCl0j7KNDlf8nuhYh6oF7TL1qa/7NWG01i3jt27aHFyTMRXL3w B87+A32OLcj8qP08MU1e0XP2CC47POnRJoyDq28hEvsPAW6U0UMxWLwsi7DBiNw/mOhS 2OaeNbG/zFQW+kaXAs8G0mUbfLissxXt+/ol0RqwDceOfmUQ7i61VnYFtwY+WVOuKIQy YlQbIjYIm7Zo1YpOCypJM2P0jUivR3N8uN+Ic0klvqZjZIzQCu13PF58V9bLU5PTd8UK BBBGvjVIn0NQqYG18I7352KuBMixs3AcRhaq9Fao2PMI8QtY7KksbXHjJelhczLwFK4C N55w== ARC-Authentication-Results: i=1; mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=0ECqOAP5; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Return-Path: Received: from vger.kernel.org (vger.kernel.org. [23.128.96.18]) by mx.google.com with ESMTP id z16si11148030eju.554.2020.07.20.12.35.15; Mon, 20 Jul 2020 12:35:40 -0700 (PDT) Received-SPF: pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) client-ip=23.128.96.18; Authentication-Results: mx.google.com; dkim=pass header.i=@kernel.org header.s=default header.b=0ECqOAP5; spf=pass (google.com: domain of linux-ext4-owner@vger.kernel.org designates 23.128.96.18 as permitted sender) smtp.mailfrom=linux-ext4-owner@vger.kernel.org; dmarc=pass (p=NONE sp=NONE dis=NONE) header.from=kernel.org Received: (majordomo@vger.kernel.org) by vger.kernel.org via listexpand id S1729698AbgGTTez (ORCPT + 99 others); Mon, 20 Jul 2020 15:34:55 -0400 Received: from mail.kernel.org ([198.145.29.99]:48746 "EHLO mail.kernel.org" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1726491AbgGTTez (ORCPT ); Mon, 20 Jul 2020 15:34:55 -0400 Received: from gmail.com (unknown [104.132.1.76]) (using TLSv1.2 with cipher ECDHE-RSA-AES256-GCM-SHA384 (256/256 bits)) (No client certificate requested) by mail.kernel.org (Postfix) with ESMTPSA id F190F207DF; Mon, 20 Jul 2020 19:34:54 +0000 (UTC) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=kernel.org; s=default; t=1595273695; bh=gvoR90bmjWKLI6StivijfjivWNaNOvpnS43HZMXXkI8=; h=Date:From:To:Cc:Subject:References:In-Reply-To:From; b=0ECqOAP5qntFeHvHP3rCgmLeWZmcRzkVpjPjpKKX7kc222b4dMmX7dKOhC4k0q20s s+qvigsG3jg0HwEhIG6q2zoyS//842FNc1Fb7Fh45OW6uxRqipMEFAIlYpdpg0AwOE edNygX41zP00UlndM2ZspUciOB1QqJ7lXDZa41AQ= Date: Mon, 20 Jul 2020 12:34:53 -0700 From: Eric Biggers To: Satya Tangirala Cc: linux-fscrypt@vger.kernel.org, linux-fsdevel@vger.kernel.org, linux-f2fs-devel@lists.sourceforge.net, linux-ext4@vger.kernel.org, linux-xfs@vger.kernel.org Subject: Re: [PATCH v3 6/7] fscrypt: document inline encryption support Message-ID: <20200720193453.GH1292162@gmail.com> References: <20200717014540.71515-1-satyat@google.com> <20200717014540.71515-7-satyat@google.com> MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: <20200717014540.71515-7-satyat@google.com> Sender: linux-ext4-owner@vger.kernel.org Precedence: bulk List-ID: X-Mailing-List: linux-ext4@vger.kernel.org On Fri, Jul 17, 2020 at 01:45:39AM +0000, Satya Tangirala wrote: > Update the fscrypt documentation file for inline encryption support. > > Signed-off-by: Satya Tangirala Reviewed-by: Eric Biggers > diff --git a/Documentation/filesystems/fscrypt.rst b/Documentation/filesystems/fscrypt.rst > index f5d8b0303ddf..f3d87a1a0a7f 100644 > --- a/Documentation/filesystems/fscrypt.rst > +++ b/Documentation/filesystems/fscrypt.rst > @@ -1204,6 +1204,18 @@ buffer. Some filesystems, such as UBIFS, already use temporary > buffers regardless of encryption. Other filesystems, such as ext4 and > F2FS, have to allocate bounce pages specially for encryption. > > +Fscrypt is also able to use inline encryption hardware instead of the > +kernel crypto API for en/decryption of file contents. When possible, and > +if directed to do so (by specifying the 'inlinecrypt' mount option for > +an ext4/F2FS filesystem), it adds encryption contexts to bios and > +uses blk-crypto to perform the en/decryption instead of making use > +of the above read/write path changes. Of course, even if directed to make > +use of inline encryption, fscrypt will only be able to do so if either > +hardware inline encryption support is available for the selected encryption > +algorithm or CONFIG_BLK_INLINE_ENCRYPTION_FALLBACK is selected. If neither > +is the case, fscrypt will fall back to using the above mentioned read/write > +path changes for en/decryption. > + Nit: most of the text in this file is formatted with textwidth=70. > Filename hashing and encoding > ----------------------------- > > @@ -1250,7 +1262,9 @@ Tests > > To test fscrypt, use xfstests, which is Linux's de facto standard > filesystem test suite. First, run all the tests in the "encrypt" > -group on the relevant filesystem(s). For example, to test ext4 and > +group on the relevant filesystem(s). One can also run the tests > +with the 'inlinecrypt' mount option to test the implementation for > +inline encryption support. For example, to test ext4 and > f2fs encryption using `kvm-xfstests > `_:: > > -- > 2.28.0.rc0.105.gf9edc3c819-goog >