env: add prototypes for weak function
PATCH RESEND 1/1 env: add prototypes for weak function
This patch adds prototypes for several weak functions:
- env_ext4_get_intf
- env_ext4_get_dev_part
- env_get_location
It solves the following warnings when compiling with W=1 on stm32mp1 board:
board/st/stm32mp1/stm32mp1.c:849:19: warning: no previous prototype for 'env_get_location' [-Wmissing-prototypes]
enum env_location env_get_location(enum env_operation op, int prio)
^~~~~~~~~~~~~~~~
board/st/stm32mp1/stm32mp1.c:876:13: warning: no previous prototype for 'env_ext4_get_intf' [-Wmissing-prototypes]
const char *env_ext4_get_intf(void)
^~~~~~~~~~~~~~~~~
board/st/stm32mp1/stm32mp1.c:889:13: warning: no previous prototype for 'env_ext4_get_dev_part' [-Wmissing-prototypes]
const char *env_ext4_get_dev_part(void)
^~~~~~~~~~~~~~~~~~~~~Commit-note
Hi,
I resend this patch, rebased on master without modification
http://patchwork.ozlabs.org/project/uboot/list/?series=155601
Regards
Patrick
END
---
include/env_internal.h | 31 +++++++++++++++++++++++++++++++ 1 file changed, 31 insertions(+)
include/env_internal.h +31 -0
@@ -211,6 +211,37 @@ struct env_driver {extern struct hsearch_data env_htab; +/** +* env_ext4_get_intf() - Provide the interface for env in EXT4 +* +* It is a weak function allowing board to overidde the default interface for +* U-Boot env in EXT4: CONFIG_ENV_EXT4_INTERFACE +* +* @return string of interface, empty if not supported +*/ +const char *env_ext4_get_intf (void ); + +/** +* env_ext4_get_dev_part() - Provide the device and partition for env in EXT4 +* +* It is a weak function allowing board to overidde the default device and +* partition used for U-Boot env in EXT4: CONFIG_ENV_EXT4_DEVICE_AND_PART +* +* @return string of device and partition +*/ +const char *env_ext4_get_dev_part (void ); + +/** +* env_get_location()- Provide the best location for the U-Boot environment +* +* It is a weak function allowing board to overidde the environment location +* +* @op: operations performed on the environment +* @prio: priority between the multiple environments, 0 being the +* highest priority +* @return an enum env_location value on success, or -ve error code. +*/ +enum env_location env_get_location (enum env_operation op,int prio);#endif /* DO_DEPS_ONLY */ #endif /* _ENV_INTERNAL_H_ */
Signature · 1 line
2.17.1
PATCH RESEND 1/1 env: add prototypes for weak function
Quoted 24 lines · Patrick Delaunay
This patch adds prototypes for several weak functions:
-env_ext4_get_intf
-env_ext4_get_dev_part
-env_get_locationIt solves the following warnings when compiling with W=1 on stm32mp1 board:
board/st/stm32mp1/stm32mp1.c:849:19: warning: no previous prototype for 'env_get_location' [-Wmissing-prototypes]
enumenv_locationenv_get_location(enum env_operation op, int prio)^~~~~~~~~~~~~~~~ board/st/stm32mp1/stm32mp1.c:876:13: warning: no previous prototype for 'env_ext4_get_intf' [-Wmissing-prototypes] const char *env_ext4_get_intf(void) ^~~~~~~~~~~~~~~~~ board/st/stm32mp1/stm32mp1.c:889:13: warning: no previous prototype for 'env_ext4_get_dev_part' [-Wmissing-prototypes] const char *env_ext4_get_dev_part(void) ^~~~~~~~~~~~~~~~~~~~~Commit-note
Hi,I resend this patch, rebased on master without modification
http://patchwork.ozlabs.org/project/uboot/list/?series=155601
Quoted 8 lines
Regards
Patrick
END
Signed-off-by Patrice Chotard <[email protected]>Signed-off-by Patrick Delaunay <[email protected]>
Applied to u-boot/master, thanks!
Signature · 8 lines
Tom -------------- next part -------------- A non-text attachment was scrubbed... Name: signature.asc Type: application/pgp-signature Size: 659 bytes Desc: not available URL: <https://lists.denx.de/pipermail/u-boot/attachments/20200731/2111516a/attachment.sig>