aboutsummaryrefslogtreecommitdiffstats
path: root/fs/sysfs/sysfs.h
diff options
context:
space:
mode:
authorTejun Heo <htejun@gmail.com>2007-08-02 08:38:03 -0400
committerGreg Kroah-Hartman <gregkh@suse.de>2007-10-12 17:51:04 -0400
commit23dc279950a056c33a14d09cf759f5173d41abd9 (patch)
tree852f8cc24c24988717dbae8f98da999ff27755fa /fs/sysfs/sysfs.h
parent41fc1c27452e041a18e5141b8203ee0ea72bc483 (diff)
sysfs: make sysfs_add_one() automatically check for duplicate entry
Make sysfs_add_one() check for duplicate entry and return -EEXIST if such entry exists. This simplifies node addition code a bit. This patch doesn't introduce any noticeable behavior change. Signed-off-by: Tejun Heo <htejun@gmail.com> Acked-by: Cornelia Huck <cornelia.huck@de.ibm.com> Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
Diffstat (limited to 'fs/sysfs/sysfs.h')
-rw-r--r--fs/sysfs/sysfs.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/fs/sysfs/sysfs.h b/fs/sysfs/sysfs.h
index 32b8b64e5cf1..bb3f0c999b15 100644
--- a/fs/sysfs/sysfs.h
+++ b/fs/sysfs/sysfs.h
@@ -62,7 +62,7 @@ extern struct sysfs_dirent *sysfs_get_active_two(struct sysfs_dirent *sd);
62extern void sysfs_put_active_two(struct sysfs_dirent *sd); 62extern void sysfs_put_active_two(struct sysfs_dirent *sd);
63extern void sysfs_addrm_start(struct sysfs_addrm_cxt *acxt, 63extern void sysfs_addrm_start(struct sysfs_addrm_cxt *acxt,
64 struct sysfs_dirent *parent_sd); 64 struct sysfs_dirent *parent_sd);
65extern void sysfs_add_one(struct sysfs_addrm_cxt *acxt, 65extern int sysfs_add_one(struct sysfs_addrm_cxt *acxt,
66 struct sysfs_dirent *sd); 66 struct sysfs_dirent *sd);
67extern void sysfs_remove_one(struct sysfs_addrm_cxt *acxt, 67extern void sysfs_remove_one(struct sysfs_addrm_cxt *acxt,
68 struct sysfs_dirent *sd); 68 struct sysfs_dirent *sd);