]> git.dujemihanovic.xyz Git - u-boot.git/commitdiff
env: the ops driver load becomes mandatory in struct env_driver
authorPatrick Delaunay <patrick.delaunay@st.com>
Tue, 28 Jul 2020 09:51:19 +0000 (11:51 +0200)
committerTom Rini <trini@konsulko.com>
Fri, 31 Jul 2020 14:13:00 +0000 (10:13 -0400)
The ops driver load becomes mandatory in struct env_drive,
change the comment for this ops and remove unnecessary test.

Signed-off-by: Patrick Delaunay <patrick.delaunay@st.com>
env/env.c
include/env_internal.h

index bcc68c6bcefb82fd559b5c54d00e40466dd86ff5..5cf5bd238fcb7ac197bc426f59e35f0bfbd03128 100644 (file)
--- a/env/env.c
+++ b/env/env.c
@@ -187,9 +187,6 @@ int env_load(void)
        for (prio = 0; (drv = env_driver_lookup(ENVOP_LOAD, prio)); prio++) {
                int ret;
 
-               if (!drv->load)
-                       continue;
-
                if (!env_has_inited(drv->location))
                        continue;
 
index b9459f926c6fe9be1423b045e6003f001ec0b00e..b26dc6239c82bd3004c564f10e31a08390cf24bf 100644 (file)
@@ -154,8 +154,7 @@ struct env_driver {
        /**
         * load() - Load the environment from storage
         *
-        * This method is optional. If not provided, no environment will be
-        * loaded.
+        * This method is required for loading environment
         *
         * @return 0 if OK, -ve on error
         */