FD.io VPP
v21.06-3-gbb25fbf28
Vector Packet Processing
Main Page
Related Pages
Modules
Namespaces
Namespace List
Namespace Members
All
b
d
e
f
g
i
l
m
n
o
p
r
s
t
v
w
Functions
d
f
g
l
m
n
o
p
t
v
Variables
Typedefs
Enumerations
Enumerator
Data Structures
Data Structures
Data Structure Index
Class Hierarchy
Data Fields
All
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
~
Functions
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
r
s
t
u
v
w
z
~
Variables
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
y
z
Typedefs
c
e
g
h
k
m
n
o
r
s
Related Functions
c
d
e
h
i
m
o
p
r
s
v
Source
Files
Symbols
All
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Functions
a
b
c
d
e
f
g
h
i
j
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Variables
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Typedefs
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
u
v
w
x
z
Enumerations
a
b
c
d
e
f
g
h
i
l
m
n
o
p
q
r
s
t
u
v
w
x
Enumerator
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
Macros
a
b
c
d
e
f
g
h
i
k
l
m
n
o
p
q
r
s
t
u
v
w
x
z
•
All
Data Structures
Namespaces
Files
Functions
Variables
Typedefs
Enumerations
Enumerator
Friends
Macros
Modules
Pages
qos_types.c
Go to the documentation of this file.
1
/*
2
*------------------------------------------------------------------
3
* Copyright (c) 2018 Cisco and/or its affiliates.
4
* Licensed under the Apache License, Version 2.0 (the "License");
5
* you may not use this file except in compliance with the License.
6
* You may obtain a copy of the License at:
7
*
8
* http://www.apache.org/licenses/LICENSE-2.0
9
*
10
* Unless required by applicable law or agreed to in writing, software
11
* distributed under the License is distributed on an "AS IS" BASIS,
12
* WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
* See the License for the specific language governing permissions and
14
* limitations under the License.
15
*------------------------------------------------------------------
16
*/
17
18
/**
19
* QoS types
20
*/
21
22
#include <
vnet/qos/qos_types.h
>
23
24
static
const
char
*
qos_source_names
[] =
QOS_SOURCE_NAMES
;
25
26
u8
*
27
format_qos_source
(
u8
* s, va_list * args)
28
{
29
int
qs = va_arg (*args,
int
);
30
31
return
(
format
(s,
"%s"
,
qos_source_names
[qs]));
32
}
33
34
uword
35
unformat_qos_source
(
unformat_input_t
* input, va_list * args)
36
{
37
int
*qs = va_arg (*args,
int
*);
38
39
if
(
unformat
(input,
"ip"
))
40
*qs =
QOS_SOURCE_IP
;
41
else
if
(
unformat
(input,
"mpls"
))
42
*qs =
QOS_SOURCE_MPLS
;
43
else
if
(
unformat
(input,
"ext"
))
44
*qs =
QOS_SOURCE_EXT
;
45
else
if
(
unformat
(input,
"vlan"
))
46
*qs =
QOS_SOURCE_VLAN
;
47
else
48
return
0;
49
50
return
1;
51
}
52
53
/*
54
* fd.io coding-style-patch-verification: ON
55
*
56
* Local Variables:
57
* eval: (c-set-style "gnu")
58
* End:
59
*/
QOS_SOURCE_EXT
@ QOS_SOURCE_EXT
Some external source, e.g.
Definition:
qos_types.h:35
unformat_qos_source
uword unformat_qos_source(unformat_input_t *input, va_list *args)
Definition:
qos_types.c:35
QOS_SOURCE_MPLS
@ QOS_SOURCE_MPLS
Definition:
qos_types.h:37
qos_types.h
unformat_input_t
struct _unformat_input_t unformat_input_t
QOS_SOURCE_NAMES
#define QOS_SOURCE_NAMES
Definition:
qos_types.h:47
unformat
uword unformat(unformat_input_t *i, const char *fmt,...)
Definition:
unformat.c:978
qos_source_names
static const char * qos_source_names[]
QoS types.
Definition:
qos_types.c:24
QOS_SOURCE_VLAN
@ QOS_SOURCE_VLAN
Definition:
qos_types.h:36
format_qos_source
u8 * format_qos_source(u8 *s, va_list *args)
format/unformat QoS source types
Definition:
qos_types.c:27
uword
u64 uword
Definition:
types.h:112
format
description fragment has unexpected format
Definition:
map.api:433
u8
unsigned char u8
Definition:
types.h:56
QOS_SOURCE_IP
@ QOS_SOURCE_IP
Definition:
qos_types.h:38
src
vnet
qos
qos_types.c
Generated on Sat Jan 8 2022 10:05:25 for FD.io VPP by
1.8.17