From: Carmine Scarpitta Date: Thu, 13 Feb 2025 10:03:18 +0000 (+0100) Subject: staticd: Extend `static_zebra_srv6_sid_uninstall` to uninstall SRv6 uA SIDs X-Git-Url: https://git.puffer.fish/?a=commitdiff_plain;h=95abf9d678806ff7bd9eeee8da6302ddb55f1773;p=matthieu%2Ffrr.git staticd: Extend `static_zebra_srv6_sid_uninstall` to uninstall SRv6 uA SIDs This commit extends the `static_zebra_srv6_sid_uninstall` function to allow staticd to remove SRv6 uA SIDs from the zebra RIB. Signed-off-by: Carmine Scarpitta --- diff --git a/staticd/static_zebra.c b/staticd/static_zebra.c index 83d123e655..9a5e0efc4d 100644 --- a/staticd/static_zebra.c +++ b/staticd/static_zebra.c @@ -842,12 +842,20 @@ void static_zebra_srv6_sid_uninstall(struct static_srv6_sid *sid) return; } break; + case SRV6_ENDPOINT_BEHAVIOR_END_X_NEXT_CSID: + ctx.nh6 = sid->attributes.nh6; + ifp = if_lookup_by_name(sid->attributes.ifname, VRF_DEFAULT); + if (!ifp) { + zlog_warn("Failed to install SID %pFX: failed to get interface %s", + &sid->addr, sid->attributes.ifname); + return; + } + break; case SRV6_ENDPOINT_BEHAVIOR_END_PSP_USD: case SRV6_ENDPOINT_BEHAVIOR_END_NEXT_CSID_PSP_USD: case SRV6_ENDPOINT_BEHAVIOR_END_X: case SRV6_ENDPOINT_BEHAVIOR_END_X_PSP: case SRV6_ENDPOINT_BEHAVIOR_END_X_PSP_USD: - case SRV6_ENDPOINT_BEHAVIOR_END_X_NEXT_CSID: case SRV6_ENDPOINT_BEHAVIOR_END_X_NEXT_CSID_PSP: case SRV6_ENDPOINT_BEHAVIOR_END_X_NEXT_CSID_PSP_USD: case SRV6_ENDPOINT_BEHAVIOR_OPAQUE: