diff options
author | Jeff Layton <jlayton@redhat.com> | 2013-07-16 09:16:45 -0400 |
---|---|---|
committer | Trond Myklebust <Trond.Myklebust@netapp.com> | 2013-07-23 18:18:53 -0400 |
commit | 275448eb10cfb2b09b34b0b08498a3401222b413 (patch) | |
tree | b0a5b06a1b1cfb6a234d3ef7353cffc2de5bf521 /net/sunrpc/rpc_pipe.c | |
parent | cc7936f9ad085351bc2ccb403c403392e1337050 (diff) |
rpc_pipe: convert back to simple_dir_inode_operations
Now that Al has fixed simple_lookup to account for the case where
sb->s_d_op is set, there's no need to keep our own special lookup op.
Signed-off-by: Jeff Layton <jlayton@redhat.com>
Signed-off-by: Trond Myklebust <Trond.Myklebust@netapp.com>
Diffstat (limited to 'net/sunrpc/rpc_pipe.c')
-rw-r--r-- | net/sunrpc/rpc_pipe.c | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/net/sunrpc/rpc_pipe.c b/net/sunrpc/rpc_pipe.c index 406859cc68aa..017aedc8a7a1 100644 --- a/net/sunrpc/rpc_pipe.c +++ b/net/sunrpc/rpc_pipe.c | |||
@@ -480,23 +480,6 @@ static const struct dentry_operations rpc_dentry_operations = { | |||
480 | .d_delete = rpc_delete_dentry, | 480 | .d_delete = rpc_delete_dentry, |
481 | }; | 481 | }; |
482 | 482 | ||
483 | /* | ||
484 | * Lookup the data. This is trivial - if the dentry didn't already | ||
485 | * exist, we know it is negative. | ||
486 | */ | ||
487 | static struct dentry * | ||
488 | rpc_lookup(struct inode *dir, struct dentry *dentry, unsigned int flags) | ||
489 | { | ||
490 | if (dentry->d_name.len > NAME_MAX) | ||
491 | return ERR_PTR(-ENAMETOOLONG); | ||
492 | d_add(dentry, NULL); | ||
493 | return NULL; | ||
494 | } | ||
495 | |||
496 | static const struct inode_operations rpc_dir_inode_operations = { | ||
497 | .lookup = rpc_lookup, | ||
498 | }; | ||
499 | |||
500 | static struct inode * | 483 | static struct inode * |
501 | rpc_get_inode(struct super_block *sb, umode_t mode) | 484 | rpc_get_inode(struct super_block *sb, umode_t mode) |
502 | { | 485 | { |
@@ -509,7 +492,7 @@ rpc_get_inode(struct super_block *sb, umode_t mode) | |||
509 | switch (mode & S_IFMT) { | 492 | switch (mode & S_IFMT) { |
510 | case S_IFDIR: | 493 | case S_IFDIR: |
511 | inode->i_fop = &simple_dir_operations; | 494 | inode->i_fop = &simple_dir_operations; |
512 | inode->i_op = &rpc_dir_inode_operations; | 495 | inode->i_op = &simple_dir_inode_operations; |
513 | inc_nlink(inode); | 496 | inc_nlink(inode); |
514 | default: | 497 | default: |
515 | break; | 498 | break; |