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
ac6b3d07
Commit
ac6b3d07
authored
Mar 03, 2016
by
Alessandro Rubini
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
msg.c: merge issue_delay_req() and issue_pdelay_req()
Signed-off-by:
Alessandro Rubini
<
rubini@gnudd.com
>
parent
0ad2eb51
Hide whitespace changes
Inline
Side-by-side
Showing
4 changed files
with
12 additions
and
6 deletions
+12
-6
ppsi.h
include/ppsi/ppsi.h
+1
-2
msg.c
proto-standard/msg.c
+9
-2
state-pclock.c
proto-standard/state-pclock.c
+1
-1
state-slave.c
proto-standard/state-slave.c
+1
-1
No files found.
include/ppsi/ppsi.h
View file @
ac6b3d07
...
...
@@ -429,9 +429,8 @@ extern void msg_pack_pdelay_req(struct pp_instance *ppi,
extern
void
*
msg_copy_header
(
MsgHeader
*
dest
,
MsgHeader
*
src
);
/* REMOVE ME!! */
extern
int
msg_issue_announce
(
struct
pp_instance
*
ppi
);
extern
int
msg_issue_sync_followup
(
struct
pp_instance
*
ppi
);
extern
int
msg_issue_
delay_req
(
struct
pp_instance
*
ppi
);
extern
int
msg_issue_
request
(
struct
pp_instance
*
ppi
);
extern
int
msg_issue_delay_resp
(
struct
pp_instance
*
ppi
,
TimeInternal
*
time
);
extern
int
msg_issue_pdelay_req
(
struct
pp_instance
*
ppi
);
extern
int
msg_issue_pdelay_resp_followup
(
struct
pp_instance
*
ppi
,
TimeInternal
*
time
);
extern
int
msg_issue_pdelay_resp
(
struct
pp_instance
*
ppi
,
TimeInternal
*
time
);
...
...
proto-standard/msg.c
View file @
ac6b3d07
...
...
@@ -525,7 +525,7 @@ int msg_issue_pdelay_resp_followup(struct pp_instance *ppi, TimeInternal * time)
}
/* Pack and send on event multicast ip adress a DelayReq message */
int
msg_issue_delay_req
(
struct
pp_instance
*
ppi
)
static
int
msg_issue_delay_req
(
struct
pp_instance
*
ppi
)
{
Timestamp
orig_tstamp
;
TimeInternal
now
;
...
...
@@ -539,7 +539,7 @@ int msg_issue_delay_req(struct pp_instance *ppi)
}
/* Pack and send on event multicast ip adress a PDelayReq message */
int
msg_issue_pdelay_req
(
struct
pp_instance
*
ppi
)
static
int
msg_issue_pdelay_req
(
struct
pp_instance
*
ppi
)
{
Timestamp
orig_tstamp
;
TimeInternal
now
;
...
...
@@ -552,6 +552,13 @@ int msg_issue_pdelay_req(struct pp_instance *ppi)
PP_NP_EVT
);
}
int
msg_issue_request
(
struct
pp_instance
*
ppi
)
{
if
(
ppi
->
glbs
->
delay_mech
==
PP_E2E_MECH
)
return
msg_issue_delay_req
(
ppi
);
return
msg_issue_pdelay_req
(
ppi
);
}
/* Pack and send on event multicast ip adress a DelayResp message */
int
msg_issue_delay_resp
(
struct
pp_instance
*
ppi
,
TimeInternal
*
time
)
{
...
...
proto-standard/state-pclock.c
View file @
ac6b3d07
...
...
@@ -112,7 +112,7 @@ out:
e
=
st_com_execute_slave
(
ppi
);
if
(
pp_timeout_z
(
ppi
,
PP_TO_DELAYREQ
))
{
e
=
msg_issue_
pdelay_req
(
ppi
);
e
=
msg_issue_
request
(
ppi
);
ppi
->
t3
=
ppi
->
last_snt_time
;
...
...
proto-standard/state-slave.c
View file @
ac6b3d07
...
...
@@ -105,7 +105,7 @@ out:
e
=
st_com_execute_slave
(
ppi
);
if
(
pp_timeout_z
(
ppi
,
PP_TO_DELAYREQ
))
{
e
=
msg_issue_
delay_req
(
ppi
);
e
=
msg_issue_
request
(
ppi
);
ppi
->
t3
=
ppi
->
last_snt_time
;
...
...
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