summaryrefslogtreecommitdiff
path: root/Documentation/admin-guide
diff options
context:
space:
mode:
authorRajat Jain <rajatja@google.com>2018-06-16 20:49:46 +0300
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2018-07-07 18:54:46 +0300
commitc855cf2759d27142f771173d9fd8e7fdf9cf5138 (patch)
treebdca38399864bfa1900851f1ef1f6248b9debf5a /Documentation/admin-guide
parent319b11ef5719a2f0ae65ce5f665f263a5e7a06c3 (diff)
downloadlinux-c855cf2759d27142f771173d9fd8e7fdf9cf5138.tar.xz
sysfs: Fix internal_create_group() for named group updates
There are a couple of problems with named group updates in the code today: * sysfs_update_group() will always fail for a named group, because internal_create_group() will try to create a new sysfs directory unconditionally, which will ofcourse fail with -EEXIST. * We can leak the kernfs_node for grp->name if some one tries to: - rename a group (change grp->name), or - update a named group, to an unnamed group It appears that the whole purpose of sysfs_update_group() was to allow changing the permissions or visibility of attributes and not the names. So make it clear in the comments, and allow it to update an existing named group. Signed-off-by: Rajat Jain <rajatja@google.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'Documentation/admin-guide')
0 files changed, 0 insertions, 0 deletions