mirror of
https://git.kernel.org/pub/scm/linux/kernel/git/netdev/net.git/
synced 2026-04-05 00:07:48 -04:00
nvmem: make nvmem_bus_type constant
Now that the driver core can properly handle constant struct bus_type, move the nvmem_bus_type variable to be a constant structure as well, placing it into read-only memory which can not be modified at runtime. Cc: Srinivas Kandagatla <srini@kernel.org> Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: Srinivas Kandagatla <srini@kernel.org> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Link: https://lore.kernel.org/r/20250712181905.6738-6-srini@kernel.org Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
@@ -544,7 +544,7 @@ static const struct device_type nvmem_provider_type = {
|
||||
.release = nvmem_release,
|
||||
};
|
||||
|
||||
static struct bus_type nvmem_bus_type = {
|
||||
static const struct bus_type nvmem_bus_type = {
|
||||
.name = "nvmem",
|
||||
};
|
||||
|
||||
|
||||
Reference in New Issue
Block a user