summaryrefslogtreecommitdiff
path: root/include/linux/cdx
diff options
context:
space:
mode:
authorGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-09-14 15:42:40 +0200
committerGreg Kroah-Hartman <gregkh@linuxfoundation.org>2025-10-22 07:54:33 +0200
commit9fd2eb9e18a0a0b5a127937586388ed0181d9dac (patch)
treedd3c1f67271b918a5739646b80b00e24fd53e515 /include/linux/cdx
parent69cddd82ef78bbd5a92d11f725ab22a84b561a10 (diff)
cdx: make cdx_bus_type constant
Now that the driver core can properly handle constant struct bus_type, move the cdx_bus_type variable to be a constant structure as well, placing it into read-only memory which can not be modified at runtime. Cc: Nipun Gupta <nipun.gupta@amd.com> Cc: Nikhil Agarwal <nikhil.agarwal@amd.com> Acked-by: Nipun Gupta <nipun.gupta@amd.com> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Link: https://patch.msgid.link/2025091439-sustained-acorn-4af4@gregkh Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
Diffstat (limited to 'include/linux/cdx')
-rw-r--r--include/linux/cdx/cdx_bus.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/linux/cdx/cdx_bus.h b/include/linux/cdx/cdx_bus.h
index 79bb80e56790..b1ba97f6c9ad 100644
--- a/include/linux/cdx/cdx_bus.h
+++ b/include/linux/cdx/cdx_bus.h
@@ -234,7 +234,7 @@ int __must_check __cdx_driver_register(struct cdx_driver *cdx_driver,
*/
void cdx_driver_unregister(struct cdx_driver *cdx_driver);
-extern struct bus_type cdx_bus_type;
+extern const struct bus_type cdx_bus_type;
/**
* cdx_dev_reset - Reset CDX device