]> git.proxmox.com Git - mirror_frr.git/blobdiff - bgpd/bgp_damp.h
bgpd: Allow shortened 'no set large-community' and 'no set large-comm-list'
[mirror_frr.git] / bgpd / bgp_damp.h
index 89ec1e933f1449f75b6678dcc4287230c0e5d053..18bf561c477c83114a9db5a73a4645916d96c28f 100644 (file)
@@ -1,22 +1,22 @@
 /* BGP flap dampening
  Copyright (C) 2001 IP Infusion Inc.
-
-This file is part of GNU Zebra.
-
-GNU Zebra is free software; you can redistribute it and/or modify it
-under the terms of the GNU General Public License as published by the
-Free Software Foundation; either version 2, or (at your option) any
-later version.
-
-GNU Zebra is distributed in the hope that it will be useful, but
-WITHOUT ANY WARRANTY; without even the implied warranty of
-MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
-General Public License for more details.
-
-You should have received a copy of the GNU General Public License
-along with GNU Zebra; see the file COPYING.  If not, write to the Free
-Software Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA
-02111-1307, USA.  */
* Copyright (C) 2001 IP Infusion Inc.
+ *
+ * This file is part of GNU Zebra.
+ *
+ * GNU Zebra is free software; you can redistribute it and/or modify it
+ * under the terms of the GNU General Public License as published by the
+ * Free Software Foundation; either version 2, or (at your option) any
+ * later version.
+ *
+ * GNU Zebra is distributed in the hope that it will be useful, but
+ * WITHOUT ANY WARRANTY; without even the implied warranty of
+ * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
+ * General Public License for more details.
+ *
+ * You should have received a copy of the GNU General Public License along
+ * with this program; see the file COPYING; if not, write to the Free Software
+ * Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
+ */
 
 #ifndef _QUAGGA_BGP_DAMP_H
 #define _QUAGGA_BGP_DAMP_H
@@ -43,8 +43,8 @@ struct bgp_damp_info {
        /* Time of route start to be suppressed.  */
        time_t suppress_time;
 
-       /* Back reference to bgp_info. */
-       struct bgp_info *binfo;
+       /* Back reference to bgp_path_info. */
+       struct bgp_path_info *path;
 
        /* Back reference to bgp_node. */
        struct bgp_node *rn;
@@ -53,7 +53,7 @@ struct bgp_damp_info {
        int index;
 
        /* Last time message type. */
-       u_char lastrecord;
+       uint8_t lastrecord;
 #define BGP_RECORD_UPDATE      1U
 #define BGP_RECORD_WITHDRAW    2U
 
@@ -130,19 +130,21 @@ struct bgp_damp_config {
 extern int bgp_damp_enable(struct bgp *, afi_t, safi_t, time_t, unsigned int,
                           unsigned int, time_t);
 extern int bgp_damp_disable(struct bgp *, afi_t, safi_t);
-extern int bgp_damp_withdraw(struct bgp_info *, struct bgp_node *, afi_t,
-                            safi_t, int);
-extern int bgp_damp_update(struct bgp_info *, struct bgp_node *, afi_t, safi_t);
-extern int bgp_damp_scan(struct bgp_info *, afi_t, safi_t);
-extern void bgp_damp_info_free(struct bgp_damp_info *, int);
+extern int bgp_damp_withdraw(struct bgp_path_info *path, struct bgp_node *rn,
+                            afi_t afi, safi_t safi, int attr_change);
+extern int bgp_damp_update(struct bgp_path_info *path, struct bgp_node *rn,
+                          afi_t afi, safi_t saff);
+extern int bgp_damp_scan(struct bgp_path_info *path, afi_t afi, safi_t safi);
+extern void bgp_damp_info_free(struct bgp_damp_info *path, int withdraw);
 extern void bgp_damp_info_clean(void);
 extern int bgp_damp_decay(time_t, int);
 extern void bgp_config_write_damp(struct vty *);
-extern void bgp_damp_info_vty(struct vty *, struct bgp_info *,
+extern void bgp_damp_info_vty(struct vty *vty, struct bgp_path_info *path,
                              json_object *json_path);
-extern const char *bgp_damp_reuse_time_vty(struct vty *, struct bgp_info *,
-                                          char *, size_t, u_char,
-                                          json_object *);
+extern const char *bgp_damp_reuse_time_vty(struct vty *vty,
+                                          struct bgp_path_info *path,
+                                          char *timebuf, size_t len,
+                                          bool use_json, json_object *json);
 extern int bgp_show_dampening_parameters(struct vty *vty, afi_t, safi_t);
 
 #endif /* _QUAGGA_BGP_DAMP_H */