Skip to content

Commit e4b5a39

Browse files
javiercarrascocruzwens
authored andcommitted
bus: sunxi-rsb: Constify struct regmap_bus
`regmap_sunxi_rsb` is not modified and can be declared as const to move its data to a read-only section. Signed-off-by: Javier Carrasco <[email protected]> Link: https://lore.kernel.org/r/20240705-sunxi-rsb-bus-const-regmap_bus-v1-1-129094960ce9@gmail.com Signed-off-by: Chen-Yu Tsai <[email protected]>
1 parent 9bc1e34 commit e4b5a39

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/bus/sunxi-rsb.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -457,7 +457,7 @@ static void regmap_sunxi_rsb_free_ctx(void *context)
457457
kfree(ctx);
458458
}
459459

460-
static struct regmap_bus regmap_sunxi_rsb = {
460+
static const struct regmap_bus regmap_sunxi_rsb = {
461461
.reg_write = regmap_sunxi_rsb_reg_write,
462462
.reg_read = regmap_sunxi_rsb_reg_read,
463463
.free_context = regmap_sunxi_rsb_free_ctx,

0 commit comments

Comments
 (0)