summaryrefslogtreecommitdiff
path: root/include/net
diff options
context:
space:
mode:
authorJens Axboe <axboe@kernel.dk>2020-02-27 08:11:20 -0700
committerJens Axboe <axboe@kernel.dk>2020-03-10 09:12:49 -0600
commit0a384abfae66651b28e4bbe16883b1ff046ba3b3 (patch)
tree482a79b57843d0a2184ecff7c5535ddf9304a88a /include/net
parent4d954c258a0c365a85a2d1b1cccf63aec38fca4c (diff)
net: abstract out normal and compat msghdr import
This splits it into two parts, one that imports the message, and one that imports the iovec. This allows a caller to only do the first part, and import the iovec manually afterwards. No functional changes in this patch. Acked-by: David Miller <davem@davemloft.net> Signed-off-by: Jens Axboe <axboe@kernel.dk>
Diffstat (limited to 'include/net')
-rw-r--r--include/net/compat.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/include/net/compat.h b/include/net/compat.h
index f277653c7e17..e341260642fe 100644
--- a/include/net/compat.h
+++ b/include/net/compat.h
@@ -38,6 +38,9 @@ struct compat_cmsghdr {
#define compat_mmsghdr mmsghdr
#endif /* defined(CONFIG_COMPAT) */
+int __get_compat_msghdr(struct msghdr *kmsg, struct compat_msghdr __user *umsg,
+ struct sockaddr __user **save_addr, compat_uptr_t *ptr,
+ compat_size_t *len);
int get_compat_msghdr(struct msghdr *, struct compat_msghdr __user *,
struct sockaddr __user **, struct iovec **);
struct sock_fprog __user *get_compat_bpf_fprog(char __user *optval);