linux-kernel.vger.kernel.org archive mirror
 help / color / mirror / Atom feed
From: Eric Biggers <ebiggers@kernel.org>
To: Daniel Rosenberg <drosen@google.com>
Cc: "Theodore Y . Ts'o" <tytso@mit.edu>,
	Jaegeuk Kim <jaegeuk@kernel.org>,
	Andreas Dilger <adilger.kernel@dilger.ca>,
	Chao Yu <chao@kernel.org>,
	Alexander Viro <viro@zeniv.linux.org.uk>,
	Richard Weinberger <richard@nod.at>,
	linux-fscrypt@vger.kernel.org, linux-ext4@vger.kernel.org,
	linux-f2fs-devel@lists.sourceforge.net,
	linux-kernel@vger.kernel.org, linux-fsdevel@vger.kernel.org,
	linux-mtd@lists.infradead.org,
	Gabriel Krisman Bertazi <krisman@collabora.com>,
	kernel-team@android.com
Subject: Re: [PATCH v3 1/3] libfs: Add generic function for setting dentry_ops
Date: Wed, 18 Nov 2020 10:32:02 -0800	[thread overview]
Message-ID: <X7VooviygzLQoprL@sol.localdomain> (raw)
In-Reply-To: <20201118064245.265117-2-drosen@google.com>

On Wed, Nov 18, 2020 at 06:42:43AM +0000, Daniel Rosenberg wrote:
> +#if IS_ENABLED(CONFIG_UNICODE) && IS_ENABLED(CONFIG_FS_ENCRYPTION)
> +static const struct dentry_operations generic_encrypted_ci_dentry_ops = {
> +	.d_hash = generic_ci_d_hash,
> +	.d_compare = generic_ci_d_compare,
> +	.d_revalidate = fscrypt_d_revalidate,
> +};
> +#endif

One nit: it would be good to change the #if condition above to:

	#if defined(CONFIG_FS_ENCRYPTION) && defined(CONFIG_UNICODE)

... to make it identical to the #if condition later on:

> +#if defined(CONFIG_FS_ENCRYPTION) && defined(CONFIG_UNICODE)
> +	if (needs_encrypt_ops && needs_ci_ops) {
> +		d_set_d_op(dentry, &generic_encrypted_ci_dentry_ops);
> +		return;
> +	}
>  #endif

It doesn't actually matter, but it's nice to keep things consistent.

Otherwise, please feel free to add:

	Reviewed-by: Eric Biggers <ebiggers@google.com>

- Eric

  reply	other threads:[~2020-11-18 18:32 UTC|newest]

Thread overview: 7+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2020-11-18  6:42 [PATCH v3 0/3] Add support for Encryption and Casefolding in F2FS Daniel Rosenberg
2020-11-18  6:42 ` [PATCH v3 1/3] libfs: Add generic function for setting dentry_ops Daniel Rosenberg
2020-11-18 18:32   ` Eric Biggers [this message]
2020-11-18  6:42 ` [PATCH v3 2/3] fscrypt: Have filesystems handle their d_ops Daniel Rosenberg
2020-11-18 18:33   ` Eric Biggers
2020-11-18  6:42 ` [PATCH v3 3/3] f2fs: Handle casefolding with Encryption Daniel Rosenberg
2020-11-18 19:05   ` Eric Biggers

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=X7VooviygzLQoprL@sol.localdomain \
    --to=ebiggers@kernel.org \
    --cc=adilger.kernel@dilger.ca \
    --cc=chao@kernel.org \
    --cc=drosen@google.com \
    --cc=jaegeuk@kernel.org \
    --cc=kernel-team@android.com \
    --cc=krisman@collabora.com \
    --cc=linux-ext4@vger.kernel.org \
    --cc=linux-f2fs-devel@lists.sourceforge.net \
    --cc=linux-fscrypt@vger.kernel.org \
    --cc=linux-fsdevel@vger.kernel.org \
    --cc=linux-kernel@vger.kernel.org \
    --cc=linux-mtd@lists.infradead.org \
    --cc=richard@nod.at \
    --cc=tytso@mit.edu \
    --cc=viro@zeniv.linux.org.uk \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).