summaryrefslogtreecommitdiffstats
path: root/include/linux/fscrypt_supp.h
diff options
context:
space:
mode:
authorEric Biggers <ebiggers@google.com>2018-01-05 10:44:55 -0800
committerTheodore Ts'o <tytso@mit.edu>2018-01-11 22:06:18 -0500
commit542060c02cdb5c0740fd7156651463e321a859a3 (patch)
treed83fcf2674052594475048c5c473ce7e5b9b13dd /include/linux/fscrypt_supp.h
parente4de782a0960b9620c084881f12fb5e73ebff82b (diff)
downloadblackbird-op-linux-542060c02cdb5c0740fd7156651463e321a859a3.tar.gz
blackbird-op-linux-542060c02cdb5c0740fd7156651463e321a859a3.zip
fscrypt: move fscrypt_ctx declaration to fscrypt_supp.h
Filesystems only ever access 'struct fscrypt_ctx' through fscrypt functions. But when a filesystem is built without encryption support, these functions are all stubbed out, so the declaration of fscrypt_ctx is unneeded. Therefore, move it from fscrypt.h to fscrypt_supp.h. Signed-off-by: Eric Biggers <ebiggers@google.com> Signed-off-by: Theodore Ts'o <tytso@mit.edu>
Diffstat (limited to 'include/linux/fscrypt_supp.h')
-rw-r--r--include/linux/fscrypt_supp.h15
1 files changed, 15 insertions, 0 deletions
diff --git a/include/linux/fscrypt_supp.h b/include/linux/fscrypt_supp.h
index 33d641e27c18..fd6ee089ced0 100644
--- a/include/linux/fscrypt_supp.h
+++ b/include/linux/fscrypt_supp.h
@@ -11,6 +11,21 @@
#ifndef _LINUX_FSCRYPT_SUPP_H
#define _LINUX_FSCRYPT_SUPP_H
+struct fscrypt_ctx {
+ union {
+ struct {
+ struct page *bounce_page; /* Ciphertext page */
+ struct page *control_page; /* Original page */
+ } w;
+ struct {
+ struct bio *bio;
+ struct work_struct work;
+ } r;
+ struct list_head free_list; /* Free list */
+ };
+ u8 flags; /* Flags */
+};
+
static inline bool fscrypt_has_encryption_key(const struct inode *inode)
{
return (inode->i_crypt_info != NULL);
OpenPOWER on IntegriCloud