netdevsim: make nsim_bus const
authorRicardo B. Marliere <ricardo@marliere.net>
Sun, 4 Feb 2024 20:16:34 +0000 (17:16 -0300)
committerDavid S. Miller <davem@davemloft.net>
Wed, 7 Feb 2024 13:40:27 +0000 (13:40 +0000)
commit56b93cd358b304b2d1945c0330dffe8f872bc0d3
tree25147a4ecf9ce2cef9bf68a0ce43fb2c03d1217a
parent59d6bccebe5c747d6f4dcbc4862ad7b52571b3fc
netdevsim: make nsim_bus const

Now that the driver core can properly handle constant struct bus_type,
move the nsim_bus 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-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Ricardo B. Marliere <ricardo@marliere.net>
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: David S. Miller <davem@davemloft.net>
drivers/net/netdevsim/bus.c