ARM: 9416/1: amba: make amba_bustype constant
authorKunwu Chan <chentao@kylinos.cn>
Mon, 2 Sep 2024 06:43:23 +0000 (07:43 +0100)
committerRussell King (Oracle) <rmk+kernel@armlinux.org.uk>
Wed, 4 Sep 2024 14:01:17 +0000 (15:01 +0100)
commita4d398a573d0f0c98c39d4af1866a3edaec4959c
treeaf00a750333e20eb6bd4afb8bf669b8d8c6def25
parentde9c2c66ad8e787abec7c9d7eff4f8c3cdd28aed
ARM: 9416/1: amba: make amba_bustype constant

Since commit d492cc2573a0 ("driver core: device.h: make struct
bus_type a const *"), the driver core can properly handle constant
struct bus_type, move the amba_bustype 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: Kunwu Chan <chentao@kylinos.cn>
Signed-off-by: Russell King (Oracle) <rmk+kernel@armlinux.org.uk>
drivers/amba/bus.c
include/linux/amba/bus.h