mirror of
https://git.proxmox.com/git/mirror_frr
synced 2025-08-07 10:49:24 +00:00
Revert "zebra: Add connected with noprefixroute"
This reverts commit b311787366
.
This commit is contained in:
parent
aa5ff67844
commit
fa68e7c285
2
lib/if.h
2
lib/if.h
@ -420,8 +420,6 @@ struct connected {
|
|||||||
#define ZEBRA_IFA_SECONDARY (1 << 0)
|
#define ZEBRA_IFA_SECONDARY (1 << 0)
|
||||||
#define ZEBRA_IFA_PEER (1 << 1)
|
#define ZEBRA_IFA_PEER (1 << 1)
|
||||||
#define ZEBRA_IFA_UNNUMBERED (1 << 2)
|
#define ZEBRA_IFA_UNNUMBERED (1 << 2)
|
||||||
#define ZEBRA_IFA_NOPREFIXROUTE (1 << 3)
|
|
||||||
|
|
||||||
/* N.B. the ZEBRA_IFA_PEER flag should be set if and only if
|
/* N.B. the ZEBRA_IFA_PEER flag should be set if and only if
|
||||||
a peer address has been configured. If this flag is set,
|
a peer address has been configured. If this flag is set,
|
||||||
the destination field must contain the peer address.
|
the destination field must contain the peer address.
|
||||||
|
@ -276,15 +276,13 @@ void connected_up(struct interface *ifp, struct connected *ifc)
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
if (!CHECK_FLAG(ifc->flags, ZEBRA_IFA_NOPREFIXROUTE)) {
|
rib_add(afi, SAFI_UNICAST, zvrf->vrf->vrf_id, ZEBRA_ROUTE_CONNECT, 0,
|
||||||
rib_add(afi, SAFI_UNICAST, zvrf->vrf->vrf_id,
|
flags, &p, NULL, &nh, 0, zvrf->table_id, metric, 0, 0, 0,
|
||||||
ZEBRA_ROUTE_CONNECT, 0, flags, &p, NULL, &nh, 0,
|
false);
|
||||||
zvrf->table_id, metric, 0, 0, 0, false);
|
|
||||||
|
|
||||||
rib_add(afi, SAFI_MULTICAST, zvrf->vrf->vrf_id,
|
rib_add(afi, SAFI_MULTICAST, zvrf->vrf->vrf_id, ZEBRA_ROUTE_CONNECT, 0,
|
||||||
ZEBRA_ROUTE_CONNECT, 0, flags, &p, NULL, &nh, 0,
|
flags, &p, NULL, &nh, 0, zvrf->table_id, metric, 0, 0, 0,
|
||||||
zvrf->table_id, metric, 0, 0, 0, false);
|
false);
|
||||||
}
|
|
||||||
|
|
||||||
/* Schedule LSP forwarding entries for processing, if appropriate. */
|
/* Schedule LSP forwarding entries for processing, if appropriate. */
|
||||||
if (zvrf->vrf->vrf_id == VRF_DEFAULT) {
|
if (zvrf->vrf->vrf_id == VRF_DEFAULT) {
|
||||||
@ -459,15 +457,11 @@ void connected_down(struct interface *ifp, struct connected *ifc)
|
|||||||
* Same logic as for connected_up(): push the changes into the
|
* Same logic as for connected_up(): push the changes into the
|
||||||
* head.
|
* head.
|
||||||
*/
|
*/
|
||||||
if (!CHECK_FLAG(ifc->flags, ZEBRA_IFA_NOPREFIXROUTE)) {
|
rib_delete(afi, SAFI_UNICAST, zvrf->vrf->vrf_id, ZEBRA_ROUTE_CONNECT, 0,
|
||||||
rib_delete(afi, SAFI_UNICAST, zvrf->vrf->vrf_id,
|
0, &p, NULL, &nh, 0, zvrf->table_id, 0, 0, false);
|
||||||
ZEBRA_ROUTE_CONNECT, 0, 0, &p, NULL, &nh, 0,
|
|
||||||
zvrf->table_id, 0, 0, false);
|
|
||||||
|
|
||||||
rib_delete(afi, SAFI_MULTICAST, zvrf->vrf->vrf_id,
|
rib_delete(afi, SAFI_MULTICAST, zvrf->vrf->vrf_id, ZEBRA_ROUTE_CONNECT,
|
||||||
ZEBRA_ROUTE_CONNECT, 0, 0, &p, NULL, &nh, 0,
|
0, 0, &p, NULL, &nh, 0, zvrf->table_id, 0, 0, false);
|
||||||
zvrf->table_id, 0, 0, false);
|
|
||||||
}
|
|
||||||
|
|
||||||
/* Schedule LSP forwarding entries for processing, if appropriate. */
|
/* Schedule LSP forwarding entries for processing, if appropriate. */
|
||||||
if (zvrf->vrf->vrf_id == VRF_DEFAULT) {
|
if (zvrf->vrf->vrf_id == VRF_DEFAULT) {
|
||||||
|
@ -1331,9 +1331,6 @@ static void zebra_if_addr_update_ctx(struct zebra_dplane_ctx *ctx,
|
|||||||
if (dplane_ctx_intf_is_secondary(ctx))
|
if (dplane_ctx_intf_is_secondary(ctx))
|
||||||
SET_FLAG(flags, ZEBRA_IFA_SECONDARY);
|
SET_FLAG(flags, ZEBRA_IFA_SECONDARY);
|
||||||
|
|
||||||
if (dplane_ctx_intf_is_noprefixroute(ctx))
|
|
||||||
SET_FLAG(flags, ZEBRA_IFA_NOPREFIXROUTE);
|
|
||||||
|
|
||||||
/* Label? */
|
/* Label? */
|
||||||
if (dplane_ctx_intf_has_label(ctx))
|
if (dplane_ctx_intf_has_label(ctx))
|
||||||
label = dplane_ctx_get_intf_label(ctx);
|
label = dplane_ctx_get_intf_label(ctx);
|
||||||
@ -2410,12 +2407,6 @@ static void connected_dump_vty(struct vty *vty, json_object *json,
|
|||||||
else if (CHECK_FLAG(connected->flags, ZEBRA_IFA_SECONDARY))
|
else if (CHECK_FLAG(connected->flags, ZEBRA_IFA_SECONDARY))
|
||||||
vty_out(vty, " secondary");
|
vty_out(vty, " secondary");
|
||||||
|
|
||||||
if (json)
|
|
||||||
json_object_boolean_add(json_addr, "noPrefixRoute",
|
|
||||||
CHECK_FLAG(connected->flags, ZEBRA_IFA_NOPREFIXROUTE));
|
|
||||||
else if (CHECK_FLAG(connected->flags, ZEBRA_IFA_NOPREFIXROUTE))
|
|
||||||
vty_out(vty, " noprefixroute");
|
|
||||||
|
|
||||||
if (json)
|
if (json)
|
||||||
json_object_boolean_add(
|
json_object_boolean_add(
|
||||||
json_addr, "unnumbered",
|
json_addr, "unnumbered",
|
||||||
|
Loading…
Reference in New Issue
Block a user