diff options
author | Ricardo B. Marliere <ricardo@marliere.net> | 2024-02-04 10:47:05 -0300 |
---|---|---|
committer | Tejun Heo <tj@kernel.org> | 2024-02-04 11:23:25 -1000 |
commit | d412ace11144aa2bf692c7cf9778351efc15c827 (patch) | |
tree | 2a509054146522b3ee24fcd9f7fbb3806ed9bc92 | |
parent | c70e1779b73a39f7648b26bdc835304c60100ce3 (diff) |
workqueue: make wq_subsys const
Now that the driver core can properly handle constant struct bus_type,
move the wq_subsys variable to be a constant structure as well,
placing it into read-only memory which can not be modified at runtime.
Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Suggested-and-reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Ricardo B. Marliere <ricardo@marliere.net>
Signed-off-by: Tejun Heo <tj@kernel.org>
-rw-r--r-- | kernel/workqueue.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/kernel/workqueue.c b/kernel/workqueue.c index 55c9816506b0..695f6f5ad038 100644 --- a/kernel/workqueue.c +++ b/kernel/workqueue.c @@ -6692,7 +6692,7 @@ static struct device_attribute wq_sysfs_unbound_attrs[] = { __ATTR_NULL, }; -static struct bus_type wq_subsys = { +static const struct bus_type wq_subsys = { .name = "workqueue", .dev_groups = wq_sysfs_groups, }; |