Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
W
White Rabbit Switch - Software
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
84
Issues
84
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
White Rabbit Switch - Software
Commits
4f08674f
Commit
4f08674f
authored
Oct 06, 2020
by
Kinga Wujek
Committed by
Adam Wujek
Oct 29, 2020
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
userspace/tools: make rtu_stat to read shmem from another location
Signed-off-by:
Kinga Wujek
<
dev_public@wujek.eu
>
parent
bbfe02a5
Pipeline
#729
failed with stage
in 102 minutes and 48 seconds
Changes
1
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
14 additions
and
2 deletions
+14
-2
rtu_stat.c
userspace/tools/rtu_stat.c
+14
-2
No files found.
userspace/tools/rtu_stat.c
View file @
4f08674f
...
...
@@ -133,8 +133,9 @@ char *decode_ports(int dpm, int nports)
void
show_help
(
char
*
prgname
)
{
fprintf
(
stderr
,
"usage: %s <command> <values>
\n
"
,
prgname
);
fprintf
(
stderr
,
" help: Show this message
\n
"
);
fprintf
(
stderr
,
" list: List the routing table (same as empty command)
\n
"
);
fprintf
(
stderr
,
" help: Show this message
\n
"
);
fprintf
(
stderr
,
" list: List the routing table (same as empty command)
\n
"
);
fprintf
(
stderr
,
" list shmem <path>: List the routing table read from shmem at a given directory
\n
"
);
fprintf
(
stderr
,
" remove all <port> [<type>]: Remove all RTU entries for the given port
\n
"
" with an optional type (default %d-dynamic)
\n
"
,
RTU_ENTRY_TYPE_DYNAMIC
);
...
...
@@ -537,6 +538,17 @@ int main(int argc, char **argv)
int
enable
;
uint32_t
mask
;
/* change of a path to shmem has to be done before openning shmem */
if
(
argc
>=
4
&&
!
strcmp
(
argv
[
1
],
"list"
)
&&
!
strcmp
(
argv
[
2
],
"shmem"
))
{
printf
(
"set shmem path to: %s
\n
"
,
argv
[
3
]);
wrs_shm_set_path
(
argv
[
3
]);
/* ignore WRS_SHM_LOCKED flag (don't check if process
* is alive) */
wrs_shm_ignore_flag_locked
(
1
);
}
nports
=
get_nports_from_hal
();
while
(
!
(
rtud_ch
=
minipc_client_create
(
"rtud"
,
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