[U-Boot] [PATCH v2 0/5] tools/env: pass arguments as parameters not global structure

Andreas Fenkart andreas.fenkart at digitalstrom.com
Tue Apr 19 22:43:38 CEST 2016


u-boot tools can be built as a library (libubootenv.a). Passing arguments
to the library using global structures is a bad interface.

v2:
- fix env_aes_cbc_crypt prototype
- check opts pointer for not NULL

Andreas Fenkart (5):
  tools/env: pass key as argument to env_aes_cbc_crypt
  tools/env: remove 'extern' from function prototype in fw_env.h
  tools/env: fw_printenv pass value_only as argument
  tools/env: compute size of usable area only once
  tools/env: replace global variables by parameter passing

 tools/env/fw_env.c      | 111 ++++++++++++++++++++++++++++--------------------
 tools/env/fw_env.h      |  31 +++++---------
 tools/env/fw_env_main.c |  28 +++++++-----
 3 files changed, 94 insertions(+), 76 deletions(-)

-- 
2.8.0.rc3



More information about the U-Boot mailing list