fscrypt: remove fscrypt_symlink_data_len()
authorEric Biggers <ebiggers@google.com>
Tue, 4 Apr 2017 21:43:34 +0000 (14:43 -0700)
committerTheodore Ts'o <tytso@mit.edu>
Sun, 30 Apr 2017 05:26:34 +0000 (01:26 -0400)
fscrypt_symlink_data_len() is never called and can be removed.

Signed-off-by: Eric Biggers <ebiggers@google.com>
Reviewed-by: Richard Weinberger <richard@nod.at>
Signed-off-by: Theodore Ts'o <tytso@mit.edu>
include/linux/fscrypt_common.h

index 10c1abfbac6c45d1049fdf9f1b1f133371521461..0a30c106c1e535188637d7947a74f77c933968a1 100644 (file)
@@ -46,17 +46,6 @@ struct fscrypt_symlink_data {
        char encrypted_path[1];
 } __packed;
 
-/**
- * This function is used to calculate the disk space required to
- * store a filename of length l in encrypted symlink format.
- */
-static inline u32 fscrypt_symlink_data_len(u32 l)
-{
-       if (l < FS_CRYPTO_BLOCK_SIZE)
-               l = FS_CRYPTO_BLOCK_SIZE;
-       return (l + sizeof(struct fscrypt_symlink_data) - 1);
-}
-
 struct fscrypt_str {
        unsigned char *name;
        u32 len;