/* Send a SYN-ACK after having received a SYN. This still operates on a request_sock only, not on a big socket.  */
static int __tcp_v4_send_synack(struct sock *sk, struct dst_entry *dst, struct request_sock *req, struct request_values *rvp)
/* Send a SYN-ACK after having received a SYN. This still operates on a request_sock only, not on a big socket.  */
static int __tcp_v4_send_synack(struct sock *sk, struct dst_entry *dst, struct request_sock *req, struct request_values *rvp)
{
	const struct inet_request_sock *ireq = inet_rsk(req);
	int err = -1;
	struct sk_buff * skb;
	if (!dst && (dst = inet_csk_route_req(sk, req)) == NULL)
		return -1;
	skb = tcp_make_synack(sk, dst, req, rvp);
	if (skb) {
		struct tcphdr *th = tcp_hdr(skb);
		th->check = tcp_v4_check(skb->len,
					 ireq->loc_addr,
					 ireq->rmt_addr,
					 csum_partial(th, skb->len,
						      skb->csum));
		err = ip_build_and_send_pkt(skb, sk, ireq->loc_addr,
					    ireq->rmt_addr,
					    ireq->opt);
		err = net_xmit_eval(err);
	}
	dst_release(dst);
	return err;
}