Skip to content

Commit e3c5df1

Browse files
rbmarliereTzung-Bi Shih
authored andcommitted
firmware: coreboot: make coreboot_bus_type const
Now that the driver core can properly handle constant struct bus_type, move the coreboot_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@linuxfoundation.org> Suggested-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Signed-off-by: "Ricardo B. Marliere" <ricardo@marliere.net> Reviewed-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org> Link: https://lore.kernel.org/r/20240204-bus_cleanup-firmware-v1-1-d1bff946606d@marliere.net Signed-off-by: Tzung-Bi Shih <tzungbi@kernel.org>
1 parent 6613476 commit e3c5df1

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

drivers/firmware/google/coreboot_table.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ static void coreboot_bus_remove(struct device *dev)
5353
driver->remove(device);
5454
}
5555

56-
static struct bus_type coreboot_bus_type = {
56+
static const struct bus_type coreboot_bus_type = {
5757
.name = "coreboot",
5858
.match = coreboot_bus_match,
5959
.probe = coreboot_bus_probe,

0 commit comments

Comments
 (0)