diff options
author | David S. Miller <davem@davemloft.net> | 2008-07-27 04:40:08 -0700 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2008-07-27 04:40:08 -0700 |
commit | 15d3b4a26291c170563e2b25ded5de1324f93959 (patch) | |
tree | 9bea548a7de5215c58a091d58f4eefdb92349f2c /fs/sysfs | |
parent | 2c3abab7c95295f319dc8899b74cbd60140fcdfb (diff) | |
parent | 8be1a6d6c77ab4532e4476fdb8177030ef48b52c (diff) |
Merge branch 'master' of master.kernel.org:/pub/scm/linux/kernel/git/torvalds/linux-2.6
Diffstat (limited to 'fs/sysfs')
-rw-r--r-- | fs/sysfs/dir.c | 5 | ||||
-rw-r--r-- | fs/sysfs/file.c | 3 | ||||
-rw-r--r-- | fs/sysfs/group.c | 3 |
3 files changed, 3 insertions, 8 deletions
diff --git a/fs/sysfs/dir.c b/fs/sysfs/dir.c index c1a7efb310b..aedaeba82ae 100644 --- a/fs/sysfs/dir.c +++ b/fs/sysfs/dir.c @@ -459,11 +459,8 @@ int sysfs_add_one(struct sysfs_addrm_cxt *acxt, struct sysfs_dirent *sd) int ret; ret = __sysfs_add_one(acxt, sd); - if (ret == -EEXIST) { - printk(KERN_WARNING "sysfs: duplicate filename '%s' " + WARN(ret == -EEXIST, KERN_WARNING "sysfs: duplicate filename '%s' " "can not be created\n", sd->s_name); - WARN_ON(1); - } return ret; } diff --git a/fs/sysfs/file.c b/fs/sysfs/file.c index 3f07893ff89..c9e4e5091da 100644 --- a/fs/sysfs/file.c +++ b/fs/sysfs/file.c @@ -337,9 +337,8 @@ static int sysfs_open_file(struct inode *inode, struct file *file) if (kobj->ktype && kobj->ktype->sysfs_ops) ops = kobj->ktype->sysfs_ops; else { - printk(KERN_ERR "missing sysfs attribute operations for " + WARN(1, KERN_ERR "missing sysfs attribute operations for " "kobject: %s\n", kobject_name(kobj)); - WARN_ON(1); goto err_out; } diff --git a/fs/sysfs/group.c b/fs/sysfs/group.c index eeba38417b1..fe611949a7f 100644 --- a/fs/sysfs/group.c +++ b/fs/sysfs/group.c @@ -134,9 +134,8 @@ void sysfs_remove_group(struct kobject * kobj, if (grp->name) { sd = sysfs_get_dirent(dir_sd, grp->name); if (!sd) { - printk(KERN_WARNING "sysfs group %p not found for " + WARN(!sd, KERN_WARNING "sysfs group %p not found for " "kobject '%s'\n", grp, kobject_name(kobj)); - WARN_ON(!sd); return; } } else |