]> git.proxmox.com Git - mirror_frr.git/commitdiff
bgpd: use DLIST for adv_fifo
authorDavid Lamparter <equinox@diac24.net>
Mon, 20 May 2019 21:41:16 +0000 (23:41 +0200)
committerDavid Lamparter <equinox@diac24.net>
Tue, 21 May 2019 20:46:48 +0000 (22:46 +0200)
I mistakenly assumed that something called "FIFO" would primarily be
used by removing items from the front.  This isn't the case for the
adv_fifo... so use a DLIST there to make sure deletions from the middle
of the queue are fast.

Signed-off-by: David Lamparter <equinox@diac24.net>
(cherry picked from commit 5ac8ecbabd9638f726fdff5d49b43e675a47e434)

bgpd/bgp_advertise.h

index cc845b93e751a025a7120231bd834080193fec3c..502c72a5eeacc2096c2dff20b718d7ff9eda0524 100644 (file)
@@ -23,7 +23,7 @@
 
 #include "lib/typesafe.h"
 
-PREDECL_LIST(bgp_adv_fifo)
+PREDECL_DLIST(bgp_adv_fifo)
 
 struct update_subgroup;
 
@@ -60,7 +60,7 @@ struct bgp_advertise {
        struct bgp_path_info *pathi;
 };
 
-DECLARE_LIST(bgp_adv_fifo, struct bgp_advertise, fifo)
+DECLARE_DLIST(bgp_adv_fifo, struct bgp_advertise, fifo)
 
 /* BGP adjacency out.  */
 struct bgp_adj_out {