[PATCH] mmc: bootstd: Staticize and constify driver ops

Marek Vasut marek.vasut+renesas at mailbox.org
Fri May 8 00:07:48 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: Jaehoon Chung <jh80.chung at samsung.com>
Cc: Peng Fan <peng.fan at nxp.com>
Cc: Simon Glass <sjg at chromium.org>
Cc: Tom Rini <trini at konsulko.com>
Cc: u-boot at lists.denx.de
---
 drivers/mmc/mmc_bootdev.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/drivers/mmc/mmc_bootdev.c b/drivers/mmc/mmc_bootdev.c
index 5a1688b75d0..b382521fdeb 100644
--- a/drivers/mmc/mmc_bootdev.c
+++ b/drivers/mmc/mmc_bootdev.c
@@ -19,7 +19,7 @@ static int mmc_bootdev_bind(struct udevice *dev)
 	return 0;
 }
 
-struct bootdev_ops mmc_bootdev_ops = {
+static const struct bootdev_ops mmc_bootdev_ops = {
 };
 
 static const struct udevice_id mmc_bootdev_ids[] = {
-- 
2.53.0



More information about the U-Boot mailing list