diff options
author | Andy King <acking@vmware.com> | 2013-03-07 05:26:13 +0000 |
---|---|---|
committer | David S. Miller <davem@davemloft.net> | 2013-03-08 12:24:48 -0500 |
commit | c031e234ee304b507b79f76a7677ea0a7a8890e8 (patch) | |
tree | eae2744a314f1eb1875699531383d0b2da431d94 /include/uapi/linux/vm_sockets.h | |
parent | 7f0e44ac9f7f12a2519bfed9ea4df3c1471bd8bb (diff) |
VSOCK: Split vm_sockets.h into kernel/uapi
Split the vSockets header into kernel and UAPI parts. The former gets the bits
that used to be in __KERNEL__ guards, while the latter gets everything that is
user-visible. Tested by compiling vsock (+transport) and a simple user-mode
vSockets application.
Reported-by: David Howells <dhowells@redhat.com>
Acked-by: Dmitry Torokhov <dtor@vmware.com>
Signed-off-by: Andy King <acking@vmware.com>
Acked-by: David Howells <dhowells@redhat.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'include/uapi/linux/vm_sockets.h')
-rw-r--r-- | include/uapi/linux/vm_sockets.h | 23 |
1 files changed, 8 insertions, 15 deletions
diff --git a/include/uapi/linux/vm_sockets.h b/include/uapi/linux/vm_sockets.h index df91301847e..b4ed5d89569 100644 --- a/include/uapi/linux/vm_sockets.h +++ b/include/uapi/linux/vm_sockets.h @@ -13,12 +13,10 @@ * more details. */ -#ifndef _VM_SOCKETS_H_ -#define _VM_SOCKETS_H_ +#ifndef _UAPI_VM_SOCKETS_H +#define _UAPI_VM_SOCKETS_H -#if !defined(__KERNEL__) -#include <sys/socket.h> -#endif +#include <linux/socket.h> /* Option name for STREAM socket buffer size. Use as the option name in * setsockopt(3) or getsockopt(3) to set or get an unsigned long long that @@ -137,14 +135,13 @@ #define VM_SOCKETS_VERSION_MINOR(_v) (((_v) & 0x0000FFFF)) /* Address structure for vSockets. The address family should be set to - * whatever vmci_sock_get_af_value_fd() returns. The structure members should - * all align on their natural boundaries without resorting to compiler packing - * directives. The total size of this structure should be exactly the same as - * that of struct sockaddr. + * AF_VSOCK. The structure members should all align on their natural + * boundaries without resorting to compiler packing directives. The total size + * of this structure should be exactly the same as that of struct sockaddr. */ struct sockaddr_vm { - sa_family_t svm_family; + __kernel_sa_family_t svm_family; unsigned short svm_reserved1; unsigned int svm_port; unsigned int svm_cid; @@ -156,8 +153,4 @@ struct sockaddr_vm { #define IOCTL_VM_SOCKETS_GET_LOCAL_CID _IO(7, 0xb9) -#if defined(__KERNEL__) -int vm_sockets_get_local_cid(void); -#endif - -#endif +#endif /* _UAPI_VM_SOCKETS_H */ |