mirror of
https://git.openafs.org/openafs.git
synced 2025-01-18 06:50:12 +00:00
Linux 4.2: Pass namespace to sock_create_kern
sock_create_kern gains an additional network namespace argument. Pass in the default system namesapce. Change-Id: I640e9497510242788e5060759779785ffb563a81 Reviewed-on: http://gerrit.openafs.org/11925 Tested-by: BuildBot <buildbot@rampaginggeek.com> Reviewed-by: Perry Ruiter <pruiter@sinenomine.net> Reviewed-by: Chas Williams <3chas3@gmail.com> Reviewed-by: Benjamin Kaduk <kaduk@mit.edu> Reviewed-by: Jeffrey Altman <jaltman@your-file-system.com>
This commit is contained in:
parent
4ef47f787a
commit
e597b87967
@ -1053,6 +1053,9 @@ case $AFS_SYSNAME in *_linux* | *_umlinux*)
|
||||
AC_CHECK_LINUX_FUNC([sock_create_kern],
|
||||
[#include <linux/net.h>],
|
||||
[sock_create_kern(0, 0, 0, NULL);])
|
||||
AC_CHECK_LINUX_FUNC([sock_create_kern_ns],
|
||||
[#include <linux/net.h>],
|
||||
[sock_create_kern(NULL, 0, 0, 0, NULL);])
|
||||
AC_CHECK_LINUX_FUNC([splice_direct_to_actor],
|
||||
[#include <linux/splice.h>],
|
||||
[splice_direct_to_actor(NULL,NULL,NULL);])
|
||||
|
@ -48,7 +48,9 @@ rxk_NewSocketHost(afs_uint32 ahost, short aport)
|
||||
int pmtu = IP_PMTUDISC_DONT;
|
||||
#endif
|
||||
|
||||
#ifdef HAVE_LINUX_SOCK_CREATE_KERN
|
||||
#ifdef HAVE_LINUX_SOCK_CREATE_KERN_NS
|
||||
code = sock_create_kern(&init_net, AF_INET, SOCK_DGRAM, IPPROTO_UDP, &sockp);
|
||||
#elif defined(HAVE_LINUX_SOCK_CREATE_KERN)
|
||||
code = sock_create_kern(AF_INET, SOCK_DGRAM, IPPROTO_UDP, &sockp);
|
||||
#elif defined(LINUX_KERNEL_SOCK_CREATE_V)
|
||||
code = sock_create(AF_INET, SOCK_DGRAM, IPPROTO_UDP, &sockp, 0);
|
||||
|
Loading…
Reference in New Issue
Block a user