spi: make spi_bus_type const
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>
Fri, 5 Jan 2024 10:32:50 +0000 (11:32 +0100)
committerMark Brown <broonie@kernel.org>
Mon, 22 Jan 2024 00:06:53 +0000 (00:06 +0000)
commit6df534cc7136fc9e023cbd4e0011a04e3659e74d
tree053cdf919817f3b4cb12db3d318fe020ab75382c
parent4247d7f2ca564bbede54054da1f35a359bb061bd
spi: make spi_bus_type const

Now that the driver core can properly handle constant struct bus_type,
move the spi_bus_type variable to be a constant structure as well,
placing it into read-only memory which can not be modified at runtime.

Cc: Mark Brown <broonie@kernel.org>
Cc: <linux-spi@vger.kernel.org>
Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Link: https://msgid.link/r/2024010549-erasure-swoop-1cc6@gregkh
Signed-off-by: Mark Brown <broonie@kernel.org>
drivers/spi/spi.c
include/linux/spi/spi.h