Lines Matching refs:tcph
142 static unsigned int get_conntrack_index(const struct tcphdr *tcph)
144 if (tcph->rst) return 3;
145 else if (tcph->syn) return 0;
146 else if (tcph->fin) return 1;
147 else if (tcph->ack) return 2;
157 struct tcphdr *tcph = (struct tcphdr *)((u_int32_t *)iph + iph->ihl);
161 if (len < (iph->ihl + tcph->doff) * 4) {
171 [get_conntrack_index(tcph)][oldtcpstate];
176 CTINFO2DIR(ctinfo), get_conntrack_index(tcph),
187 && tcph->syn && tcph->ack)
189 = htonl(ntohl(tcph->seq) + 1);
195 if (!(conntrack->status & IPS_SEEN_REPLY) && tcph->rst) {
203 && tcph->ack && !tcph->syn
204 && tcph->ack_seq == conntrack->proto.tcp.handshake_ack)
219 struct tcphdr *tcph = (struct tcphdr *)((u_int32_t *)iph + iph->ihl);
223 = tcp_conntracks[0][get_conntrack_index(tcph)]
240 struct tcphdr *tcph = (struct tcphdr *)((u_int32_t *)iph + iph->ihl);
243 datalen = (*pskb)->len - iph->ihl*4 - tcph->doff*4;
245 return between(exp->seq, ntohl(tcph->seq), ntohl(tcph->seq) + datalen);