diff options
author | stroese <stroese> | 2003-04-04 15:44:49 +0000 |
---|---|---|
committer | stroese <stroese> | 2003-04-04 15:44:49 +0000 |
commit | 0587597ca333f9a5877af7a7d272d5fb5d8070cc (patch) | |
tree | 73e24de16ce4ccb2e19304a684d629f658518b82 /common/main.c | |
parent | 0db5bca8076998a7516102988ac976a2da28d531 (diff) | |
download | u-boot-midas-0587597ca333f9a5877af7a7d272d5fb5d8070cc.tar.gz u-boot-midas-0587597ca333f9a5877af7a7d272d5fb5d8070cc.tar.bz2 u-boot-midas-0587597ca333f9a5877af7a7d272d5fb5d8070cc.zip |
U-Boot version environment variable "ver" added (CONFIG_VERSION_VARIABLE).
Diffstat (limited to 'common/main.c')
-rw-r--r-- | common/main.c | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/common/main.c b/common/main.c index 9ee32a5804..e32845e471 100644 --- a/common/main.c +++ b/common/main.c @@ -279,6 +279,16 @@ void main_loop (void) } #endif /* CONFIG_MODEM_SUPPORT */ +#ifdef CONFIG_VERSION_VARIABLE + { + extern char version_string[]; + char *str = getenv("ver"); + + if (!str) + setenv ("ver", version_string); /* set version variable */ + } +#endif /* CONFIG_VERSION_VARIABLE */ + #ifdef CFG_HUSH_PARSER u_boot_hush_start (); #endif |