]>
git.proxmox.com Git - mirror_frr.git/blob - lib/spf_backoff.h
2 * This is an implementation of the IETF SPF delay algorithm
3 * as explained in draft-ietf-rtgwg-backoff-algo-04
5 * Created: 25-01-2017 by S. Litkowski
7 * Copyright (C) 2017 Orange Labs http://www.orange.com/
8 * Copyright (C) 2017 by Christian Franke, Open Source Routing / NetDEF Inc.
10 * This file is part of FreeRangeRouting (FRR)
12 * FRR is free software; you can redistribute it and/or modify it
13 * under the terms of the GNU General Public License as published by the
14 * Free Software Foundation; either version 2, or (at your option) any
17 * FRR is distributed in the hope that it will be useful, but
18 * WITHOUT ANY WARRANTY; without even the implied warranty of
19 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU
20 * General Public License for more details.
22 * You should have received a copy of the GNU General Public License
23 * along with FRR; see the file COPYING. If not, write to the Free
24 * Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
27 #ifndef _ZEBRA_SPF_BACKOFF_H
28 #define _ZEBRA_SPF_BACKOFF_H
34 struct spf_backoff
*spf_backoff_new(struct thread_master
*m
,
42 void spf_backoff_free(struct spf_backoff
*backoff
);
44 /* Called whenever an IGP event is received, returns how many
45 * milliseconds routing table computation should be delayed */
46 long spf_backoff_schedule(struct spf_backoff
*backoff
);
48 /* Shows status of SPF backoff instance */
49 void spf_backoff_show(struct spf_backoff
*backoff
,
53 /* Writes out global SPF backoff debug config */
54 int spf_backoff_write_config(struct vty
*vty
);
56 /* Registers global SPF backoff debug commands */
57 void spf_backoff_cmd_init(void);
59 /* Accessor functions for SPF backoff parameters */
60 long spf_backoff_init_delay(struct spf_backoff
*backoff
);
61 long spf_backoff_short_delay(struct spf_backoff
*backoff
);
62 long spf_backoff_long_delay(struct spf_backoff
*backoff
);
63 long spf_backoff_holddown(struct spf_backoff
*backoff
);
64 long spf_backoff_timetolearn(struct spf_backoff
*backoff
);