Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
R
RIOT
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Container Registry
Model registry
Operate
Environments
Monitor
Incidents
Service Desk
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
cm-projects
RIOT
Commits
01225ca9
Commit
01225ca9
authored
9 years ago
by
Cenk Gündoğan
Browse files
Options
Downloads
Patches
Plain Diff
gnrc_nettest: use xtimer instead of vtimer
parent
c2ae6a86
No related branches found
No related tags found
No related merge requests found
Changes
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
Makefile.dep
+1
-1
1 addition, 1 deletion
Makefile.dep
sys/net/gnrc/nettest/gnrc_nettest.c
+2
-5
2 additions, 5 deletions
sys/net/gnrc/nettest/gnrc_nettest.c
with
3 additions
and
6 deletions
Makefile.dep
+
1
−
1
View file @
01225ca9
...
@@ -255,7 +255,7 @@ ifneq (,$(filter gnrc_nettest,$(USEMODULE)))
...
@@ -255,7 +255,7 @@ ifneq (,$(filter gnrc_nettest,$(USEMODULE)))
USEMODULE
+=
gnrc_netreg
USEMODULE
+=
gnrc_netreg
USEMODULE
+=
gnrc_netif
USEMODULE
+=
gnrc_netif
USEMODULE
+=
gnrc_pktbuf
USEMODULE
+=
gnrc_pktbuf
USEMODULE
+=
v
timer
USEMODULE
+=
x
timer
endif
endif
ifneq
(,$(filter gnrc_pktdump,$(USEMODULE)))
ifneq
(,$(filter gnrc_pktdump,$(USEMODULE)))
...
...
This diff is collapsed.
Click to expand it.
sys/net/gnrc/nettest/gnrc_nettest.c
+
2
−
5
View file @
01225ca9
...
@@ -22,9 +22,8 @@
...
@@ -22,9 +22,8 @@
#include
"net/netopt.h"
#include
"net/netopt.h"
#include
"net/gnrc/netreg.h"
#include
"net/gnrc/netreg.h"
#include
"net/gnrc/pktbuf.h"
#include
"net/gnrc/pktbuf.h"
#include
"timex.h"
#include
"thread.h"
#include
"thread.h"
#include
"
v
timer.h"
#include
"
x
timer.h"
#include
"net/gnrc/nettest.h"
#include
"net/gnrc/nettest.h"
...
@@ -55,14 +54,12 @@ static gnrc_nettest_res_t _pkt_test(uint16_t cmd_type, kernel_pid_t pid,
...
@@ -55,14 +54,12 @@ static gnrc_nettest_res_t _pkt_test(uint16_t cmd_type, kernel_pid_t pid,
const
gnrc_pktsnip_t
**
exp_out
)
const
gnrc_pktsnip_t
**
exp_out
)
{
{
msg_t
msg
;
msg_t
msg
;
timex_t
t
=
{
0
,
GNRC_NETTEST_TIMEOUT
};
gnrc_nettest_res_t
res
=
GNRC_NETTEST_SUCCESS
;
gnrc_nettest_res_t
res
=
GNRC_NETTEST_SUCCESS
;
msg
.
type
=
cmd_type
;
msg
.
type
=
cmd_type
;
msg
.
content
.
ptr
=
(
char
*
)
in
;
msg
.
content
.
ptr
=
(
char
*
)
in
;
msg_send
(
&
msg
,
pid
);
msg_send
(
&
msg
,
pid
);
timex_normalize
(
&
t
);
if
(
exp_pkts
==
0
)
{
if
(
exp_pkts
==
0
)
{
thread_yield
();
thread_yield
();
...
@@ -72,7 +69,7 @@ static gnrc_nettest_res_t _pkt_test(uint16_t cmd_type, kernel_pid_t pid,
...
@@ -72,7 +69,7 @@ static gnrc_nettest_res_t _pkt_test(uint16_t cmd_type, kernel_pid_t pid,
gnrc_pktsnip_t
*
out
;
gnrc_pktsnip_t
*
out
;
const
gnrc_pktsnip_t
*
exp
=
exp_out
[
i
];
const
gnrc_pktsnip_t
*
exp
=
exp_out
[
i
];
if
(
v
timer_msg_receive_timeout
(
&
msg
,
t
)
<
0
)
{
if
(
x
timer_msg_receive_timeout
(
&
msg
,
GNRC_NETTEST_TIMEOUT
)
<
0
)
{
return
GNRC_NETTEST_TIMED_OUT
;
return
GNRC_NETTEST_TIMED_OUT
;
}
}
...
...
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment