To modify Ixia port numbers and IP in pod.yaml
[kvmfornfv.git] / kernel / include / net / bonding.h
index 78ed135..93abe5f 100644 (file)
@@ -136,6 +136,9 @@ struct bond_params {
        int packets_per_slave;
        int tlb_dynamic_lb;
        struct reciprocal_value reciprocal_packets_per_slave;
+       u16 ad_actor_sys_prio;
+       u16 ad_user_port_key;
+       u8 ad_actor_system[ETH_ALEN];
 };
 
 struct bond_parm_tbl {
@@ -211,6 +214,7 @@ struct bonding {
         * ALB mode (6) - to sync the use and modifications of its hash table
         */
        spinlock_t mode_lock;
+       spinlock_t stats_lock;
        u8       send_peer_notif;
        u8       igmp_retrans;
 #ifdef CONFIG_PROC_FS
@@ -307,6 +311,13 @@ static inline bool bond_uses_primary(struct bonding *bond)
        return bond_mode_uses_primary(BOND_MODE(bond));
 }
 
+static inline struct net_device *bond_option_active_slave_get_rcu(struct bonding *bond)
+{
+       struct slave *slave = rcu_dereference(bond->curr_active_slave);
+
+       return bond_uses_primary(bond) && slave ? slave->dev : NULL;
+}
+
 static inline bool bond_slave_is_up(struct slave *slave)
 {
        return netif_running(slave->dev) && netif_carrier_ok(slave->dev);