FD.io VPP  v20.05-21-gb1500e9ff
Vector Packet Processing
counter_types.h
Go to the documentation of this file.
1 /*
2  * Copyright (c) 2018 Cisco and/or its affiliates.
3  * Licensed under the Apache License, Version 2.0 (the "License");
4  * you may not use this file except in compliance with the License.
5  * You may obtain a copy of the License at:
6  *
7  * http://www.apache.org/licenses/LICENSE-2.0
8  *
9  * Unless required by applicable law or agreed to in writing, software
10  * distributed under the License is distributed on an "AS IS" BASIS,
11  * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
12  * See the License for the specific language governing permissions and
13  * limitations under the License.
14  */
15 
16 #ifndef included_vlib_counter_types_h
17 #define included_vlib_counter_types_h
18 
19 #include <stdint.h>
20 
21 /** 64bit counters */
22 typedef uint64_t counter_t;
23 
24 /** Combined counter to hold both packets and byte differences.
25  */
26 typedef struct
27 {
28  counter_t packets; /**< packet counter */
29  counter_t bytes; /**< byte counter */
31 
32 #endif
Combined counter to hold both packets and byte differences.
Definition: counter_types.h:26
uint64_t counter_t
64bit counters
Definition: counter_types.h:22
counter_t packets
packet counter
Definition: counter_types.h:28
counter_t bytes
byte counter
Definition: counter_types.h:29