diff options
| -rw-r--r-- | fs/debugfs/inode.c | 11 |
1 files changed, 2 insertions, 9 deletions
diff --git a/fs/debugfs/inode.c b/fs/debugfs/inode.c index 18564b08884c..c69e00d69ff1 100644 --- a/fs/debugfs/inode.c +++ b/fs/debugfs/inode.c | |||
| @@ -103,14 +103,6 @@ static int debugfs_mkdir(struct dentry *dentry, umode_t mode) | |||
| 103 | return res; | 103 | return res; |
| 104 | } | 104 | } |
| 105 | 105 | ||
| 106 | static int debugfs_link(struct dentry *dentry, umode_t mode, | ||
| 107 | void *data) | ||
| 108 | { | ||
| 109 | struct inode *dir = dentry->d_parent->d_inode; | ||
| 110 | mode = (mode & S_IALLUGO) | S_IFLNK; | ||
| 111 | return debugfs_mknod(dir, dentry, mode, 0, data, NULL); | ||
| 112 | } | ||
| 113 | |||
| 114 | static int debugfs_create(struct dentry *dentry, umode_t mode, | 106 | static int debugfs_create(struct dentry *dentry, umode_t mode, |
| 115 | void *data, const struct file_operations *fops) | 107 | void *data, const struct file_operations *fops) |
| 116 | { | 108 | { |
| @@ -466,7 +458,8 @@ struct dentry *debugfs_create_symlink(const char *name, struct dentry *parent, | |||
| 466 | return NULL; | 458 | return NULL; |
| 467 | } | 459 | } |
| 468 | 460 | ||
| 469 | error = debugfs_link(dentry, S_IFLNK | S_IRWXUGO, link); | 461 | error = debugfs_mknod(dentry->d_parent->d_inode, dentry, |
| 462 | S_IFLNK | S_IRWXUGO, 0, link, NULL); | ||
| 470 | if (error) | 463 | if (error) |
| 471 | kfree(link); | 464 | kfree(link); |
| 472 | 465 | ||
