Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 1a14fbcb authored by Peter Pan(潘卫平)'s avatar Peter Pan(潘卫平) Committed by David S. Miller
Browse files

bonding:delete agg_select_mode from ad_bond_info



bond_params->ad_select and ad_bond_info->agg_select_mode have the same
meaning, they are duplicate and need extra synchronization.

__get_agg_selection_mode() get ad_select from bond_params directly.

Signed-off-by: default avatarWeiping Pan <panweiping3@gmail.com>
Signed-off-by: default avatarJay Vosburgh <fubar@us.ibm.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 56d00c67
Loading
Loading
Loading
Loading
+1 −2
Original line number Diff line number Diff line
@@ -262,7 +262,7 @@ static inline u32 __get_agg_selection_mode(struct port *port)
	if (bond == NULL)
		return BOND_AD_STABLE;

	return BOND_AD_INFO(bond).agg_select_mode;
	return bond->params.ad_select;
}

/**
@@ -1859,7 +1859,6 @@ static void ad_marker_response_received(struct bond_marker *marker,
void bond_3ad_initiate_agg_selection(struct bonding *bond, int timeout)
{
	BOND_AD_INFO(bond).agg_select_timer = timeout;
	BOND_AD_INFO(bond).agg_select_mode = bond->params.ad_select;
}

static u16 aggregator_identifier;
+0 −1
Original line number Diff line number Diff line
@@ -253,7 +253,6 @@ struct ad_system {
struct ad_bond_info {
	struct ad_system system;	    /* 802.3ad system structure */
	u32 agg_select_timer;	    // Timer to select aggregator after all adapter's hand shakes
	u32 agg_select_mode;	    // Mode of selection of active aggregator(bandwidth/count)
	struct timer_list ad_timer;
};