xprtsock.c (34b8c399dc04c8e51f014b73458e654570698597) xprtsock.c (02107148349f31eee7c0fb06fd7a880df73dbd20)
1/*
2 * linux/net/sunrpc/xprtsock.c
3 *
4 * Client-side transport implementation for sockets.
5 *
6 * TCP callback races fixes (C) 1998 Red Hat Software <alan@redhat.com>
7 * TCP send fixes (C) 1998 Red Hat Software <alan@redhat.com>
8 * TCP NFS related read + write fixes

--- 14 unchanged lines hidden (view full) ---

23#include <linux/errno.h>
24#include <linux/socket.h>
25#include <linux/in.h>
26#include <linux/net.h>
27#include <linux/mm.h>
28#include <linux/udp.h>
29#include <linux/tcp.h>
30#include <linux/sunrpc/clnt.h>
1/*
2 * linux/net/sunrpc/xprtsock.c
3 *
4 * Client-side transport implementation for sockets.
5 *
6 * TCP callback races fixes (C) 1998 Red Hat Software <alan@redhat.com>
7 * TCP send fixes (C) 1998 Red Hat Software <alan@redhat.com>
8 * TCP NFS related read + write fixes

--- 14 unchanged lines hidden (view full) ---

23#include <linux/errno.h>
24#include <linux/socket.h>
25#include <linux/in.h>
26#include <linux/net.h>
27#include <linux/mm.h>
28#include <linux/udp.h>
29#include <linux/tcp.h>
30#include <linux/sunrpc/clnt.h>
31#include <linux/sunrpc/sched.h>
31#include <linux/file.h>
32
33#include <net/sock.h>
34#include <net/checksum.h>
35#include <net/udp.h>
36#include <net/tcp.h>
37
38/*

--- 1117 unchanged lines hidden (view full) ---

1156 }
1157}
1158
1159static struct rpc_xprt_ops xs_udp_ops = {
1160 .set_buffer_size = xs_udp_set_buffer_size,
1161 .reserve_xprt = xprt_reserve_xprt_cong,
1162 .release_xprt = xprt_release_xprt_cong,
1163 .connect = xs_connect,
32#include <linux/file.h>
33
34#include <net/sock.h>
35#include <net/checksum.h>
36#include <net/udp.h>
37#include <net/tcp.h>
38
39/*

--- 1117 unchanged lines hidden (view full) ---

1157 }
1158}
1159
1160static struct rpc_xprt_ops xs_udp_ops = {
1161 .set_buffer_size = xs_udp_set_buffer_size,
1162 .reserve_xprt = xprt_reserve_xprt_cong,
1163 .release_xprt = xprt_release_xprt_cong,
1164 .connect = xs_connect,
1165 .buf_alloc = rpc_malloc,
1166 .buf_free = rpc_free,
1164 .send_request = xs_udp_send_request,
1165 .set_retrans_timeout = xprt_set_retrans_timeout_rtt,
1166 .timer = xs_udp_timer,
1167 .release_request = xprt_release_rqst_cong,
1168 .close = xs_close,
1169 .destroy = xs_destroy,
1170};
1171
1172static struct rpc_xprt_ops xs_tcp_ops = {
1173 .reserve_xprt = xprt_reserve_xprt,
1174 .release_xprt = xprt_release_xprt,
1175 .connect = xs_connect,
1167 .send_request = xs_udp_send_request,
1168 .set_retrans_timeout = xprt_set_retrans_timeout_rtt,
1169 .timer = xs_udp_timer,
1170 .release_request = xprt_release_rqst_cong,
1171 .close = xs_close,
1172 .destroy = xs_destroy,
1173};
1174
1175static struct rpc_xprt_ops xs_tcp_ops = {
1176 .reserve_xprt = xprt_reserve_xprt,
1177 .release_xprt = xprt_release_xprt,
1178 .connect = xs_connect,
1179 .buf_alloc = rpc_malloc,
1180 .buf_free = rpc_free,
1176 .send_request = xs_tcp_send_request,
1177 .set_retrans_timeout = xprt_set_retrans_timeout_def,
1178 .close = xs_close,
1179 .destroy = xs_destroy,
1180};
1181
1182/**
1183 * xs_setup_udp - Set up transport to use a UDP socket

--- 80 unchanged lines hidden ---
1181 .send_request = xs_tcp_send_request,
1182 .set_retrans_timeout = xprt_set_retrans_timeout_def,
1183 .close = xs_close,
1184 .destroy = xs_destroy,
1185};
1186
1187/**
1188 * xs_setup_udp - Set up transport to use a UDP socket

--- 80 unchanged lines hidden ---