[PATCH 1/2] block: ide: Staticize and constify driver ops
Marek Vasut
marek.vasut+renesas at mailbox.org
Thu May 7 18:42:39 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: Tom Rini <trini at konsulko.com>
Cc: u-boot at lists.denx.de
---
drivers/block/ide.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/drivers/block/ide.c b/drivers/block/ide.c
index cab5e1bc92b..fe98d7f783f 100644
--- a/drivers/block/ide.c
+++ b/drivers/block/ide.c
@@ -969,7 +969,7 @@ static int ide_bootdev_hunt(struct bootdev_hunter *info, bool show)
return 0;
}
-struct bootdev_ops ide_bootdev_ops = {
+static const struct bootdev_ops ide_bootdev_ops = {
};
static const struct udevice_id ide_bootdev_ids[] = {
--
2.53.0
More information about the U-Boot
mailing list