aboutsummaryrefslogtreecommitdiffstats
path: root/fs/configfs/symlink.c
diff options
context:
space:
mode:
Diffstat (limited to 'fs/configfs/symlink.c')
-rw-r--r--fs/configfs/symlink.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/fs/configfs/symlink.c b/fs/configfs/symlink.c
index 0004d18c40ac..c12801a12c34 100644
--- a/fs/configfs/symlink.c
+++ b/fs/configfs/symlink.c
@@ -78,6 +78,12 @@ static int create_link(struct config_item *parent_item,
78 if (sl) { 78 if (sl) {
79 sl->sl_target = config_item_get(item); 79 sl->sl_target = config_item_get(item);
80 spin_lock(&configfs_dirent_lock); 80 spin_lock(&configfs_dirent_lock);
81 if (target_sd->s_type & CONFIGFS_USET_DROPPING) {
82 spin_unlock(&configfs_dirent_lock);
83 config_item_put(item);
84 kfree(sl);
85 return -ENOENT;
86 }
81 list_add(&sl->sl_list, &target_sd->s_links); 87 list_add(&sl->sl_list, &target_sd->s_links);
82 spin_unlock(&configfs_dirent_lock); 88 spin_unlock(&configfs_dirent_lock);
83 ret = configfs_create_link(sl, parent_item->ci_dentry, 89 ret = configfs_create_link(sl, parent_item->ci_dentry,