sh: dma-sysfs: Make dma_subsys const

Now that the driver core can properly handle constant struct bus_type,
move the dma_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 <gregkh@linuxfoundation.org>
Suggested-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Signed-off-by: Ricardo B. Marliere <ricardo@marliere.net>
Reviewed-by: Geert Uytterhoeven <geert+renesas@glider.be>
Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Reviewed-by: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
Link: https://lore.kernel.org/r/20240204-bus_cleanup-sh-v1-1-44ced951bb16@marliere.net
Signed-off-by: John Paul Adrian Glaubitz <glaubitz@physik.fu-berlin.de>
This commit is contained in:
Ricardo B. Marliere 2024-02-04 12:15:09 -03:00 committed by John Paul Adrian Glaubitz
parent 6613476e22
commit d32b8d7e3d
1 changed files with 1 additions and 1 deletions

View File

@ -15,7 +15,7 @@
#include <linux/string.h>
#include <asm/dma.h>
static struct bus_type dma_subsys = {
static const struct bus_type dma_subsys = {
.name = "dma",
.dev_name = "dma",
};