Lines Matching defs:th
255 * Fixes th->seq based on ip_vs_seq info.
257 static inline void vs_fix_seq(const struct ip_vs_seq *vseq, struct tcphdr *th)
259 __u32 seq = ntohl(th->seq);
268 th->seq = htonl(seq + vseq->delta);
272 th->seq = htonl(seq + vseq->previous_delta);
281 * Fixes th->ack_seq based on ip_vs_seq info.
284 vs_fix_ack_seq(const struct ip_vs_seq *vseq, struct tcphdr *th)
286 __u32 ack_seq = ntohl(th->ack_seq);
297 th->ack_seq = htonl(ack_seq - vseq->delta);
302 th->ack_seq = htonl(ack_seq - vseq->previous_delta);
334 struct tcphdr *th;
337 if (!skb_make_writable(skb, tcp_offset + sizeof(*th)))
340 th = (struct tcphdr *)(skb_network_header(skb) + tcp_offset);
345 seq = ntohl(th->seq);
351 vs_fix_seq(&cp->out_seq, th);
353 vs_fix_ack_seq(&cp->in_seq, th);
409 struct tcphdr *th;
412 if (!skb_make_writable(skb, tcp_offset + sizeof(*th)))
415 th = (struct tcphdr *)(skb_network_header(skb) + tcp_offset);
420 seq = ntohl(th->seq);
426 vs_fix_seq(&cp->in_seq, th);
428 vs_fix_ack_seq(&cp->out_seq, th);