sysfs: remove exports of sysfs_*change_owner()
Greg Kroah-Hartman
maintainerPATCH 1/2 sysfs: remove exports of sysfs_*change_owner()
Both sysfs_change_owner() and sysfs_file_change_owner() are exported to modules, but there are no in-kernel module users, so remove the exports so that crazy out-of-tree drivers don't get the impression that it is safe to call these functions at all.
--- fs/sysfs/file.c | 2 -- 1 file changed, 2 deletions(-)
fs/sysfs/file.c +0 -2
@@ -689,7 +689,6 @@ int sysfs_file_change_owner(struct kobject *kobj, const char *name, kuid_t kuid,return error; } -EXPORT_SYMBOL_GPL (sysfs_file_change_owner);/** * sysfs_change_owner - change owner of the given object.
@@ -736,7 +735,6 @@ int sysfs_change_owner(struct kobject *kobj, kuid_t kuid, kgid_t kgid)return 0 ; } -EXPORT_SYMBOL_GPL (sysfs_change_owner);/** * sysfs_emit - scnprintf equivalent, aware of PAGE_SIZE buffer.
Signature · 1 line
2.53.0
Greg Kroah-Hartman
maintainerPATCH 2/2 driver core: remove device_change_owner() export
The function, device_change_owner() is exported for modules to use, but there are no in-kernel users of it, so remove the export to prevent out-of-tree code from thinking this is a safe function to call.
--- drivers/base/core.c | 1 - 1 file changed, 1 deletion(-)
drivers/base/core.c +0 -1
@@ -4781,7 +4781,6 @@ int device_change_owner(struct device *dev, kuid_t kuid, kgid_t kgid)put_device (dev);return error; } -EXPORT_SYMBOL_GPL (device_change_owner);/** * device_shutdown - call ->shutdown() on each device to shutdown.
Signature · 1 line
2.53.0
Re: [PATCH 2/2] driver core: remove device_change_owner() export
Quoted 5 lines · Greg Kroah-Hartman
The function,
device_change_owner()is exported for modules to use, but there are no in-kernel users of it, so remove the export to prevent out-of-tree code from thinking this is a safe function to call.Signed-off-by Greg Kroah-Hartman <[email protected]>
Re: [PATCH 2/2] driver core: remove device_change_owner() export
In reply to Greg Kroah-HartmanQuoted 6 lines · Greg Kroah-Hartman
The function,
device_change_owner()is exported for modules to use, but there are no in-kernel users of it, so remove the export to prevent out-of-tree code from thinking this is a safe function to call.Signed-off-by Greg Kroah-Hartman <[email protected]>
Quoted 19 lines
--- drivers/base/core.c | 1 - 1 file changed, 1 deletion(-)drivers/base/core.c +0
-2@@ -4781,7 +4781,6 @@ int device_change_owner(struct device *dev, kuid_t kuid, kgid_t kgid)put_device (dev);return error; } -EXPORT_SYMBOL_GPL (device_change_owner);/** * device_shutdown - call ->shutdown() on each device to shutdown. -- 2.53.0
Quoted 6 lines · Greg Kroah-Hartman
Both
sysfs_change_owner()andsysfs_file_change_owner()are exported to modules, but there are no in-kernel module users, so remove the exports so that crazy out-of-tree drivers don't get the impression that it is safe to call these functions at all.Signed-off-by Greg Kroah-Hartman <[email protected]>
Quoted 7 lines · Greg Kroah-Hartman
Both
sysfs_change_owner()andsysfs_file_change_owner()are exported to modules, but there are no in-kernel module users, so remove the exports so that crazy out-of-tree drivers don't get the impression that it is safe to call these functions at all.Signed-off-by Greg Kroah-Hartman <[email protected]>
Quoted 27 lines
--- fs/sysfs/file.c | 2 -- 1 file changed, 2 deletions(-)fs/sysfs/file.c +0
-3@@ -689,7 +689,6 @@ int sysfs_file_change_owner(struct kobject *kobj, const char *name, kuid_t kuid,return error; } -EXPORT_SYMBOL_GPL (sysfs_file_change_owner);/** * sysfs_change_owner - change owner of the given object. @@ -736,7 +735,6 @@ int sysfs_change_owner(struct kobject *kobj, kuid_t kuid, kgid_t kgid)return 0 ; } -EXPORT_SYMBOL_GPL (sysfs_change_owner);/** * sysfs_emit - scnprintf equivalent, aware of PAGE_SIZE buffer. -- 2.53.0
Quoted 6 lines · Greg Kroah-Hartman
Both
sysfs_change_owner()andsysfs_file_change_owner()are exported to modules, but there are no in-kernel module users, so remove the exports so that crazy out-of-tree drivers don't get the impression that it is safe to call these functions at all.Signed-off-by Greg Kroah-Hartman <[email protected]>
:)
Quoted 27 lines
--- fs/sysfs/file.c | 2 -- 1 file changed, 2 deletions(-)fs/sysfs/file.c +0
-2@@ -689,7 +689,6 @@ int sysfs_file_change_owner(struct kobject *kobj, const char *name, kuid_t kuid,return error; } -EXPORT_SYMBOL_GPL (sysfs_file_change_owner);/** * sysfs_change_owner - change owner of the given object. @@ -736,7 +735,6 @@ int sysfs_change_owner(struct kobject *kobj, kuid_t kuid, kgid_t kgid)return 0 ; } -EXPORT_SYMBOL_GPL (sysfs_change_owner);/** * sysfs_emit - scnprintf equivalent, aware of PAGE_SIZE buffer. Signature · 1 line
2.53.0
Signature · 1 line
Lee Jones [李琼斯]