aboutsummaryrefslogtreecommitdiffstats
path: root/drivers/net
diff options
context:
space:
mode:
authorHolger Eitzenberger <holger@eitzenberger.org>2008-12-26 16:26:54 -0500
committerDavid S. Miller <davem@davemloft.net>2008-12-26 16:26:54 -0500
commitf48127b6f3270cf7234a7a9f770533332e85e8ae (patch)
treeb92b215a91e0389fd1c48cae87dadb9e28e01bad /drivers/net
parentd238d458a70ad134cb421c3ffc66242277f30dda (diff)
802.3ad: turn ports is_enabled into a bool
Turn ports is_enabled into a bool. There is no functional change. Signed-off-by: Holger Eitzenberger <holger@eitzenberger.org> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'drivers/net')
-rw-r--r--drivers/net/bonding/bond_3ad.c6
-rw-r--r--drivers/net/bonding/bond_3ad.h3
2 files changed, 5 insertions, 4 deletions
diff --git a/drivers/net/bonding/bond_3ad.c b/drivers/net/bonding/bond_3ad.c
index 4fa92cce1bd2..86f4ba779b50 100644
--- a/drivers/net/bonding/bond_3ad.c
+++ b/drivers/net/bonding/bond_3ad.c
@@ -1679,7 +1679,7 @@ static void ad_initialize_port(struct port *port, int lacp_fast)
1679 memcpy(&port->partner_admin, &tmpl, sizeof(tmpl)); 1679 memcpy(&port->partner_admin, &tmpl, sizeof(tmpl));
1680 memcpy(&port->partner_oper, &tmpl, sizeof(tmpl)); 1680 memcpy(&port->partner_oper, &tmpl, sizeof(tmpl));
1681 1681
1682 port->is_enabled = 1; 1682 port->is_enabled = true;
1683 // ****** private parameters ****** 1683 // ****** private parameters ******
1684 port->sm_vars = 0x3; 1684 port->sm_vars = 0x3;
1685 port->sm_rx_state = 0; 1685 port->sm_rx_state = 0;
@@ -2308,14 +2308,14 @@ void bond_3ad_handle_link_change(struct slave *slave, char link)
2308 // on link down we are zeroing duplex and speed since some of the adaptors(ce1000.lan) report full duplex/speed instead of N/A(duplex) / 0(speed) 2308 // on link down we are zeroing duplex and speed since some of the adaptors(ce1000.lan) report full duplex/speed instead of N/A(duplex) / 0(speed)
2309 // on link up we are forcing recheck on the duplex and speed since some of he adaptors(ce1000.lan) report 2309 // on link up we are forcing recheck on the duplex and speed since some of he adaptors(ce1000.lan) report
2310 if (link == BOND_LINK_UP) { 2310 if (link == BOND_LINK_UP) {
2311 port->is_enabled = 1; 2311 port->is_enabled = true;
2312 port->actor_admin_port_key &= ~AD_DUPLEX_KEY_BITS; 2312 port->actor_admin_port_key &= ~AD_DUPLEX_KEY_BITS;
2313 port->actor_oper_port_key=port->actor_admin_port_key |= __get_duplex(port); 2313 port->actor_oper_port_key=port->actor_admin_port_key |= __get_duplex(port);
2314 port->actor_admin_port_key &= ~AD_SPEED_KEY_BITS; 2314 port->actor_admin_port_key &= ~AD_SPEED_KEY_BITS;
2315 port->actor_oper_port_key=port->actor_admin_port_key |= (__get_link_speed(port) << 1); 2315 port->actor_oper_port_key=port->actor_admin_port_key |= (__get_link_speed(port) << 1);
2316 } else { 2316 } else {
2317 /* link has failed */ 2317 /* link has failed */
2318 port->is_enabled = 0; 2318 port->is_enabled = false;
2319 port->actor_admin_port_key &= ~AD_DUPLEX_KEY_BITS; 2319 port->actor_admin_port_key &= ~AD_DUPLEX_KEY_BITS;
2320 port->actor_oper_port_key= (port->actor_admin_port_key &= ~AD_SPEED_KEY_BITS); 2320 port->actor_oper_port_key= (port->actor_admin_port_key &= ~AD_SPEED_KEY_BITS);
2321 } 2321 }
diff --git a/drivers/net/bonding/bond_3ad.h b/drivers/net/bonding/bond_3ad.h
index 1c97def13f66..1f822a1d29aa 100644
--- a/drivers/net/bonding/bond_3ad.h
+++ b/drivers/net/bonding/bond_3ad.h
@@ -224,7 +224,8 @@ typedef struct port {
224 struct port_params partner_admin; 224 struct port_params partner_admin;
225 struct port_params partner_oper; 225 struct port_params partner_oper;
226 226
227 u16 is_enabled; // BOOLEAN 227 bool is_enabled;
228
228 // ****** PRIVATE PARAMETERS ****** 229 // ****** PRIVATE PARAMETERS ******
229 u16 sm_vars; // all state machines variables for this port 230 u16 sm_vars; // all state machines variables for this port
230 rx_states_t sm_rx_state; // state machine rx state 231 rx_states_t sm_rx_state; // state machine rx state