diff options
author | Linus Torvalds <torvalds@linux-foundation.org> | 2011-01-13 20:19:38 -0500 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2011-01-13 20:19:38 -0500 |
commit | 6254b32b5791e47ba1c679d023f26985fa34755a (patch) | |
tree | 121faecbf6c17732ee620fd68009e3e24205340e /fs/ecryptfs | |
parent | 2a86cb7c2b1e9eb98b36d0a3cf4444d8851968b1 (diff) |
ecryptfs: fix broken build
Stephen Rothwell reports that the vfs merge broke the build of ecryptfs.
The breakage comes from commit 66cb76666d69 ("sanitize ecryptfs
->mount()") which was obviously not even build tested. Tssk, tssk, Al.
This is the minimal build fixup for the situation, although I don't have
a filesystem to actually test it with.
Reported-by: Stephen Rothwell <sfr@canb.auug.org.au>
Cc: Al Viro <viro@zeniv.linux.org.uk>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'fs/ecryptfs')
-rw-r--r-- | fs/ecryptfs/main.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/fs/ecryptfs/main.c b/fs/ecryptfs/main.c index 9ed476906327..d3b28abdd6aa 100644 --- a/fs/ecryptfs/main.c +++ b/fs/ecryptfs/main.c | |||
@@ -141,13 +141,12 @@ int ecryptfs_init_persistent_file(struct dentry *ecryptfs_dentry) | |||
141 | return rc; | 141 | return rc; |
142 | } | 142 | } |
143 | 143 | ||
144 | static inode *ecryptfs_get_inode(struct inode *lower_inode, | 144 | static struct inode *ecryptfs_get_inode(struct inode *lower_inode, |
145 | struct super_block *sb) | 145 | struct super_block *sb) |
146 | { | 146 | { |
147 | struct inode *inode; | 147 | struct inode *inode; |
148 | int rc = 0; | 148 | int rc = 0; |
149 | 149 | ||
150 | lower_inode = lower_dentry->d_inode; | ||
151 | if (lower_inode->i_sb != ecryptfs_superblock_to_lower(sb)) { | 150 | if (lower_inode->i_sb != ecryptfs_superblock_to_lower(sb)) { |
152 | rc = -EXDEV; | 151 | rc = -EXDEV; |
153 | goto out; | 152 | goto out; |
@@ -202,7 +201,7 @@ int ecryptfs_interpose(struct dentry *lower_dentry, struct dentry *dentry, | |||
202 | { | 201 | { |
203 | struct inode *lower_inode = lower_dentry->d_inode; | 202 | struct inode *lower_inode = lower_dentry->d_inode; |
204 | struct inode *inode = ecryptfs_get_inode(lower_inode, sb); | 203 | struct inode *inode = ecryptfs_get_inode(lower_inode, sb); |
205 | if (IS_ERR(inode) | 204 | if (IS_ERR(inode)) |
206 | return PTR_ERR(inode); | 205 | return PTR_ERR(inode); |
207 | if (flags & ECRYPTFS_INTERPOSE_FLAG_D_ADD) | 206 | if (flags & ECRYPTFS_INTERPOSE_FLAG_D_ADD) |
208 | d_add(dentry, inode); | 207 | d_add(dentry, inode); |