Elliott Hughes | 180edef | 2023-11-02 00:08:05 +0000 | [diff] [blame] | 1 | /* |
| 2 | * This file is auto-generated. Modifications will be lost. |
| 3 | * |
| 4 | * See https://android.googlesource.com/platform/bionic/+/master/libc/kernel/ |
| 5 | * for more information. |
| 6 | */ |
Ben Cheng | 655a7c0 | 2013-10-16 16:09:24 -0700 | [diff] [blame] | 7 | #ifndef _UAPI_LINUX_NET_H |
| 8 | #define _UAPI_LINUX_NET_H |
| 9 | #include <linux/socket.h> |
| 10 | #include <asm/socket.h> |
Ben Cheng | 655a7c0 | 2013-10-16 16:09:24 -0700 | [diff] [blame] | 11 | #define NPROTO AF_MAX |
| 12 | #define SYS_SOCKET 1 |
| 13 | #define SYS_BIND 2 |
| 14 | #define SYS_CONNECT 3 |
Ben Cheng | 655a7c0 | 2013-10-16 16:09:24 -0700 | [diff] [blame] | 15 | #define SYS_LISTEN 4 |
| 16 | #define SYS_ACCEPT 5 |
| 17 | #define SYS_GETSOCKNAME 6 |
| 18 | #define SYS_GETPEERNAME 7 |
Ben Cheng | 655a7c0 | 2013-10-16 16:09:24 -0700 | [diff] [blame] | 19 | #define SYS_SOCKETPAIR 8 |
| 20 | #define SYS_SEND 9 |
| 21 | #define SYS_RECV 10 |
| 22 | #define SYS_SENDTO 11 |
Ben Cheng | 655a7c0 | 2013-10-16 16:09:24 -0700 | [diff] [blame] | 23 | #define SYS_RECVFROM 12 |
| 24 | #define SYS_SHUTDOWN 13 |
| 25 | #define SYS_SETSOCKOPT 14 |
| 26 | #define SYS_GETSOCKOPT 15 |
Ben Cheng | 655a7c0 | 2013-10-16 16:09:24 -0700 | [diff] [blame] | 27 | #define SYS_SENDMSG 16 |
| 28 | #define SYS_RECVMSG 17 |
| 29 | #define SYS_ACCEPT4 18 |
| 30 | #define SYS_RECVMMSG 19 |
Ben Cheng | 655a7c0 | 2013-10-16 16:09:24 -0700 | [diff] [blame] | 31 | #define SYS_SENDMMSG 20 |
| 32 | typedef enum { |
Tao Bao | d7db594 | 2015-01-28 10:07:51 -0800 | [diff] [blame] | 33 | SS_FREE = 0, |
| 34 | SS_UNCONNECTED, |
Tao Bao | d7db594 | 2015-01-28 10:07:51 -0800 | [diff] [blame] | 35 | SS_CONNECTING, |
| 36 | SS_CONNECTED, |
| 37 | SS_DISCONNECTING |
Ben Cheng | 655a7c0 | 2013-10-16 16:09:24 -0700 | [diff] [blame] | 38 | } socket_state; |
Ben Cheng | 655a7c0 | 2013-10-16 16:09:24 -0700 | [diff] [blame] | 39 | #define __SO_ACCEPTCON (1 << 16) |
Nick Kralevich | a67e4de | 2013-01-14 11:28:26 -0800 | [diff] [blame] | 40 | #endif |