[PATCH 0/4] fscrypt: Add FSTR() helper macro and convert initializers

Eric Biggers ebiggers at kernel.org
Tue Nov 24 15:11:55 PST 2026


On Wed, Nov 18, 2026 at 01:28:46AM +0100, Thorsten Blum wrote:
> Similar to QSTR(), add FSTR() to initialize struct fscrypt_str from a
> NUL-terminated string without specifying its length.
> 
> Use the helper for 8 initializers in btrfs, F2FS, and UBIFS, replacing
> hard-coded lengths and explicit strlen() calls.
> 
> Thorsten Blum (4):
>   fscrypt: Add FSTR() helper macro
>   btrfs: Use FSTR() for the "default" name
>   f2fs: Use FSTR() in f2fs_do_make_empty_dir()
>   ubifs: Use FSTR() in ubifs_xattr_{set,get,remove}()
> 
>  fs/btrfs/inode.c        | 3 +--
>  fs/btrfs/ioctl.c        | 3 +--
>  fs/btrfs/super.c        | 3 +--
>  fs/f2fs/dir.c           | 7 ++-----
>  fs/ubifs/xattr.c        | 6 +++---
>  include/linux/fscrypt.h | 1 +
>  6 files changed, 9 insertions(+), 14 deletions(-)

Applied to https://git.kernel.org/pub/scm/fs/fscrypt/linux.git/log/?h=for-next

- Eric



More information about the linux-mtd mailing list