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
d0055660
Commit
d0055660
authored
8 years ago
by
Cenk Gündoğan
Committed by
astralien3000
6 years ago
Browse files
Options
Downloads
Patches
Plain Diff
gnrc: add nettype handling for NDN
parent
05d4c23c
No related branches found
Branches containing commit
No related tags found
No related merge requests found
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
sys/include/net/gnrc/nettype.h
+13
-1
13 additions, 1 deletion
sys/include/net/gnrc/nettype.h
with
13 additions
and
1 deletion
sys/include/net/gnrc/nettype.h
+
13
−
1
View file @
d0055660
...
@@ -115,6 +115,10 @@ typedef enum {
...
@@ -115,6 +115,10 @@ typedef enum {
chunk */
chunk */
#endif
#endif
#ifdef MODULE_NDN_RIOT
GNRC_NETTYPE_NDN
,
/**< Protocol is NDN */
#endif
/**
/**
* @{
* @{
* @name Testing
* @name Testing
...
@@ -147,9 +151,13 @@ static inline gnrc_nettype_t gnrc_nettype_from_ethertype(uint16_t type)
...
@@ -147,9 +151,13 @@ static inline gnrc_nettype_t gnrc_nettype_from_ethertype(uint16_t type)
case
ETHERTYPE_IPV6
:
case
ETHERTYPE_IPV6
:
return
GNRC_NETTYPE_IPV6
;
return
GNRC_NETTYPE_IPV6
;
#endif
#endif
#ifdef
MODULE_CCN_LITE
#if
def
ined(
MODULE_CCN_LITE
) || defined(MODULE_NDN_RIOT)
case
ETHERTYPE_NDN
:
case
ETHERTYPE_NDN
:
#if defined(MODULE_CCN_LITE)
return
GNRC_NETTYPE_CCN
;
return
GNRC_NETTYPE_CCN
;
#elif defined(MODULE_NDN_RIOT)
return
GNRC_NETTYPE_NDN
;
#endif
#endif
#endif
default:
default:
return
GNRC_NETTYPE_UNDEF
;
return
GNRC_NETTYPE_UNDEF
;
...
@@ -177,6 +185,10 @@ static inline uint16_t gnrc_nettype_to_ethertype(gnrc_nettype_t type)
...
@@ -177,6 +185,10 @@ static inline uint16_t gnrc_nettype_to_ethertype(gnrc_nettype_t type)
#ifdef MODULE_CCN_LITE
#ifdef MODULE_CCN_LITE
case
GNRC_NETTYPE_CCN
:
case
GNRC_NETTYPE_CCN
:
return
ETHERTYPE_NDN
;
return
ETHERTYPE_NDN
;
#endif
#ifdef MODULE_NDN_RIOT
case
GNRC_NETTYPE_NDN
:
return
ETHERTYPE_NDN
;
#endif
#endif
default:
default:
return
ETHERTYPE_UNKNOWN
;
return
ETHERTYPE_UNKNOWN
;
...
...
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