]>
Commit | Line | Data |
---|---|---|
efba0985 SM |
1 | /* |
2 | * Copyright (C) 2020 NetDEF, Inc. | |
3 | * | |
4 | * This program is free software; you can redistribute it and/or modify it | |
5 | * under the terms of the GNU General Public License as published by the Free | |
6 | * Software Foundation; either version 2 of the License, or (at your option) | |
7 | * any later version. | |
8 | * | |
9 | * This program is distributed in the hope that it will be useful, but WITHOUT | |
10 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | |
11 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | |
12 | * more details. | |
13 | * | |
14 | * You should have received a copy of the GNU General Public License along | |
15 | * with this program; see the file COPYING; if not, write to the Free Software | |
16 | * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA | |
17 | */ | |
18 | ||
19 | #ifndef _PATH_PCEP_CONFIG_H_ | |
20 | #define _PATH_PCEP_CONFIG_H_ | |
21 | ||
22 | #include <stdbool.h> | |
23 | #include <debug.h> | |
24 | ||
25 | #include "pathd/path_pcep.h" | |
26 | ||
27 | #define PATH_NB_NO_CHANGE 0 | |
28 | #define PATH_NB_OK 1 | |
29 | #define PATH_NB_ERR -1 | |
30 | ||
31 | typedef int (*path_list_cb_t)(struct path *path, void *arg); | |
32 | ||
33 | /* Lookup the candidate path and fill up the missing path attributes like name | |
74971473 JG |
34 | * and type. Used for path generated from PCEP message received from the PCE |
35 | * so they contains more information about the candidate path. If no matching | |
36 | * policy or candidate path is found, nothing is changed. | |
37 | * MUST BE CALLED FROM THE MAIN THREAD */ | |
38 | void path_pcep_refine_path(struct path *path); | |
efba0985 SM |
39 | struct path *path_pcep_config_get_path(struct lsp_nb_key *key); |
40 | void path_pcep_config_list_path(path_list_cb_t cb, void *arg); | |
ab7fe289 | 41 | int path_pcep_config_initiate_path(struct path *path); |
efba0985 SM |
42 | int path_pcep_config_update_path(struct path *path); |
43 | struct path *candidate_to_path(struct srte_candidate *candidate); | |
44 | ||
45 | ||
46 | #endif // _PATH_PCEP_CONFIG_H_ |