[PATCH 12/14] reset: sti: Staticize and constify driver ops

Marek Vasut marek.vasut+renesas at mailbox.org
Sat May 9 17:12:35 CEST 2026


Set the ops structure as static const. The structure is not accessible
from outside of this driver and is not going to be modified at runtime.

Signed-off-by: Marek Vasut <marek.vasut+renesas at mailbox.org>
---
Cc: Patrice Chotard <patrice.chotard at foss.st.com>
Cc: Tom Rini <trini at konsulko.com>
Cc: u-boot at lists.denx.de
---
 drivers/reset/sti-reset.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/reset/sti-reset.c b/drivers/reset/sti-reset.c
index 412a0c5b452..37a37a72fd3 100644
--- a/drivers/reset/sti-reset.c
+++ b/drivers/reset/sti-reset.c
@@ -290,7 +290,7 @@ static int sti_reset_deassert(struct reset_ctl *reset_ctl)
 	return sti_reset_program_hw(reset_ctl, false);
 }
 
-struct reset_ops sti_reset_ops = {
+static const struct reset_ops sti_reset_ops = {
 	.rst_assert = sti_reset_assert,
 	.rst_deassert = sti_reset_deassert,
 };
-- 
2.53.0



More information about the U-Boot mailing list