2 * Copyright (c) 2016 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:
7 * http://www.apache.org/licenses/LICENSE-2.0
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.
19 #include <vnet/vnet.h>
20 #include <vnet/dpo/dpo.h>
23 * A representation of a MAP DPO
25 typedef struct map_dpo_t
28 * The dat-plane protocol
33 * the MAP domain index
38 * Number of locks/users of the label
43 extern void map_dpo_create (dpo_proto_t dproto,
46 extern void map_t_dpo_create (dpo_proto_t dproto,
50 extern u8* format_map_dpo(u8 *s, va_list *args);
53 * Encapsulation violation for fast data-path access
55 extern map_dpo_t *map_dpo_pool;
56 extern dpo_type_t map_dpo_type;
57 extern dpo_type_t map_t_dpo_type;
59 static inline map_dpo_t *
60 map_dpo_get (index_t index)
62 return (pool_elt_at_index(map_dpo_pool, index));
65 extern void map_dpo_module_init(void);