[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <20240204-bus_cleanup-bcma-v1-1-0d881c793190@marliere.net>
Date: Sun, 04 Feb 2024 17:57:23 -0300
From: "Ricardo B. Marliere" <ricardo@...liere.net>
To: Rafał Miłecki <zajec5@...il.com>
Cc: linux-wireless@...r.kernel.org, linux-kernel@...r.kernel.org,
Greg Kroah-Hartman <gregkh@...uxfoundation.org>,
"Ricardo B. Marliere" <ricardo@...liere.net>
Subject: [PATCH] bcma: make bcma_bus_type const
Now that the driver core can properly handle constant struct bus_type,
move the bcma_bus_type 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@...uxfoundation.org>
Suggested-by: Greg Kroah-Hartman <gregkh@...uxfoundation.org>
Signed-off-by: Ricardo B. Marliere <ricardo@...liere.net>
---
drivers/bcma/main.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/bcma/main.c b/drivers/bcma/main.c
index 7061d3ee836a..6b5d34919c72 100644
--- a/drivers/bcma/main.c
+++ b/drivers/bcma/main.c
@@ -68,7 +68,7 @@ static struct attribute *bcma_device_attrs[] = {
};
ATTRIBUTE_GROUPS(bcma_device);
-static struct bus_type bcma_bus_type = {
+static const struct bus_type bcma_bus_type = {
.name = "bcma",
.match = bcma_bus_match,
.probe = bcma_device_probe,
---
base-commit: 41b9fb381a486360b2daaec0c7480f8e3ff72bc7
change-id: 20240204-bus_cleanup-bcma-51f04ad9a6e7
Best regards,
--
Ricardo B. Marliere <ricardo@...liere.net>
Powered by blists - more mailing lists