Home
last modified time | relevance | path

Searched full:bond (Results 1 – 25 of 86) sorted by relevance

1234

/linux/drivers/net/bonding/
H A Dbond_options.c3 * drivers/net/bond/bond_options.c - bonding options
21 static int bond_option_active_slave_set(struct bonding *bond,
23 static int bond_option_miimon_set(struct bonding *bond,
25 static int bond_option_updelay_set(struct bonding *bond,
27 static int bond_option_downdelay_set(struct bonding *bond,
29 static int bond_option_peer_notif_delay_set(struct bonding *bond,
31 static int bond_option_use_carrier_set(struct bonding *bond,
33 static int bond_option_arp_interval_set(struct bonding *bond,
35 static int bond_option_arp_ip_target_add(struct bonding *bond, __be32 target);
36 static int bond_option_arp_ip_target_rem(struct bonding *bond, __be32 target);
[all …]
H A Dbond_main.c268 static bool bond_time_in_interval(struct bonding *bond, unsigned long last_act,
295 * @bond: bond device that got this skb for tx.
299 netdev_tx_t bond_dev_queue_xmit(struct bonding *bond, struct sk_buff *skb, in bond_dev_queue_xmit() argument
308 if (unlikely(netpoll_tx_running(bond->dev))) in bond_dev_queue_xmit()
309 return bond_netpoll_send_skb(bond_get_slave_by_dev(bond, slave_dev), skb); in bond_dev_queue_xmit()
314 static bool bond_sk_check(struct bonding *bond) in bond_sk_check() argument
316 switch (BOND_MODE(bond)) { in bond_sk_check()
319 if (bond->params.xmit_policy == BOND_XMIT_POLICY_LAYER34) in bond_sk_check()
346 bool bond_xdp_check(struct bonding *bond, int mode) in bond_xdp_check() argument
348 return __bond_xdp_check(mode, bond->params.xmit_policy); in bond_xdp_check()
[all …]
H A Dbond_procfs.c14 struct bonding *bond = pde_data(file_inode(seq->file)); in bond_info_seq_start() local
24 bond_for_each_slave_rcu(bond, slave, iter) in bond_info_seq_start()
33 struct bonding *bond = pde_data(file_inode(seq->file)); in bond_info_seq_next() local
40 return bond_first_slave_rcu(bond); in bond_info_seq_next()
42 bond_for_each_slave_rcu(bond, slave, iter) { in bond_info_seq_next()
60 struct bonding *bond = pde_data(file_inode(seq->file)); in bond_info_show_master() local
65 curr = rcu_dereference(bond->curr_active_slave); in bond_info_show_master()
68 bond_mode_name(BOND_MODE(bond))); in bond_info_show_master()
70 if (BOND_MODE(bond) == BOND_MODE_ACTIVEBACKUP && in bond_info_show_master()
71 bond->params.fail_over_mac) { in bond_info_show_master()
[all …]
H A Dbond_debugfs.c20 struct bonding *bond = m->private; in bond_debug_rlb_hash_show() local
21 struct alb_bond_info *bond_info = &(BOND_ALB_INFO(bond)); in bond_debug_rlb_hash_show()
25 if (BOND_MODE(bond) != BOND_MODE_ALB) in bond_debug_rlb_hash_show()
31 spin_lock_bh(&bond->mode_lock); in bond_debug_rlb_hash_show()
50 spin_unlock_bh(&bond->mode_lock); in bond_debug_rlb_hash_show()
56 void bond_debug_register(struct bonding *bond) in bond_debug_register() argument
58 bond->debug_dir = in bond_debug_register()
59 debugfs_create_dir(bond->dev->name, bonding_debug_root); in bond_debug_register()
61 debugfs_create_file("rlb_hash_table", 0400, bond->debug_dir, in bond_debug_register()
62 bond, &bond_debug_rlb_hash_fops); in bond_debug_register()
[all …]
H A Dbond_sysfs_slave.c2 /* Sysfs attributes of bond slaves
64 if (BOND_MODE(slave->bond) == BOND_MODE_8023AD) { in ad_aggregator_id_show()
79 if (BOND_MODE(slave->bond) == BOND_MODE_8023AD) { in ad_actor_oper_port_state_show()
94 if (BOND_MODE(slave->bond) == BOND_MODE_8023AD) { in ad_partner_oper_port_state_show()
/linux/include/net/
H A Dbonding.h3 * Bond several ethernet interfaces into a Cisco, running 'Etherchannel'.
51 #define BOND_MODE(bond) ((bond)->params.mode) argument
54 #define bond_slave_list(bond) (&(bond)->dev->adj_list.lower) argument
56 #define bond_has_slaves(bond) !list_empty(bond_slave_list(bond)) argument
59 #define bond_first_slave(bond) \ argument
60 (bond_has_slaves(bond) ? \
61 netdev_adjacent_get_private(bond_slave_list(bond)->next) : \
63 #define bond_last_slave(bond) \ argument
64 (bond_has_slaves(bond) ? \
65 netdev_adjacent_get_private(bond_slave_list(bond)->prev) : \
[all …]
H A Dbond_alb.h14 #define BOND_ALB_INFO(bond) ((bond)->alb_info) argument
23 #define BOND_ALB_LP_INTERVAL(bond) (bond->params.lp_interval) /* In seconds, periodic send of argument
30 #define BOND_ALB_LP_TICKS(bond) (BOND_ALB_LP_INTERVAL(bond) \ argument
153 int bond_alb_initialize(struct bonding *bond, int rlb_enabled);
154 void bond_alb_deinitialize(struct bonding *bond);
155 int bond_alb_init_slave(struct bonding *bond, struct slave *slave);
156 void bond_alb_deinit_slave(struct bonding *bond, struct slave *slave);
157 void bond_alb_handle_link_change(struct bonding *bond, struct slave *slave, char link);
158 void bond_alb_handle_active_change(struct bonding *bond, struct slave *new_slave);
161 struct slave *bond_xmit_alb_slave_get(struct bonding *bond,
[all …]
/linux/tools/testing/selftests/bpf/prog_tests/
H A Dxdp_bonding.c7 * and verifies that XDP_TX program loaded on a bond device
149 SYS(fail, "ip link add bond1 type bond mode %s xmit_hash_policy %s", in bonding_setup()
152 SYS(fail, "ip -netns ns_dst link add bond2 type bond mode %s xmit_hash_policy %s", in bonding_setup()
329 * to neither the ingress bond device (bond2) or its slave (veth2_1).
379 /* Test that XDP programs cannot be attached to both the bond master and slaves simultaneously */
384 int veth, bond, err; in test_xdp_bonding_attach() local
388 if (!ASSERT_OK(system("ip link add bond type bond"), "add bond")) in test_xdp_bonding_attach()
394 bond = if_nametoindex("bond"); in test_xdp_bonding_attach()
395 if (!ASSERT_GE(bond, 0, "if_nametoindex bond")) in test_xdp_bonding_attach()
403 err = system("ip link set veth master bond"); in test_xdp_bonding_attach()
[all …]
/linux/drivers/net/ethernet/microchip/lan966x/
H A Dlan966x_lag.c32 if (!port || !port->bond) in lan966x_lag_set_aggr_pgids()
42 struct net_device *bond; in lan966x_lag_set_aggr_pgids() local
46 if (!port || !port->bond || (visited & BIT(lag))) in lan966x_lag_set_aggr_pgids()
49 bond = port->bond; in lan966x_lag_set_aggr_pgids()
50 bond_mask = lan966x_lag_get_mask(lan966x, bond); in lan966x_lag_set_aggr_pgids()
87 if (port->bond == bond) in lan966x_lag_set_aggr_pgids()
107 bond_mask = lan966x_lag_get_mask(lan966x, port->bond); in lan966x_lag_set_port_ids()
126 struct net_device *bond, in lan966x_lag_port_join() argument
135 bond_mask = lan966x_lag_get_mask(lan966x, bond); in lan966x_lag_port_join()
139 port->bond = bond; in lan966x_lag_port_join()
[all …]
/linux/tools/testing/selftests/drivers/net/bonding/
H A Dbond-eth-type-change.sh4 # Test bond device ether type changing
21 check_err $? "MASTER flag is missing from the bond device"
24 check_err $? "SLAVE flag is missing from the bond device"
27 # test enslaved bond dev type change from ARPHRD_ETHER and back
40 ip link add name "$devbond0" type bond
43 ip link set dev "$devbond0" type bond mode active-backup
44 check_err $? "could not change bond mode to active-backup"
46 ip link add name "$devbond1" type bond
47 ip link add name "$devbond2" type bond
50 # change bond type to non-ARPHRD_ETHER
[all …]
H A Dbond-break-lacpdu-tx.sh6 # the bond.
32 ip link del veth1-bond >/dev/null 2>&1 || :
33 ip link del veth2-bond >/dev/null 2>&1 || :
43 # create the bond
44 ip link add fbond type bond mode 4 miimon 200 xmit_hash_policy 1 \
47 # set bond address
51 # set again bond sysfs parameters
52 ip link set fbond type bond ad_actor_sys_prio 65535
55 ip link add name veth1-bond type veth peer name veth1-end
56 ip link add name veth2-bond type veth peer name veth2-end
[all …]
H A Dbond_options.sh39 ip -n ${s_ns} link add bond1 type bond ns_ip6_target ${g_ip6}
75 # create bond
78 ip -n ${s_ns} link set bond0 type bond active_slave eth1
143 # Test changing bond slave prio
190 log_test_skip "prio ns" "Current iproute or kernel doesn't support bond option 'ns_ip6_target'."
205 log_test_skip "prio" "Current iproute or kernel doesn't support bond option 'prio'."
230 # create bond
311 …log_test_skip "arp_validate ns" "Current iproute or kernel doesn't support bond option 'ns_ip6_tar…
335 # create bond
398 # bond mac address should be same with the first added slave
[all …]
H A Dbond_passive_lacp.sh4 # Test if a bond interface works with lacp_active=off.
48 ip -n "${s_ns}" link add bond0 type bond mode 802.3ad lacp_active on lacp_rate fast
52 ip -n "${c_ns}" link add bond0 type bond mode 802.3ad lacp_active off lacp_rate fast
61 # The bond will send 2 lacpdu pkts during init time, let's wait at least 2s
85 log_test "bond 802.3ad lacp_active off" "port connection"
92 # Due to Periodic Machine and Rx Machine state change, the bond will still
99 log_test "bond 802.3ad lacp_active on" "port pkt after disconnect"
103 log_test "bond 802.3ad lacp_active off" "port pkt after disconnect"
H A Ddev_addr_lists.sh4 # Test bond device handling of addr lists (dev->uc, mc)
40 # bond driver control paths vary between modes that have a primary slave
58 # Initial state of bond device, up | down
63 ip link add bond1 "$init_state" type bond mode 802.3ad
84 log_test "bonding LACPDU multicast address to slave (from bond $init_state)"
88 # of the bond when enslaving a device. Test both cases.
H A Dnetcons_over_bonding.sh64 if ! ip -n "${TXNS}" link add "${BOND_TX_MAIN_IF}" type bond mode balance-rr
66 echo "Failed to create bond TX interface. Is CONFIG_BONDING set?" >&2
89 link add "${BOND_RX_MAIN_IF}" type bond mode balance-rr
106 # and the other two will be bond to the RX interface (on the other namespace)
190 link delete "${BOND_TX_MAIN_IF}" type bond
192 # BOND_TX1_SLAVE_IF is not attached to a bond interface anymore
237 link add "${BOND_TX_MAIN_IF}" type bond mode balance-rr
251 echo "test failed: Device is part of a bond iface, cannot have netcons enabled" >&2
334 # Test #3: Unplug the sub-interface from bond and enable netconsole
346 # Enslave an interface to a bond interface that has netpoll attached
[all …]
H A DMakefile5 bond-arp-interval-causes-panic.sh \
6 bond-break-lacpdu-tx.sh \
7 bond-eth-type-change.sh \
8 bond-lladdr-target.sh \
H A Dlag_lib.sh21 ip link add "$name" up type bond mode "$mode"
147 ip netns exec ${CLIENT} ip link add bond0 type bond $@
164 # force the links of the bond down
174 check_err $rc "Bond failed to recover"
175 log_test "$1 ($2) bond recovery"
H A Dmode-2-recovery-updelay.sh5 # When the bond is configured with down/updelay and the link state of
6 # slave members flaps if there are no remaining members up the bond
17 # | | bond | link2 | Br0 | |
H A Dmode-1-recovery-updelay.sh5 # When the bond is configured with down/updelay and the link state of
6 # slave members flaps if there are no remaining members up the bond
17 # | | bond | link2 | Br0 | |
/linux/drivers/net/ethernet/mellanox/mlx5/core/en/rep/
H A Dbond.c27 /* private of uplink holding rep bond metadata list */
42 list_for_each_entry(cur, &uplink_priv->bond->metadata_list, list) { in mlx5e_lookup_rep_bond_metadata()
107 list_add(&mdata->list, &rpriv->uplink_priv.bond->metadata_list); in mlx5e_rep_bond_enslave()
268 /* Bond device of representors and netdev events are used here in specific way
271 * also change the traditional behavior of lower dev under bond device.
273 * of bond device are not supported.
280 struct mlx5e_rep_bond *bond; in mlx5e_rep_esw_bond_netevent() local
286 bond = container_of(nb, struct mlx5e_rep_bond, nb); in mlx5e_rep_esw_bond_netevent()
289 /* Verify VF representor is on the same device of the bond handling the netevent. */ in mlx5e_rep_esw_bond_netevent()
290 if (rpriv->uplink_priv.bond != bond) in mlx5e_rep_esw_bond_netevent()
[all …]
/linux/tools/testing/selftests/net/
H A Dvlan_hw_filter.sh41 ip netns exec ${NETNS} ip link add bond0 type bond mode 0
55 ip netns exec ${NETNS} ip link add bond0 type bond mode 0
69 ip netns exec ${NETNS} ip link add bond0 type bond mode 0
84 ip netns exec ${NETNS} ip link add bond0 type bond mode 0
96 ip netns exec ${NETNS} ip link add bond0 up type bond mode 0
/linux/drivers/net/ethernet/mscc/
H A Docelot.c1721 static u32 ocelot_get_bond_mask(struct ocelot *ocelot, struct net_device *bond) in ocelot_get_bond_mask() argument
1734 if (ocelot_port->bond == bond) in ocelot_get_bond_mask()
1744 int ocelot_bond_get_id(struct ocelot *ocelot, struct net_device *bond) in ocelot_bond_get_id() argument
1746 int bond_mask = ocelot_get_bond_mask(ocelot, bond); in ocelot_bond_get_id()
1781 if (cpu->bond) in ocelot_dsa_8021q_cpu_assigned_ports()
1782 mask &= ~ocelot_get_bond_mask(ocelot, cpu->bond); in ocelot_dsa_8021q_cpu_assigned_ports()
1798 if (cpu_port->bond) in ocelot_port_assigned_dsa_8021q_cpu_mask()
1799 return ocelot_get_bond_mask(ocelot, cpu_port->bond); in ocelot_port_assigned_dsa_8021q_cpu_mask()
1864 struct net_device *bond = ocelot_port->bond; in ocelot_apply_bridge_fwd_mask() local
1872 if (bond) in ocelot_apply_bridge_fwd_mask()
[all …]
/linux/drivers/infiniband/hw/hns/
H A Dhns_roce_bond.c109 dev_err(hr_dev->dev, "failed to set netdev for bond.\n"); in hns_roce_set_bond_netdev()
240 /* Prevent this device from being initialized as a bond device */ in hns_roce_slave_init()
359 BOND_ERR_LOG("failed to set RoCE bond, ret = %d.\n", ret); in hns_roce_set_bond()
363 "RoCE set bond finished!\n"); in hns_roce_set_bond()
406 "failed to change RoCE bond slave state, ret = %d.\n", in hns_roce_slave_changestate()
440 BOND_ERR_LOG("failed to change RoCE bond slave num, ret = %d.\n", ret); in hns_roce_slave_change_num()
553 "bond work: bond_ready - %d, bond_state - %d.\n", in hns_roce_bond_work()
564 /* In set_bond flow, we don't need to set bond netdev here as in hns_roce_bond_work()
612 BOND_ERR_LOG("failed to clear RoCE bond, ret = %d.\n", ret); in hns_roce_cleanup_bond()
615 "RoCE clear bond finished!\n"); in hns_roce_cleanup_bond()
[all …]
/linux/Documentation/devicetree/bindings/media/
H A Drenesas,drif.yaml40 property called "renesas,primary-bond".
44 the zeroth channel is selected as primary-bond. This channels accepts
45 properties common to all the members of the bond.
47 "renesas,bonding" or "renesas,primary-bond" will have no effect. That
93 renesas,primary-bond:
134 - renesas,primary-bond
188 renesas,primary-bond;
/linux/drivers/comedi/drivers/
H A Dcomedi_bond.c4 * A Comedi driver to 'bond' or merge multiple drivers and devices as one.
13 * Description: A driver to 'bond' (merge) multiple subdevices from multiple
20 * This driver allows you to 'bond' (merge) multiple comedi subdevices
23 * another with 1 DIO subdevice, you could 'bond' them with this driver
36 * List of comedi-minors to bond. All subdevices of the same type
196 "Cannot bond this driver to itself!\n"); in do_dev_config()
346 MODULE_DESCRIPTION("comedi_bond: A driver for COMEDI to bond multiple COMEDI devices together as on…

1234