Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
S
Software for White Rabbit PTP Core
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
28
Issues
28
List
Board
Labels
Milestones
Merge Requests
4
Merge Requests
4
CI / CD
CI / CD
Pipelines
Schedules
Wiki
Wiki
image/svg+xml
Discourse
Discourse
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Charts
Create a new issue
Commits
Issue Boards
Open sidebar
Projects
Software for White Rabbit PTP Core
Commits
31c79183
Commit
31c79183
authored
May 07, 2013
by
Alessandro Rubini
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
cmd_version: better output, report unsupported builds
Signed-off-by:
Alessandro Rubini
<
rubini@gnudd.com
>
parent
992dc8d7
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
18 additions
and
3 deletions
+18
-3
revision.c
revision.c
+1
-1
cmd_version.c
shell/cmd_version.c
+17
-2
No files found.
revision.c
View file @
31c79183
...
...
@@ -4,6 +4,6 @@ const char *build_revision = GIT_REVISION;
#ifdef CONFIG_DETERMINISTIC_BINARY
const
char
*
build_date
=
""
;
#else
const
char
*
build_date
=
"
, compiled on: "
__DATE__
" "
__TIME__
;
const
char
*
build_date
=
"
Built on "
__DATE__
", "
__TIME__
"
\n
"
;
#endif
shell/cmd_version.c
View file @
31c79183
...
...
@@ -5,10 +5,25 @@
extern
const
char
*
build_revision
,
*
build_date
;
#ifdef CONFIG_DEVELOPER
#define SUPPORT " (unsupported developer build)"
#else
#define SUPPORT ""
#endif
static
int
cmd_ver
(
const
char
*
args
[])
{
mprintf
(
"WR Core build: %s%s (memory size: %d kB)
\n
"
,
build_revision
,
build_date
,
sysc_get_memsize
());
int
hwram
=
sysc_get_memsize
();
pp_printf
(
"WR Core build: %s%s
\n
"
,
build_revision
,
SUPPORT
);
pp_printf
(
"%s"
,
build_date
);
/* may be empty, or complete with \n */
pp_printf
(
"Built for %d kB RAM, stack is %d bytes
\n
"
,
CONFIG_RAMSIZE
/
1024
,
CONFIG_STACKSIZE
);
/* hardware reports memory size, with a 16kB granularity */
if
(
hwram
/
16
!=
CONFIG_RAMSIZE
/
1024
/
16
)
pp_printf
(
"WARNING: hardware says %ikB <= RAM < %ikB
\n
"
,
hwram
,
hwram
+
16
);
return
0
;
}
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment