aboutsummaryrefslogtreecommitdiffstats
path: root/fs/ecryptfs/ecryptfs_kernel.h
diff options
context:
space:
mode:
authorMichael Halcrow <mhalcrow@us.ibm.com>2007-10-16 04:28:08 -0400
committerLinus Torvalds <torvalds@woody.linux-foundation.org>2007-10-16 12:43:12 -0400
commit0216f7f7921759211e48e8b940eae29f0fe43902 (patch)
tree44999b1dfb49944bfd83881c8d9e0cbe3a90e2b7 /fs/ecryptfs/ecryptfs_kernel.h
parentda0102a10aed2244d8fc34f289e81e502622b81e (diff)
eCryptfs: replace encrypt, decrypt, and inode size write
Replace page encryption and decryption routines and inode size write routine with versions that utilize the read_write.c functions. Signed-off-by: Michael Halcrow <mhalcrow@us.ibm.com> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/ecryptfs/ecryptfs_kernel.h')
-rw-r--r--fs/ecryptfs/ecryptfs_kernel.h14
1 files changed, 5 insertions, 9 deletions
diff --git a/fs/ecryptfs/ecryptfs_kernel.h b/fs/ecryptfs/ecryptfs_kernel.h
index e6a68a87b5df..65f7ddfd4d4a 100644
--- a/fs/ecryptfs/ecryptfs_kernel.h
+++ b/fs/ecryptfs/ecryptfs_kernel.h
@@ -552,13 +552,7 @@ void ecryptfs_destroy_crypt_stat(struct ecryptfs_crypt_stat *crypt_stat);
552void ecryptfs_destroy_mount_crypt_stat( 552void ecryptfs_destroy_mount_crypt_stat(
553 struct ecryptfs_mount_crypt_stat *mount_crypt_stat); 553 struct ecryptfs_mount_crypt_stat *mount_crypt_stat);
554int ecryptfs_init_crypt_ctx(struct ecryptfs_crypt_stat *crypt_stat); 554int ecryptfs_init_crypt_ctx(struct ecryptfs_crypt_stat *crypt_stat);
555#define ECRYPTFS_LOWER_I_MUTEX_NOT_HELD 0 555int ecryptfs_write_inode_size_to_metadata(struct inode *ecryptefs_inode);
556#define ECRYPTFS_LOWER_I_MUTEX_HELD 1
557int ecryptfs_write_inode_size_to_metadata(struct file *lower_file,
558 struct inode *lower_inode,
559 struct inode *inode,
560 struct dentry *ecryptfs_dentry,
561 int lower_i_mutex_held);
562int ecryptfs_get_lower_page(struct page **lower_page, struct inode *lower_inode, 556int ecryptfs_get_lower_page(struct page **lower_page, struct inode *lower_inode,
563 struct file *lower_file, 557 struct file *lower_file,
564 unsigned long lower_page_index, int byte_offset, 558 unsigned long lower_page_index, int byte_offset,
@@ -574,8 +568,8 @@ int ecryptfs_do_readpage(struct file *file, struct page *page,
574int ecryptfs_writepage_and_release_lower_page(struct page *lower_page, 568int ecryptfs_writepage_and_release_lower_page(struct page *lower_page,
575 struct inode *lower_inode, 569 struct inode *lower_inode,
576 struct writeback_control *wbc); 570 struct writeback_control *wbc);
577int ecryptfs_encrypt_page(struct ecryptfs_page_crypt_context *ctx); 571int ecryptfs_encrypt_page(struct page *page);
578int ecryptfs_decrypt_page(struct file *file, struct page *page); 572int ecryptfs_decrypt_page(struct page *page);
579int ecryptfs_write_metadata(struct dentry *ecryptfs_dentry, 573int ecryptfs_write_metadata(struct dentry *ecryptfs_dentry,
580 struct file *lower_file); 574 struct file *lower_file);
581int ecryptfs_read_metadata(struct dentry *ecryptfs_dentry, 575int ecryptfs_read_metadata(struct dentry *ecryptfs_dentry,
@@ -655,6 +649,8 @@ int ecryptfs_keyring_auth_tok_for_sig(struct key **auth_tok_key,
655 char *sig); 649 char *sig);
656int ecryptfs_write_zeros(struct file *file, pgoff_t index, int start, 650int ecryptfs_write_zeros(struct file *file, pgoff_t index, int start,
657 int num_zeros); 651 int num_zeros);
652void ecryptfs_lower_offset_for_extent(loff_t *offset, loff_t extent_num,
653 struct ecryptfs_crypt_stat *crypt_stat);
658int ecryptfs_write_lower(struct inode *ecryptfs_inode, char *data, 654int ecryptfs_write_lower(struct inode *ecryptfs_inode, char *data,
659 loff_t offset, size_t size); 655 loff_t offset, size_t size);
660int ecryptfs_write_lower_page_segment(struct inode *ecryptfs_inode, 656int ecryptfs_write_lower_page_segment(struct inode *ecryptfs_inode,