diff options
| author | Ricardo B. Marliere <[email protected]> | 2024-02-04 14:40:17 +0000 |
|---|---|---|
| committer | Ilpo Järvinen <[email protected]> | 2024-02-06 09:58:03 +0000 |
| commit | 41b43c75121208a9e4e84fd148f918bddb3f5d1f (patch) | |
| tree | 2334f6163233f1f6962196e47876f21deb15929c /drivers/platform/x86/ibm_rtl.c | |
| parent | platform: x86: wmi: make wmi_bus_type const (diff) | |
| download | kernel-41b43c75121208a9e4e84fd148f918bddb3f5d1f.tar.gz kernel-41b43c75121208a9e4e84fd148f918bddb3f5d1f.zip | |
platform: x86: ibm_rtl: make rtl_subsys const
Now that the driver core can properly handle constant struct bus_type,
move the rtl_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 <[email protected]>
Suggested-by: Greg Kroah-Hartman <[email protected]>
Signed-off-by: "Ricardo B. Marliere" <[email protected]>
Link: https://lore.kernel.org/r/20240204-bus_cleanup-platform-drivers-x86-v1-2-1f0839b385c6@marliere.net
Reviewed-by: Ilpo Järvinen <[email protected]>
Signed-off-by: Ilpo Järvinen <[email protected]>
Diffstat (limited to 'drivers/platform/x86/ibm_rtl.c')
| -rw-r--r-- | drivers/platform/x86/ibm_rtl.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/drivers/platform/x86/ibm_rtl.c b/drivers/platform/x86/ibm_rtl.c index 2ab7d9ac542d..1d4bbae115f1 100644 --- a/drivers/platform/x86/ibm_rtl.c +++ b/drivers/platform/x86/ibm_rtl.c @@ -179,7 +179,7 @@ static ssize_t rtl_set_state(struct device *dev, return ret; } -static struct bus_type rtl_subsys = { +static const struct bus_type rtl_subsys = { .name = "ibm_rtl", .dev_name = "ibm_rtl", }; |
