mmc: core: constify the struct device_type usage
authorRicardo B. Marliere <ricardo@marliere.net>
Mon, 19 Feb 2024 12:43:57 +0000 (09:43 -0300)
committerUlf Hansson <ulf.hansson@linaro.org>
Tue, 27 Feb 2024 12:48:36 +0000 (13:48 +0100)
commit68f5630ae15407d8d3daaadbbfbafbd319e3ecd4
treed7b1412e20af18877e4b8ee20f938283543639e4
parent017199c2849c3d6d417791ec1cf5521005d663a1
mmc: core: constify the struct device_type usage

Since commit aed65af1cc2f ("drivers: make device_type const"), the driver
core can properly handle constant struct device_type. Move the sdio_type,
sd_type and mmc_type variables to be constant structures as well, placing
it into read-only memory which can not be modified at runtime.

Cc: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Ricardo B. Marliere <ricardo@marliere.net>
Link: https://lore.kernel.org/r/20240219-device_cleanup-mmc-v1-1-1910e283cf5a@marliere.net
Signed-off-by: Ulf Hansson <ulf.hansson@linaro.org>
drivers/mmc/core/bus.c
drivers/mmc/core/bus.h
drivers/mmc/core/mmc.c
drivers/mmc/core/sd.c
drivers/mmc/core/sd.h
drivers/mmc/core/sdio.c