printk(KERN_ERR DRV_NAME ": An illegal loopback occurred on adapter (%s)\n", port->slave->dev->name); printk(KERN_ERR "Check the configuration to verify that all Adapters " "are connected to 802.3ad compliant switch ports\n"); 
printk(KERN_ERR DRV_NAME ": %s: An illegal loopback occurred on " "adapter (%s). Check the configuration to verify that all " "Adapters are connected to 802.3ad compliant switch ports\n", port->slave->dev->master->name, port->slave->dev->name); 
static void ad_rx_machine(struct lacpdu *lacpdu, struct port *port){	rx_states_t last_state;	// Lock to prevent 2 instances of this function to run simultaneously(rx interrupt and periodic machine callback)	__get_rx_machine_lock(port);	// keep current State Machine state to compare later if it was changed	last_state = port->sm_rx_state;	// check if state machine should change state	// first, check if port was reinitialized	if (port->sm_vars & AD_PORT_BEGIN) {		port->sm_rx_state = AD_RX_INITIALIZE;		    // next state	}	// check if port is not enabled	else if (!(port->sm_vars & AD_PORT_BEGIN) && !port->is_enabled && !(port->sm_vars & AD_PORT_MOVED)) {		port->sm_rx_state = AD_RX_PORT_DISABLED;	    // next state	}	// check if new lacpdu arrived	else if (lacpdu && ((port->sm_rx_state == AD_RX_EXPIRED) || (port->sm_rx_state == AD_RX_DEFAULTED) || (port->sm_rx_state == AD_RX_CURRENT))) {		port->sm_rx_timer_counter = 0; // zero timer		port->sm_rx_state = AD_RX_CURRENT;	} else {		// if timer is on, and if it is expired		if (port->sm_rx_timer_counter && !(--port->sm_rx_timer_counter)) {			switch (port->sm_rx_state) {			case AD_RX_EXPIRED:				port->sm_rx_state = AD_RX_DEFAULTED;		// next state				break;			case AD_RX_CURRENT:				port->sm_rx_state = AD_RX_EXPIRED;	    // next state				break;			default:    //to silence the compiler				break;			}		} else {			// if no lacpdu arrived and no timer is on			switch (port->sm_rx_state) {			case AD_RX_PORT_DISABLED:				if (port->sm_vars & AD_PORT_MOVED) {					port->sm_rx_state = AD_RX_INITIALIZE;	    // next state				} else if (port->is_enabled && (port->sm_vars & AD_PORT_LACP_ENABLED)) {					port->sm_rx_state = AD_RX_EXPIRED;	// next state				} else if (port->is_enabled && ((port->sm_vars & AD_PORT_LACP_ENABLED) == 0)) {					port->sm_rx_state = AD_RX_LACP_DISABLED;    // next state				}				break;			default:    //to silence the compiler				break;			}		}	}	// check if the State machine was changed or new lacpdu arrived	if ((port->sm_rx_state != last_state) || (lacpdu)) {		dprintk("Rx Machine: Port=%d, Last State=%d, Curr State=%d\n", port->actor_port_number, last_state, port->sm_rx_state);		switch (port->sm_rx_state) {		case AD_RX_INITIALIZE:			if (!(port->actor_oper_port_key & AD_DUPLEX_KEY_BITS)) {				port->sm_vars &= ~AD_PORT_LACP_ENABLED;			} else {				port->sm_vars |= AD_PORT_LACP_ENABLED;			}			port->sm_vars &= ~AD_PORT_SELECTED;			__record_default(port);			port->actor_oper_port_state &= ~AD_STATE_EXPIRED;			port->sm_vars &= ~AD_PORT_MOVED;			port->sm_rx_state = AD_RX_PORT_DISABLED;	// next state			/*- Fall Through -*/		case AD_RX_PORT_DISABLED:			port->sm_vars &= ~AD_PORT_MATCHED;			break;		case AD_RX_LACP_DISABLED:			port->sm_vars &= ~AD_PORT_SELECTED;			__record_default(port);			port->partner_oper_port_state &= ~AD_STATE_AGGREGATION;			port->sm_vars |= AD_PORT_MATCHED;			port->actor_oper_port_state &= ~AD_STATE_EXPIRED;			break;		case AD_RX_EXPIRED:			//Reset of the Synchronization flag. (Standard 43.4.12)			//This reset cause to disable this port in the COLLECTING_DISTRIBUTING state of the			//mux machine in case of EXPIRED even if LINK_DOWN didn't arrive for the port.			port->partner_oper_port_state &= ~AD_STATE_SYNCHRONIZATION;			port->sm_vars &= ~AD_PORT_MATCHED;			port->partner_oper_port_state |= AD_SHORT_TIMEOUT;			port->sm_rx_timer_counter = __ad_timer_to_ticks(AD_CURRENT_WHILE_TIMER, (u16)(AD_SHORT_TIMEOUT));			port->actor_oper_port_state |= AD_STATE_EXPIRED;			break;		case AD_RX_DEFAULTED:			__update_default_selected(port);			__record_default(port);			port->sm_vars |= AD_PORT_MATCHED;			port->actor_oper_port_state &= ~AD_STATE_EXPIRED;			break;		case AD_RX_CURRENT:			// detect loopback situation			if (!MAC_ADDRESS_COMPARE(&(lacpdu->actor_system), &(port->actor_system))) {				// INFO_RECEIVED_LOOPBACK_FRAMES				printk(KERN_ERR DRV_NAME ": An illegal loopback occurred on adapter (%s)\n",						port->slave->dev->name);				printk(KERN_ERR "Check the configuration to verify that all Adapters "						"are connected to 802.3ad compliant switch ports\n");				__release_rx_machine_lock(port);				return;			}			__update_selected(lacpdu, port);			__update_ntt(lacpdu, port);			__record_pdu(lacpdu, port);			__choose_matched(lacpdu, port);			port->sm_rx_timer_counter = __ad_timer_to_ticks(AD_CURRENT_WHILE_TIMER, (u16)(port->actor_oper_port_state & AD_STATE_LACP_TIMEOUT));			port->actor_oper_port_state &= ~AD_STATE_EXPIRED;			// verify that if the aggregator is enabled, the port is enabled too.			//(because if the link goes down for a short time, the 802.3ad will not			// catch it, and the port will continue to be disabled)			if (port->aggregator && port->aggregator->is_active && !__port_is_enabled(port)) {				__enable_port(port);			}			break;		default:    //to silence the compiler			break;		}	}	__release_rx_machine_lock(port);}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/4e0952c74ee450ded86e8946ce58ea8dfd05b007/bond_3ad.c/buggy/drivers/net/bonding/bond_3ad.c