]> git.baikalelectronics.ru Git - kernel.git/commit
sysfs: add sysfs_file_change_owner()
authorChristian Brauner <christian.brauner@ubuntu.com>
Thu, 27 Feb 2020 03:37:11 +0000 (04:37 +0100)
committerDavid S. Miller <davem@davemloft.net>
Thu, 27 Feb 2020 04:07:25 +0000 (20:07 -0800)
commitaabef34af0da42affd2d9e913359f718286d09c6
treefa62764ac154c9e86c2fa446aa534eebefeedb32
parent5bceaa1fd2c2ca8cd5c8b9e4639dc5653388e8b3
sysfs: add sysfs_file_change_owner()

Add helpers to change the owner of a sysfs files.
This function will be used to correctly account for kobject ownership
changes, e.g. when moving network devices between network namespaces.

Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
fs/sysfs/file.c
include/linux/sysfs.h