tp->bytes_acked = 0; 
tcp_fastretrans_alert(struct sock *sk, u32 prior_snd_una,		      int prior_packets, int flag){	struct inet_connection_sock *icsk = inet_csk(sk);	struct tcp_sock *tp = tcp_sk(sk);	int is_dupack = (tp->snd_una == prior_snd_una && !(flag&FLAG_NOT_DUP));	/* Some technical things:	 * 1. Reno does not count dupacks (sacked_out) automatically. */	if (!tp->packets_out)		tp->sacked_out = 0;        /* 2. SACK counts snd_fack in packets inaccurately. */	if (tp->sacked_out == 0)		tp->fackets_out = 0;        /* Now state machine starts.	 * A. ECE, hence prohibit cwnd undoing, the reduction is required. */	if (flag&FLAG_ECE)		tp->prior_ssthresh = 0;	/* B. In all the states check for reneging SACKs. */	if (tp->sacked_out && tcp_check_sack_reneging(sk))		return;	/* C. Process data loss notification, provided it is valid. */	if ((flag&FLAG_DATA_LOST) &&	    before(tp->snd_una, tp->high_seq) &&	    icsk->icsk_ca_state != TCP_CA_Open &&	    tp->fackets_out > tp->reordering) {		tcp_mark_head_lost(sk, tp, tp->fackets_out-tp->reordering, tp->high_seq);		NET_INC_STATS_BH(LINUX_MIB_TCPLOSS);	}	/* D. Synchronize left_out to current state. */	tcp_sync_left_out(tp);	/* E. Check state exit conditions. State can be terminated	 *    when high_seq is ACKed. */	if (icsk->icsk_ca_state == TCP_CA_Open) {		if (!sysctl_tcp_frto)			BUG_TRAP(tp->retrans_out == 0);		tp->retrans_stamp = 0;	} else if (!before(tp->snd_una, tp->high_seq)) {		switch (icsk->icsk_ca_state) {		case TCP_CA_Loss:			icsk->icsk_retransmits = 0;			if (tcp_try_undo_recovery(sk, tp))				return;			break;		case TCP_CA_CWR:			/* CWR is to be held something *above* high_seq			 * is ACKed for CWR bit to reach receiver. */			if (tp->snd_una != tp->high_seq) {				tcp_complete_cwr(sk);				tcp_set_ca_state(sk, TCP_CA_Open);			}			break;		case TCP_CA_Disorder:			tcp_try_undo_dsack(sk, tp);			if (!tp->undo_marker ||			    /* For SACK case do not Open to allow to undo			     * catching for all duplicate ACKs. */			    IsReno(tp) || tp->snd_una != tp->high_seq) {				tp->undo_marker = 0;				tcp_set_ca_state(sk, TCP_CA_Open);			}			break;		case TCP_CA_Recovery:			if (IsReno(tp))				tcp_reset_reno_sack(tp);			if (tcp_try_undo_recovery(sk, tp))				return;			tcp_complete_cwr(sk);			break;		}	}	/* F. Process state. */	switch (icsk->icsk_ca_state) {	case TCP_CA_Recovery:		if (prior_snd_una == tp->snd_una) {			if (IsReno(tp) && is_dupack)				tcp_add_reno_sack(sk);		} else {			int acked = prior_packets - tp->packets_out;			if (IsReno(tp))				tcp_remove_reno_sacks(sk, tp, acked);			is_dupack = tcp_try_undo_partial(sk, tp, acked);		}		break;	case TCP_CA_Loss:		if (flag&FLAG_DATA_ACKED)			icsk->icsk_retransmits = 0;		if (!tcp_try_undo_loss(sk, tp)) {			tcp_moderate_cwnd(tp);			tcp_xmit_retransmit_queue(sk);			return;		}		if (icsk->icsk_ca_state != TCP_CA_Open)			return;		/* Loss is undone; fall through to processing in Open state. */	default:		if (IsReno(tp)) {			if (tp->snd_una != prior_snd_una)				tcp_reset_reno_sack(tp);			if (is_dupack)				tcp_add_reno_sack(sk);		}		if (icsk->icsk_ca_state == TCP_CA_Disorder)			tcp_try_undo_dsack(sk, tp);		if (!tcp_time_to_recover(sk, tp)) {			tcp_try_to_open(sk, tp, flag);			return;		}		/* Otherwise enter Recovery state */		if (IsReno(tp))			NET_INC_STATS_BH(LINUX_MIB_TCPRENORECOVERY);		else			NET_INC_STATS_BH(LINUX_MIB_TCPSACKRECOVERY);		tp->high_seq = tp->snd_nxt;		tp->prior_ssthresh = 0;		tp->undo_marker = tp->snd_una;		tp->undo_retrans = tp->retrans_out;		if (icsk->icsk_ca_state < TCP_CA_CWR) {			if (!(flag&FLAG_ECE))				tp->prior_ssthresh = tcp_current_ssthresh(sk);			tp->snd_ssthresh = icsk->icsk_ca_ops->ssthresh(sk);			TCP_ECN_queue_cwr(tp);		}		tp->snd_cwnd_cnt = 0;		tcp_set_ca_state(sk, TCP_CA_Recovery);	}	if (is_dupack || tcp_head_timedout(sk, tp))		tcp_update_scoreboard(sk, tp);	tcp_cwnd_down(sk);	tcp_xmit_retransmit_queue(sk);}
4520	/local/tlutelli/issta_data/temp/c/2005_temp/2005/4520/9772efb970780aeed488c19d8b4afd46c3b484af/tcp_input.c/clean/net/ipv4/tcp_input.c