static void print_explain(FILE *f)
{
- fprintf(f, "Usage: ... bond_slave [ queue_id ID ] [ prio PRIORITY ]\n");
+ fprintf(f, "Usage: ... bond_slave [ queue_id ID ] [ prio PRIORITY ]\n"
+ " [ actor_port_prio PRIORITY ]\n"
+ );
}
static void explain(void)
state);
print_slave_oper_state(f, "ad_partner_oper_port_state_str", state);
}
+
+ if (tb[IFLA_BOND_SLAVE_ACTOR_PORT_PRIO])
+ print_int(PRINT_ANY,
+ "actor_port_prio",
+ "actor_port_prio %d ",
+ rta_getattr_u16(tb[IFLA_BOND_SLAVE_ACTOR_PORT_PRIO]));
}
static int bond_slave_parse_opt(struct link_util *lu, int argc, char **argv,
struct nlmsghdr *n)
{
- __u16 queue_id;
+ __u16 queue_id, actor_port_prio;
int prio;
while (argc > 0) {
if (get_s32(&prio, *argv, 0))
invarg("prio is invalid", *argv);
addattr32(n, 1024, IFLA_BOND_SLAVE_PRIO, prio);
+ } else if (strcmp(*argv, "actor_port_prio") == 0) {
+ NEXT_ARG();
+ if (get_u16(&actor_port_prio, *argv, 0))
+ invarg("actor prio is invalid", *argv);
+ addattr16(n, 1024, IFLA_BOND_SLAVE_ACTOR_PORT_PRIO,
+ actor_port_prio);
} else {
if (matches(*argv, "help") != 0)
fprintf(stderr,
(a 32bit signed value). This option only valid for active-backup(1),
balance-tlb (5) and balance-alb (6) mode.
+.sp
+.BI actor_port_prio " PRIORITY"
+- set the slave's ad actor port priority for 802.3ad aggregation selection
+logic during failover (a 16bit unsigned value). This option only valid for
+802.3ad (4) mode.
+
.in -8
.TP