Lines Matching full:slave

265 		.desc = "Packets to send per slave in RR mode",
417 .desc = "Reselect primary slave once it comes up",
431 .desc = "Currently active slave",
441 .desc = "Set queue id of a slave",
462 …nds between instances where the bonding driver sends learning packets to each slave's peer switch",
469 .desc = "Slave membership management",
961 slave_err(bond->dev, slave_dev, "Device is not bonding slave\n"); in bond_option_active_slave_set()
966 slave_err(bond->dev, slave_dev, "Device is not our slave\n"); in bond_option_active_slave_set()
974 netdev_dbg(bond->dev, "Clearing current active slave\n"); in bond_option_active_slave_set()
978 struct slave *old_active = rtnl_dereference(bond->curr_active_slave); in bond_option_active_slave_set()
979 struct slave *new_active = bond_slave_get_rtnl(slave_dev); in bond_option_active_slave_set()
985 slave_dbg(bond->dev, new_active->dev, "is already the current active slave\n"); in bond_option_active_slave_set()
989 slave_dbg(bond->dev, new_active->dev, "Setting as active slave\n"); in bond_option_active_slave_set()
992 …slave_err(bond->dev, new_active->dev, "Could not set as active slave; either %s is down or the lin… in bond_option_active_slave_set()
1151 struct slave *slave; in _bond_options_arp_ip_target_set() local
1154 bond_for_each_slave(bond, slave, iter) in _bond_options_arp_ip_target_set()
1155 slave->target_last_arp_rx[slot] = last_rx; in _bond_options_arp_ip_target_set()
1199 struct slave *slave; in bond_option_arp_ip_target_rem() local
1221 bond_for_each_slave(bond, slave, iter) { in bond_option_arp_ip_target_rem()
1222 targets_rx = slave->target_last_arp_rx; in bond_option_arp_ip_target_rem()
1269 static bool slave_can_set_ns_maddr(const struct bonding *bond, struct slave *slave) in slave_can_set_ns_maddr() argument
1272 !bond_is_active_slave(slave) && in slave_can_set_ns_maddr()
1273 slave->dev->flags & IFF_MULTICAST; in slave_can_set_ns_maddr()
1277 * slave_set_ns_maddrs - add/del all NS mac addresses for slave
1279 * @slave: slave device
1282 * This function tries to add or delete all the NS mac addresses on the slave
1293 static void slave_set_ns_maddrs(struct bonding *bond, struct slave *slave, bool add) in slave_set_ns_maddrs() argument
1300 if (!slave_can_set_ns_maddr(bond, slave)) in slave_set_ns_maddrs()
1308 if (!ndisc_mc_map(&mcaddr, slot_maddr, slave->dev, 0)) { in slave_set_ns_maddrs()
1310 dev_mc_add(slave->dev, slot_maddr); in slave_set_ns_maddrs()
1312 dev_mc_del(slave->dev, slot_maddr); in slave_set_ns_maddrs()
1317 void bond_slave_ns_maddrs_add(struct bonding *bond, struct slave *slave) in bond_slave_ns_maddrs_add() argument
1321 slave_set_ns_maddrs(bond, slave, true); in bond_slave_ns_maddrs_add()
1324 void bond_slave_ns_maddrs_del(struct bonding *bond, struct slave *slave) in bond_slave_ns_maddrs_del() argument
1328 slave_set_ns_maddrs(bond, slave, false); in bond_slave_ns_maddrs_del()
1332 * slave_set_ns_maddr - set new NS mac address for slave
1334 * @slave: slave device
1338 * This function tries to replace the old mac address to new one on the slave.
1348 static void slave_set_ns_maddr(struct bonding *bond, struct slave *slave, in slave_set_ns_maddr() argument
1354 if (!bond->params.arp_validate || !slave_can_set_ns_maddr(bond, slave)) in slave_set_ns_maddr()
1357 /* remove the previous mac addr from slave */ in slave_set_ns_maddr()
1360 !ndisc_mc_map(&mcast_addr, mac_addr, slave->dev, 0)) in slave_set_ns_maddr()
1361 dev_mc_del(slave->dev, mac_addr); in slave_set_ns_maddr()
1363 /* add new mac addr on slave if target is set */ in slave_set_ns_maddr()
1366 !ndisc_mc_map(&mcast_addr, mac_addr, slave->dev, 0)) in slave_set_ns_maddr()
1367 dev_mc_add(slave->dev, mac_addr); in slave_set_ns_maddr()
1376 struct slave *slave; in _bond_options_ns_ip6_target_set() local
1379 bond_for_each_slave(bond, slave, iter) { in _bond_options_ns_ip6_target_set()
1380 slave->target_last_arp_rx[slot] = last_rx; in _bond_options_ns_ip6_target_set()
1381 slave_set_ns_maddr(bond, slave, target, &targets[slot]); in _bond_options_ns_ip6_target_set()
1435 static void slave_set_ns_maddrs(struct bonding *bond, struct slave *slave, bool add) {} in slave_set_ns_maddrs() argument
1437 void bond_slave_ns_maddrs_add(struct bonding *bond, struct slave *slave) {} in bond_slave_ns_maddrs_add() argument
1439 void bond_slave_ns_maddrs_del(struct bonding *bond, struct slave *slave) {} in bond_slave_ns_maddrs_del() argument
1447 struct slave *slave; in bond_option_arp_validate_set() local
1454 bond_for_each_slave(bond, slave, iter) in bond_option_arp_validate_set()
1455 slave_set_ns_maddrs(bond, slave, !!bond->params.arp_validate); in bond_option_arp_validate_set()
1484 struct slave *slave; in bond_option_prio_set() local
1486 slave = bond_slave_get_rtnl(newval->slave_dev); in bond_option_prio_set()
1487 if (!slave) { in bond_option_prio_set()
1488 netdev_dbg(newval->slave_dev, "%s called on NULL slave\n", __func__); in bond_option_prio_set()
1491 slave->prio = newval->value; in bond_option_prio_set()
1494 slave_warn(bond->dev, slave->dev, in bond_option_prio_set()
1495 "prio updated, but will not affect failover re-selection as primary slave have been set\n"); in bond_option_prio_set()
1507 struct slave *slave; in bond_option_primary_set() local
1516 netdev_dbg(bond->dev, "Setting primary slave to None\n"); in bond_option_primary_set()
1523 bond_for_each_slave(bond, slave, iter) { in bond_option_primary_set()
1524 if (strncmp(slave->dev->name, primary, IFNAMSIZ) == 0) { in bond_option_primary_set()
1525 slave_dbg(bond->dev, slave->dev, "Setting as primary slave\n"); in bond_option_primary_set()
1526 rcu_assign_pointer(bond->primary_slave, slave); in bond_option_primary_set()
1527 strcpy(bond->params.primary, slave->dev->name); in bond_option_primary_set()
1535 netdev_dbg(bond->dev, "Setting primary slave to None\n"); in bond_option_primary_set()
1606 struct slave *slave; in bond_option_all_slaves_active_set() local
1611 bond_for_each_slave(bond, slave, iter) { in bond_option_all_slaves_active_set()
1612 if (!bond_is_active_slave(slave)) { in bond_option_all_slaves_active_set()
1614 slave->inactive = 0; in bond_option_all_slaves_active_set()
1616 slave->inactive = 1; in bond_option_all_slaves_active_set()
1645 netdev_dbg(bond->dev, "Setting packets per slave to %llu\n", in bond_option_pps_set()
1697 struct slave *slave, *update_slave; in bond_option_queue_id_set() local
1726 /* Search for thes slave and check for duplicate qids */ in bond_option_queue_id_set()
1728 bond_for_each_slave(bond, slave, iter) { in bond_option_queue_id_set()
1729 if (sdev == slave->dev) in bond_option_queue_id_set()
1731 * slave for dups, since we're overwriting it in bond_option_queue_id_set()
1733 update_slave = slave; in bond_option_queue_id_set()
1734 else if (qid && qid == slave->queue_id) { in bond_option_queue_id_set()
1742 /* Actually set the qids for the slave */ in bond_option_queue_id_set()
1828 struct slave *slave; in bond_option_actor_port_prio_set() local
1830 slave = bond_slave_get_rtnl(newval->slave_dev); in bond_option_actor_port_prio_set()
1831 if (!slave) { in bond_option_actor_port_prio_set()
1832 netdev_dbg(bond->dev, "%s called on NULL slave\n", __func__); in bond_option_actor_port_prio_set()
1839 SLAVE_AD_INFO(slave)->port_priority = newval->value; in bond_option_actor_port_prio_set()