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
32
Issues
32
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
757194ee
Commit
757194ee
authored
Feb 22, 2021
by
Omar Gabella
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
KM3NET BROADCAST : auto negociation disabled + commits on ppsi submodule.
parent
7be3865b
Pipeline
#949
failed with stages
Changes
3
Pipelines
1
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
20 additions
and
2 deletions
+20
-2
endpoint.c
dev/endpoint.c
+13
-0
ppsi
ppsi
+1
-1
wrc_main.c
wrc_main.c
+6
-1
No files found.
dev/endpoint.c
View file @
757194ee
...
...
@@ -30,14 +30,22 @@ static int autoneg_enabled;
volatile
struct
EP_WB
*
EP
;
/* functions for accessing PCS (MDIO) registers */
#ifdef BROADCAST
uint16_t
pcs_read
(
int
location
)
// KM3NeT
#else
static
uint16_t
pcs_read
(
int
location
)
#endif
{
EP
->
MDIO_CR
=
EP_MDIO_CR_ADDR_W
(
location
>>
2
);
while
((
EP
->
MDIO_ASR
&
EP_MDIO_ASR_READY
)
==
0
)
;
return
EP_MDIO_ASR_RDATA_R
(
EP
->
MDIO_ASR
)
&
0xffff
;
}
#ifdef BROADCAST
void
pcs_write
(
int
location
,
int
value
)
// KM3NeT
#else
static
void
pcs_write
(
int
location
,
int
value
)
#endif
{
EP
->
MDIO_CR
=
EP_MDIO_CR_ADDR_W
(
location
>>
2
)
|
EP_MDIO_CR_DATA_W
(
value
)
...
...
@@ -140,6 +148,11 @@ int ep_link_up(uint16_t * lpa)
uint16_t
flags
=
MDIO_MSR_LSTATUS
;
volatile
uint16_t
msr
;
#ifdef BROADCAST
/* Autonegotiation disabled by default in broadcast mode */
autoneg_enabled
=
((
uint16_t
)
pcs_read
(
MDIO_REG_MCR
)
&
(
0x1000
));
#endif
if
(
autoneg_enabled
)
flags
|=
MDIO_MSR_ANEGCOMPLETE
;
...
...
ppsi
@
83e2608e
Subproject commit
6f577f41f14c37855635669d9937747c41a2ffaa
Subproject commit
83e2608e59cd5bfd73c557250f23b994812774e1
wrc_main.c
View file @
757194ee
...
...
@@ -100,7 +100,12 @@ static void wrc_initialize(void)
/* Sleep for 1s to make sure WRS v4.2 always realizes that
* the link is down */
timer_delay_ms
(
200
);
ep_enable
(
1
,
1
);
#ifdef BROADCAST
ep_enable
(
1
,
0
);
// Auto negociation disable.
#else
ep_enable
(
1
,
1
);
#endif
minic_init
();
shw_pps_gen_init
();
...
...
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