From 54de8bbe36d7d968c6367939277942518bd4e11f Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Mon, 5 Aug 2024 11:56:24 +0200 Subject: Merging upstream version 10.1. Signed-off-by: Daniel Baumann --- bfdd/bfd.h | 4 +++- bfdd/bfd_packet.c | 6 ++++++ 2 files changed, 9 insertions(+), 1 deletion(-) (limited to 'bfdd') diff --git a/bfdd/bfd.h b/bfdd/bfd.h index 66bf706..f4ff884 100644 --- a/bfdd/bfd.h +++ b/bfdd/bfd.h @@ -105,6 +105,8 @@ struct bfd_echo_pkt { #define BFD_CBIT 0x08 #define BFD_ABIT 0x04 #define BFD_DEMANDBIT 0x02 +#define BFD_MBIT 0x01 +#define BFD_GETMBIT(flags) (flags & BFD_MBIT) #define BFD_SETDEMANDBIT(flags, val) \ { \ if ((val)) \ @@ -133,7 +135,7 @@ struct bfd_echo_pkt { if ((val)) \ flags |= val; \ } -#define BFD_GETCBIT(flags) (flags & BFD_FBIT) +#define BFD_GETCBIT(flags) (flags & BFD_CBIT) #define BFD_ECHO_VERSION 1 #define BFD_ECHO_PKT_LEN sizeof(struct bfd_echo_pkt) diff --git a/bfdd/bfd_packet.c b/bfdd/bfd_packet.c index fec195c..8110f43 100644 --- a/bfdd/bfd_packet.c +++ b/bfdd/bfd_packet.c @@ -898,6 +898,12 @@ void bfd_recv_cb(struct event *t) return; } + if (BFD_GETMBIT(cp->flags)) { + cp_debug(is_mhop, &peer, &local, ifindex, vrfid, + "detect non-zero Multipoint (M) flag"); + return; + } + if (cp->discrs.my_discr == 0) { cp_debug(is_mhop, &peer, &local, ifindex, vrfid, "'my discriminator' is zero"); -- cgit v1.2.3