Skip to content
Projects
Groups
Snippets
Help
Loading...
Sign in
Toggle navigation
P
PPSi
Project
Project
Details
Activity
Cycle Analytics
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Charts
Issues
50
Issues
50
List
Board
Labels
Milestones
Merge Requests
1
Merge Requests
1
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
PPSi
Commits
12bd4376
Commit
12bd4376
authored
Dec 17, 2014
by
Alessandro Rubini
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
arch-wrs: header update (minor shmem changes)
Signed-off-by:
Alessandro Rubini
<
rubini@gnudd.com
>
parent
f49685ec
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
with
13 additions
and
4 deletions
+13
-4
hal_shmem.h
arch-wrs/include/libwr/hal_shmem.h
+1
-1
sfp_lib.h
arch-wrs/include/libwr/sfp_lib.h
+12
-3
No files found.
arch-wrs/include/libwr/hal_shmem.h
View file @
12bd4376
...
...
@@ -91,7 +91,7 @@ struct hal_port_state {
};
/* This is the overall structure stored in shared memory */
#define HAL_SHMEM_VERSION
1
#define HAL_SHMEM_VERSION
2
/* Version 2 because sfp calib changed */
struct
hal_shmem_header
{
int
nports
;
struct
hal_port_state
*
ports
;
...
...
arch-wrs/include/libwr/sfp_lib.h
View file @
12bd4376
...
...
@@ -23,12 +23,21 @@
struct
shw_sfp_caldata
{
int
flags
;
char
part_num
[
16
];
/* part number of device as found in DB */
/*
* Part number used to identify it. Serial number because we
* may specify per-specimen delays, but it is not used at this
* point in time
*/
char
part_num
[
16
];
char
vendor_serial
[
16
];
/* Callibration data */
double
alpha
;
uint32_t
delta_tx
;
uint32_t
delta_rx
;
/* wavelengths, used to get alpha from fiber type */
int
tx_wl
;
int
rx_wl
;
/* and link as a list */
struct
shw_sfp_caldata
*
next
;
};
...
...
@@ -87,8 +96,8 @@ static inline void shw_sfp_set_generic(int num, int status, int type)
shw_sfp_gpio_set
(
num
,
state
);
}
/* Load the db from
a file
*/
int
shw_sfp_read_db
(
char
*
filename
);
/* Load the db from
dot-config to internal structures
*/
int
shw_sfp_read_db
(
void
);
/* Read and verify the header all at once. returns -1 on failure */
int
shw_sfp_read_verify_header
(
int
num
,
struct
shw_sfp_header
*
head
);
...
...
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