diff options
author | Hauke Mehrtens <hauke@hauke-m.de> | 2015-05-25 15:58:59 +0200 |
---|---|---|
committer | Hauke Mehrtens <hauke@hauke-m.de> | 2015-05-25 23:28:58 +0200 |
commit | 356815b171d6720d7093fa33b17cac9f8c8fbcf1 (patch) | |
tree | 1cebcd6c4de831e53d0d06593ce460dd01735a42 | |
parent | d7b4e5d487cc1a417b9404b0e6ba6782d4880b41 (diff) |
header: handler new parameter net in sock_create_kern()
Linux commit eeb1bd5c4 added a new parameter to sock_create_kern(). In
the original function it was replaced with &init_net every time, now it
is taken from the parameter.
Signed-off-by: Hauke Mehrtens <hauke@hauke-m.de>
-rw-r--r-- | backport/backport-include/linux/net.h | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/backport/backport-include/linux/net.h b/backport/backport-include/linux/net.h index 0e436d41..4d9250b8 100644 --- a/backport/backport-include/linux/net.h +++ b/backport/backport-include/linux/net.h @@ -97,4 +97,9 @@ bool __net_get_random_once(void *buf, int nbytes, bool *done, #endif /* __BACKPORT_NET_GET_RANDOM_ONCE */ +#if LINUX_VERSION_CODE < KERNEL_VERSION(4,2,0) +#define sock_create_kern(net, family, type, proto, res) \ + __sock_create(net, family, type, proto, res, 1) +#endif + #endif /* __BACKPORT_LINUX_NET_H */ |