diff options
author | Al Viro <viro@zeniv.linux.org.uk> | 2013-09-15 20:50:13 -0400 |
---|---|---|
committer | Al Viro <viro@zeniv.linux.org.uk> | 2013-10-24 23:34:48 -0400 |
commit | 92dd123033d50051d1352fada1bad91c22a119cf (patch) | |
tree | d484a1611ec94750fa80b4f4f86c055c7399d6fb /fs/ecryptfs | |
parent | 2edbfbf1c1ab0aeb58ce8abfb69b6f6b63542848 (diff) |
ecryptfs: get rid of ecryptfs_set_dentry_lower{,_mnt}
Signed-off-by: Al Viro <viro@zeniv.linux.org.uk>
Diffstat (limited to 'fs/ecryptfs')
-rw-r--r-- | fs/ecryptfs/ecryptfs_kernel.h | 14 | ||||
-rw-r--r-- | fs/ecryptfs/inode.c | 4 | ||||
-rw-r--r-- | fs/ecryptfs/main.c | 3 |
3 files changed, 3 insertions, 18 deletions
diff --git a/fs/ecryptfs/ecryptfs_kernel.h b/fs/ecryptfs/ecryptfs_kernel.h index e7ad2b3f24a7..90d1882b306f 100644 --- a/fs/ecryptfs/ecryptfs_kernel.h +++ b/fs/ecryptfs/ecryptfs_kernel.h | |||
@@ -515,13 +515,6 @@ ecryptfs_dentry_to_lower(struct dentry *dentry) | |||
515 | return ((struct ecryptfs_dentry_info *)dentry->d_fsdata)->lower_path.dentry; | 515 | return ((struct ecryptfs_dentry_info *)dentry->d_fsdata)->lower_path.dentry; |
516 | } | 516 | } |
517 | 517 | ||
518 | static inline void | ||
519 | ecryptfs_set_dentry_lower(struct dentry *dentry, struct dentry *lower_dentry) | ||
520 | { | ||
521 | ((struct ecryptfs_dentry_info *)dentry->d_fsdata)->lower_path.dentry = | ||
522 | lower_dentry; | ||
523 | } | ||
524 | |||
525 | static inline struct vfsmount * | 518 | static inline struct vfsmount * |
526 | ecryptfs_dentry_to_lower_mnt(struct dentry *dentry) | 519 | ecryptfs_dentry_to_lower_mnt(struct dentry *dentry) |
527 | { | 520 | { |
@@ -534,13 +527,6 @@ ecryptfs_dentry_to_lower_path(struct dentry *dentry) | |||
534 | return &((struct ecryptfs_dentry_info *)dentry->d_fsdata)->lower_path; | 527 | return &((struct ecryptfs_dentry_info *)dentry->d_fsdata)->lower_path; |
535 | } | 528 | } |
536 | 529 | ||
537 | static inline void | ||
538 | ecryptfs_set_dentry_lower_mnt(struct dentry *dentry, struct vfsmount *lower_mnt) | ||
539 | { | ||
540 | ((struct ecryptfs_dentry_info *)dentry->d_fsdata)->lower_path.mnt = | ||
541 | lower_mnt; | ||
542 | } | ||
543 | |||
544 | #define ecryptfs_printk(type, fmt, arg...) \ | 530 | #define ecryptfs_printk(type, fmt, arg...) \ |
545 | __ecryptfs_printk(type "%s: " fmt, __func__, ## arg); | 531 | __ecryptfs_printk(type "%s: " fmt, __func__, ## arg); |
546 | __printf(1, 2) | 532 | __printf(1, 2) |
diff --git a/fs/ecryptfs/inode.c b/fs/ecryptfs/inode.c index 67e9b6339691..2ca62c40c6c2 100644 --- a/fs/ecryptfs/inode.c +++ b/fs/ecryptfs/inode.c | |||
@@ -361,8 +361,8 @@ static int ecryptfs_lookup_interpose(struct dentry *dentry, | |||
361 | BUG_ON(!d_count(lower_dentry)); | 361 | BUG_ON(!d_count(lower_dentry)); |
362 | 362 | ||
363 | ecryptfs_set_dentry_private(dentry, dentry_info); | 363 | ecryptfs_set_dentry_private(dentry, dentry_info); |
364 | ecryptfs_set_dentry_lower(dentry, lower_dentry); | 364 | dentry_info->lower_path.mnt = lower_mnt; |
365 | ecryptfs_set_dentry_lower_mnt(dentry, lower_mnt); | 365 | dentry_info->lower_path.dentry = lower_dentry; |
366 | 366 | ||
367 | if (!lower_dentry->d_inode) { | 367 | if (!lower_dentry->d_inode) { |
368 | /* We want to add because we couldn't find in lower */ | 368 | /* We want to add because we couldn't find in lower */ |
diff --git a/fs/ecryptfs/main.c b/fs/ecryptfs/main.c index eb1c5979ecaf..1b119d3bf924 100644 --- a/fs/ecryptfs/main.c +++ b/fs/ecryptfs/main.c | |||
@@ -585,8 +585,7 @@ static struct dentry *ecryptfs_mount(struct file_system_type *fs_type, int flags | |||
585 | 585 | ||
586 | /* ->kill_sb() will take care of root_info */ | 586 | /* ->kill_sb() will take care of root_info */ |
587 | ecryptfs_set_dentry_private(s->s_root, root_info); | 587 | ecryptfs_set_dentry_private(s->s_root, root_info); |
588 | ecryptfs_set_dentry_lower(s->s_root, path.dentry); | 588 | root_info->lower_path = path; |
589 | ecryptfs_set_dentry_lower_mnt(s->s_root, path.mnt); | ||
590 | 589 | ||
591 | s->s_flags |= MS_ACTIVE; | 590 | s->s_flags |= MS_ACTIVE; |
592 | return dget(s->s_root); | 591 | return dget(s->s_root); |