The patch titled fix the sysfs_add_file_to_group interfaces has been added to the -mm tree. Its filename is fix-the-sysfs_add_file_to_group-interfaces.patch *** Remember to use Documentation/SubmitChecklist when testing your code *** See http://www.zip.com.au/~akpm/linux/patches/stuff/added-to-mm.txt to find out what to do about this The current -mm tree may be found at http://userweb.kernel.org/~akpm/mmotm/ ------------------------------------------------------ Subject: fix the sysfs_add_file_to_group interfaces From: James Bottomley <James.Bottomley@xxxxxxxxxxxxxxxxxxxxx> I can't see a reason why these shouldn't work on every group. However, they only seem to work on named groups. This patch allows the group functions to work on anonymous groups (those with NULL names). Signed-off-by: James Bottomley <James.Bottomley@xxxxxxxxxxxxxxxxxxxxx> Cc: Kay Sievers <kay.sievers@xxxxxxxx> Cc: Greg KH <greg@xxxxxxxxx> Signed-off-by: Andrew Morton <akpm@xxxxxxxxxxxxxxxxxxxx> --- fs/sysfs/file.c | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff -puN fs/sysfs/file.c~fix-the-sysfs_add_file_to_group-interfaces fs/sysfs/file.c --- a/fs/sysfs/file.c~fix-the-sysfs_add_file_to_group-interfaces +++ a/fs/sysfs/file.c @@ -537,7 +537,11 @@ int sysfs_add_file_to_group(struct kobje struct sysfs_dirent *dir_sd; int error; - dir_sd = sysfs_get_dirent(kobj->sd, group); + if (group) + dir_sd = sysfs_get_dirent(kobj->sd, group); + else + dir_sd = sysfs_get(kobj->sd); + if (!dir_sd) return -ENOENT; @@ -625,7 +629,10 @@ void sysfs_remove_file_from_group(struct { struct sysfs_dirent *dir_sd; - dir_sd = sysfs_get_dirent(kobj->sd, group); + if (group) + dir_sd = sysfs_get_dirent(kobj->sd, group); + else + dir_sd = sysfs_get(kobj->sd); if (dir_sd) { sysfs_hash_and_remove(dir_sd, attr->name); sysfs_put(dir_sd); _ Patches currently in -mm which might be from James.Bottomley@xxxxxxxxxxxxxxxxxxxxx are fix-the-sysfs_add_file_to_group-interfaces.patch attribute_container-update-to-use-the-group-interface.patch git-scsi-misc.patch scsi-pending-arm-convert-to-accessors.patch - To unsubscribe from this list: send the line "unsubscribe mm-commits" in the body of a message to majordomo@xxxxxxxxxxxxxxx More majordomo info at http://vger.kernel.org/majordomo-info.html