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
86
Issues
86
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
9c2217cf
Commit
9c2217cf
authored
Nov 26, 2014
by
Alessandro Rubini
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
userspace/tools: added fields to wrs_dump_shmem
Signed-off-by:
Alessandro Rubini
<
rubini@gnudd.com
>
parent
1cabcabb
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
12 additions
and
1 deletion
+12
-1
wrs_dump_shmem.c
userspace/tools/wrs_dump_shmem.c
+12
-1
No files found.
userspace/tools/wrs_dump_shmem.c
View file @
9c2217cf
...
...
@@ -48,6 +48,7 @@ enum dump_type {
/* normal types follow */
dump_type_uint32_t
,
dump_type_int
,
dump_type_double
,
};
void
dump_one_field
(
void
*
addr
,
struct
dump_info
*
info
)
...
...
@@ -71,6 +72,9 @@ void dump_one_field(void *addr, struct dump_info *info)
case
dump_type_uint32_t
:
printf
(
"0x%08lx
\n
"
,
(
long
)
*
(
uint32_t
*
)
p
);
break
;
case
dump_type_double
:
printf
(
"%lf
\n
"
,
*
(
double
*
)
p
);
break
;
}
}
void
dump_many_fields
(
void
*
addr
,
struct
dump_info
*
info
,
int
ninfo
)
...
...
@@ -118,7 +122,14 @@ struct dump_info hal_port_info [] = {
DUMP_FIELD
(
int
,
calib
.
rx_calibrated
),
DUMP_FIELD
(
int
,
calib
.
tx_calibrated
),
// FIXME: add these struct shw_sfp_caldata sfp;
/* Another internal structure, with a final pointer, so int32_t */
DUMP_FIELD
(
int
,
calib
.
sfp
.
flags
),
DUMP_FIELD_SIZE
(
char
,
calib
.
sfp
.
part_num
,
16
),
DUMP_FIELD_SIZE
(
char
,
calib
.
sfp
.
vendor_serial
,
16
),
DUMP_FIELD
(
double
,
calib
.
sfp
.
alpha
),
DUMP_FIELD
(
uint32_t
,
calib
.
sfp
.
delta_tx
),
DUMP_FIELD
(
uint32_t
,
calib
.
sfp
.
delta_rx
),
DUMP_FIELD
(
uint32_t
,
calib
.
sfp
.
next
),
DUMP_FIELD
(
uint32_t
,
phase_val
),
DUMP_FIELD
(
int
,
phase_val_valid
),
...
...
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