mirror of
https://gitlab.nic.cz/labs/bird.git
synced 2024-12-22 17:51:53 +00:00
Nest: Use 'distance' instead of 'preference'
This commit is contained in:
parent
bf58ebc0bb
commit
8777f29783
@ -410,7 +410,7 @@ CF_KEYWORDS(FUNCTION, PRINT, PRINTN, UNSET, RETURN,
|
|||||||
IF, THEN, ELSE, CASE,
|
IF, THEN, ELSE, CASE,
|
||||||
TRUE, FALSE, RT, RO, UNKNOWN, GENERIC,
|
TRUE, FALSE, RT, RO, UNKNOWN, GENERIC,
|
||||||
FROM, GW, NET, MASK, PROTO, SOURCE, SCOPE, DEST, IFNAME, IFINDEX,
|
FROM, GW, NET, MASK, PROTO, SOURCE, SCOPE, DEST, IFNAME, IFINDEX,
|
||||||
PREFERENCE,
|
PREFERENCE, DISTANCE,
|
||||||
ROA_CHECK, ASN,
|
ROA_CHECK, ASN,
|
||||||
IS_V4, IS_V6,
|
IS_V4, IS_V6,
|
||||||
LEN, MAXLEN,
|
LEN, MAXLEN,
|
||||||
@ -886,6 +886,7 @@ term:
|
|||||||
| constructor { $$ = $1; }
|
| constructor { $$ = $1; }
|
||||||
|
|
||||||
| PREFERENCE { $$ = f_new_inst(FI_PREF_GET); }
|
| PREFERENCE { $$ = f_new_inst(FI_PREF_GET); }
|
||||||
|
| DISTANCE { $$ = f_new_inst(FI_PREF_GET); }
|
||||||
|
|
||||||
| rtadot static_attr { $$ = f_new_inst_sa(FI_RTA_GET, $2); }
|
| rtadot static_attr { $$ = f_new_inst_sa(FI_RTA_GET, $2); }
|
||||||
|
|
||||||
@ -1031,6 +1032,10 @@ cmd:
|
|||||||
$$ = f_new_inst(FI_PREF_SET);
|
$$ = f_new_inst(FI_PREF_SET);
|
||||||
$$->a1.p = $3;
|
$$->a1.p = $3;
|
||||||
}
|
}
|
||||||
|
| DISTANCE '=' term ';' {
|
||||||
|
$$ = f_new_inst(FI_PREF_SET);
|
||||||
|
$$->a1.p = $3;
|
||||||
|
}
|
||||||
| UNSET '(' rtadot dynamic_attr ')' ';' {
|
| UNSET '(' rtadot dynamic_attr ')' ';' {
|
||||||
$$ = f_new_inst_da(FI_EA_SET, $4);
|
$$ = f_new_inst_da(FI_EA_SET, $4);
|
||||||
$$->aux = EAF_TYPE_UNDEF | EAF_TEMP;
|
$$->aux = EAF_TYPE_UNDEF | EAF_TEMP;
|
||||||
|
@ -64,7 +64,7 @@ proto_postconfig(void)
|
|||||||
|
|
||||||
CF_DECLS
|
CF_DECLS
|
||||||
|
|
||||||
CF_KEYWORDS(ROUTER, ID, PROTOCOL, TEMPLATE, PREFERENCE, DISABLED, DEBUG, ALL, OFF, DIRECT)
|
CF_KEYWORDS(ROUTER, ID, PROTOCOL, TEMPLATE, PREFERENCE, DISTANCE, DISABLED, DEBUG, ALL, OFF, DIRECT)
|
||||||
CF_KEYWORDS(INTERFACE, IMPORT, EXPORT, FILTER, NONE, VRF, TABLE, STATES, ROUTES, FILTERS)
|
CF_KEYWORDS(INTERFACE, IMPORT, EXPORT, FILTER, NONE, VRF, TABLE, STATES, ROUTES, FILTERS)
|
||||||
CF_KEYWORDS(IPV4, IPV6, VPN4, VPN6, ROA4, ROA6, FLOW4, FLOW6, SADR, MPLS)
|
CF_KEYWORDS(IPV4, IPV6, VPN4, VPN6, ROA4, ROA6, FLOW4, FLOW6, SADR, MPLS)
|
||||||
CF_KEYWORDS(RECEIVE, LIMIT, ACTION, WARN, BLOCK, RESTART, DISABLE, KEEP, FILTERED)
|
CF_KEYWORDS(RECEIVE, LIMIT, ACTION, WARN, BLOCK, RESTART, DISABLE, KEEP, FILTERED)
|
||||||
@ -230,6 +230,7 @@ channel_item:
|
|||||||
| IMPORT LIMIT limit_spec { this_channel->in_limit = $3; }
|
| IMPORT LIMIT limit_spec { this_channel->in_limit = $3; }
|
||||||
| EXPORT LIMIT limit_spec { this_channel->out_limit = $3; }
|
| EXPORT LIMIT limit_spec { this_channel->out_limit = $3; }
|
||||||
| PREFERENCE expr { this_channel->preference = $2; check_u16($2); }
|
| PREFERENCE expr { this_channel->preference = $2; check_u16($2); }
|
||||||
|
| DISTANCE expr { this_channel->preference = $2; check_u16($2); }
|
||||||
| IMPORT KEEP FILTERED bool { this_channel->in_keep_filtered = $4; }
|
| IMPORT KEEP FILTERED bool { this_channel->in_keep_filtered = $4; }
|
||||||
;
|
;
|
||||||
|
|
||||||
|
@ -1658,7 +1658,7 @@ channel_show_info(struct channel *c)
|
|||||||
cli_msg(-1006, " Channel %s", c->name);
|
cli_msg(-1006, " Channel %s", c->name);
|
||||||
cli_msg(-1006, " State: %s", c_states[c->channel_state]);
|
cli_msg(-1006, " State: %s", c_states[c->channel_state]);
|
||||||
cli_msg(-1006, " Table: %s", c->table->name);
|
cli_msg(-1006, " Table: %s", c->table->name);
|
||||||
cli_msg(-1006, " Preference: %d", c->preference);
|
cli_msg(-1006, " Distance: %d", c->preference);
|
||||||
cli_msg(-1006, " Input filter: %s", filter_name(c->in_filter));
|
cli_msg(-1006, " Input filter: %s", filter_name(c->in_filter));
|
||||||
cli_msg(-1006, " Output filter: %s", filter_name(c->out_filter));
|
cli_msg(-1006, " Output filter: %s", filter_name(c->out_filter));
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user