summaryrefslogtreecommitdiffstats
path: root/include/linux/net.h
diff options
context:
space:
mode:
authorTom Herbert <tom@herbertland.com>2016-08-28 17:43:17 -0400
committerDavid S. Miller <davem@davemloft.net>2016-08-28 23:32:41 -0400
commit0294b625ad5a6d1fb50632d67cf384862d8a4a46 (patch)
tree2807436d5a82ed273a11b0706e81fce6899f1fe8 /include/linux/net.h
parente19ac1578fd8eb3f7c93f2be2657deb2ccefffd7 (diff)
net: Add read_sock proto_op
Add new function in proto_ops structure. This includes moving the typedef got sk_read_actor into net.h and removing the definition from tcp.h. Signed-off-by: Tom Herbert <tom@herbertland.com> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/linux/net.h')
-rw-r--r--include/linux/net.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/include/linux/net.h b/include/linux/net.h
index b9f0ff4d489c..cd0c8bd0a1de 100644
--- a/include/linux/net.h
+++ b/include/linux/net.h
@@ -25,6 +25,7 @@
25#include <linux/kmemcheck.h> 25#include <linux/kmemcheck.h>
26#include <linux/rcupdate.h> 26#include <linux/rcupdate.h>
27#include <linux/once.h> 27#include <linux/once.h>
28#include <linux/fs.h>
28 29
29#include <uapi/linux/net.h> 30#include <uapi/linux/net.h>
30 31
@@ -128,6 +129,9 @@ struct page;
128struct sockaddr; 129struct sockaddr;
129struct msghdr; 130struct msghdr;
130struct module; 131struct module;
132struct sk_buff;
133typedef int (*sk_read_actor_t)(read_descriptor_t *, struct sk_buff *,
134 unsigned int, size_t);
131 135
132struct proto_ops { 136struct proto_ops {
133 int family; 137 int family;
@@ -186,6 +190,8 @@ struct proto_ops {
186 struct pipe_inode_info *pipe, size_t len, unsigned int flags); 190 struct pipe_inode_info *pipe, size_t len, unsigned int flags);
187 int (*set_peek_off)(struct sock *sk, int val); 191 int (*set_peek_off)(struct sock *sk, int val);
188 int (*peek_len)(struct socket *sock); 192 int (*peek_len)(struct socket *sock);
193 int (*read_sock)(struct sock *sk, read_descriptor_t *desc,
194 sk_read_actor_t recv_actor);
189}; 195};
190 196
191#define DECLARE_SOCKADDR(type, dst, src) \ 197#define DECLARE_SOCKADDR(type, dst, src) \