diff options
Diffstat (limited to 'include/uapi')
84 files changed, 1645 insertions, 203 deletions
diff --git a/include/uapi/asm-generic/fcntl.h b/include/uapi/asm-generic/fcntl.h index a48937d4a5ea..95e46c8e05f9 100644 --- a/include/uapi/asm-generic/fcntl.h +++ b/include/uapi/asm-generic/fcntl.h | |||
@@ -84,6 +84,14 @@ | |||
84 | #define O_PATH 010000000 | 84 | #define O_PATH 010000000 |
85 | #endif | 85 | #endif |
86 | 86 | ||
87 | #ifndef __O_TMPFILE | ||
88 | #define __O_TMPFILE 020000000 | ||
89 | #endif | ||
90 | |||
91 | /* a horrid kludge trying to make sure that this will fail on old kernels */ | ||
92 | #define O_TMPFILE (__O_TMPFILE | O_DIRECTORY) | ||
93 | #define O_TMPFILE_MASK (__O_TMPFILE | O_DIRECTORY | O_CREAT) | ||
94 | |||
87 | #ifndef O_NDELAY | 95 | #ifndef O_NDELAY |
88 | #define O_NDELAY O_NONBLOCK | 96 | #define O_NDELAY O_NONBLOCK |
89 | #endif | 97 | #endif |
diff --git a/include/uapi/asm-generic/poll.h b/include/uapi/asm-generic/poll.h index 9ce7f44aebd2..a9694982689f 100644 --- a/include/uapi/asm-generic/poll.h +++ b/include/uapi/asm-generic/poll.h | |||
@@ -30,6 +30,8 @@ | |||
30 | 30 | ||
31 | #define POLLFREE 0x4000 /* currently only for epoll */ | 31 | #define POLLFREE 0x4000 /* currently only for epoll */ |
32 | 32 | ||
33 | #define POLL_BUSY_LOOP 0x8000 | ||
34 | |||
33 | struct pollfd { | 35 | struct pollfd { |
34 | int fd; | 36 | int fd; |
35 | short events; | 37 | short events; |
diff --git a/include/uapi/asm-generic/socket.h b/include/uapi/asm-generic/socket.h index c5d2e3a1cf68..f04b69b6abf2 100644 --- a/include/uapi/asm-generic/socket.h +++ b/include/uapi/asm-generic/socket.h | |||
@@ -76,4 +76,6 @@ | |||
76 | 76 | ||
77 | #define SO_SELECT_ERR_QUEUE 45 | 77 | #define SO_SELECT_ERR_QUEUE 45 |
78 | 78 | ||
79 | #define SO_BUSY_POLL 46 | ||
80 | |||
79 | #endif /* __ASM_GENERIC_SOCKET_H */ | 81 | #endif /* __ASM_GENERIC_SOCKET_H */ |
diff --git a/include/uapi/asm-generic/unistd.h b/include/uapi/asm-generic/unistd.h index 0cc74c4403e4..a20a9b4d3871 100644 --- a/include/uapi/asm-generic/unistd.h +++ b/include/uapi/asm-generic/unistd.h | |||
@@ -361,7 +361,7 @@ __SYSCALL(__NR_syslog, sys_syslog) | |||
361 | #define __NR_ptrace 117 | 361 | #define __NR_ptrace 117 |
362 | __SYSCALL(__NR_ptrace, sys_ptrace) | 362 | __SYSCALL(__NR_ptrace, sys_ptrace) |
363 | 363 | ||
364 | /* kernel/sched.c */ | 364 | /* kernel/sched/core.c */ |
365 | #define __NR_sched_setparam 118 | 365 | #define __NR_sched_setparam 118 |
366 | __SYSCALL(__NR_sched_setparam, sys_sched_setparam) | 366 | __SYSCALL(__NR_sched_setparam, sys_sched_setparam) |
367 | #define __NR_sched_setscheduler 119 | 367 | #define __NR_sched_setscheduler 119 |
diff --git a/include/uapi/drm/Kbuild b/include/uapi/drm/Kbuild index 119487e05e65..2d9a25daab05 100644 --- a/include/uapi/drm/Kbuild +++ b/include/uapi/drm/Kbuild | |||
@@ -16,3 +16,4 @@ header-y += sis_drm.h | |||
16 | header-y += tegra_drm.h | 16 | header-y += tegra_drm.h |
17 | header-y += via_drm.h | 17 | header-y += via_drm.h |
18 | header-y += vmwgfx_drm.h | 18 | header-y += vmwgfx_drm.h |
19 | header-y += msm_drm.h | ||
diff --git a/include/uapi/drm/drm.h b/include/uapi/drm/drm.h index 5a57be68bab7..ece867889cc7 100644 --- a/include/uapi/drm/drm.h +++ b/include/uapi/drm/drm.h | |||
@@ -181,7 +181,7 @@ enum drm_map_type { | |||
181 | _DRM_AGP = 3, /**< AGP/GART */ | 181 | _DRM_AGP = 3, /**< AGP/GART */ |
182 | _DRM_SCATTER_GATHER = 4, /**< Scatter/gather memory for PCI DMA */ | 182 | _DRM_SCATTER_GATHER = 4, /**< Scatter/gather memory for PCI DMA */ |
183 | _DRM_CONSISTENT = 5, /**< Consistent memory for PCI DMA */ | 183 | _DRM_CONSISTENT = 5, /**< Consistent memory for PCI DMA */ |
184 | _DRM_GEM = 6, /**< GEM object */ | 184 | _DRM_GEM = 6, /**< GEM object (obsolete) */ |
185 | }; | 185 | }; |
186 | 186 | ||
187 | /** | 187 | /** |
@@ -732,6 +732,7 @@ struct drm_prime_handle { | |||
732 | #define DRM_IOCTL_MODE_ADDFB2 DRM_IOWR(0xB8, struct drm_mode_fb_cmd2) | 732 | #define DRM_IOCTL_MODE_ADDFB2 DRM_IOWR(0xB8, struct drm_mode_fb_cmd2) |
733 | #define DRM_IOCTL_MODE_OBJ_GETPROPERTIES DRM_IOWR(0xB9, struct drm_mode_obj_get_properties) | 733 | #define DRM_IOCTL_MODE_OBJ_GETPROPERTIES DRM_IOWR(0xB9, struct drm_mode_obj_get_properties) |
734 | #define DRM_IOCTL_MODE_OBJ_SETPROPERTY DRM_IOWR(0xBA, struct drm_mode_obj_set_property) | 734 | #define DRM_IOCTL_MODE_OBJ_SETPROPERTY DRM_IOWR(0xBA, struct drm_mode_obj_set_property) |
735 | #define DRM_IOCTL_MODE_CURSOR2 DRM_IOWR(0xBB, struct drm_mode_cursor2) | ||
735 | 736 | ||
736 | /** | 737 | /** |
737 | * Device specific ioctls should only be in their respective headers | 738 | * Device specific ioctls should only be in their respective headers |
@@ -779,6 +780,7 @@ struct drm_event_vblank { | |||
779 | #define DRM_CAP_DUMB_PREFER_SHADOW 0x4 | 780 | #define DRM_CAP_DUMB_PREFER_SHADOW 0x4 |
780 | #define DRM_CAP_PRIME 0x5 | 781 | #define DRM_CAP_PRIME 0x5 |
781 | #define DRM_CAP_TIMESTAMP_MONOTONIC 0x6 | 782 | #define DRM_CAP_TIMESTAMP_MONOTONIC 0x6 |
783 | #define DRM_CAP_ASYNC_PAGE_FLIP 0x7 | ||
782 | 784 | ||
783 | #define DRM_PRIME_CAP_IMPORT 0x1 | 785 | #define DRM_PRIME_CAP_IMPORT 0x1 |
784 | #define DRM_PRIME_CAP_EXPORT 0x2 | 786 | #define DRM_PRIME_CAP_EXPORT 0x2 |
diff --git a/include/uapi/drm/drm_mode.h b/include/uapi/drm/drm_mode.h index 090e5331ab7e..550811712f78 100644 --- a/include/uapi/drm/drm_mode.h +++ b/include/uapi/drm/drm_mode.h | |||
@@ -388,6 +388,19 @@ struct drm_mode_cursor { | |||
388 | __u32 handle; | 388 | __u32 handle; |
389 | }; | 389 | }; |
390 | 390 | ||
391 | struct drm_mode_cursor2 { | ||
392 | __u32 flags; | ||
393 | __u32 crtc_id; | ||
394 | __s32 x; | ||
395 | __s32 y; | ||
396 | __u32 width; | ||
397 | __u32 height; | ||
398 | /* driver specific handle */ | ||
399 | __u32 handle; | ||
400 | __s32 hot_x; | ||
401 | __s32 hot_y; | ||
402 | }; | ||
403 | |||
391 | struct drm_mode_crtc_lut { | 404 | struct drm_mode_crtc_lut { |
392 | __u32 crtc_id; | 405 | __u32 crtc_id; |
393 | __u32 gamma_size; | 406 | __u32 gamma_size; |
@@ -399,7 +412,8 @@ struct drm_mode_crtc_lut { | |||
399 | }; | 412 | }; |
400 | 413 | ||
401 | #define DRM_MODE_PAGE_FLIP_EVENT 0x01 | 414 | #define DRM_MODE_PAGE_FLIP_EVENT 0x01 |
402 | #define DRM_MODE_PAGE_FLIP_FLAGS DRM_MODE_PAGE_FLIP_EVENT | 415 | #define DRM_MODE_PAGE_FLIP_ASYNC 0x02 |
416 | #define DRM_MODE_PAGE_FLIP_FLAGS (DRM_MODE_PAGE_FLIP_EVENT|DRM_MODE_PAGE_FLIP_ASYNC) | ||
403 | 417 | ||
404 | /* | 418 | /* |
405 | * Request a page flip on the specified crtc. | 419 | * Request a page flip on the specified crtc. |
@@ -413,11 +427,14 @@ struct drm_mode_crtc_lut { | |||
413 | * flip is already pending as the ioctl is called, EBUSY will be | 427 | * flip is already pending as the ioctl is called, EBUSY will be |
414 | * returned. | 428 | * returned. |
415 | * | 429 | * |
416 | * The ioctl supports one flag, DRM_MODE_PAGE_FLIP_EVENT, which will | 430 | * Flag DRM_MODE_PAGE_FLIP_EVENT requests that drm sends back a vblank |
417 | * request that drm sends back a vblank event (see drm.h: struct | 431 | * event (see drm.h: struct drm_event_vblank) when the page flip is |
418 | * drm_event_vblank) when the page flip is done. The user_data field | 432 | * done. The user_data field passed in with this ioctl will be |
419 | * passed in with this ioctl will be returned as the user_data field | 433 | * returned as the user_data field in the vblank event struct. |
420 | * in the vblank event struct. | 434 | * |
435 | * Flag DRM_MODE_PAGE_FLIP_ASYNC requests that the flip happen | ||
436 | * 'as soon as possible', meaning that it not delay waiting for vblank. | ||
437 | * This may cause tearing on the screen. | ||
421 | * | 438 | * |
422 | * The reserved field must be zero until we figure out something | 439 | * The reserved field must be zero until we figure out something |
423 | * clever to use it for. | 440 | * clever to use it for. |
diff --git a/include/uapi/drm/i915_drm.h b/include/uapi/drm/i915_drm.h index 07d59419fe6b..55bb5729bd78 100644 --- a/include/uapi/drm/i915_drm.h +++ b/include/uapi/drm/i915_drm.h | |||
@@ -33,6 +33,30 @@ | |||
33 | * subject to backwards-compatibility constraints. | 33 | * subject to backwards-compatibility constraints. |
34 | */ | 34 | */ |
35 | 35 | ||
36 | /** | ||
37 | * DOC: uevents generated by i915 on it's device node | ||
38 | * | ||
39 | * I915_L3_PARITY_UEVENT - Generated when the driver receives a parity mismatch | ||
40 | * event from the gpu l3 cache. Additional information supplied is ROW, | ||
41 | * BANK, SUBBANK of the affected cacheline. Userspace should keep track of | ||
42 | * these events and if a specific cache-line seems to have a persistent | ||
43 | * error remap it with the l3 remapping tool supplied in intel-gpu-tools. | ||
44 | * The value supplied with the event is always 1. | ||
45 | * | ||
46 | * I915_ERROR_UEVENT - Generated upon error detection, currently only via | ||
47 | * hangcheck. The error detection event is a good indicator of when things | ||
48 | * began to go badly. The value supplied with the event is a 1 upon error | ||
49 | * detection, and a 0 upon reset completion, signifying no more error | ||
50 | * exists. NOTE: Disabling hangcheck or reset via module parameter will | ||
51 | * cause the related events to not be seen. | ||
52 | * | ||
53 | * I915_RESET_UEVENT - Event is generated just before an attempt to reset the | ||
54 | * the GPU. The value supplied with the event is always 1. NOTE: Disable | ||
55 | * reset via module parameter will cause this event to not be seen. | ||
56 | */ | ||
57 | #define I915_L3_PARITY_UEVENT "L3_PARITY_ERROR" | ||
58 | #define I915_ERROR_UEVENT "ERROR" | ||
59 | #define I915_RESET_UEVENT "RESET" | ||
36 | 60 | ||
37 | /* Each region is a minimum of 16k, and there are at most 255 of them. | 61 | /* Each region is a minimum of 16k, and there are at most 255 of them. |
38 | */ | 62 | */ |
@@ -305,11 +329,12 @@ typedef struct drm_i915_irq_wait { | |||
305 | #define I915_PARAM_HAS_WAIT_TIMEOUT 19 | 329 | #define I915_PARAM_HAS_WAIT_TIMEOUT 19 |
306 | #define I915_PARAM_HAS_SEMAPHORES 20 | 330 | #define I915_PARAM_HAS_SEMAPHORES 20 |
307 | #define I915_PARAM_HAS_PRIME_VMAP_FLUSH 21 | 331 | #define I915_PARAM_HAS_PRIME_VMAP_FLUSH 21 |
308 | #define I915_PARAM_RSVD_FOR_FUTURE_USE 22 | 332 | #define I915_PARAM_HAS_VEBOX 22 |
309 | #define I915_PARAM_HAS_SECURE_BATCHES 23 | 333 | #define I915_PARAM_HAS_SECURE_BATCHES 23 |
310 | #define I915_PARAM_HAS_PINNED_BATCHES 24 | 334 | #define I915_PARAM_HAS_PINNED_BATCHES 24 |
311 | #define I915_PARAM_HAS_EXEC_NO_RELOC 25 | 335 | #define I915_PARAM_HAS_EXEC_NO_RELOC 25 |
312 | #define I915_PARAM_HAS_EXEC_HANDLE_LUT 26 | 336 | #define I915_PARAM_HAS_EXEC_HANDLE_LUT 26 |
337 | #define I915_PARAM_HAS_WT 27 | ||
313 | 338 | ||
314 | typedef struct drm_i915_getparam { | 339 | typedef struct drm_i915_getparam { |
315 | int param; | 340 | int param; |
@@ -660,6 +685,7 @@ struct drm_i915_gem_execbuffer2 { | |||
660 | #define I915_EXEC_RENDER (1<<0) | 685 | #define I915_EXEC_RENDER (1<<0) |
661 | #define I915_EXEC_BSD (2<<0) | 686 | #define I915_EXEC_BSD (2<<0) |
662 | #define I915_EXEC_BLT (3<<0) | 687 | #define I915_EXEC_BLT (3<<0) |
688 | #define I915_EXEC_VEBOX (4<<0) | ||
663 | 689 | ||
664 | /* Used for switching the constants addressing mode on gen4+ RENDER ring. | 690 | /* Used for switching the constants addressing mode on gen4+ RENDER ring. |
665 | * Gen6+ only supports relative addressing to dynamic state (default) and | 691 | * Gen6+ only supports relative addressing to dynamic state (default) and |
@@ -743,8 +769,32 @@ struct drm_i915_gem_busy { | |||
743 | __u32 busy; | 769 | __u32 busy; |
744 | }; | 770 | }; |
745 | 771 | ||
772 | /** | ||
773 | * I915_CACHING_NONE | ||
774 | * | ||
775 | * GPU access is not coherent with cpu caches. Default for machines without an | ||
776 | * LLC. | ||
777 | */ | ||
746 | #define I915_CACHING_NONE 0 | 778 | #define I915_CACHING_NONE 0 |
779 | /** | ||
780 | * I915_CACHING_CACHED | ||
781 | * | ||
782 | * GPU access is coherent with cpu caches and furthermore the data is cached in | ||
783 | * last-level caches shared between cpu cores and the gpu GT. Default on | ||
784 | * machines with HAS_LLC. | ||
785 | */ | ||
747 | #define I915_CACHING_CACHED 1 | 786 | #define I915_CACHING_CACHED 1 |
787 | /** | ||
788 | * I915_CACHING_DISPLAY | ||
789 | * | ||
790 | * Special GPU caching mode which is coherent with the scanout engines. | ||
791 | * Transparently falls back to I915_CACHING_NONE on platforms where no special | ||
792 | * cache mode (like write-through or gfdt flushing) is available. The kernel | ||
793 | * automatically sets this mode when using a buffer as a scanout target. | ||
794 | * Userspace can manually set this mode to avoid a costly stall and clflush in | ||
795 | * the hotpath of drawing the first frame. | ||
796 | */ | ||
797 | #define I915_CACHING_DISPLAY 2 | ||
748 | 798 | ||
749 | struct drm_i915_gem_caching { | 799 | struct drm_i915_gem_caching { |
750 | /** | 800 | /** |
diff --git a/include/uapi/drm/msm_drm.h b/include/uapi/drm/msm_drm.h new file mode 100644 index 000000000000..d3c62074016d --- /dev/null +++ b/include/uapi/drm/msm_drm.h | |||
@@ -0,0 +1,207 @@ | |||
1 | /* | ||
2 | * Copyright (C) 2013 Red Hat | ||
3 | * Author: Rob Clark <robdclark@gmail.com> | ||
4 | * | ||
5 | * This program is free software; you can redistribute it and/or modify it | ||
6 | * under the terms of the GNU General Public License version 2 as published by | ||
7 | * the Free Software Foundation. | ||
8 | * | ||
9 | * This program is distributed in the hope that it will be useful, but WITHOUT | ||
10 | * ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or | ||
11 | * FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for | ||
12 | * more details. | ||
13 | * | ||
14 | * You should have received a copy of the GNU General Public License along with | ||
15 | * this program. If not, see <http://www.gnu.org/licenses/>. | ||
16 | */ | ||
17 | |||
18 | #ifndef __MSM_DRM_H__ | ||
19 | #define __MSM_DRM_H__ | ||
20 | |||
21 | #include <stddef.h> | ||
22 | #include <drm/drm.h> | ||
23 | |||
24 | /* Please note that modifications to all structs defined here are | ||
25 | * subject to backwards-compatibility constraints: | ||
26 | * 1) Do not use pointers, use uint64_t instead for 32 bit / 64 bit | ||
27 | * user/kernel compatibility | ||
28 | * 2) Keep fields aligned to their size | ||
29 | * 3) Because of how drm_ioctl() works, we can add new fields at | ||
30 | * the end of an ioctl if some care is taken: drm_ioctl() will | ||
31 | * zero out the new fields at the tail of the ioctl, so a zero | ||
32 | * value should have a backwards compatible meaning. And for | ||
33 | * output params, userspace won't see the newly added output | ||
34 | * fields.. so that has to be somehow ok. | ||
35 | */ | ||
36 | |||
37 | #define MSM_PIPE_NONE 0x00 | ||
38 | #define MSM_PIPE_2D0 0x01 | ||
39 | #define MSM_PIPE_2D1 0x02 | ||
40 | #define MSM_PIPE_3D0 0x10 | ||
41 | |||
42 | /* timeouts are specified in clock-monotonic absolute times (to simplify | ||
43 | * restarting interrupted ioctls). The following struct is logically the | ||
44 | * same as 'struct timespec' but 32/64b ABI safe. | ||
45 | */ | ||
46 | struct drm_msm_timespec { | ||
47 | int64_t tv_sec; /* seconds */ | ||
48 | int64_t tv_nsec; /* nanoseconds */ | ||
49 | }; | ||
50 | |||
51 | #define MSM_PARAM_GPU_ID 0x01 | ||
52 | #define MSM_PARAM_GMEM_SIZE 0x02 | ||
53 | |||
54 | struct drm_msm_param { | ||
55 | uint32_t pipe; /* in, MSM_PIPE_x */ | ||
56 | uint32_t param; /* in, MSM_PARAM_x */ | ||
57 | uint64_t value; /* out (get_param) or in (set_param) */ | ||
58 | }; | ||
59 | |||
60 | /* | ||
61 | * GEM buffers: | ||
62 | */ | ||
63 | |||
64 | #define MSM_BO_SCANOUT 0x00000001 /* scanout capable */ | ||
65 | #define MSM_BO_GPU_READONLY 0x00000002 | ||
66 | #define MSM_BO_CACHE_MASK 0x000f0000 | ||
67 | /* cache modes */ | ||
68 | #define MSM_BO_CACHED 0x00010000 | ||
69 | #define MSM_BO_WC 0x00020000 | ||
70 | #define MSM_BO_UNCACHED 0x00040000 | ||
71 | |||
72 | struct drm_msm_gem_new { | ||
73 | uint64_t size; /* in */ | ||
74 | uint32_t flags; /* in, mask of MSM_BO_x */ | ||
75 | uint32_t handle; /* out */ | ||
76 | }; | ||
77 | |||
78 | struct drm_msm_gem_info { | ||
79 | uint32_t handle; /* in */ | ||
80 | uint32_t pad; | ||
81 | uint64_t offset; /* out, offset to pass to mmap() */ | ||
82 | }; | ||
83 | |||
84 | #define MSM_PREP_READ 0x01 | ||
85 | #define MSM_PREP_WRITE 0x02 | ||
86 | #define MSM_PREP_NOSYNC 0x04 | ||
87 | |||
88 | struct drm_msm_gem_cpu_prep { | ||
89 | uint32_t handle; /* in */ | ||
90 | uint32_t op; /* in, mask of MSM_PREP_x */ | ||
91 | struct drm_msm_timespec timeout; /* in */ | ||
92 | }; | ||
93 | |||
94 | struct drm_msm_gem_cpu_fini { | ||
95 | uint32_t handle; /* in */ | ||
96 | }; | ||
97 | |||
98 | /* | ||
99 | * Cmdstream Submission: | ||
100 | */ | ||
101 | |||
102 | /* The value written into the cmdstream is logically: | ||
103 | * | ||
104 | * ((relocbuf->gpuaddr + reloc_offset) << shift) | or | ||
105 | * | ||
106 | * When we have GPU's w/ >32bit ptrs, it should be possible to deal | ||
107 | * with this by emit'ing two reloc entries with appropriate shift | ||
108 | * values. Or a new MSM_SUBMIT_CMD_x type would also be an option. | ||
109 | * | ||
110 | * NOTE that reloc's must be sorted by order of increasing submit_offset, | ||
111 | * otherwise EINVAL. | ||
112 | */ | ||
113 | struct drm_msm_gem_submit_reloc { | ||
114 | uint32_t submit_offset; /* in, offset from submit_bo */ | ||
115 | uint32_t or; /* in, value OR'd with result */ | ||
116 | int32_t shift; /* in, amount of left shift (can be negative) */ | ||
117 | uint32_t reloc_idx; /* in, index of reloc_bo buffer */ | ||
118 | uint64_t reloc_offset; /* in, offset from start of reloc_bo */ | ||
119 | }; | ||
120 | |||
121 | /* submit-types: | ||
122 | * BUF - this cmd buffer is executed normally. | ||
123 | * IB_TARGET_BUF - this cmd buffer is an IB target. Reloc's are | ||
124 | * processed normally, but the kernel does not setup an IB to | ||
125 | * this buffer in the first-level ringbuffer | ||
126 | * CTX_RESTORE_BUF - only executed if there has been a GPU context | ||
127 | * switch since the last SUBMIT ioctl | ||
128 | */ | ||
129 | #define MSM_SUBMIT_CMD_BUF 0x0001 | ||
130 | #define MSM_SUBMIT_CMD_IB_TARGET_BUF 0x0002 | ||
131 | #define MSM_SUBMIT_CMD_CTX_RESTORE_BUF 0x0003 | ||
132 | struct drm_msm_gem_submit_cmd { | ||
133 | uint32_t type; /* in, one of MSM_SUBMIT_CMD_x */ | ||
134 | uint32_t submit_idx; /* in, index of submit_bo cmdstream buffer */ | ||
135 | uint32_t submit_offset; /* in, offset into submit_bo */ | ||
136 | uint32_t size; /* in, cmdstream size */ | ||
137 | uint32_t pad; | ||
138 | uint32_t nr_relocs; /* in, number of submit_reloc's */ | ||
139 | uint64_t __user relocs; /* in, ptr to array of submit_reloc's */ | ||
140 | }; | ||
141 | |||
142 | /* Each buffer referenced elsewhere in the cmdstream submit (ie. the | ||
143 | * cmdstream buffer(s) themselves or reloc entries) has one (and only | ||
144 | * one) entry in the submit->bos[] table. | ||
145 | * | ||
146 | * As a optimization, the current buffer (gpu virtual address) can be | ||
147 | * passed back through the 'presumed' field. If on a subsequent reloc, | ||
148 | * userspace passes back a 'presumed' address that is still valid, | ||
149 | * then patching the cmdstream for this entry is skipped. This can | ||
150 | * avoid kernel needing to map/access the cmdstream bo in the common | ||
151 | * case. | ||
152 | */ | ||
153 | #define MSM_SUBMIT_BO_READ 0x0001 | ||
154 | #define MSM_SUBMIT_BO_WRITE 0x0002 | ||
155 | struct drm_msm_gem_submit_bo { | ||
156 | uint32_t flags; /* in, mask of MSM_SUBMIT_BO_x */ | ||
157 | uint32_t handle; /* in, GEM handle */ | ||
158 | uint64_t presumed; /* in/out, presumed buffer address */ | ||
159 | }; | ||
160 | |||
161 | /* Each cmdstream submit consists of a table of buffers involved, and | ||
162 | * one or more cmdstream buffers. This allows for conditional execution | ||
163 | * (context-restore), and IB buffers needed for per tile/bin draw cmds. | ||
164 | */ | ||
165 | struct drm_msm_gem_submit { | ||
166 | uint32_t pipe; /* in, MSM_PIPE_x */ | ||
167 | uint32_t fence; /* out */ | ||
168 | uint32_t nr_bos; /* in, number of submit_bo's */ | ||
169 | uint32_t nr_cmds; /* in, number of submit_cmd's */ | ||
170 | uint64_t __user bos; /* in, ptr to array of submit_bo's */ | ||
171 | uint64_t __user cmds; /* in, ptr to array of submit_cmd's */ | ||
172 | }; | ||
173 | |||
174 | /* The normal way to synchronize with the GPU is just to CPU_PREP on | ||
175 | * a buffer if you need to access it from the CPU (other cmdstream | ||
176 | * submission from same or other contexts, PAGE_FLIP ioctl, etc, all | ||
177 | * handle the required synchronization under the hood). This ioctl | ||
178 | * mainly just exists as a way to implement the gallium pipe_fence | ||
179 | * APIs without requiring a dummy bo to synchronize on. | ||
180 | */ | ||
181 | struct drm_msm_wait_fence { | ||
182 | uint32_t fence; /* in */ | ||
183 | uint32_t pad; | ||
184 | struct drm_msm_timespec timeout; /* in */ | ||
185 | }; | ||
186 | |||
187 | #define DRM_MSM_GET_PARAM 0x00 | ||
188 | /* placeholder: | ||
189 | #define DRM_MSM_SET_PARAM 0x01 | ||
190 | */ | ||
191 | #define DRM_MSM_GEM_NEW 0x02 | ||
192 | #define DRM_MSM_GEM_INFO 0x03 | ||
193 | #define DRM_MSM_GEM_CPU_PREP 0x04 | ||
194 | #define DRM_MSM_GEM_CPU_FINI 0x05 | ||
195 | #define DRM_MSM_GEM_SUBMIT 0x06 | ||
196 | #define DRM_MSM_WAIT_FENCE 0x07 | ||
197 | #define DRM_MSM_NUM_IOCTLS 0x08 | ||
198 | |||
199 | #define DRM_IOCTL_MSM_GET_PARAM DRM_IOWR(DRM_COMMAND_BASE + DRM_MSM_GET_PARAM, struct drm_msm_param) | ||
200 | #define DRM_IOCTL_MSM_GEM_NEW DRM_IOWR(DRM_COMMAND_BASE + DRM_MSM_GEM_NEW, struct drm_msm_gem_new) | ||
201 | #define DRM_IOCTL_MSM_GEM_INFO DRM_IOWR(DRM_COMMAND_BASE + DRM_MSM_GEM_INFO, struct drm_msm_gem_info) | ||
202 | #define DRM_IOCTL_MSM_GEM_CPU_PREP DRM_IOW (DRM_COMMAND_BASE + DRM_MSM_GEM_CPU_PREP, struct drm_msm_gem_cpu_prep) | ||
203 | #define DRM_IOCTL_MSM_GEM_CPU_FINI DRM_IOW (DRM_COMMAND_BASE + DRM_MSM_GEM_CPU_FINI, struct drm_msm_gem_cpu_fini) | ||
204 | #define DRM_IOCTL_MSM_GEM_SUBMIT DRM_IOWR(DRM_COMMAND_BASE + DRM_MSM_GEM_SUBMIT, struct drm_msm_gem_submit) | ||
205 | #define DRM_IOCTL_MSM_WAIT_FENCE DRM_IOW (DRM_COMMAND_BASE + DRM_MSM_WAIT_FENCE, struct drm_msm_wait_fence) | ||
206 | |||
207 | #endif /* __MSM_DRM_H__ */ | ||
diff --git a/include/uapi/drm/radeon_drm.h b/include/uapi/drm/radeon_drm.h index 321d4ac5c512..fa8b3adf9ffb 100644 --- a/include/uapi/drm/radeon_drm.h +++ b/include/uapi/drm/radeon_drm.h | |||
@@ -979,6 +979,8 @@ struct drm_radeon_cs { | |||
979 | #define RADEON_INFO_RING_WORKING 0x15 | 979 | #define RADEON_INFO_RING_WORKING 0x15 |
980 | /* SI tile mode array */ | 980 | /* SI tile mode array */ |
981 | #define RADEON_INFO_SI_TILE_MODE_ARRAY 0x16 | 981 | #define RADEON_INFO_SI_TILE_MODE_ARRAY 0x16 |
982 | /* query if CP DMA is supported on the compute ring */ | ||
983 | #define RADEON_INFO_SI_CP_DMA_COMPUTE 0x17 | ||
982 | 984 | ||
983 | 985 | ||
984 | struct drm_radeon_info { | 986 | struct drm_radeon_info { |
diff --git a/include/uapi/drm/tegra_drm.h b/include/uapi/drm/tegra_drm.h index 6e132a2f7420..73bde4eaf16c 100644 --- a/include/uapi/drm/tegra_drm.h +++ b/include/uapi/drm/tegra_drm.h | |||
@@ -17,6 +17,8 @@ | |||
17 | #ifndef _UAPI_TEGRA_DRM_H_ | 17 | #ifndef _UAPI_TEGRA_DRM_H_ |
18 | #define _UAPI_TEGRA_DRM_H_ | 18 | #define _UAPI_TEGRA_DRM_H_ |
19 | 19 | ||
20 | #include <drm/drm.h> | ||
21 | |||
20 | struct drm_tegra_gem_create { | 22 | struct drm_tegra_gem_create { |
21 | __u64 size; | 23 | __u64 size; |
22 | __u32 flags; | 24 | __u32 flags; |
diff --git a/include/uapi/linux/Kbuild b/include/uapi/linux/Kbuild index a5e677a7070f..115add2515aa 100644 --- a/include/uapi/linux/Kbuild +++ b/include/uapi/linux/Kbuild | |||
@@ -62,6 +62,7 @@ header-y += auxvec.h | |||
62 | header-y += ax25.h | 62 | header-y += ax25.h |
63 | header-y += b1lli.h | 63 | header-y += b1lli.h |
64 | header-y += baycom.h | 64 | header-y += baycom.h |
65 | header-y += bcm933xx_hcs.h | ||
65 | header-y += bfs_fs.h | 66 | header-y += bfs_fs.h |
66 | header-y += binfmts.h | 67 | header-y += binfmts.h |
67 | header-y += blkpg.h | 68 | header-y += blkpg.h |
@@ -226,6 +227,7 @@ header-y += kvm_para.h | |||
226 | endif | 227 | endif |
227 | 228 | ||
228 | header-y += l2tp.h | 229 | header-y += l2tp.h |
230 | header-y += libc-compat.h | ||
229 | header-y += limits.h | 231 | header-y += limits.h |
230 | header-y += llc.h | 232 | header-y += llc.h |
231 | header-y += loop.h | 233 | header-y += loop.h |
@@ -261,6 +263,7 @@ header-y += net_dropmon.h | |||
261 | header-y += net_tstamp.h | 263 | header-y += net_tstamp.h |
262 | header-y += netconf.h | 264 | header-y += netconf.h |
263 | header-y += netdevice.h | 265 | header-y += netdevice.h |
266 | header-y += netlink_diag.h | ||
264 | header-y += netfilter.h | 267 | header-y += netfilter.h |
265 | header-y += netfilter_arp.h | 268 | header-y += netfilter_arp.h |
266 | header-y += netfilter_bridge.h | 269 | header-y += netfilter_bridge.h |
diff --git a/include/uapi/linux/bcm933xx_hcs.h b/include/uapi/linux/bcm933xx_hcs.h new file mode 100644 index 000000000000..d22821831549 --- /dev/null +++ b/include/uapi/linux/bcm933xx_hcs.h | |||
@@ -0,0 +1,24 @@ | |||
1 | /* | ||
2 | * Broadcom Cable Modem firmware format | ||
3 | */ | ||
4 | |||
5 | #ifndef __BCM933XX_HCS_H | ||
6 | #define __BCM933XX_HCS_H | ||
7 | |||
8 | #include <linux/types.h> | ||
9 | |||
10 | struct bcm_hcs { | ||
11 | __u16 magic; | ||
12 | __u16 control; | ||
13 | __u16 rev_maj; | ||
14 | __u16 rev_min; | ||
15 | __u32 build_date; | ||
16 | __u32 filelen; | ||
17 | __u32 ldaddress; | ||
18 | char filename[64]; | ||
19 | __u16 hcs; | ||
20 | __u16 her_znaet_chto; | ||
21 | __u32 crc; | ||
22 | }; | ||
23 | |||
24 | #endif /* __BCM933XX_HCS */ | ||
diff --git a/include/uapi/linux/btrfs.h b/include/uapi/linux/btrfs.h index 5ef0df545a2a..05aed70627e2 100644 --- a/include/uapi/linux/btrfs.h +++ b/include/uapi/linux/btrfs.h | |||
@@ -447,6 +447,46 @@ struct btrfs_ioctl_send_args { | |||
447 | __u64 reserved[4]; /* in */ | 447 | __u64 reserved[4]; /* in */ |
448 | }; | 448 | }; |
449 | 449 | ||
450 | /* Error codes as returned by the kernel */ | ||
451 | enum btrfs_err_code { | ||
452 | notused, | ||
453 | BTRFS_ERROR_DEV_RAID1_MIN_NOT_MET, | ||
454 | BTRFS_ERROR_DEV_RAID10_MIN_NOT_MET, | ||
455 | BTRFS_ERROR_DEV_RAID5_MIN_NOT_MET, | ||
456 | BTRFS_ERROR_DEV_RAID6_MIN_NOT_MET, | ||
457 | BTRFS_ERROR_DEV_TGT_REPLACE, | ||
458 | BTRFS_ERROR_DEV_MISSING_NOT_FOUND, | ||
459 | BTRFS_ERROR_DEV_ONLY_WRITABLE, | ||
460 | BTRFS_ERROR_DEV_EXCL_RUN_IN_PROGRESS | ||
461 | }; | ||
462 | /* An error code to error string mapping for the kernel | ||
463 | * error codes | ||
464 | */ | ||
465 | static inline char *btrfs_err_str(enum btrfs_err_code err_code) | ||
466 | { | ||
467 | switch (err_code) { | ||
468 | case BTRFS_ERROR_DEV_RAID1_MIN_NOT_MET: | ||
469 | return "unable to go below two devices on raid1"; | ||
470 | case BTRFS_ERROR_DEV_RAID10_MIN_NOT_MET: | ||
471 | return "unable to go below four devices on raid10"; | ||
472 | case BTRFS_ERROR_DEV_RAID5_MIN_NOT_MET: | ||
473 | return "unable to go below two devices on raid5"; | ||
474 | case BTRFS_ERROR_DEV_RAID6_MIN_NOT_MET: | ||
475 | return "unable to go below three devices on raid6"; | ||
476 | case BTRFS_ERROR_DEV_TGT_REPLACE: | ||
477 | return "unable to remove the dev_replace target dev"; | ||
478 | case BTRFS_ERROR_DEV_MISSING_NOT_FOUND: | ||
479 | return "no missing devices found to remove"; | ||
480 | case BTRFS_ERROR_DEV_ONLY_WRITABLE: | ||
481 | return "unable to remove the only writeable device"; | ||
482 | case BTRFS_ERROR_DEV_EXCL_RUN_IN_PROGRESS: | ||
483 | return "add/delete/balance/replace/resize operation "\ | ||
484 | "in progress"; | ||
485 | default: | ||
486 | return NULL; | ||
487 | } | ||
488 | } | ||
489 | |||
450 | #define BTRFS_IOC_SNAP_CREATE _IOW(BTRFS_IOCTL_MAGIC, 1, \ | 490 | #define BTRFS_IOC_SNAP_CREATE _IOW(BTRFS_IOCTL_MAGIC, 1, \ |
451 | struct btrfs_ioctl_vol_args) | 491 | struct btrfs_ioctl_vol_args) |
452 | #define BTRFS_IOC_DEFRAG _IOW(BTRFS_IOCTL_MAGIC, 2, \ | 492 | #define BTRFS_IOC_DEFRAG _IOW(BTRFS_IOCTL_MAGIC, 2, \ |
@@ -530,6 +570,7 @@ struct btrfs_ioctl_send_args { | |||
530 | struct btrfs_ioctl_quota_rescan_args) | 570 | struct btrfs_ioctl_quota_rescan_args) |
531 | #define BTRFS_IOC_QUOTA_RESCAN_STATUS _IOR(BTRFS_IOCTL_MAGIC, 45, \ | 571 | #define BTRFS_IOC_QUOTA_RESCAN_STATUS _IOR(BTRFS_IOCTL_MAGIC, 45, \ |
532 | struct btrfs_ioctl_quota_rescan_args) | 572 | struct btrfs_ioctl_quota_rescan_args) |
573 | #define BTRFS_IOC_QUOTA_RESCAN_WAIT _IO(BTRFS_IOCTL_MAGIC, 46) | ||
533 | #define BTRFS_IOC_GET_FSLABEL _IOR(BTRFS_IOCTL_MAGIC, 49, \ | 574 | #define BTRFS_IOC_GET_FSLABEL _IOR(BTRFS_IOCTL_MAGIC, 49, \ |
534 | char[BTRFS_LABEL_SIZE]) | 575 | char[BTRFS_LABEL_SIZE]) |
535 | #define BTRFS_IOC_SET_FSLABEL _IOW(BTRFS_IOCTL_MAGIC, 50, \ | 576 | #define BTRFS_IOC_SET_FSLABEL _IOW(BTRFS_IOCTL_MAGIC, 50, \ |
@@ -538,5 +579,4 @@ struct btrfs_ioctl_send_args { | |||
538 | struct btrfs_ioctl_get_dev_stats) | 579 | struct btrfs_ioctl_get_dev_stats) |
539 | #define BTRFS_IOC_DEV_REPLACE _IOWR(BTRFS_IOCTL_MAGIC, 53, \ | 580 | #define BTRFS_IOC_DEV_REPLACE _IOWR(BTRFS_IOCTL_MAGIC, 53, \ |
540 | struct btrfs_ioctl_dev_replace_args) | 581 | struct btrfs_ioctl_dev_replace_args) |
541 | |||
542 | #endif /* _UAPI_LINUX_BTRFS_H */ | 582 | #endif /* _UAPI_LINUX_BTRFS_H */ |
diff --git a/include/uapi/linux/can/gw.h b/include/uapi/linux/can/gw.h index ae07bec74f4b..4e27c82b564a 100644 --- a/include/uapi/linux/can/gw.h +++ b/include/uapi/linux/can/gw.h | |||
@@ -45,6 +45,7 @@ enum { | |||
45 | CGW_DST_IF, /* ifindex of destination network interface */ | 45 | CGW_DST_IF, /* ifindex of destination network interface */ |
46 | CGW_FILTER, /* specify struct can_filter on source CAN device */ | 46 | CGW_FILTER, /* specify struct can_filter on source CAN device */ |
47 | CGW_DELETED, /* number of deleted CAN frames (see max_hops param) */ | 47 | CGW_DELETED, /* number of deleted CAN frames (see max_hops param) */ |
48 | CGW_LIM_HOPS, /* limit the number of hops of this specific rule */ | ||
48 | __CGW_MAX | 49 | __CGW_MAX |
49 | }; | 50 | }; |
50 | 51 | ||
@@ -116,13 +117,19 @@ enum { | |||
116 | * Sets a CAN receive filter for the gateway job specified by the | 117 | * Sets a CAN receive filter for the gateway job specified by the |
117 | * struct can_filter described in include/linux/can.h | 118 | * struct can_filter described in include/linux/can.h |
118 | * | 119 | * |
119 | * CGW_MOD_XXX (length 17 bytes): | 120 | * CGW_MOD_(AND|OR|XOR|SET) (length 17 bytes): |
120 | * Specifies a modification that's done to a received CAN frame before it is | 121 | * Specifies a modification that's done to a received CAN frame before it is |
121 | * send out to the destination interface. | 122 | * send out to the destination interface. |
122 | * | 123 | * |
123 | * <struct can_frame> data used as operator | 124 | * <struct can_frame> data used as operator |
124 | * <u8> affected CAN frame elements | 125 | * <u8> affected CAN frame elements |
125 | * | 126 | * |
127 | * CGW_LIM_HOPS (length 1 byte): | ||
128 | * Limit the number of hops of this specific rule. Usually the received CAN | ||
129 | * frame can be processed as much as 'max_hops' times (which is given at module | ||
130 | * load time of the can-gw module). This value is used to reduce the number of | ||
131 | * possible hops for this gateway rule to a value smaller then max_hops. | ||
132 | * | ||
126 | * CGW_CS_XOR (length 4 bytes): | 133 | * CGW_CS_XOR (length 4 bytes): |
127 | * Set a simple XOR checksum starting with an initial value into | 134 | * Set a simple XOR checksum starting with an initial value into |
128 | * data[result-idx] using data[start-idx] .. data[end-idx] | 135 | * data[result-idx] using data[start-idx] .. data[end-idx] |
diff --git a/include/uapi/linux/cm4000_cs.h b/include/uapi/linux/cm4000_cs.h index bc51f77db918..1217f751a1bc 100644 --- a/include/uapi/linux/cm4000_cs.h +++ b/include/uapi/linux/cm4000_cs.h | |||
@@ -2,6 +2,7 @@ | |||
2 | #define _UAPI_CM4000_H_ | 2 | #define _UAPI_CM4000_H_ |
3 | 3 | ||
4 | #include <linux/types.h> | 4 | #include <linux/types.h> |
5 | #include <linux/ioctl.h> | ||
5 | 6 | ||
6 | #define MAX_ATR 33 | 7 | #define MAX_ATR 33 |
7 | 8 | ||
diff --git a/include/uapi/linux/const.h b/include/uapi/linux/const.h index c22c707c455d..c872bfd25e13 100644 --- a/include/uapi/linux/const.h +++ b/include/uapi/linux/const.h | |||
@@ -21,4 +21,7 @@ | |||
21 | #define _AT(T,X) ((T)(X)) | 21 | #define _AT(T,X) ((T)(X)) |
22 | #endif | 22 | #endif |
23 | 23 | ||
24 | #define _BITUL(x) (_AC(1,UL) << (x)) | ||
25 | #define _BITULL(x) (_AC(1,ULL) << (x)) | ||
26 | |||
24 | #endif /* !(_LINUX_CONST_H) */ | 27 | #endif /* !(_LINUX_CONST_H) */ |
diff --git a/include/uapi/linux/dm-ioctl.h b/include/uapi/linux/dm-ioctl.h index 7e75b6fd8d45..afd0cbd52edb 100644 --- a/include/uapi/linux/dm-ioctl.h +++ b/include/uapi/linux/dm-ioctl.h | |||
@@ -267,9 +267,9 @@ enum { | |||
267 | #define DM_DEV_SET_GEOMETRY _IOWR(DM_IOCTL, DM_DEV_SET_GEOMETRY_CMD, struct dm_ioctl) | 267 | #define DM_DEV_SET_GEOMETRY _IOWR(DM_IOCTL, DM_DEV_SET_GEOMETRY_CMD, struct dm_ioctl) |
268 | 268 | ||
269 | #define DM_VERSION_MAJOR 4 | 269 | #define DM_VERSION_MAJOR 4 |
270 | #define DM_VERSION_MINOR 24 | 270 | #define DM_VERSION_MINOR 25 |
271 | #define DM_VERSION_PATCHLEVEL 0 | 271 | #define DM_VERSION_PATCHLEVEL 0 |
272 | #define DM_VERSION_EXTRA "-ioctl (2013-01-15)" | 272 | #define DM_VERSION_EXTRA "-ioctl (2013-06-26)" |
273 | 273 | ||
274 | /* Status bits */ | 274 | /* Status bits */ |
275 | #define DM_READONLY_FLAG (1 << 0) /* In/Out */ | 275 | #define DM_READONLY_FLAG (1 << 0) /* In/Out */ |
diff --git a/include/uapi/linux/dn.h b/include/uapi/linux/dn.h index 9c50445462d9..5fbdd3d49eba 100644 --- a/include/uapi/linux/dn.h +++ b/include/uapi/linux/dn.h | |||
@@ -2,6 +2,7 @@ | |||
2 | #define _LINUX_DN_H | 2 | #define _LINUX_DN_H |
3 | 3 | ||
4 | #include <linux/types.h> | 4 | #include <linux/types.h> |
5 | #include <linux/if_ether.h> | ||
5 | 6 | ||
6 | /* | 7 | /* |
7 | 8 | ||
@@ -120,7 +121,7 @@ struct linkinfo_dn { | |||
120 | * Ethernet address format (for DECnet) | 121 | * Ethernet address format (for DECnet) |
121 | */ | 122 | */ |
122 | union etheraddress { | 123 | union etheraddress { |
123 | __u8 dne_addr[6]; /* Full ethernet address */ | 124 | __u8 dne_addr[ETH_ALEN]; /* Full ethernet address */ |
124 | struct { | 125 | struct { |
125 | __u8 dne_hiord[4]; /* DECnet HIORD prefix */ | 126 | __u8 dne_hiord[4]; /* DECnet HIORD prefix */ |
126 | __u8 dne_nodeaddr[2]; /* DECnet node address */ | 127 | __u8 dne_nodeaddr[2]; /* DECnet node address */ |
diff --git a/include/uapi/linux/elf-em.h b/include/uapi/linux/elf-em.h index 8e2b7bac4378..59c17a2d38ad 100644 --- a/include/uapi/linux/elf-em.h +++ b/include/uapi/linux/elf-em.h | |||
@@ -22,6 +22,7 @@ | |||
22 | #define EM_PPC 20 /* PowerPC */ | 22 | #define EM_PPC 20 /* PowerPC */ |
23 | #define EM_PPC64 21 /* PowerPC64 */ | 23 | #define EM_PPC64 21 /* PowerPC64 */ |
24 | #define EM_SPU 23 /* Cell BE SPU */ | 24 | #define EM_SPU 23 /* Cell BE SPU */ |
25 | #define EM_ARM 40 /* ARM 32 bit */ | ||
25 | #define EM_SH 42 /* SuperH */ | 26 | #define EM_SH 42 /* SuperH */ |
26 | #define EM_SPARCV9 43 /* SPARC v9 64-bit */ | 27 | #define EM_SPARCV9 43 /* SPARC v9 64-bit */ |
27 | #define EM_IA_64 50 /* HP/Intel IA-64 */ | 28 | #define EM_IA_64 50 /* HP/Intel IA-64 */ |
@@ -34,6 +35,7 @@ | |||
34 | #define EM_MN10300 89 /* Panasonic/MEI MN10300, AM33 */ | 35 | #define EM_MN10300 89 /* Panasonic/MEI MN10300, AM33 */ |
35 | #define EM_BLACKFIN 106 /* ADI Blackfin Processor */ | 36 | #define EM_BLACKFIN 106 /* ADI Blackfin Processor */ |
36 | #define EM_TI_C6000 140 /* TI C6X DSPs */ | 37 | #define EM_TI_C6000 140 /* TI C6X DSPs */ |
38 | #define EM_AARCH64 183 /* ARM 64 bit */ | ||
37 | #define EM_FRV 0x5441 /* Fujitsu FR-V */ | 39 | #define EM_FRV 0x5441 /* Fujitsu FR-V */ |
38 | #define EM_AVR32 0x18ad /* Atmel AVR32 */ | 40 | #define EM_AVR32 0x18ad /* Atmel AVR32 */ |
39 | 41 | ||
diff --git a/include/uapi/linux/ethtool.h b/include/uapi/linux/ethtool.h index 0c9b44871df0..38dbafaa5341 100644 --- a/include/uapi/linux/ethtool.h +++ b/include/uapi/linux/ethtool.h | |||
@@ -993,8 +993,8 @@ enum ethtool_sfeatures_retval_bits { | |||
993 | #define PORT_OTHER 0xff | 993 | #define PORT_OTHER 0xff |
994 | 994 | ||
995 | /* Which transceiver to use. */ | 995 | /* Which transceiver to use. */ |
996 | #define XCVR_INTERNAL 0x00 | 996 | #define XCVR_INTERNAL 0x00 /* PHY and MAC are in the same package */ |
997 | #define XCVR_EXTERNAL 0x01 | 997 | #define XCVR_EXTERNAL 0x01 /* PHY and MAC are in different packages */ |
998 | #define XCVR_DUMMY1 0x02 | 998 | #define XCVR_DUMMY1 0x02 |
999 | #define XCVR_DUMMY2 0x03 | 999 | #define XCVR_DUMMY2 0x03 |
1000 | #define XCVR_DUMMY3 0x04 | 1000 | #define XCVR_DUMMY3 0x04 |
diff --git a/include/uapi/linux/fib_rules.h b/include/uapi/linux/fib_rules.h index 51da65b68b85..2b82d7e30974 100644 --- a/include/uapi/linux/fib_rules.h +++ b/include/uapi/linux/fib_rules.h | |||
@@ -44,8 +44,8 @@ enum { | |||
44 | FRA_FWMARK, /* mark */ | 44 | FRA_FWMARK, /* mark */ |
45 | FRA_FLOW, /* flow/class id */ | 45 | FRA_FLOW, /* flow/class id */ |
46 | FRA_UNUSED6, | 46 | FRA_UNUSED6, |
47 | FRA_UNUSED7, | 47 | FRA_SUPPRESS_IFGROUP, |
48 | FRA_UNUSED8, | 48 | FRA_SUPPRESS_PREFIXLEN, |
49 | FRA_TABLE, /* Extended table id */ | 49 | FRA_TABLE, /* Extended table id */ |
50 | FRA_FWMASK, /* mask for netfilter mark */ | 50 | FRA_FWMASK, /* mask for netfilter mark */ |
51 | FRA_OIFNAME, | 51 | FRA_OIFNAME, |
diff --git a/include/uapi/linux/fiemap.h b/include/uapi/linux/fiemap.h index d830747f5c0b..0c51d617dae9 100644 --- a/include/uapi/linux/fiemap.h +++ b/include/uapi/linux/fiemap.h | |||
@@ -40,6 +40,7 @@ struct fiemap { | |||
40 | 40 | ||
41 | #define FIEMAP_FLAG_SYNC 0x00000001 /* sync file data before map */ | 41 | #define FIEMAP_FLAG_SYNC 0x00000001 /* sync file data before map */ |
42 | #define FIEMAP_FLAG_XATTR 0x00000002 /* map extended attribute tree */ | 42 | #define FIEMAP_FLAG_XATTR 0x00000002 /* map extended attribute tree */ |
43 | #define FIEMAP_FLAG_CACHE 0x00000004 /* request caching of the extents */ | ||
43 | 44 | ||
44 | #define FIEMAP_FLAGS_COMPAT (FIEMAP_FLAG_SYNC | FIEMAP_FLAG_XATTR) | 45 | #define FIEMAP_FLAGS_COMPAT (FIEMAP_FLAG_SYNC | FIEMAP_FLAG_XATTR) |
45 | 46 | ||
diff --git a/include/uapi/linux/firewire-cdev.h b/include/uapi/linux/firewire-cdev.h index d50036953497..1db453e4b550 100644 --- a/include/uapi/linux/firewire-cdev.h +++ b/include/uapi/linux/firewire-cdev.h | |||
@@ -215,8 +215,8 @@ struct fw_cdev_event_request2 { | |||
215 | * with the %FW_CDEV_ISO_INTERRUPT bit set, when explicitly requested with | 215 | * with the %FW_CDEV_ISO_INTERRUPT bit set, when explicitly requested with |
216 | * %FW_CDEV_IOC_FLUSH_ISO, or when there have been so many completed packets | 216 | * %FW_CDEV_IOC_FLUSH_ISO, or when there have been so many completed packets |
217 | * without the interrupt bit set that the kernel's internal buffer for @header | 217 | * without the interrupt bit set that the kernel's internal buffer for @header |
218 | * is about to overflow. (In the last case, kernels with ABI version < 5 drop | 218 | * is about to overflow. (In the last case, ABI versions < 5 drop header data |
219 | * header data up to the next interrupt packet.) | 219 | * up to the next interrupt packet.) |
220 | * | 220 | * |
221 | * Isochronous transmit events (context type %FW_CDEV_ISO_CONTEXT_TRANSMIT): | 221 | * Isochronous transmit events (context type %FW_CDEV_ISO_CONTEXT_TRANSMIT): |
222 | * | 222 | * |
diff --git a/include/uapi/linux/gen_stats.h b/include/uapi/linux/gen_stats.h index 552c8a0a12d1..6487317ea619 100644 --- a/include/uapi/linux/gen_stats.h +++ b/include/uapi/linux/gen_stats.h | |||
@@ -9,6 +9,7 @@ enum { | |||
9 | TCA_STATS_RATE_EST, | 9 | TCA_STATS_RATE_EST, |
10 | TCA_STATS_QUEUE, | 10 | TCA_STATS_QUEUE, |
11 | TCA_STATS_APP, | 11 | TCA_STATS_APP, |
12 | TCA_STATS_RATE_EST64, | ||
12 | __TCA_STATS_MAX, | 13 | __TCA_STATS_MAX, |
13 | }; | 14 | }; |
14 | #define TCA_STATS_MAX (__TCA_STATS_MAX - 1) | 15 | #define TCA_STATS_MAX (__TCA_STATS_MAX - 1) |
@@ -38,6 +39,16 @@ struct gnet_stats_rate_est { | |||
38 | }; | 39 | }; |
39 | 40 | ||
40 | /** | 41 | /** |
42 | * struct gnet_stats_rate_est64 - rate estimator | ||
43 | * @bps: current byte rate | ||
44 | * @pps: current packet rate | ||
45 | */ | ||
46 | struct gnet_stats_rate_est64 { | ||
47 | __u64 bps; | ||
48 | __u64 pps; | ||
49 | }; | ||
50 | |||
51 | /** | ||
41 | * struct gnet_stats_queue - queuing statistics | 52 | * struct gnet_stats_queue - queuing statistics |
42 | * @qlen: queue length | 53 | * @qlen: queue length |
43 | * @backlog: backlog size of queue | 54 | * @backlog: backlog size of queue |
diff --git a/include/uapi/linux/icmpv6.h b/include/uapi/linux/icmpv6.h index e0133c73c304..590beda78ea0 100644 --- a/include/uapi/linux/icmpv6.h +++ b/include/uapi/linux/icmpv6.h | |||
@@ -115,6 +115,8 @@ struct icmp6hdr { | |||
115 | #define ICMPV6_NOT_NEIGHBOUR 2 | 115 | #define ICMPV6_NOT_NEIGHBOUR 2 |
116 | #define ICMPV6_ADDR_UNREACH 3 | 116 | #define ICMPV6_ADDR_UNREACH 3 |
117 | #define ICMPV6_PORT_UNREACH 4 | 117 | #define ICMPV6_PORT_UNREACH 4 |
118 | #define ICMPV6_POLICY_FAIL 5 | ||
119 | #define ICMPV6_REJECT_ROUTE 6 | ||
118 | 120 | ||
119 | /* | 121 | /* |
120 | * Codes for Time Exceeded | 122 | * Codes for Time Exceeded |
diff --git a/include/uapi/linux/if_arp.h b/include/uapi/linux/if_arp.h index 82c7d1bdadeb..d7fea3496f32 100644 --- a/include/uapi/linux/if_arp.h +++ b/include/uapi/linux/if_arp.h | |||
@@ -93,6 +93,7 @@ | |||
93 | #define ARPHRD_PHONET_PIPE 821 /* PhoNet pipe header */ | 93 | #define ARPHRD_PHONET_PIPE 821 /* PhoNet pipe header */ |
94 | #define ARPHRD_CAIF 822 /* CAIF media type */ | 94 | #define ARPHRD_CAIF 822 /* CAIF media type */ |
95 | #define ARPHRD_IP6GRE 823 /* GRE over IPv6 */ | 95 | #define ARPHRD_IP6GRE 823 /* GRE over IPv6 */ |
96 | #define ARPHRD_NETLINK 824 /* Netlink header */ | ||
96 | 97 | ||
97 | #define ARPHRD_VOID 0xFFFF /* Void type, nothing is known */ | 98 | #define ARPHRD_VOID 0xFFFF /* Void type, nothing is known */ |
98 | #define ARPHRD_NONE 0xFFFE /* zero header length */ | 99 | #define ARPHRD_NONE 0xFFFE /* zero header length */ |
diff --git a/include/uapi/linux/if_bridge.h b/include/uapi/linux/if_bridge.h index 2d70d79ce2fd..39f621a9fe82 100644 --- a/include/uapi/linux/if_bridge.h +++ b/include/uapi/linux/if_bridge.h | |||
@@ -14,6 +14,7 @@ | |||
14 | #define _UAPI_LINUX_IF_BRIDGE_H | 14 | #define _UAPI_LINUX_IF_BRIDGE_H |
15 | 15 | ||
16 | #include <linux/types.h> | 16 | #include <linux/types.h> |
17 | #include <linux/if_ether.h> | ||
17 | 18 | ||
18 | #define SYSFS_BRIDGE_ATTR "bridge" | 19 | #define SYSFS_BRIDGE_ATTR "bridge" |
19 | #define SYSFS_BRIDGE_FDB "brforward" | 20 | #define SYSFS_BRIDGE_FDB "brforward" |
@@ -88,7 +89,7 @@ struct __port_info { | |||
88 | }; | 89 | }; |
89 | 90 | ||
90 | struct __fdb_entry { | 91 | struct __fdb_entry { |
91 | __u8 mac_addr[6]; | 92 | __u8 mac_addr[ETH_ALEN]; |
92 | __u8 port_no; | 93 | __u8 port_no; |
93 | __u8 is_local; | 94 | __u8 is_local; |
94 | __u32 ageing_timer_value; | 95 | __u32 ageing_timer_value; |
diff --git a/include/uapi/linux/if_link.h b/include/uapi/linux/if_link.h index b05823cae784..80394e8dc3a3 100644 --- a/include/uapi/linux/if_link.h +++ b/include/uapi/linux/if_link.h | |||
@@ -143,6 +143,7 @@ enum { | |||
143 | IFLA_NUM_TX_QUEUES, | 143 | IFLA_NUM_TX_QUEUES, |
144 | IFLA_NUM_RX_QUEUES, | 144 | IFLA_NUM_RX_QUEUES, |
145 | IFLA_CARRIER, | 145 | IFLA_CARRIER, |
146 | IFLA_PHYS_PORT_ID, | ||
146 | __IFLA_MAX | 147 | __IFLA_MAX |
147 | }; | 148 | }; |
148 | 149 | ||
@@ -221,6 +222,8 @@ enum { | |||
221 | IFLA_BRPORT_GUARD, /* bpdu guard */ | 222 | IFLA_BRPORT_GUARD, /* bpdu guard */ |
222 | IFLA_BRPORT_PROTECT, /* root port protection */ | 223 | IFLA_BRPORT_PROTECT, /* root port protection */ |
223 | IFLA_BRPORT_FAST_LEAVE, /* multicast fast leave */ | 224 | IFLA_BRPORT_FAST_LEAVE, /* multicast fast leave */ |
225 | IFLA_BRPORT_LEARNING, /* mac learning */ | ||
226 | IFLA_BRPORT_UNICAST_FLOOD, /* flood unicast traffic */ | ||
224 | __IFLA_BRPORT_MAX | 227 | __IFLA_BRPORT_MAX |
225 | }; | 228 | }; |
226 | #define IFLA_BRPORT_MAX (__IFLA_BRPORT_MAX - 1) | 229 | #define IFLA_BRPORT_MAX (__IFLA_BRPORT_MAX - 1) |
@@ -311,6 +314,8 @@ enum { | |||
311 | IFLA_VXLAN_L2MISS, | 314 | IFLA_VXLAN_L2MISS, |
312 | IFLA_VXLAN_L3MISS, | 315 | IFLA_VXLAN_L3MISS, |
313 | IFLA_VXLAN_PORT, /* destination port */ | 316 | IFLA_VXLAN_PORT, /* destination port */ |
317 | IFLA_VXLAN_GROUP6, | ||
318 | IFLA_VXLAN_LOCAL6, | ||
314 | __IFLA_VXLAN_MAX | 319 | __IFLA_VXLAN_MAX |
315 | }; | 320 | }; |
316 | #define IFLA_VXLAN_MAX (__IFLA_VXLAN_MAX - 1) | 321 | #define IFLA_VXLAN_MAX (__IFLA_VXLAN_MAX - 1) |
@@ -336,6 +341,7 @@ enum { | |||
336 | IFLA_VF_VLAN, | 341 | IFLA_VF_VLAN, |
337 | IFLA_VF_TX_RATE, /* TX Bandwidth Allocation */ | 342 | IFLA_VF_TX_RATE, /* TX Bandwidth Allocation */ |
338 | IFLA_VF_SPOOFCHK, /* Spoof Checking on/off switch */ | 343 | IFLA_VF_SPOOFCHK, /* Spoof Checking on/off switch */ |
344 | IFLA_VF_LINK_STATE, /* link state enable/disable/auto switch */ | ||
339 | __IFLA_VF_MAX, | 345 | __IFLA_VF_MAX, |
340 | }; | 346 | }; |
341 | 347 | ||
@@ -362,6 +368,18 @@ struct ifla_vf_spoofchk { | |||
362 | __u32 setting; | 368 | __u32 setting; |
363 | }; | 369 | }; |
364 | 370 | ||
371 | enum { | ||
372 | IFLA_VF_LINK_STATE_AUTO, /* link state of the uplink */ | ||
373 | IFLA_VF_LINK_STATE_ENABLE, /* link always up */ | ||
374 | IFLA_VF_LINK_STATE_DISABLE, /* link always down */ | ||
375 | __IFLA_VF_LINK_STATE_MAX, | ||
376 | }; | ||
377 | |||
378 | struct ifla_vf_link_state { | ||
379 | __u32 vf; | ||
380 | __u32 link_state; | ||
381 | }; | ||
382 | |||
365 | /* VF ports management section | 383 | /* VF ports management section |
366 | * | 384 | * |
367 | * Nested layout of set/get msg is: | 385 | * Nested layout of set/get msg is: |
diff --git a/include/uapi/linux/if_packet.h b/include/uapi/linux/if_packet.h index b950c02030c0..dbf06667394b 100644 --- a/include/uapi/linux/if_packet.h +++ b/include/uapi/linux/if_packet.h | |||
@@ -56,6 +56,7 @@ struct sockaddr_ll { | |||
56 | #define PACKET_FANOUT_LB 1 | 56 | #define PACKET_FANOUT_LB 1 |
57 | #define PACKET_FANOUT_CPU 2 | 57 | #define PACKET_FANOUT_CPU 2 |
58 | #define PACKET_FANOUT_ROLLOVER 3 | 58 | #define PACKET_FANOUT_ROLLOVER 3 |
59 | #define PACKET_FANOUT_RND 4 | ||
59 | #define PACKET_FANOUT_FLAG_ROLLOVER 0x1000 | 60 | #define PACKET_FANOUT_FLAG_ROLLOVER 0x1000 |
60 | #define PACKET_FANOUT_FLAG_DEFRAG 0x8000 | 61 | #define PACKET_FANOUT_FLAG_DEFRAG 0x8000 |
61 | 62 | ||
diff --git a/include/uapi/linux/if_pppox.h b/include/uapi/linux/if_pppox.h index 0b46fd57c8f6..e128769331b5 100644 --- a/include/uapi/linux/if_pppox.h +++ b/include/uapi/linux/if_pppox.h | |||
@@ -46,7 +46,7 @@ struct pppoe_addr { | |||
46 | * PPTP addressing definition | 46 | * PPTP addressing definition |
47 | */ | 47 | */ |
48 | struct pptp_addr { | 48 | struct pptp_addr { |
49 | __be16 call_id; | 49 | __u16 call_id; |
50 | struct in_addr sin_addr; | 50 | struct in_addr sin_addr; |
51 | }; | 51 | }; |
52 | 52 | ||
@@ -135,11 +135,11 @@ struct pppoe_tag { | |||
135 | 135 | ||
136 | struct pppoe_hdr { | 136 | struct pppoe_hdr { |
137 | #if defined(__LITTLE_ENDIAN_BITFIELD) | 137 | #if defined(__LITTLE_ENDIAN_BITFIELD) |
138 | __u8 ver : 4; | ||
139 | __u8 type : 4; | 138 | __u8 type : 4; |
139 | __u8 ver : 4; | ||
140 | #elif defined(__BIG_ENDIAN_BITFIELD) | 140 | #elif defined(__BIG_ENDIAN_BITFIELD) |
141 | __u8 type : 4; | ||
142 | __u8 ver : 4; | 141 | __u8 ver : 4; |
142 | __u8 type : 4; | ||
143 | #else | 143 | #else |
144 | #error "Please fix <asm/byteorder.h>" | 144 | #error "Please fix <asm/byteorder.h>" |
145 | #endif | 145 | #endif |
diff --git a/include/uapi/linux/if_tun.h b/include/uapi/linux/if_tun.h index 2835b85fd46d..e9502dd1ee2c 100644 --- a/include/uapi/linux/if_tun.h +++ b/include/uapi/linux/if_tun.h | |||
@@ -56,6 +56,8 @@ | |||
56 | #define TUNGETVNETHDRSZ _IOR('T', 215, int) | 56 | #define TUNGETVNETHDRSZ _IOR('T', 215, int) |
57 | #define TUNSETVNETHDRSZ _IOW('T', 216, int) | 57 | #define TUNSETVNETHDRSZ _IOW('T', 216, int) |
58 | #define TUNSETQUEUE _IOW('T', 217, int) | 58 | #define TUNSETQUEUE _IOW('T', 217, int) |
59 | #define TUNSETIFINDEX _IOW('T', 218, unsigned int) | ||
60 | #define TUNGETFILTER _IOR('T', 219, struct sock_fprog) | ||
59 | 61 | ||
60 | /* TUNSETIFF ifr flags */ | 62 | /* TUNSETIFF ifr flags */ |
61 | #define IFF_TUN 0x0001 | 63 | #define IFF_TUN 0x0001 |
@@ -68,6 +70,12 @@ | |||
68 | #define IFF_MULTI_QUEUE 0x0100 | 70 | #define IFF_MULTI_QUEUE 0x0100 |
69 | #define IFF_ATTACH_QUEUE 0x0200 | 71 | #define IFF_ATTACH_QUEUE 0x0200 |
70 | #define IFF_DETACH_QUEUE 0x0400 | 72 | #define IFF_DETACH_QUEUE 0x0400 |
73 | /* read-only flag */ | ||
74 | #define IFF_PERSIST 0x0800 | ||
75 | #define IFF_NOFILTER 0x1000 | ||
76 | |||
77 | /* Socket options */ | ||
78 | #define TUN_TX_TIMESTAMP 1 | ||
71 | 79 | ||
72 | /* Features for GSO (TUNSETOFFLOAD). */ | 80 | /* Features for GSO (TUNSETOFFLOAD). */ |
73 | #define TUN_F_CSUM 0x01 /* You can hand me unchecksummed packets. */ | 81 | #define TUN_F_CSUM 0x01 /* You can hand me unchecksummed packets. */ |
diff --git a/include/uapi/linux/in.h b/include/uapi/linux/in.h index 9edb441df827..f9e8e496ae5d 100644 --- a/include/uapi/linux/in.h +++ b/include/uapi/linux/in.h | |||
@@ -24,30 +24,53 @@ | |||
24 | /* Standard well-defined IP protocols. */ | 24 | /* Standard well-defined IP protocols. */ |
25 | enum { | 25 | enum { |
26 | IPPROTO_IP = 0, /* Dummy protocol for TCP */ | 26 | IPPROTO_IP = 0, /* Dummy protocol for TCP */ |
27 | #define IPPROTO_IP IPPROTO_IP | ||
27 | IPPROTO_ICMP = 1, /* Internet Control Message Protocol */ | 28 | IPPROTO_ICMP = 1, /* Internet Control Message Protocol */ |
29 | #define IPPROTO_ICMP IPPROTO_ICMP | ||
28 | IPPROTO_IGMP = 2, /* Internet Group Management Protocol */ | 30 | IPPROTO_IGMP = 2, /* Internet Group Management Protocol */ |
31 | #define IPPROTO_IGMP IPPROTO_IGMP | ||
29 | IPPROTO_IPIP = 4, /* IPIP tunnels (older KA9Q tunnels use 94) */ | 32 | IPPROTO_IPIP = 4, /* IPIP tunnels (older KA9Q tunnels use 94) */ |
33 | #define IPPROTO_IPIP IPPROTO_IPIP | ||
30 | IPPROTO_TCP = 6, /* Transmission Control Protocol */ | 34 | IPPROTO_TCP = 6, /* Transmission Control Protocol */ |
35 | #define IPPROTO_TCP IPPROTO_TCP | ||
31 | IPPROTO_EGP = 8, /* Exterior Gateway Protocol */ | 36 | IPPROTO_EGP = 8, /* Exterior Gateway Protocol */ |
37 | #define IPPROTO_EGP IPPROTO_EGP | ||
32 | IPPROTO_PUP = 12, /* PUP protocol */ | 38 | IPPROTO_PUP = 12, /* PUP protocol */ |
39 | #define IPPROTO_PUP IPPROTO_PUP | ||
33 | IPPROTO_UDP = 17, /* User Datagram Protocol */ | 40 | IPPROTO_UDP = 17, /* User Datagram Protocol */ |
41 | #define IPPROTO_UDP IPPROTO_UDP | ||
34 | IPPROTO_IDP = 22, /* XNS IDP protocol */ | 42 | IPPROTO_IDP = 22, /* XNS IDP protocol */ |
43 | #define IPPROTO_IDP IPPROTO_IDP | ||
44 | IPPROTO_TP = 29, /* SO Transport Protocol Class 4 */ | ||
45 | #define IPPROTO_TP IPPROTO_TP | ||
35 | IPPROTO_DCCP = 33, /* Datagram Congestion Control Protocol */ | 46 | IPPROTO_DCCP = 33, /* Datagram Congestion Control Protocol */ |
36 | IPPROTO_RSVP = 46, /* RSVP protocol */ | 47 | #define IPPROTO_DCCP IPPROTO_DCCP |
48 | IPPROTO_IPV6 = 41, /* IPv6-in-IPv4 tunnelling */ | ||
49 | #define IPPROTO_IPV6 IPPROTO_IPV6 | ||
50 | IPPROTO_RSVP = 46, /* RSVP Protocol */ | ||
51 | #define IPPROTO_RSVP IPPROTO_RSVP | ||
37 | IPPROTO_GRE = 47, /* Cisco GRE tunnels (rfc 1701,1702) */ | 52 | IPPROTO_GRE = 47, /* Cisco GRE tunnels (rfc 1701,1702) */ |
38 | 53 | #define IPPROTO_GRE IPPROTO_GRE | |
39 | IPPROTO_IPV6 = 41, /* IPv6-in-IPv4 tunnelling */ | 54 | IPPROTO_ESP = 50, /* Encapsulation Security Payload protocol */ |
40 | 55 | #define IPPROTO_ESP IPPROTO_ESP | |
41 | IPPROTO_ESP = 50, /* Encapsulation Security Payload protocol */ | 56 | IPPROTO_AH = 51, /* Authentication Header protocol */ |
42 | IPPROTO_AH = 51, /* Authentication Header protocol */ | 57 | #define IPPROTO_AH IPPROTO_AH |
43 | IPPROTO_BEETPH = 94, /* IP option pseudo header for BEET */ | 58 | IPPROTO_MTP = 92, /* Multicast Transport Protocol */ |
44 | IPPROTO_PIM = 103, /* Protocol Independent Multicast */ | 59 | #define IPPROTO_MTP IPPROTO_MTP |
45 | 60 | IPPROTO_BEETPH = 94, /* IP option pseudo header for BEET */ | |
46 | IPPROTO_COMP = 108, /* Compression Header protocol */ | 61 | #define IPPROTO_BEETPH IPPROTO_BEETPH |
47 | IPPROTO_SCTP = 132, /* Stream Control Transport Protocol */ | 62 | IPPROTO_ENCAP = 98, /* Encapsulation Header */ |
63 | #define IPPROTO_ENCAP IPPROTO_ENCAP | ||
64 | IPPROTO_PIM = 103, /* Protocol Independent Multicast */ | ||
65 | #define IPPROTO_PIM IPPROTO_PIM | ||
66 | IPPROTO_COMP = 108, /* Compression Header Protocol */ | ||
67 | #define IPPROTO_COMP IPPROTO_COMP | ||
68 | IPPROTO_SCTP = 132, /* Stream Control Transport Protocol */ | ||
69 | #define IPPROTO_SCTP IPPROTO_SCTP | ||
48 | IPPROTO_UDPLITE = 136, /* UDP-Lite (RFC 3828) */ | 70 | IPPROTO_UDPLITE = 136, /* UDP-Lite (RFC 3828) */ |
49 | 71 | #define IPPROTO_UDPLITE IPPROTO_UDPLITE | |
50 | IPPROTO_RAW = 255, /* Raw IP packets */ | 72 | IPPROTO_RAW = 255, /* Raw IP packets */ |
73 | #define IPPROTO_RAW IPPROTO_RAW | ||
51 | IPPROTO_MAX | 74 | IPPROTO_MAX |
52 | }; | 75 | }; |
53 | 76 | ||
diff --git a/include/uapi/linux/in6.h b/include/uapi/linux/in6.h index 53b1d56a6e7f..440d5c479145 100644 --- a/include/uapi/linux/in6.h +++ b/include/uapi/linux/in6.h | |||
@@ -22,22 +22,30 @@ | |||
22 | #define _UAPI_LINUX_IN6_H | 22 | #define _UAPI_LINUX_IN6_H |
23 | 23 | ||
24 | #include <linux/types.h> | 24 | #include <linux/types.h> |
25 | #include <linux/libc-compat.h> | ||
25 | 26 | ||
26 | /* | 27 | /* |
27 | * IPv6 address structure | 28 | * IPv6 address structure |
28 | */ | 29 | */ |
29 | 30 | ||
31 | #if __UAPI_DEF_IN6_ADDR | ||
30 | struct in6_addr { | 32 | struct in6_addr { |
31 | union { | 33 | union { |
32 | __u8 u6_addr8[16]; | 34 | __u8 u6_addr8[16]; |
35 | #if __UAPI_DEF_IN6_ADDR_ALT | ||
33 | __be16 u6_addr16[8]; | 36 | __be16 u6_addr16[8]; |
34 | __be32 u6_addr32[4]; | 37 | __be32 u6_addr32[4]; |
38 | #endif | ||
35 | } in6_u; | 39 | } in6_u; |
36 | #define s6_addr in6_u.u6_addr8 | 40 | #define s6_addr in6_u.u6_addr8 |
41 | #if __UAPI_DEF_IN6_ADDR_ALT | ||
37 | #define s6_addr16 in6_u.u6_addr16 | 42 | #define s6_addr16 in6_u.u6_addr16 |
38 | #define s6_addr32 in6_u.u6_addr32 | 43 | #define s6_addr32 in6_u.u6_addr32 |
44 | #endif | ||
39 | }; | 45 | }; |
46 | #endif /* __UAPI_DEF_IN6_ADDR */ | ||
40 | 47 | ||
48 | #if __UAPI_DEF_SOCKADDR_IN6 | ||
41 | struct sockaddr_in6 { | 49 | struct sockaddr_in6 { |
42 | unsigned short int sin6_family; /* AF_INET6 */ | 50 | unsigned short int sin6_family; /* AF_INET6 */ |
43 | __be16 sin6_port; /* Transport layer port # */ | 51 | __be16 sin6_port; /* Transport layer port # */ |
@@ -45,7 +53,9 @@ struct sockaddr_in6 { | |||
45 | struct in6_addr sin6_addr; /* IPv6 address */ | 53 | struct in6_addr sin6_addr; /* IPv6 address */ |
46 | __u32 sin6_scope_id; /* scope id (new in RFC2553) */ | 54 | __u32 sin6_scope_id; /* scope id (new in RFC2553) */ |
47 | }; | 55 | }; |
56 | #endif /* __UAPI_DEF_SOCKADDR_IN6 */ | ||
48 | 57 | ||
58 | #if __UAPI_DEF_IPV6_MREQ | ||
49 | struct ipv6_mreq { | 59 | struct ipv6_mreq { |
50 | /* IPv6 multicast address of group */ | 60 | /* IPv6 multicast address of group */ |
51 | struct in6_addr ipv6mr_multiaddr; | 61 | struct in6_addr ipv6mr_multiaddr; |
@@ -53,6 +63,7 @@ struct ipv6_mreq { | |||
53 | /* local IPv6 address of interface */ | 63 | /* local IPv6 address of interface */ |
54 | int ipv6mr_ifindex; | 64 | int ipv6mr_ifindex; |
55 | }; | 65 | }; |
66 | #endif /* __UAPI_DEF_IVP6_MREQ */ | ||
56 | 67 | ||
57 | #define ipv6mr_acaddr ipv6mr_multiaddr | 68 | #define ipv6mr_acaddr ipv6mr_multiaddr |
58 | 69 | ||
@@ -114,13 +125,24 @@ struct in6_flowlabel_req { | |||
114 | /* | 125 | /* |
115 | * IPV6 extension headers | 126 | * IPV6 extension headers |
116 | */ | 127 | */ |
117 | #define IPPROTO_HOPOPTS 0 /* IPv6 hop-by-hop options */ | 128 | #if __UAPI_DEF_IPPROTO_V6 |
118 | #define IPPROTO_ROUTING 43 /* IPv6 routing header */ | 129 | enum { |
119 | #define IPPROTO_FRAGMENT 44 /* IPv6 fragmentation header */ | 130 | IPPROTO_HOPOPTS = 0, /* IPv6 hop-by-hop options */ |
120 | #define IPPROTO_ICMPV6 58 /* ICMPv6 */ | 131 | #define IPPROTO_HOPOPTS IPPROTO_HOPOPTS |
121 | #define IPPROTO_NONE 59 /* IPv6 no next header */ | 132 | IPPROTO_ROUTING = 43, /* IPv6 routing header */ |
122 | #define IPPROTO_DSTOPTS 60 /* IPv6 destination options */ | 133 | #define IPPROTO_ROUTING IPPROTO_ROUTING |
123 | #define IPPROTO_MH 135 /* IPv6 mobility header */ | 134 | IPPROTO_FRAGMENT = 44, /* IPv6 fragmentation header */ |
135 | #define IPPROTO_FRAGMENT IPPROTO_FRAGMENT | ||
136 | IPPROTO_ICMPV6 = 58, /* ICMPv6 */ | ||
137 | #define IPPROTO_ICMPV6 IPPROTO_ICMPV6 | ||
138 | IPPROTO_NONE = 59, /* IPv6 no next header */ | ||
139 | #define IPPROTO_NONE IPPROTO_NONE | ||
140 | IPPROTO_DSTOPTS = 60, /* IPv6 destination options */ | ||
141 | #define IPPROTO_DSTOPTS IPPROTO_DSTOPTS | ||
142 | IPPROTO_MH = 135, /* IPv6 mobility header */ | ||
143 | #define IPPROTO_MH IPPROTO_MH | ||
144 | }; | ||
145 | #endif /* __UAPI_DEF_IPPROTO_V6 */ | ||
124 | 146 | ||
125 | /* | 147 | /* |
126 | * IPv6 TLV options. | 148 | * IPv6 TLV options. |
diff --git a/include/uapi/linux/input.h b/include/uapi/linux/input.h index 4649ee35b605..d08abf9101d2 100644 --- a/include/uapi/linux/input.h +++ b/include/uapi/linux/input.h | |||
@@ -194,6 +194,8 @@ struct input_keymap_entry { | |||
194 | #define SYN_CONFIG 1 | 194 | #define SYN_CONFIG 1 |
195 | #define SYN_MT_REPORT 2 | 195 | #define SYN_MT_REPORT 2 |
196 | #define SYN_DROPPED 3 | 196 | #define SYN_DROPPED 3 |
197 | #define SYN_MAX 0xf | ||
198 | #define SYN_CNT (SYN_MAX+1) | ||
197 | 199 | ||
198 | /* | 200 | /* |
199 | * Keys and buttons | 201 | * Keys and buttons |
@@ -506,11 +508,15 @@ struct input_keymap_entry { | |||
506 | #define BTN_DEAD 0x12f | 508 | #define BTN_DEAD 0x12f |
507 | 509 | ||
508 | #define BTN_GAMEPAD 0x130 | 510 | #define BTN_GAMEPAD 0x130 |
509 | #define BTN_A 0x130 | 511 | #define BTN_SOUTH 0x130 |
510 | #define BTN_B 0x131 | 512 | #define BTN_A BTN_SOUTH |
513 | #define BTN_EAST 0x131 | ||
514 | #define BTN_B BTN_EAST | ||
511 | #define BTN_C 0x132 | 515 | #define BTN_C 0x132 |
512 | #define BTN_X 0x133 | 516 | #define BTN_NORTH 0x133 |
513 | #define BTN_Y 0x134 | 517 | #define BTN_X BTN_NORTH |
518 | #define BTN_WEST 0x134 | ||
519 | #define BTN_Y BTN_WEST | ||
514 | #define BTN_Z 0x135 | 520 | #define BTN_Z 0x135 |
515 | #define BTN_TL 0x136 | 521 | #define BTN_TL 0x136 |
516 | #define BTN_TR 0x137 | 522 | #define BTN_TR 0x137 |
@@ -707,6 +713,11 @@ struct input_keymap_entry { | |||
707 | #define KEY_ATTENDANT_TOGGLE 0x21d /* Attendant call on or off */ | 713 | #define KEY_ATTENDANT_TOGGLE 0x21d /* Attendant call on or off */ |
708 | #define KEY_LIGHTS_TOGGLE 0x21e /* Reading light on or off */ | 714 | #define KEY_LIGHTS_TOGGLE 0x21e /* Reading light on or off */ |
709 | 715 | ||
716 | #define BTN_DPAD_UP 0x220 | ||
717 | #define BTN_DPAD_DOWN 0x221 | ||
718 | #define BTN_DPAD_LEFT 0x222 | ||
719 | #define BTN_DPAD_RIGHT 0x223 | ||
720 | |||
710 | #define BTN_TRIGGER_HAPPY 0x2c0 | 721 | #define BTN_TRIGGER_HAPPY 0x2c0 |
711 | #define BTN_TRIGGER_HAPPY1 0x2c0 | 722 | #define BTN_TRIGGER_HAPPY1 0x2c0 |
712 | #define BTN_TRIGGER_HAPPY2 0x2c1 | 723 | #define BTN_TRIGGER_HAPPY2 0x2c1 |
diff --git a/include/uapi/linux/ip.h b/include/uapi/linux/ip.h index 6cf06bfd841b..411959405ab6 100644 --- a/include/uapi/linux/ip.h +++ b/include/uapi/linux/ip.h | |||
@@ -133,4 +133,40 @@ struct ip_beet_phdr { | |||
133 | __u8 reserved; | 133 | __u8 reserved; |
134 | }; | 134 | }; |
135 | 135 | ||
136 | /* index values for the variables in ipv4_devconf */ | ||
137 | enum | ||
138 | { | ||
139 | IPV4_DEVCONF_FORWARDING=1, | ||
140 | IPV4_DEVCONF_MC_FORWARDING, | ||
141 | IPV4_DEVCONF_PROXY_ARP, | ||
142 | IPV4_DEVCONF_ACCEPT_REDIRECTS, | ||
143 | IPV4_DEVCONF_SECURE_REDIRECTS, | ||
144 | IPV4_DEVCONF_SEND_REDIRECTS, | ||
145 | IPV4_DEVCONF_SHARED_MEDIA, | ||
146 | IPV4_DEVCONF_RP_FILTER, | ||
147 | IPV4_DEVCONF_ACCEPT_SOURCE_ROUTE, | ||
148 | IPV4_DEVCONF_BOOTP_RELAY, | ||
149 | IPV4_DEVCONF_LOG_MARTIANS, | ||
150 | IPV4_DEVCONF_TAG, | ||
151 | IPV4_DEVCONF_ARPFILTER, | ||
152 | IPV4_DEVCONF_MEDIUM_ID, | ||
153 | IPV4_DEVCONF_NOXFRM, | ||
154 | IPV4_DEVCONF_NOPOLICY, | ||
155 | IPV4_DEVCONF_FORCE_IGMP_VERSION, | ||
156 | IPV4_DEVCONF_ARP_ANNOUNCE, | ||
157 | IPV4_DEVCONF_ARP_IGNORE, | ||
158 | IPV4_DEVCONF_PROMOTE_SECONDARIES, | ||
159 | IPV4_DEVCONF_ARP_ACCEPT, | ||
160 | IPV4_DEVCONF_ARP_NOTIFY, | ||
161 | IPV4_DEVCONF_ACCEPT_LOCAL, | ||
162 | IPV4_DEVCONF_SRC_VMARK, | ||
163 | IPV4_DEVCONF_PROXY_ARP_PVLAN, | ||
164 | IPV4_DEVCONF_ROUTE_LOCALNET, | ||
165 | IPV4_DEVCONF_IGMPV2_UNSOLICITED_REPORT_INTERVAL, | ||
166 | IPV4_DEVCONF_IGMPV3_UNSOLICITED_REPORT_INTERVAL, | ||
167 | __IPV4_DEVCONF_MAX | ||
168 | }; | ||
169 | |||
170 | #define IPV4_DEVCONF_MAX (__IPV4_DEVCONF_MAX - 1) | ||
171 | |||
136 | #endif /* _UAPI_LINUX_IP_H */ | 172 | #endif /* _UAPI_LINUX_IP_H */ |
diff --git a/include/uapi/linux/ip_vs.h b/include/uapi/linux/ip_vs.h index a24537725e80..29458223d044 100644 --- a/include/uapi/linux/ip_vs.h +++ b/include/uapi/linux/ip_vs.h | |||
@@ -20,6 +20,12 @@ | |||
20 | #define IP_VS_SVC_F_PERSISTENT 0x0001 /* persistent port */ | 20 | #define IP_VS_SVC_F_PERSISTENT 0x0001 /* persistent port */ |
21 | #define IP_VS_SVC_F_HASHED 0x0002 /* hashed entry */ | 21 | #define IP_VS_SVC_F_HASHED 0x0002 /* hashed entry */ |
22 | #define IP_VS_SVC_F_ONEPACKET 0x0004 /* one-packet scheduling */ | 22 | #define IP_VS_SVC_F_ONEPACKET 0x0004 /* one-packet scheduling */ |
23 | #define IP_VS_SVC_F_SCHED1 0x0008 /* scheduler flag 1 */ | ||
24 | #define IP_VS_SVC_F_SCHED2 0x0010 /* scheduler flag 2 */ | ||
25 | #define IP_VS_SVC_F_SCHED3 0x0020 /* scheduler flag 3 */ | ||
26 | |||
27 | #define IP_VS_SVC_F_SCHED_SH_FALLBACK IP_VS_SVC_F_SCHED1 /* SH fallback */ | ||
28 | #define IP_VS_SVC_F_SCHED_SH_PORT IP_VS_SVC_F_SCHED2 /* SH use port */ | ||
23 | 29 | ||
24 | /* | 30 | /* |
25 | * Destination Server Flags | 31 | * Destination Server Flags |
diff --git a/include/uapi/linux/ipv6.h b/include/uapi/linux/ipv6.h index 4bda4cf5b0f5..593b0e32d956 100644 --- a/include/uapi/linux/ipv6.h +++ b/include/uapi/linux/ipv6.h | |||
@@ -160,6 +160,9 @@ enum { | |||
160 | DEVCONF_ACCEPT_DAD, | 160 | DEVCONF_ACCEPT_DAD, |
161 | DEVCONF_FORCE_TLLAO, | 161 | DEVCONF_FORCE_TLLAO, |
162 | DEVCONF_NDISC_NOTIFY, | 162 | DEVCONF_NDISC_NOTIFY, |
163 | DEVCONF_MLDV1_UNSOLICITED_REPORT_INTERVAL, | ||
164 | DEVCONF_MLDV2_UNSOLICITED_REPORT_INTERVAL, | ||
165 | DEVCONF_SUPPRESS_FRAG_NDISC, | ||
163 | DEVCONF_MAX | 166 | DEVCONF_MAX |
164 | }; | 167 | }; |
165 | 168 | ||
diff --git a/include/uapi/linux/kvm.h b/include/uapi/linux/kvm.h index d88c8ee00c8b..99c25338ede8 100644 --- a/include/uapi/linux/kvm.h +++ b/include/uapi/linux/kvm.h | |||
@@ -666,6 +666,8 @@ struct kvm_ppc_smmu_info { | |||
666 | #define KVM_CAP_IRQ_MPIC 90 | 666 | #define KVM_CAP_IRQ_MPIC 90 |
667 | #define KVM_CAP_PPC_RTAS 91 | 667 | #define KVM_CAP_PPC_RTAS 91 |
668 | #define KVM_CAP_IRQ_XICS 92 | 668 | #define KVM_CAP_IRQ_XICS 92 |
669 | #define KVM_CAP_ARM_EL1_32BIT 93 | ||
670 | #define KVM_CAP_SPAPR_MULTITCE 94 | ||
669 | 671 | ||
670 | #ifdef KVM_CAP_IRQ_ROUTING | 672 | #ifdef KVM_CAP_IRQ_ROUTING |
671 | 673 | ||
@@ -783,6 +785,7 @@ struct kvm_dirty_tlb { | |||
783 | #define KVM_REG_IA64 0x3000000000000000ULL | 785 | #define KVM_REG_IA64 0x3000000000000000ULL |
784 | #define KVM_REG_ARM 0x4000000000000000ULL | 786 | #define KVM_REG_ARM 0x4000000000000000ULL |
785 | #define KVM_REG_S390 0x5000000000000000ULL | 787 | #define KVM_REG_S390 0x5000000000000000ULL |
788 | #define KVM_REG_ARM64 0x6000000000000000ULL | ||
786 | #define KVM_REG_MIPS 0x7000000000000000ULL | 789 | #define KVM_REG_MIPS 0x7000000000000000ULL |
787 | 790 | ||
788 | #define KVM_REG_SIZE_SHIFT 52 | 791 | #define KVM_REG_SIZE_SHIFT 52 |
diff --git a/include/uapi/linux/kvm_para.h b/include/uapi/linux/kvm_para.h index cea2c5c72d26..2841f86eae0b 100644 --- a/include/uapi/linux/kvm_para.h +++ b/include/uapi/linux/kvm_para.h | |||
@@ -19,6 +19,7 @@ | |||
19 | #define KVM_HC_MMU_OP 2 | 19 | #define KVM_HC_MMU_OP 2 |
20 | #define KVM_HC_FEATURES 3 | 20 | #define KVM_HC_FEATURES 3 |
21 | #define KVM_HC_PPC_MAP_MAGIC_PAGE 4 | 21 | #define KVM_HC_PPC_MAP_MAGIC_PAGE 4 |
22 | #define KVM_HC_KICK_CPU 5 | ||
22 | 23 | ||
23 | /* | 24 | /* |
24 | * hypercalls use architecture specific | 25 | * hypercalls use architecture specific |
diff --git a/include/uapi/linux/libc-compat.h b/include/uapi/linux/libc-compat.h new file mode 100644 index 000000000000..335e8a7cad39 --- /dev/null +++ b/include/uapi/linux/libc-compat.h | |||
@@ -0,0 +1,103 @@ | |||
1 | /* | ||
2 | * Compatibility interface for userspace libc header coordination: | ||
3 | * | ||
4 | * Define compatibility macros that are used to control the inclusion or | ||
5 | * exclusion of UAPI structures and definitions in coordination with another | ||
6 | * userspace C library. | ||
7 | * | ||
8 | * This header is intended to solve the problem of UAPI definitions that | ||
9 | * conflict with userspace definitions. If a UAPI header has such conflicting | ||
10 | * definitions then the solution is as follows: | ||
11 | * | ||
12 | * * Synchronize the UAPI header and the libc headers so either one can be | ||
13 | * used and such that the ABI is preserved. If this is not possible then | ||
14 | * no simple compatibility interface exists (you need to write translating | ||
15 | * wrappers and rename things) and you can't use this interface. | ||
16 | * | ||
17 | * Then follow this process: | ||
18 | * | ||
19 | * (a) Include libc-compat.h in the UAPI header. | ||
20 | * e.g. #include <linux/libc-compat.h> | ||
21 | * This include must be as early as possible. | ||
22 | * | ||
23 | * (b) In libc-compat.h add enough code to detect that the comflicting | ||
24 | * userspace libc header has been included first. | ||
25 | * | ||
26 | * (c) If the userspace libc header has been included first define a set of | ||
27 | * guard macros of the form __UAPI_DEF_FOO and set their values to 1, else | ||
28 | * set their values to 0. | ||
29 | * | ||
30 | * (d) Back in the UAPI header with the conflicting definitions, guard the | ||
31 | * definitions with: | ||
32 | * #if __UAPI_DEF_FOO | ||
33 | * ... | ||
34 | * #endif | ||
35 | * | ||
36 | * This fixes the situation where the linux headers are included *after* the | ||
37 | * libc headers. To fix the problem with the inclusion in the other order the | ||
38 | * userspace libc headers must be fixed like this: | ||
39 | * | ||
40 | * * For all definitions that conflict with kernel definitions wrap those | ||
41 | * defines in the following: | ||
42 | * #if !__UAPI_DEF_FOO | ||
43 | * ... | ||
44 | * #endif | ||
45 | * | ||
46 | * This prevents the redefinition of a construct already defined by the kernel. | ||
47 | */ | ||
48 | #ifndef _UAPI_LIBC_COMPAT_H | ||
49 | #define _UAPI_LIBC_COMPAT_H | ||
50 | |||
51 | /* We have included glibc headers... */ | ||
52 | #if defined(__GLIBC__) | ||
53 | |||
54 | /* Coordinate with glibc netinet/in.h header. */ | ||
55 | #if defined(_NETINET_IN_H) | ||
56 | |||
57 | /* GLIBC headers included first so don't define anything | ||
58 | * that would already be defined. */ | ||
59 | #define __UAPI_DEF_IN6_ADDR 0 | ||
60 | /* The exception is the in6_addr macros which must be defined | ||
61 | * if the glibc code didn't define them. This guard matches | ||
62 | * the guard in glibc/inet/netinet/in.h which defines the | ||
63 | * additional in6_addr macros e.g. s6_addr16, and s6_addr32. */ | ||
64 | #if defined(__USE_MISC) || defined (__USE_GNU) | ||
65 | #define __UAPI_DEF_IN6_ADDR_ALT 0 | ||
66 | #else | ||
67 | #define __UAPI_DEF_IN6_ADDR_ALT 1 | ||
68 | #endif | ||
69 | #define __UAPI_DEF_SOCKADDR_IN6 0 | ||
70 | #define __UAPI_DEF_IPV6_MREQ 0 | ||
71 | #define __UAPI_DEF_IPPROTO_V6 0 | ||
72 | |||
73 | #else | ||
74 | |||
75 | /* Linux headers included first, and we must define everything | ||
76 | * we need. The expectation is that glibc will check the | ||
77 | * __UAPI_DEF_* defines and adjust appropriately. */ | ||
78 | #define __UAPI_DEF_IN6_ADDR 1 | ||
79 | /* We unconditionally define the in6_addr macros and glibc must | ||
80 | * coordinate. */ | ||
81 | #define __UAPI_DEF_IN6_ADDR_ALT 1 | ||
82 | #define __UAPI_DEF_SOCKADDR_IN6 1 | ||
83 | #define __UAPI_DEF_IPV6_MREQ 1 | ||
84 | #define __UAPI_DEF_IPPROTO_V6 1 | ||
85 | |||
86 | #endif /* _NETINET_IN_H */ | ||
87 | |||
88 | |||
89 | /* If we did not see any headers from any supported C libraries, | ||
90 | * or we are being included in the kernel, then define everything | ||
91 | * that we need. */ | ||
92 | #else /* !defined(__GLIBC__) */ | ||
93 | |||
94 | /* Definitions for in6.h */ | ||
95 | #define __UAPI_DEF_IN6_ADDR 1 | ||
96 | #define __UAPI_DEF_IN6_ADDR_ALT 1 | ||
97 | #define __UAPI_DEF_SOCKADDR_IN6 1 | ||
98 | #define __UAPI_DEF_IPV6_MREQ 1 | ||
99 | #define __UAPI_DEF_IPPROTO_V6 1 | ||
100 | |||
101 | #endif /* __GLIBC__ */ | ||
102 | |||
103 | #endif /* _UAPI_LIBC_COMPAT_H */ | ||
diff --git a/include/uapi/linux/msdos_fs.h b/include/uapi/linux/msdos_fs.h index f055e58b3147..e284ff919d6e 100644 --- a/include/uapi/linux/msdos_fs.h +++ b/include/uapi/linux/msdos_fs.h | |||
@@ -104,6 +104,8 @@ struct __fat_dirent { | |||
104 | /* <linux/videotext.h> has used 0x72 ('r') in collision, so skip a few */ | 104 | /* <linux/videotext.h> has used 0x72 ('r') in collision, so skip a few */ |
105 | #define FAT_IOCTL_GET_ATTRIBUTES _IOR('r', 0x10, __u32) | 105 | #define FAT_IOCTL_GET_ATTRIBUTES _IOR('r', 0x10, __u32) |
106 | #define FAT_IOCTL_SET_ATTRIBUTES _IOW('r', 0x11, __u32) | 106 | #define FAT_IOCTL_SET_ATTRIBUTES _IOW('r', 0x11, __u32) |
107 | /*Android kernel has used 0x12, so we use 0x13*/ | ||
108 | #define FAT_IOCTL_GET_VOLUME_ID _IOR('r', 0x13, __u32) | ||
107 | 109 | ||
108 | struct fat_boot_sector { | 110 | struct fat_boot_sector { |
109 | __u8 ignored[3]; /* Boot strap short or near jump */ | 111 | __u8 ignored[3]; /* Boot strap short or near jump */ |
@@ -128,6 +130,10 @@ struct fat_boot_sector { | |||
128 | __u8 drive_number; /* Physical drive number */ | 130 | __u8 drive_number; /* Physical drive number */ |
129 | __u8 state; /* undocumented, but used | 131 | __u8 state; /* undocumented, but used |
130 | for mount state. */ | 132 | for mount state. */ |
133 | __u8 signature; /* extended boot signature */ | ||
134 | __u8 vol_id[4]; /* volume ID */ | ||
135 | __u8 vol_label[11]; /* volume label */ | ||
136 | __u8 fs_type[8]; /* file system type */ | ||
131 | /* other fiealds are not added here */ | 137 | /* other fiealds are not added here */ |
132 | } fat16; | 138 | } fat16; |
133 | 139 | ||
@@ -147,6 +153,10 @@ struct fat_boot_sector { | |||
147 | __u8 drive_number; /* Physical drive number */ | 153 | __u8 drive_number; /* Physical drive number */ |
148 | __u8 state; /* undocumented, but used | 154 | __u8 state; /* undocumented, but used |
149 | for mount state. */ | 155 | for mount state. */ |
156 | __u8 signature; /* extended boot signature */ | ||
157 | __u8 vol_id[4]; /* volume ID */ | ||
158 | __u8 vol_label[11]; /* volume label */ | ||
159 | __u8 fs_type[8]; /* file system type */ | ||
150 | /* other fiealds are not added here */ | 160 | /* other fiealds are not added here */ |
151 | } fat32; | 161 | } fat32; |
152 | }; | 162 | }; |
diff --git a/include/uapi/linux/netfilter/Kbuild b/include/uapi/linux/netfilter/Kbuild index 41115776d76f..174915420d3f 100644 --- a/include/uapi/linux/netfilter/Kbuild +++ b/include/uapi/linux/netfilter/Kbuild | |||
@@ -22,6 +22,7 @@ header-y += xt_CONNMARK.h | |||
22 | header-y += xt_CONNSECMARK.h | 22 | header-y += xt_CONNSECMARK.h |
23 | header-y += xt_CT.h | 23 | header-y += xt_CT.h |
24 | header-y += xt_DSCP.h | 24 | header-y += xt_DSCP.h |
25 | header-y += xt_HMARK.h | ||
25 | header-y += xt_IDLETIMER.h | 26 | header-y += xt_IDLETIMER.h |
26 | header-y += xt_LED.h | 27 | header-y += xt_LED.h |
27 | header-y += xt_LOG.h | 28 | header-y += xt_LOG.h |
@@ -68,6 +69,7 @@ header-y += xt_quota.h | |||
68 | header-y += xt_rateest.h | 69 | header-y += xt_rateest.h |
69 | header-y += xt_realm.h | 70 | header-y += xt_realm.h |
70 | header-y += xt_recent.h | 71 | header-y += xt_recent.h |
72 | header-y += xt_rpfilter.h | ||
71 | header-y += xt_sctp.h | 73 | header-y += xt_sctp.h |
72 | header-y += xt_set.h | 74 | header-y += xt_set.h |
73 | header-y += xt_socket.h | 75 | header-y += xt_socket.h |
diff --git a/include/uapi/linux/netfilter/nf_conntrack_common.h b/include/uapi/linux/netfilter/nf_conntrack_common.h index d69483fb3825..8dd803818ebe 100644 --- a/include/uapi/linux/netfilter/nf_conntrack_common.h +++ b/include/uapi/linux/netfilter/nf_conntrack_common.h | |||
@@ -99,7 +99,8 @@ enum ip_conntrack_events { | |||
99 | IPCT_PROTOINFO, /* protocol information has changed */ | 99 | IPCT_PROTOINFO, /* protocol information has changed */ |
100 | IPCT_HELPER, /* new helper has been set */ | 100 | IPCT_HELPER, /* new helper has been set */ |
101 | IPCT_MARK, /* new mark has been set */ | 101 | IPCT_MARK, /* new mark has been set */ |
102 | IPCT_NATSEQADJ, /* NAT is doing sequence adjustment */ | 102 | IPCT_SEQADJ, /* sequence adjustment has changed */ |
103 | IPCT_NATSEQADJ = IPCT_SEQADJ, | ||
103 | IPCT_SECMARK, /* new security mark has been set */ | 104 | IPCT_SECMARK, /* new security mark has been set */ |
104 | IPCT_LABEL, /* new connlabel has been set */ | 105 | IPCT_LABEL, /* new connlabel has been set */ |
105 | }; | 106 | }; |
diff --git a/include/uapi/linux/netfilter/nfnetlink_conntrack.h b/include/uapi/linux/netfilter/nfnetlink_conntrack.h index 08fabc6c93f3..acad6c52a652 100644 --- a/include/uapi/linux/netfilter/nfnetlink_conntrack.h +++ b/include/uapi/linux/netfilter/nfnetlink_conntrack.h | |||
@@ -42,8 +42,10 @@ enum ctattr_type { | |||
42 | CTA_ID, | 42 | CTA_ID, |
43 | CTA_NAT_DST, | 43 | CTA_NAT_DST, |
44 | CTA_TUPLE_MASTER, | 44 | CTA_TUPLE_MASTER, |
45 | CTA_NAT_SEQ_ADJ_ORIG, | 45 | CTA_SEQ_ADJ_ORIG, |
46 | CTA_NAT_SEQ_ADJ_REPLY, | 46 | CTA_NAT_SEQ_ADJ_ORIG = CTA_SEQ_ADJ_ORIG, |
47 | CTA_SEQ_ADJ_REPLY, | ||
48 | CTA_NAT_SEQ_ADJ_REPLY = CTA_SEQ_ADJ_REPLY, | ||
47 | CTA_SECMARK, /* obsolete */ | 49 | CTA_SECMARK, /* obsolete */ |
48 | CTA_ZONE, | 50 | CTA_ZONE, |
49 | CTA_SECCTX, | 51 | CTA_SECCTX, |
@@ -165,6 +167,15 @@ enum ctattr_protonat { | |||
165 | }; | 167 | }; |
166 | #define CTA_PROTONAT_MAX (__CTA_PROTONAT_MAX - 1) | 168 | #define CTA_PROTONAT_MAX (__CTA_PROTONAT_MAX - 1) |
167 | 169 | ||
170 | enum ctattr_seqadj { | ||
171 | CTA_SEQADJ_UNSPEC, | ||
172 | CTA_SEQADJ_CORRECTION_POS, | ||
173 | CTA_SEQADJ_OFFSET_BEFORE, | ||
174 | CTA_SEQADJ_OFFSET_AFTER, | ||
175 | __CTA_SEQADJ_MAX | ||
176 | }; | ||
177 | #define CTA_SEQADJ_MAX (__CTA_SEQADJ_MAX - 1) | ||
178 | |||
168 | enum ctattr_natseq { | 179 | enum ctattr_natseq { |
169 | CTA_NAT_SEQ_UNSPEC, | 180 | CTA_NAT_SEQ_UNSPEC, |
170 | CTA_NAT_SEQ_CORRECTION_POS, | 181 | CTA_NAT_SEQ_CORRECTION_POS, |
diff --git a/include/uapi/linux/netfilter/nfnetlink_queue.h b/include/uapi/linux/netfilter/nfnetlink_queue.h index a2308ae5a73d..0132bad79de7 100644 --- a/include/uapi/linux/netfilter/nfnetlink_queue.h +++ b/include/uapi/linux/netfilter/nfnetlink_queue.h | |||
@@ -46,6 +46,7 @@ enum nfqnl_attr_type { | |||
46 | NFQA_CT_INFO, /* enum ip_conntrack_info */ | 46 | NFQA_CT_INFO, /* enum ip_conntrack_info */ |
47 | NFQA_CAP_LEN, /* __u32 length of captured packet */ | 47 | NFQA_CAP_LEN, /* __u32 length of captured packet */ |
48 | NFQA_SKB_INFO, /* __u32 skb meta information */ | 48 | NFQA_SKB_INFO, /* __u32 skb meta information */ |
49 | NFQA_EXP, /* nf_conntrack_netlink.h */ | ||
49 | 50 | ||
50 | __NFQA_MAX | 51 | __NFQA_MAX |
51 | }; | 52 | }; |
@@ -105,5 +106,7 @@ enum nfqnl_attr_config { | |||
105 | #define NFQA_SKB_CSUMNOTREADY (1 << 0) | 106 | #define NFQA_SKB_CSUMNOTREADY (1 << 0) |
106 | /* packet is GSO (i.e., exceeds device mtu) */ | 107 | /* packet is GSO (i.e., exceeds device mtu) */ |
107 | #define NFQA_SKB_GSO (1 << 1) | 108 | #define NFQA_SKB_GSO (1 << 1) |
109 | /* csum not validated (incoming device doesn't support hw checksum, etc.) */ | ||
110 | #define NFQA_SKB_CSUM_NOTVERIFIED (1 << 2) | ||
108 | 111 | ||
109 | #endif /* _NFNETLINK_QUEUE_H */ | 112 | #endif /* _NFNETLINK_QUEUE_H */ |
diff --git a/include/uapi/linux/netfilter/xt_HMARK.h b/include/uapi/linux/netfilter/xt_HMARK.h new file mode 100644 index 000000000000..826fc5807577 --- /dev/null +++ b/include/uapi/linux/netfilter/xt_HMARK.h | |||
@@ -0,0 +1,50 @@ | |||
1 | #ifndef XT_HMARK_H_ | ||
2 | #define XT_HMARK_H_ | ||
3 | |||
4 | #include <linux/types.h> | ||
5 | |||
6 | enum { | ||
7 | XT_HMARK_SADDR_MASK, | ||
8 | XT_HMARK_DADDR_MASK, | ||
9 | XT_HMARK_SPI, | ||
10 | XT_HMARK_SPI_MASK, | ||
11 | XT_HMARK_SPORT, | ||
12 | XT_HMARK_DPORT, | ||
13 | XT_HMARK_SPORT_MASK, | ||
14 | XT_HMARK_DPORT_MASK, | ||
15 | XT_HMARK_PROTO_MASK, | ||
16 | XT_HMARK_RND, | ||
17 | XT_HMARK_MODULUS, | ||
18 | XT_HMARK_OFFSET, | ||
19 | XT_HMARK_CT, | ||
20 | XT_HMARK_METHOD_L3, | ||
21 | XT_HMARK_METHOD_L3_4, | ||
22 | }; | ||
23 | #define XT_HMARK_FLAG(flag) (1 << flag) | ||
24 | |||
25 | union hmark_ports { | ||
26 | struct { | ||
27 | __u16 src; | ||
28 | __u16 dst; | ||
29 | } p16; | ||
30 | struct { | ||
31 | __be16 src; | ||
32 | __be16 dst; | ||
33 | } b16; | ||
34 | __u32 v32; | ||
35 | __be32 b32; | ||
36 | }; | ||
37 | |||
38 | struct xt_hmark_info { | ||
39 | union nf_inet_addr src_mask; | ||
40 | union nf_inet_addr dst_mask; | ||
41 | union hmark_ports port_mask; | ||
42 | union hmark_ports port_set; | ||
43 | __u32 flags; | ||
44 | __u16 proto_mask; | ||
45 | __u32 hashrnd; | ||
46 | __u32 hmodulus; | ||
47 | __u32 hoffset; /* Mark offset to start from */ | ||
48 | }; | ||
49 | |||
50 | #endif /* XT_HMARK_H_ */ | ||
diff --git a/include/uapi/linux/netfilter/xt_SYNPROXY.h b/include/uapi/linux/netfilter/xt_SYNPROXY.h new file mode 100644 index 000000000000..2d59fbaa93c6 --- /dev/null +++ b/include/uapi/linux/netfilter/xt_SYNPROXY.h | |||
@@ -0,0 +1,16 @@ | |||
1 | #ifndef _XT_SYNPROXY_H | ||
2 | #define _XT_SYNPROXY_H | ||
3 | |||
4 | #define XT_SYNPROXY_OPT_MSS 0x01 | ||
5 | #define XT_SYNPROXY_OPT_WSCALE 0x02 | ||
6 | #define XT_SYNPROXY_OPT_SACK_PERM 0x04 | ||
7 | #define XT_SYNPROXY_OPT_TIMESTAMP 0x08 | ||
8 | #define XT_SYNPROXY_OPT_ECN 0x10 | ||
9 | |||
10 | struct xt_synproxy_info { | ||
11 | __u8 options; | ||
12 | __u8 wscale; | ||
13 | __u16 mss; | ||
14 | }; | ||
15 | |||
16 | #endif /* _XT_SYNPROXY_H */ | ||
diff --git a/include/uapi/linux/netfilter/xt_rpfilter.h b/include/uapi/linux/netfilter/xt_rpfilter.h new file mode 100644 index 000000000000..8358d4f71952 --- /dev/null +++ b/include/uapi/linux/netfilter/xt_rpfilter.h | |||
@@ -0,0 +1,23 @@ | |||
1 | #ifndef _XT_RPATH_H | ||
2 | #define _XT_RPATH_H | ||
3 | |||
4 | #include <linux/types.h> | ||
5 | |||
6 | enum { | ||
7 | XT_RPFILTER_LOOSE = 1 << 0, | ||
8 | XT_RPFILTER_VALID_MARK = 1 << 1, | ||
9 | XT_RPFILTER_ACCEPT_LOCAL = 1 << 2, | ||
10 | XT_RPFILTER_INVERT = 1 << 3, | ||
11 | #ifdef __KERNEL__ | ||
12 | XT_RPFILTER_OPTION_MASK = XT_RPFILTER_LOOSE | | ||
13 | XT_RPFILTER_VALID_MARK | | ||
14 | XT_RPFILTER_ACCEPT_LOCAL | | ||
15 | XT_RPFILTER_INVERT, | ||
16 | #endif | ||
17 | }; | ||
18 | |||
19 | struct xt_rpfilter_info { | ||
20 | __u8 flags; | ||
21 | }; | ||
22 | |||
23 | #endif | ||
diff --git a/include/uapi/linux/netfilter/xt_socket.h b/include/uapi/linux/netfilter/xt_socket.h index 26d7217bd4f1..6315e2ac3474 100644 --- a/include/uapi/linux/netfilter/xt_socket.h +++ b/include/uapi/linux/netfilter/xt_socket.h | |||
@@ -5,10 +5,17 @@ | |||
5 | 5 | ||
6 | enum { | 6 | enum { |
7 | XT_SOCKET_TRANSPARENT = 1 << 0, | 7 | XT_SOCKET_TRANSPARENT = 1 << 0, |
8 | XT_SOCKET_NOWILDCARD = 1 << 1, | ||
8 | }; | 9 | }; |
9 | 10 | ||
10 | struct xt_socket_mtinfo1 { | 11 | struct xt_socket_mtinfo1 { |
11 | __u8 flags; | 12 | __u8 flags; |
12 | }; | 13 | }; |
14 | #define XT_SOCKET_FLAGS_V1 XT_SOCKET_TRANSPARENT | ||
15 | |||
16 | struct xt_socket_mtinfo2 { | ||
17 | __u8 flags; | ||
18 | }; | ||
19 | #define XT_SOCKET_FLAGS_V2 (XT_SOCKET_TRANSPARENT | XT_SOCKET_NOWILDCARD) | ||
13 | 20 | ||
14 | #endif /* _XT_SOCKET_H */ | 21 | #endif /* _XT_SOCKET_H */ |
diff --git a/include/uapi/linux/netfilter_bridge/ebt_802_3.h b/include/uapi/linux/netfilter_bridge/ebt_802_3.h index 5bf84912a082..f37522aade24 100644 --- a/include/uapi/linux/netfilter_bridge/ebt_802_3.h +++ b/include/uapi/linux/netfilter_bridge/ebt_802_3.h | |||
@@ -2,6 +2,7 @@ | |||
2 | #define _UAPI__LINUX_BRIDGE_EBT_802_3_H | 2 | #define _UAPI__LINUX_BRIDGE_EBT_802_3_H |
3 | 3 | ||
4 | #include <linux/types.h> | 4 | #include <linux/types.h> |
5 | #include <linux/if_ether.h> | ||
5 | 6 | ||
6 | #define EBT_802_3_SAP 0x01 | 7 | #define EBT_802_3_SAP 0x01 |
7 | #define EBT_802_3_TYPE 0x02 | 8 | #define EBT_802_3_TYPE 0x02 |
@@ -42,8 +43,8 @@ struct hdr_ni { | |||
42 | }; | 43 | }; |
43 | 44 | ||
44 | struct ebt_802_3_hdr { | 45 | struct ebt_802_3_hdr { |
45 | __u8 daddr[6]; | 46 | __u8 daddr[ETH_ALEN]; |
46 | __u8 saddr[6]; | 47 | __u8 saddr[ETH_ALEN]; |
47 | __be16 len; | 48 | __be16 len; |
48 | union { | 49 | union { |
49 | struct hdr_ui ui; | 50 | struct hdr_ui ui; |
diff --git a/include/uapi/linux/netfilter_ipv4/ipt_CLUSTERIP.h b/include/uapi/linux/netfilter_ipv4/ipt_CLUSTERIP.h index c6a204c97047..eac0f6548f47 100644 --- a/include/uapi/linux/netfilter_ipv4/ipt_CLUSTERIP.h +++ b/include/uapi/linux/netfilter_ipv4/ipt_CLUSTERIP.h | |||
@@ -2,6 +2,7 @@ | |||
2 | #define _IPT_CLUSTERIP_H_target | 2 | #define _IPT_CLUSTERIP_H_target |
3 | 3 | ||
4 | #include <linux/types.h> | 4 | #include <linux/types.h> |
5 | #include <linux/if_ether.h> | ||
5 | 6 | ||
6 | enum clusterip_hashmode { | 7 | enum clusterip_hashmode { |
7 | CLUSTERIP_HASHMODE_SIP = 0, | 8 | CLUSTERIP_HASHMODE_SIP = 0, |
@@ -22,7 +23,7 @@ struct ipt_clusterip_tgt_info { | |||
22 | __u32 flags; | 23 | __u32 flags; |
23 | 24 | ||
24 | /* only relevant for new ones */ | 25 | /* only relevant for new ones */ |
25 | __u8 clustermac[6]; | 26 | __u8 clustermac[ETH_ALEN]; |
26 | __u16 num_total_nodes; | 27 | __u16 num_total_nodes; |
27 | __u16 num_local_nodes; | 28 | __u16 num_local_nodes; |
28 | __u16 local_nodes[CLUSTERIP_MAX_NODES]; | 29 | __u16 local_nodes[CLUSTERIP_MAX_NODES]; |
diff --git a/include/uapi/linux/nfc.h b/include/uapi/linux/nfc.h index 7c6f627a717d..29bed72a4ac4 100644 --- a/include/uapi/linux/nfc.h +++ b/include/uapi/linux/nfc.h | |||
@@ -69,6 +69,22 @@ | |||
69 | * starting a poll from a device which has a secure element enabled means | 69 | * starting a poll from a device which has a secure element enabled means |
70 | * we want to do SE based card emulation. | 70 | * we want to do SE based card emulation. |
71 | * @NFC_CMD_DISABLE_SE: Disable the physical link to a specific secure element. | 71 | * @NFC_CMD_DISABLE_SE: Disable the physical link to a specific secure element. |
72 | * @NFC_CMD_FW_DOWNLOAD: Request to Load/flash firmware, or event to inform | ||
73 | * that some firmware was loaded | ||
74 | * @NFC_EVENT_SE_ADDED: Event emitted when a new secure element is discovered. | ||
75 | * This typically will be sent whenever a new NFC controller with either | ||
76 | * an embedded SE or an UICC one connected to it through SWP. | ||
77 | * @NFC_EVENT_SE_REMOVED: Event emitted when a secure element is removed from | ||
78 | * the system, as a consequence of e.g. an NFC controller being unplugged. | ||
79 | * @NFC_EVENT_SE_CONNECTIVITY: This event is emitted whenever a secure element | ||
80 | * is requesting connectivity access. For example a UICC SE may need to | ||
81 | * talk with a sleeping modem and will notify this need by sending this | ||
82 | * event. It is then up to userspace to decide if it will wake the modem | ||
83 | * up or not. | ||
84 | * @NFC_EVENT_SE_TRANSACTION: This event is sent when an application running on | ||
85 | * a specific SE notifies us about the end of a transaction. The parameter | ||
86 | * for this event is the application ID (AID). | ||
87 | * @NFC_CMD_GET_SE: Dump all discovered secure elements from an NFC controller. | ||
72 | */ | 88 | */ |
73 | enum nfc_commands { | 89 | enum nfc_commands { |
74 | NFC_CMD_UNSPEC, | 90 | NFC_CMD_UNSPEC, |
@@ -92,6 +108,12 @@ enum nfc_commands { | |||
92 | NFC_CMD_DISABLE_SE, | 108 | NFC_CMD_DISABLE_SE, |
93 | NFC_CMD_LLC_SDREQ, | 109 | NFC_CMD_LLC_SDREQ, |
94 | NFC_EVENT_LLC_SDRES, | 110 | NFC_EVENT_LLC_SDRES, |
111 | NFC_CMD_FW_DOWNLOAD, | ||
112 | NFC_EVENT_SE_ADDED, | ||
113 | NFC_EVENT_SE_REMOVED, | ||
114 | NFC_EVENT_SE_CONNECTIVITY, | ||
115 | NFC_EVENT_SE_TRANSACTION, | ||
116 | NFC_CMD_GET_SE, | ||
95 | /* private: internal use only */ | 117 | /* private: internal use only */ |
96 | __NFC_CMD_AFTER_LAST | 118 | __NFC_CMD_AFTER_LAST |
97 | }; | 119 | }; |
@@ -121,6 +143,10 @@ enum nfc_commands { | |||
121 | * @NFC_ATTR_LLC_PARAM_RW: Receive Window size parameter | 143 | * @NFC_ATTR_LLC_PARAM_RW: Receive Window size parameter |
122 | * @NFC_ATTR_LLC_PARAM_MIUX: MIU eXtension parameter | 144 | * @NFC_ATTR_LLC_PARAM_MIUX: MIU eXtension parameter |
123 | * @NFC_ATTR_SE: Available Secure Elements | 145 | * @NFC_ATTR_SE: Available Secure Elements |
146 | * @NFC_ATTR_FIRMWARE_NAME: Free format firmware version | ||
147 | * @NFC_ATTR_SE_INDEX: Secure element index | ||
148 | * @NFC_ATTR_SE_TYPE: Secure element type (UICC or EMBEDDED) | ||
149 | * @NFC_ATTR_FIRMWARE_DOWNLOAD_STATUS: Firmware download operation status | ||
124 | */ | 150 | */ |
125 | enum nfc_attrs { | 151 | enum nfc_attrs { |
126 | NFC_ATTR_UNSPEC, | 152 | NFC_ATTR_UNSPEC, |
@@ -143,6 +169,11 @@ enum nfc_attrs { | |||
143 | NFC_ATTR_LLC_PARAM_MIUX, | 169 | NFC_ATTR_LLC_PARAM_MIUX, |
144 | NFC_ATTR_SE, | 170 | NFC_ATTR_SE, |
145 | NFC_ATTR_LLC_SDP, | 171 | NFC_ATTR_LLC_SDP, |
172 | NFC_ATTR_FIRMWARE_NAME, | ||
173 | NFC_ATTR_SE_INDEX, | ||
174 | NFC_ATTR_SE_TYPE, | ||
175 | NFC_ATTR_SE_AID, | ||
176 | NFC_ATTR_FIRMWARE_DOWNLOAD_STATUS, | ||
146 | /* private: internal use only */ | 177 | /* private: internal use only */ |
147 | __NFC_ATTR_AFTER_LAST | 178 | __NFC_ATTR_AFTER_LAST |
148 | }; | 179 | }; |
@@ -159,9 +190,12 @@ enum nfc_sdp_attr { | |||
159 | 190 | ||
160 | #define NFC_DEVICE_NAME_MAXSIZE 8 | 191 | #define NFC_DEVICE_NAME_MAXSIZE 8 |
161 | #define NFC_NFCID1_MAXSIZE 10 | 192 | #define NFC_NFCID1_MAXSIZE 10 |
193 | #define NFC_NFCID2_MAXSIZE 8 | ||
194 | #define NFC_NFCID3_MAXSIZE 10 | ||
162 | #define NFC_SENSB_RES_MAXSIZE 12 | 195 | #define NFC_SENSB_RES_MAXSIZE 12 |
163 | #define NFC_SENSF_RES_MAXSIZE 18 | 196 | #define NFC_SENSF_RES_MAXSIZE 18 |
164 | #define NFC_GB_MAXSIZE 48 | 197 | #define NFC_GB_MAXSIZE 48 |
198 | #define NFC_FIRMWARE_NAME_MAXSIZE 32 | ||
165 | 199 | ||
166 | /* NFC protocols */ | 200 | /* NFC protocols */ |
167 | #define NFC_PROTO_JEWEL 1 | 201 | #define NFC_PROTO_JEWEL 1 |
@@ -191,10 +225,12 @@ enum nfc_sdp_attr { | |||
191 | #define NFC_PROTO_ISO14443_B_MASK (1 << NFC_PROTO_ISO14443_B) | 225 | #define NFC_PROTO_ISO14443_B_MASK (1 << NFC_PROTO_ISO14443_B) |
192 | 226 | ||
193 | /* NFC Secure Elements */ | 227 | /* NFC Secure Elements */ |
194 | #define NFC_SE_NONE 0x0 | ||
195 | #define NFC_SE_UICC 0x1 | 228 | #define NFC_SE_UICC 0x1 |
196 | #define NFC_SE_EMBEDDED 0x2 | 229 | #define NFC_SE_EMBEDDED 0x2 |
197 | 230 | ||
231 | #define NFC_SE_DISABLED 0x0 | ||
232 | #define NFC_SE_ENABLED 0x1 | ||
233 | |||
198 | struct sockaddr_nfc { | 234 | struct sockaddr_nfc { |
199 | sa_family_t sa_family; | 235 | sa_family_t sa_family; |
200 | __u32 dev_idx; | 236 | __u32 dev_idx; |
diff --git a/include/uapi/linux/nl80211.h b/include/uapi/linux/nl80211.h index d1e48b5e348f..fde2c021b26d 100644 --- a/include/uapi/linux/nl80211.h +++ b/include/uapi/linux/nl80211.h | |||
@@ -27,6 +27,8 @@ | |||
27 | 27 | ||
28 | #include <linux/types.h> | 28 | #include <linux/types.h> |
29 | 29 | ||
30 | #define NL80211_GENL_NAME "nl80211" | ||
31 | |||
30 | /** | 32 | /** |
31 | * DOC: Station handling | 33 | * DOC: Station handling |
32 | * | 34 | * |
@@ -124,6 +126,31 @@ | |||
124 | */ | 126 | */ |
125 | 127 | ||
126 | /** | 128 | /** |
129 | * DOC: packet coalesce support | ||
130 | * | ||
131 | * In most cases, host that receives IPv4 and IPv6 multicast/broadcast | ||
132 | * packets does not do anything with these packets. Therefore the | ||
133 | * reception of these unwanted packets causes unnecessary processing | ||
134 | * and power consumption. | ||
135 | * | ||
136 | * Packet coalesce feature helps to reduce number of received interrupts | ||
137 | * to host by buffering these packets in firmware/hardware for some | ||
138 | * predefined time. Received interrupt will be generated when one of the | ||
139 | * following events occur. | ||
140 | * a) Expiration of hardware timer whose expiration time is set to maximum | ||
141 | * coalescing delay of matching coalesce rule. | ||
142 | * b) Coalescing buffer in hardware reaches it's limit. | ||
143 | * c) Packet doesn't match any of the configured coalesce rules. | ||
144 | * | ||
145 | * User needs to configure following parameters for creating a coalesce | ||
146 | * rule. | ||
147 | * a) Maximum coalescing delay | ||
148 | * b) List of packet patterns which needs to be matched | ||
149 | * c) Condition for coalescence. pattern 'match' or 'no match' | ||
150 | * Multiple such rules can be created. | ||
151 | */ | ||
152 | |||
153 | /** | ||
127 | * enum nl80211_commands - supported nl80211 commands | 154 | * enum nl80211_commands - supported nl80211 commands |
128 | * | 155 | * |
129 | * @NL80211_CMD_UNSPEC: unspecified command to catch errors | 156 | * @NL80211_CMD_UNSPEC: unspecified command to catch errors |
@@ -646,6 +673,19 @@ | |||
646 | * @NL80211_CMD_CRIT_PROTOCOL_STOP: Indicates the connection reliability can | 673 | * @NL80211_CMD_CRIT_PROTOCOL_STOP: Indicates the connection reliability can |
647 | * return back to normal. | 674 | * return back to normal. |
648 | * | 675 | * |
676 | * @NL80211_CMD_GET_COALESCE: Get currently supported coalesce rules. | ||
677 | * @NL80211_CMD_SET_COALESCE: Configure coalesce rules or clear existing rules. | ||
678 | * | ||
679 | * @NL80211_CMD_CHANNEL_SWITCH: Perform a channel switch by announcing the | ||
680 | * the new channel information (Channel Switch Announcement - CSA) | ||
681 | * in the beacon for some time (as defined in the | ||
682 | * %NL80211_ATTR_CH_SWITCH_COUNT parameter) and then change to the | ||
683 | * new channel. Userspace provides the new channel information (using | ||
684 | * %NL80211_ATTR_WIPHY_FREQ and the attributes determining channel | ||
685 | * width). %NL80211_ATTR_CH_SWITCH_BLOCK_TX may be supplied to inform | ||
686 | * other station that transmission must be blocked until the channel | ||
687 | * switch is complete. | ||
688 | * | ||
649 | * @NL80211_CMD_MAX: highest used command number | 689 | * @NL80211_CMD_MAX: highest used command number |
650 | * @__NL80211_CMD_AFTER_LAST: internal use | 690 | * @__NL80211_CMD_AFTER_LAST: internal use |
651 | */ | 691 | */ |
@@ -808,6 +848,11 @@ enum nl80211_commands { | |||
808 | NL80211_CMD_CRIT_PROTOCOL_START, | 848 | NL80211_CMD_CRIT_PROTOCOL_START, |
809 | NL80211_CMD_CRIT_PROTOCOL_STOP, | 849 | NL80211_CMD_CRIT_PROTOCOL_STOP, |
810 | 850 | ||
851 | NL80211_CMD_GET_COALESCE, | ||
852 | NL80211_CMD_SET_COALESCE, | ||
853 | |||
854 | NL80211_CMD_CHANNEL_SWITCH, | ||
855 | |||
811 | /* add new commands above here */ | 856 | /* add new commands above here */ |
812 | 857 | ||
813 | /* used to define NL80211_CMD_MAX below */ | 858 | /* used to define NL80211_CMD_MAX below */ |
@@ -1429,6 +1474,28 @@ enum nl80211_commands { | |||
1429 | * @NL80211_ATTR_MAX_CRIT_PROT_DURATION: duration in milliseconds in which | 1474 | * @NL80211_ATTR_MAX_CRIT_PROT_DURATION: duration in milliseconds in which |
1430 | * the connection should have increased reliability (u16). | 1475 | * the connection should have increased reliability (u16). |
1431 | * | 1476 | * |
1477 | * @NL80211_ATTR_PEER_AID: Association ID for the peer TDLS station (u16). | ||
1478 | * This is similar to @NL80211_ATTR_STA_AID but with a difference of being | ||
1479 | * allowed to be used with the first @NL80211_CMD_SET_STATION command to | ||
1480 | * update a TDLS peer STA entry. | ||
1481 | * | ||
1482 | * @NL80211_ATTR_COALESCE_RULE: Coalesce rule information. | ||
1483 | * | ||
1484 | * @NL80211_ATTR_CH_SWITCH_COUNT: u32 attribute specifying the number of TBTT's | ||
1485 | * until the channel switch event. | ||
1486 | * @NL80211_ATTR_CH_SWITCH_BLOCK_TX: flag attribute specifying that transmission | ||
1487 | * must be blocked on the current channel (before the channel switch | ||
1488 | * operation). | ||
1489 | * @NL80211_ATTR_CSA_IES: Nested set of attributes containing the IE information | ||
1490 | * for the time while performing a channel switch. | ||
1491 | * @NL80211_ATTR_CSA_C_OFF_BEACON: Offset of the channel switch counter | ||
1492 | * field in the beacons tail (%NL80211_ATTR_BEACON_TAIL). | ||
1493 | * @NL80211_ATTR_CSA_C_OFF_PRESP: Offset of the channel switch counter | ||
1494 | * field in the probe response (%NL80211_ATTR_PROBE_RESP). | ||
1495 | * | ||
1496 | * @NL80211_ATTR_RXMGMT_FLAGS: flags for nl80211_send_mgmt(), u32. | ||
1497 | * As specified in the &enum nl80211_rxmgmt_flags. | ||
1498 | * | ||
1432 | * @NL80211_ATTR_MAX: highest attribute number currently defined | 1499 | * @NL80211_ATTR_MAX: highest attribute number currently defined |
1433 | * @__NL80211_ATTR_AFTER_LAST: internal use | 1500 | * @__NL80211_ATTR_AFTER_LAST: internal use |
1434 | */ | 1501 | */ |
@@ -1727,6 +1794,18 @@ enum nl80211_attrs { | |||
1727 | NL80211_ATTR_CRIT_PROT_ID, | 1794 | NL80211_ATTR_CRIT_PROT_ID, |
1728 | NL80211_ATTR_MAX_CRIT_PROT_DURATION, | 1795 | NL80211_ATTR_MAX_CRIT_PROT_DURATION, |
1729 | 1796 | ||
1797 | NL80211_ATTR_PEER_AID, | ||
1798 | |||
1799 | NL80211_ATTR_COALESCE_RULE, | ||
1800 | |||
1801 | NL80211_ATTR_CH_SWITCH_COUNT, | ||
1802 | NL80211_ATTR_CH_SWITCH_BLOCK_TX, | ||
1803 | NL80211_ATTR_CSA_IES, | ||
1804 | NL80211_ATTR_CSA_C_OFF_BEACON, | ||
1805 | NL80211_ATTR_CSA_C_OFF_PRESP, | ||
1806 | |||
1807 | NL80211_ATTR_RXMGMT_FLAGS, | ||
1808 | |||
1730 | /* add attributes here, update the policy in nl80211.c */ | 1809 | /* add attributes here, update the policy in nl80211.c */ |
1731 | 1810 | ||
1732 | __NL80211_ATTR_AFTER_LAST, | 1811 | __NL80211_ATTR_AFTER_LAST, |
@@ -1991,6 +2070,10 @@ enum nl80211_sta_bss_param { | |||
1991 | * @NL80211_STA_INFO_PEER_PM: peer mesh STA link-specific power mode | 2070 | * @NL80211_STA_INFO_PEER_PM: peer mesh STA link-specific power mode |
1992 | * @NL80211_STA_INFO_NONPEER_PM: neighbor mesh STA power save mode towards | 2071 | * @NL80211_STA_INFO_NONPEER_PM: neighbor mesh STA power save mode towards |
1993 | * non-peer STA | 2072 | * non-peer STA |
2073 | * @NL80211_STA_INFO_CHAIN_SIGNAL: per-chain signal strength of last PPDU | ||
2074 | * Contains a nested array of signal strength attributes (u8, dBm) | ||
2075 | * @NL80211_STA_INFO_CHAIN_SIGNAL_AVG: per-chain signal strength average | ||
2076 | * Same format as NL80211_STA_INFO_CHAIN_SIGNAL. | ||
1994 | * @__NL80211_STA_INFO_AFTER_LAST: internal | 2077 | * @__NL80211_STA_INFO_AFTER_LAST: internal |
1995 | * @NL80211_STA_INFO_MAX: highest possible station info attribute | 2078 | * @NL80211_STA_INFO_MAX: highest possible station info attribute |
1996 | */ | 2079 | */ |
@@ -2020,6 +2103,8 @@ enum nl80211_sta_info { | |||
2020 | NL80211_STA_INFO_NONPEER_PM, | 2103 | NL80211_STA_INFO_NONPEER_PM, |
2021 | NL80211_STA_INFO_RX_BYTES64, | 2104 | NL80211_STA_INFO_RX_BYTES64, |
2022 | NL80211_STA_INFO_TX_BYTES64, | 2105 | NL80211_STA_INFO_TX_BYTES64, |
2106 | NL80211_STA_INFO_CHAIN_SIGNAL, | ||
2107 | NL80211_STA_INFO_CHAIN_SIGNAL_AVG, | ||
2023 | 2108 | ||
2024 | /* keep last */ | 2109 | /* keep last */ |
2025 | __NL80211_STA_INFO_AFTER_LAST, | 2110 | __NL80211_STA_INFO_AFTER_LAST, |
@@ -2413,6 +2498,8 @@ enum nl80211_survey_info { | |||
2413 | * @NL80211_MNTR_FLAG_OTHER_BSS: disable BSSID filtering | 2498 | * @NL80211_MNTR_FLAG_OTHER_BSS: disable BSSID filtering |
2414 | * @NL80211_MNTR_FLAG_COOK_FRAMES: report frames after processing. | 2499 | * @NL80211_MNTR_FLAG_COOK_FRAMES: report frames after processing. |
2415 | * overrides all other flags. | 2500 | * overrides all other flags. |
2501 | * @NL80211_MNTR_FLAG_ACTIVE: use the configured MAC address | ||
2502 | * and ACK incoming unicast packets. | ||
2416 | * | 2503 | * |
2417 | * @__NL80211_MNTR_FLAG_AFTER_LAST: internal use | 2504 | * @__NL80211_MNTR_FLAG_AFTER_LAST: internal use |
2418 | * @NL80211_MNTR_FLAG_MAX: highest possible monitor flag | 2505 | * @NL80211_MNTR_FLAG_MAX: highest possible monitor flag |
@@ -2424,6 +2511,7 @@ enum nl80211_mntr_flags { | |||
2424 | NL80211_MNTR_FLAG_CONTROL, | 2511 | NL80211_MNTR_FLAG_CONTROL, |
2425 | NL80211_MNTR_FLAG_OTHER_BSS, | 2512 | NL80211_MNTR_FLAG_OTHER_BSS, |
2426 | NL80211_MNTR_FLAG_COOK_FRAMES, | 2513 | NL80211_MNTR_FLAG_COOK_FRAMES, |
2514 | NL80211_MNTR_FLAG_ACTIVE, | ||
2427 | 2515 | ||
2428 | /* keep last */ | 2516 | /* keep last */ |
2429 | __NL80211_MNTR_FLAG_AFTER_LAST, | 2517 | __NL80211_MNTR_FLAG_AFTER_LAST, |
@@ -2559,6 +2647,10 @@ enum nl80211_mesh_power_mode { | |||
2559 | * | 2647 | * |
2560 | * @NL80211_MESHCONF_AWAKE_WINDOW: awake window duration (in TUs) | 2648 | * @NL80211_MESHCONF_AWAKE_WINDOW: awake window duration (in TUs) |
2561 | * | 2649 | * |
2650 | * @NL80211_MESHCONF_PLINK_TIMEOUT: If no tx activity is seen from a STA we've | ||
2651 | * established peering with for longer than this time (in seconds), then | ||
2652 | * remove it from the STA's list of peers. Default is 30 minutes. | ||
2653 | * | ||
2562 | * @__NL80211_MESHCONF_ATTR_AFTER_LAST: internal use | 2654 | * @__NL80211_MESHCONF_ATTR_AFTER_LAST: internal use |
2563 | */ | 2655 | */ |
2564 | enum nl80211_meshconf_params { | 2656 | enum nl80211_meshconf_params { |
@@ -2590,6 +2682,7 @@ enum nl80211_meshconf_params { | |||
2590 | NL80211_MESHCONF_HWMP_CONFIRMATION_INTERVAL, | 2682 | NL80211_MESHCONF_HWMP_CONFIRMATION_INTERVAL, |
2591 | NL80211_MESHCONF_POWER_MODE, | 2683 | NL80211_MESHCONF_POWER_MODE, |
2592 | NL80211_MESHCONF_AWAKE_WINDOW, | 2684 | NL80211_MESHCONF_AWAKE_WINDOW, |
2685 | NL80211_MESHCONF_PLINK_TIMEOUT, | ||
2593 | 2686 | ||
2594 | /* keep last */ | 2687 | /* keep last */ |
2595 | __NL80211_MESHCONF_ATTR_AFTER_LAST, | 2688 | __NL80211_MESHCONF_ATTR_AFTER_LAST, |
@@ -2637,6 +2730,10 @@ enum nl80211_meshconf_params { | |||
2637 | * @NL80211_MESH_SETUP_USERSPACE_MPM: Enable this option if userspace will | 2730 | * @NL80211_MESH_SETUP_USERSPACE_MPM: Enable this option if userspace will |
2638 | * implement an MPM which handles peer allocation and state. | 2731 | * implement an MPM which handles peer allocation and state. |
2639 | * | 2732 | * |
2733 | * @NL80211_MESH_SETUP_AUTH_PROTOCOL: Inform the kernel of the authentication | ||
2734 | * method (u8, as defined in IEEE 8.4.2.100.6, e.g. 0x1 for SAE). | ||
2735 | * Default is no authentication method required. | ||
2736 | * | ||
2640 | * @NL80211_MESH_SETUP_ATTR_MAX: highest possible mesh setup attribute number | 2737 | * @NL80211_MESH_SETUP_ATTR_MAX: highest possible mesh setup attribute number |
2641 | * | 2738 | * |
2642 | * @__NL80211_MESH_SETUP_ATTR_AFTER_LAST: Internal use | 2739 | * @__NL80211_MESH_SETUP_ATTR_AFTER_LAST: Internal use |
@@ -2650,6 +2747,7 @@ enum nl80211_mesh_setup_params { | |||
2650 | NL80211_MESH_SETUP_USERSPACE_AMPE, | 2747 | NL80211_MESH_SETUP_USERSPACE_AMPE, |
2651 | NL80211_MESH_SETUP_ENABLE_VENDOR_SYNC, | 2748 | NL80211_MESH_SETUP_ENABLE_VENDOR_SYNC, |
2652 | NL80211_MESH_SETUP_USERSPACE_MPM, | 2749 | NL80211_MESH_SETUP_USERSPACE_MPM, |
2750 | NL80211_MESH_SETUP_AUTH_PROTOCOL, | ||
2653 | 2751 | ||
2654 | /* keep last */ | 2752 | /* keep last */ |
2655 | __NL80211_MESH_SETUP_ATTR_AFTER_LAST, | 2753 | __NL80211_MESH_SETUP_ATTR_AFTER_LAST, |
@@ -2730,6 +2828,8 @@ enum nl80211_channel_type { | |||
2730 | * and %NL80211_ATTR_CENTER_FREQ2 attributes must be provided as well | 2828 | * and %NL80211_ATTR_CENTER_FREQ2 attributes must be provided as well |
2731 | * @NL80211_CHAN_WIDTH_160: 160 MHz channel, the %NL80211_ATTR_CENTER_FREQ1 | 2829 | * @NL80211_CHAN_WIDTH_160: 160 MHz channel, the %NL80211_ATTR_CENTER_FREQ1 |
2732 | * attribute must be provided as well | 2830 | * attribute must be provided as well |
2831 | * @NL80211_CHAN_WIDTH_5: 5 MHz OFDM channel | ||
2832 | * @NL80211_CHAN_WIDTH_10: 10 MHz OFDM channel | ||
2733 | */ | 2833 | */ |
2734 | enum nl80211_chan_width { | 2834 | enum nl80211_chan_width { |
2735 | NL80211_CHAN_WIDTH_20_NOHT, | 2835 | NL80211_CHAN_WIDTH_20_NOHT, |
@@ -2738,6 +2838,23 @@ enum nl80211_chan_width { | |||
2738 | NL80211_CHAN_WIDTH_80, | 2838 | NL80211_CHAN_WIDTH_80, |
2739 | NL80211_CHAN_WIDTH_80P80, | 2839 | NL80211_CHAN_WIDTH_80P80, |
2740 | NL80211_CHAN_WIDTH_160, | 2840 | NL80211_CHAN_WIDTH_160, |
2841 | NL80211_CHAN_WIDTH_5, | ||
2842 | NL80211_CHAN_WIDTH_10, | ||
2843 | }; | ||
2844 | |||
2845 | /** | ||
2846 | * enum nl80211_bss_scan_width - control channel width for a BSS | ||
2847 | * | ||
2848 | * These values are used with the %NL80211_BSS_CHAN_WIDTH attribute. | ||
2849 | * | ||
2850 | * @NL80211_BSS_CHAN_WIDTH_20: control channel is 20 MHz wide or compatible | ||
2851 | * @NL80211_BSS_CHAN_WIDTH_10: control channel is 10 MHz wide | ||
2852 | * @NL80211_BSS_CHAN_WIDTH_5: control channel is 5 MHz wide | ||
2853 | */ | ||
2854 | enum nl80211_bss_scan_width { | ||
2855 | NL80211_BSS_CHAN_WIDTH_20, | ||
2856 | NL80211_BSS_CHAN_WIDTH_10, | ||
2857 | NL80211_BSS_CHAN_WIDTH_5, | ||
2741 | }; | 2858 | }; |
2742 | 2859 | ||
2743 | /** | 2860 | /** |
@@ -2764,6 +2881,8 @@ enum nl80211_chan_width { | |||
2764 | * @NL80211_BSS_BEACON_IES: binary attribute containing the raw information | 2881 | * @NL80211_BSS_BEACON_IES: binary attribute containing the raw information |
2765 | * elements from a Beacon frame (bin); not present if no Beacon frame has | 2882 | * elements from a Beacon frame (bin); not present if no Beacon frame has |
2766 | * yet been received | 2883 | * yet been received |
2884 | * @NL80211_BSS_CHAN_WIDTH: channel width of the control channel | ||
2885 | * (u32, enum nl80211_bss_scan_width) | ||
2767 | * @__NL80211_BSS_AFTER_LAST: internal | 2886 | * @__NL80211_BSS_AFTER_LAST: internal |
2768 | * @NL80211_BSS_MAX: highest BSS attribute | 2887 | * @NL80211_BSS_MAX: highest BSS attribute |
2769 | */ | 2888 | */ |
@@ -2780,6 +2899,7 @@ enum nl80211_bss { | |||
2780 | NL80211_BSS_STATUS, | 2899 | NL80211_BSS_STATUS, |
2781 | NL80211_BSS_SEEN_MS_AGO, | 2900 | NL80211_BSS_SEEN_MS_AGO, |
2782 | NL80211_BSS_BEACON_IES, | 2901 | NL80211_BSS_BEACON_IES, |
2902 | NL80211_BSS_CHAN_WIDTH, | ||
2783 | 2903 | ||
2784 | /* keep last */ | 2904 | /* keep last */ |
2785 | __NL80211_BSS_AFTER_LAST, | 2905 | __NL80211_BSS_AFTER_LAST, |
@@ -3028,11 +3148,11 @@ enum nl80211_tx_power_setting { | |||
3028 | }; | 3148 | }; |
3029 | 3149 | ||
3030 | /** | 3150 | /** |
3031 | * enum nl80211_wowlan_packet_pattern_attr - WoWLAN packet pattern attribute | 3151 | * enum nl80211_packet_pattern_attr - packet pattern attribute |
3032 | * @__NL80211_WOWLAN_PKTPAT_INVALID: invalid number for nested attribute | 3152 | * @__NL80211_PKTPAT_INVALID: invalid number for nested attribute |
3033 | * @NL80211_WOWLAN_PKTPAT_PATTERN: the pattern, values where the mask has | 3153 | * @NL80211_PKTPAT_PATTERN: the pattern, values where the mask has |
3034 | * a zero bit are ignored | 3154 | * a zero bit are ignored |
3035 | * @NL80211_WOWLAN_PKTPAT_MASK: pattern mask, must be long enough to have | 3155 | * @NL80211_PKTPAT_MASK: pattern mask, must be long enough to have |
3036 | * a bit for each byte in the pattern. The lowest-order bit corresponds | 3156 | * a bit for each byte in the pattern. The lowest-order bit corresponds |
3037 | * to the first byte of the pattern, but the bytes of the pattern are | 3157 | * to the first byte of the pattern, but the bytes of the pattern are |
3038 | * in a little-endian-like format, i.e. the 9th byte of the pattern | 3158 | * in a little-endian-like format, i.e. the 9th byte of the pattern |
@@ -3043,39 +3163,50 @@ enum nl80211_tx_power_setting { | |||
3043 | * Note that the pattern matching is done as though frames were not | 3163 | * Note that the pattern matching is done as though frames were not |
3044 | * 802.11 frames but 802.3 frames, i.e. the frame is fully unpacked | 3164 | * 802.11 frames but 802.3 frames, i.e. the frame is fully unpacked |
3045 | * first (including SNAP header unpacking) and then matched. | 3165 | * first (including SNAP header unpacking) and then matched. |
3046 | * @NL80211_WOWLAN_PKTPAT_OFFSET: packet offset, pattern is matched after | 3166 | * @NL80211_PKTPAT_OFFSET: packet offset, pattern is matched after |
3047 | * these fixed number of bytes of received packet | 3167 | * these fixed number of bytes of received packet |
3048 | * @NUM_NL80211_WOWLAN_PKTPAT: number of attributes | 3168 | * @NUM_NL80211_PKTPAT: number of attributes |
3049 | * @MAX_NL80211_WOWLAN_PKTPAT: max attribute number | 3169 | * @MAX_NL80211_PKTPAT: max attribute number |
3050 | */ | 3170 | */ |
3051 | enum nl80211_wowlan_packet_pattern_attr { | 3171 | enum nl80211_packet_pattern_attr { |
3052 | __NL80211_WOWLAN_PKTPAT_INVALID, | 3172 | __NL80211_PKTPAT_INVALID, |
3053 | NL80211_WOWLAN_PKTPAT_MASK, | 3173 | NL80211_PKTPAT_MASK, |
3054 | NL80211_WOWLAN_PKTPAT_PATTERN, | 3174 | NL80211_PKTPAT_PATTERN, |
3055 | NL80211_WOWLAN_PKTPAT_OFFSET, | 3175 | NL80211_PKTPAT_OFFSET, |
3056 | 3176 | ||
3057 | NUM_NL80211_WOWLAN_PKTPAT, | 3177 | NUM_NL80211_PKTPAT, |
3058 | MAX_NL80211_WOWLAN_PKTPAT = NUM_NL80211_WOWLAN_PKTPAT - 1, | 3178 | MAX_NL80211_PKTPAT = NUM_NL80211_PKTPAT - 1, |
3059 | }; | 3179 | }; |
3060 | 3180 | ||
3061 | /** | 3181 | /** |
3062 | * struct nl80211_wowlan_pattern_support - pattern support information | 3182 | * struct nl80211_pattern_support - packet pattern support information |
3063 | * @max_patterns: maximum number of patterns supported | 3183 | * @max_patterns: maximum number of patterns supported |
3064 | * @min_pattern_len: minimum length of each pattern | 3184 | * @min_pattern_len: minimum length of each pattern |
3065 | * @max_pattern_len: maximum length of each pattern | 3185 | * @max_pattern_len: maximum length of each pattern |
3066 | * @max_pkt_offset: maximum Rx packet offset | 3186 | * @max_pkt_offset: maximum Rx packet offset |
3067 | * | 3187 | * |
3068 | * This struct is carried in %NL80211_WOWLAN_TRIG_PKT_PATTERN when | 3188 | * This struct is carried in %NL80211_WOWLAN_TRIG_PKT_PATTERN when |
3069 | * that is part of %NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED in the | 3189 | * that is part of %NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED or in |
3070 | * capability information given by the kernel to userspace. | 3190 | * %NL80211_ATTR_COALESCE_RULE_PKT_PATTERN when that is part of |
3191 | * %NL80211_ATTR_COALESCE_RULE in the capability information given | ||
3192 | * by the kernel to userspace. | ||
3071 | */ | 3193 | */ |
3072 | struct nl80211_wowlan_pattern_support { | 3194 | struct nl80211_pattern_support { |
3073 | __u32 max_patterns; | 3195 | __u32 max_patterns; |
3074 | __u32 min_pattern_len; | 3196 | __u32 min_pattern_len; |
3075 | __u32 max_pattern_len; | 3197 | __u32 max_pattern_len; |
3076 | __u32 max_pkt_offset; | 3198 | __u32 max_pkt_offset; |
3077 | } __attribute__((packed)); | 3199 | } __attribute__((packed)); |
3078 | 3200 | ||
3201 | /* only for backward compatibility */ | ||
3202 | #define __NL80211_WOWLAN_PKTPAT_INVALID __NL80211_PKTPAT_INVALID | ||
3203 | #define NL80211_WOWLAN_PKTPAT_MASK NL80211_PKTPAT_MASK | ||
3204 | #define NL80211_WOWLAN_PKTPAT_PATTERN NL80211_PKTPAT_PATTERN | ||
3205 | #define NL80211_WOWLAN_PKTPAT_OFFSET NL80211_PKTPAT_OFFSET | ||
3206 | #define NUM_NL80211_WOWLAN_PKTPAT NUM_NL80211_PKTPAT | ||
3207 | #define MAX_NL80211_WOWLAN_PKTPAT MAX_NL80211_PKTPAT | ||
3208 | #define nl80211_wowlan_pattern_support nl80211_pattern_support | ||
3209 | |||
3079 | /** | 3210 | /** |
3080 | * enum nl80211_wowlan_triggers - WoWLAN trigger definitions | 3211 | * enum nl80211_wowlan_triggers - WoWLAN trigger definitions |
3081 | * @__NL80211_WOWLAN_TRIG_INVALID: invalid number for nested attributes | 3212 | * @__NL80211_WOWLAN_TRIG_INVALID: invalid number for nested attributes |
@@ -3095,7 +3226,7 @@ struct nl80211_wowlan_pattern_support { | |||
3095 | * pattern matching is done after the packet is converted to the MSDU. | 3226 | * pattern matching is done after the packet is converted to the MSDU. |
3096 | * | 3227 | * |
3097 | * In %NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED, it is a binary attribute | 3228 | * In %NL80211_ATTR_WOWLAN_TRIGGERS_SUPPORTED, it is a binary attribute |
3098 | * carrying a &struct nl80211_wowlan_pattern_support. | 3229 | * carrying a &struct nl80211_pattern_support. |
3099 | * | 3230 | * |
3100 | * When reporting wakeup. it is a u32 attribute containing the 0-based | 3231 | * When reporting wakeup. it is a u32 attribute containing the 0-based |
3101 | * index of the pattern that caused the wakeup, in the patterns passed | 3232 | * index of the pattern that caused the wakeup, in the patterns passed |
@@ -3252,7 +3383,7 @@ struct nl80211_wowlan_tcp_data_token_feature { | |||
3252 | * @NL80211_WOWLAN_TCP_WAKE_PAYLOAD: wake packet payload, for advertising a | 3383 | * @NL80211_WOWLAN_TCP_WAKE_PAYLOAD: wake packet payload, for advertising a |
3253 | * u32 attribute holding the maximum length | 3384 | * u32 attribute holding the maximum length |
3254 | * @NL80211_WOWLAN_TCP_WAKE_MASK: Wake packet payload mask, not used for | 3385 | * @NL80211_WOWLAN_TCP_WAKE_MASK: Wake packet payload mask, not used for |
3255 | * feature advertising. The mask works like @NL80211_WOWLAN_PKTPAT_MASK | 3386 | * feature advertising. The mask works like @NL80211_PKTPAT_MASK |
3256 | * but on the TCP payload only. | 3387 | * but on the TCP payload only. |
3257 | * @NUM_NL80211_WOWLAN_TCP: number of TCP attributes | 3388 | * @NUM_NL80211_WOWLAN_TCP: number of TCP attributes |
3258 | * @MAX_NL80211_WOWLAN_TCP: highest attribute number | 3389 | * @MAX_NL80211_WOWLAN_TCP: highest attribute number |
@@ -3277,6 +3408,55 @@ enum nl80211_wowlan_tcp_attrs { | |||
3277 | }; | 3408 | }; |
3278 | 3409 | ||
3279 | /** | 3410 | /** |
3411 | * struct nl80211_coalesce_rule_support - coalesce rule support information | ||
3412 | * @max_rules: maximum number of rules supported | ||
3413 | * @pat: packet pattern support information | ||
3414 | * @max_delay: maximum supported coalescing delay in msecs | ||
3415 | * | ||
3416 | * This struct is carried in %NL80211_ATTR_COALESCE_RULE in the | ||
3417 | * capability information given by the kernel to userspace. | ||
3418 | */ | ||
3419 | struct nl80211_coalesce_rule_support { | ||
3420 | __u32 max_rules; | ||
3421 | struct nl80211_pattern_support pat; | ||
3422 | __u32 max_delay; | ||
3423 | } __attribute__((packed)); | ||
3424 | |||
3425 | /** | ||
3426 | * enum nl80211_attr_coalesce_rule - coalesce rule attribute | ||
3427 | * @__NL80211_COALESCE_RULE_INVALID: invalid number for nested attribute | ||
3428 | * @NL80211_ATTR_COALESCE_RULE_DELAY: delay in msecs used for packet coalescing | ||
3429 | * @NL80211_ATTR_COALESCE_RULE_CONDITION: condition for packet coalescence, | ||
3430 | * see &enum nl80211_coalesce_condition. | ||
3431 | * @NL80211_ATTR_COALESCE_RULE_PKT_PATTERN: packet offset, pattern is matched | ||
3432 | * after these fixed number of bytes of received packet | ||
3433 | * @NUM_NL80211_ATTR_COALESCE_RULE: number of attributes | ||
3434 | * @NL80211_ATTR_COALESCE_RULE_MAX: max attribute number | ||
3435 | */ | ||
3436 | enum nl80211_attr_coalesce_rule { | ||
3437 | __NL80211_COALESCE_RULE_INVALID, | ||
3438 | NL80211_ATTR_COALESCE_RULE_DELAY, | ||
3439 | NL80211_ATTR_COALESCE_RULE_CONDITION, | ||
3440 | NL80211_ATTR_COALESCE_RULE_PKT_PATTERN, | ||
3441 | |||
3442 | /* keep last */ | ||
3443 | NUM_NL80211_ATTR_COALESCE_RULE, | ||
3444 | NL80211_ATTR_COALESCE_RULE_MAX = NUM_NL80211_ATTR_COALESCE_RULE - 1 | ||
3445 | }; | ||
3446 | |||
3447 | /** | ||
3448 | * enum nl80211_coalesce_condition - coalesce rule conditions | ||
3449 | * @NL80211_COALESCE_CONDITION_MATCH: coalaesce Rx packets when patterns | ||
3450 | * in a rule are matched. | ||
3451 | * @NL80211_COALESCE_CONDITION_NO_MATCH: coalesce Rx packets when patterns | ||
3452 | * in a rule are not matched. | ||
3453 | */ | ||
3454 | enum nl80211_coalesce_condition { | ||
3455 | NL80211_COALESCE_CONDITION_MATCH, | ||
3456 | NL80211_COALESCE_CONDITION_NO_MATCH | ||
3457 | }; | ||
3458 | |||
3459 | /** | ||
3280 | * enum nl80211_iface_limit_attrs - limit attributes | 3460 | * enum nl80211_iface_limit_attrs - limit attributes |
3281 | * @NL80211_IFACE_LIMIT_UNSPEC: (reserved) | 3461 | * @NL80211_IFACE_LIMIT_UNSPEC: (reserved) |
3282 | * @NL80211_IFACE_LIMIT_MAX: maximum number of interfaces that | 3462 | * @NL80211_IFACE_LIMIT_MAX: maximum number of interfaces that |
@@ -3556,6 +3736,10 @@ enum nl80211_ap_sme_features { | |||
3556 | * Peering Management entity which may be implemented by registering for | 3736 | * Peering Management entity which may be implemented by registering for |
3557 | * beacons or NL80211_CMD_NEW_PEER_CANDIDATE events. The mesh beacon is | 3737 | * beacons or NL80211_CMD_NEW_PEER_CANDIDATE events. The mesh beacon is |
3558 | * still generated by the driver. | 3738 | * still generated by the driver. |
3739 | * @NL80211_FEATURE_ACTIVE_MONITOR: This driver supports an active monitor | ||
3740 | * interface. An active monitor interface behaves like a normal monitor | ||
3741 | * interface, but gets added to the driver. It ensures that incoming | ||
3742 | * unicast packets directed at the configured interface address get ACKed. | ||
3559 | */ | 3743 | */ |
3560 | enum nl80211_feature_flags { | 3744 | enum nl80211_feature_flags { |
3561 | NL80211_FEATURE_SK_TX_STATUS = 1 << 0, | 3745 | NL80211_FEATURE_SK_TX_STATUS = 1 << 0, |
@@ -3575,6 +3759,7 @@ enum nl80211_feature_flags { | |||
3575 | NL80211_FEATURE_ADVERTISE_CHAN_LIMITS = 1 << 14, | 3759 | NL80211_FEATURE_ADVERTISE_CHAN_LIMITS = 1 << 14, |
3576 | NL80211_FEATURE_FULL_AP_CLIENT_STATE = 1 << 15, | 3760 | NL80211_FEATURE_FULL_AP_CLIENT_STATE = 1 << 15, |
3577 | NL80211_FEATURE_USERSPACE_MPM = 1 << 16, | 3761 | NL80211_FEATURE_USERSPACE_MPM = 1 << 16, |
3762 | NL80211_FEATURE_ACTIVE_MONITOR = 1 << 17, | ||
3578 | }; | 3763 | }; |
3579 | 3764 | ||
3580 | /** | 3765 | /** |
@@ -3721,4 +3906,15 @@ enum nl80211_crit_proto_id { | |||
3721 | /* maximum duration for critical protocol measures */ | 3906 | /* maximum duration for critical protocol measures */ |
3722 | #define NL80211_CRIT_PROTO_MAX_DURATION 5000 /* msec */ | 3907 | #define NL80211_CRIT_PROTO_MAX_DURATION 5000 /* msec */ |
3723 | 3908 | ||
3909 | /** | ||
3910 | * enum nl80211_rxmgmt_flags - flags for received management frame. | ||
3911 | * | ||
3912 | * Used by cfg80211_rx_mgmt() | ||
3913 | * | ||
3914 | * @NL80211_RXMGMT_FLAG_ANSWERED: frame was answered by device/driver. | ||
3915 | */ | ||
3916 | enum nl80211_rxmgmt_flags { | ||
3917 | NL80211_RXMGMT_FLAG_ANSWERED = 1 << 0, | ||
3918 | }; | ||
3919 | |||
3724 | #endif /* __LINUX_NL80211_H */ | 3920 | #endif /* __LINUX_NL80211_H */ |
diff --git a/include/uapi/linux/openvswitch.h b/include/uapi/linux/openvswitch.h index 405918dd7b3f..a74d375b439b 100644 --- a/include/uapi/linux/openvswitch.h +++ b/include/uapi/linux/openvswitch.h | |||
@@ -1,6 +1,6 @@ | |||
1 | 1 | ||
2 | /* | 2 | /* |
3 | * Copyright (c) 2007-2011 Nicira Networks. | 3 | * Copyright (c) 2007-2013 Nicira, Inc. |
4 | * | 4 | * |
5 | * This program is free software; you can redistribute it and/or | 5 | * This program is free software; you can redistribute it and/or |
6 | * modify it under the terms of version 2 of the GNU General Public | 6 | * modify it under the terms of version 2 of the GNU General Public |
@@ -164,6 +164,8 @@ enum ovs_vport_type { | |||
164 | OVS_VPORT_TYPE_UNSPEC, | 164 | OVS_VPORT_TYPE_UNSPEC, |
165 | OVS_VPORT_TYPE_NETDEV, /* network device */ | 165 | OVS_VPORT_TYPE_NETDEV, /* network device */ |
166 | OVS_VPORT_TYPE_INTERNAL, /* network device implemented by datapath */ | 166 | OVS_VPORT_TYPE_INTERNAL, /* network device implemented by datapath */ |
167 | OVS_VPORT_TYPE_GRE, /* GRE tunnel. */ | ||
168 | OVS_VPORT_TYPE_VXLAN, /* VXLAN tunnel. */ | ||
167 | __OVS_VPORT_TYPE_MAX | 169 | __OVS_VPORT_TYPE_MAX |
168 | }; | 170 | }; |
169 | 171 | ||
@@ -192,7 +194,6 @@ enum ovs_vport_type { | |||
192 | * optional; if not specified a free port number is automatically selected. | 194 | * optional; if not specified a free port number is automatically selected. |
193 | * Whether %OVS_VPORT_ATTR_OPTIONS is required or optional depends on the type | 195 | * Whether %OVS_VPORT_ATTR_OPTIONS is required or optional depends on the type |
194 | * of vport. | 196 | * of vport. |
195 | * and other attributes are ignored. | ||
196 | * | 197 | * |
197 | * For other requests, if %OVS_VPORT_ATTR_NAME is specified then it is used to | 198 | * For other requests, if %OVS_VPORT_ATTR_NAME is specified then it is used to |
198 | * look up the vport to operate on; otherwise dp_idx from the &struct | 199 | * look up the vport to operate on; otherwise dp_idx from the &struct |
@@ -211,6 +212,16 @@ enum ovs_vport_attr { | |||
211 | 212 | ||
212 | #define OVS_VPORT_ATTR_MAX (__OVS_VPORT_ATTR_MAX - 1) | 213 | #define OVS_VPORT_ATTR_MAX (__OVS_VPORT_ATTR_MAX - 1) |
213 | 214 | ||
215 | /* OVS_VPORT_ATTR_OPTIONS attributes for tunnels. | ||
216 | */ | ||
217 | enum { | ||
218 | OVS_TUNNEL_ATTR_UNSPEC, | ||
219 | OVS_TUNNEL_ATTR_DST_PORT, /* 16-bit UDP port, used by L4 tunnels. */ | ||
220 | __OVS_TUNNEL_ATTR_MAX | ||
221 | }; | ||
222 | |||
223 | #define OVS_TUNNEL_ATTR_MAX (__OVS_TUNNEL_ATTR_MAX - 1) | ||
224 | |||
214 | /* Flows. */ | 225 | /* Flows. */ |
215 | 226 | ||
216 | #define OVS_FLOW_FAMILY "ovs_flow" | 227 | #define OVS_FLOW_FAMILY "ovs_flow" |
@@ -247,11 +258,30 @@ enum ovs_key_attr { | |||
247 | OVS_KEY_ATTR_ARP, /* struct ovs_key_arp */ | 258 | OVS_KEY_ATTR_ARP, /* struct ovs_key_arp */ |
248 | OVS_KEY_ATTR_ND, /* struct ovs_key_nd */ | 259 | OVS_KEY_ATTR_ND, /* struct ovs_key_nd */ |
249 | OVS_KEY_ATTR_SKB_MARK, /* u32 skb mark */ | 260 | OVS_KEY_ATTR_SKB_MARK, /* u32 skb mark */ |
261 | OVS_KEY_ATTR_TUNNEL, /* Nested set of ovs_tunnel attributes */ | ||
262 | OVS_KEY_ATTR_SCTP, /* struct ovs_key_sctp */ | ||
263 | |||
264 | #ifdef __KERNEL__ | ||
265 | OVS_KEY_ATTR_IPV4_TUNNEL, /* struct ovs_key_ipv4_tunnel */ | ||
266 | #endif | ||
250 | __OVS_KEY_ATTR_MAX | 267 | __OVS_KEY_ATTR_MAX |
251 | }; | 268 | }; |
252 | 269 | ||
253 | #define OVS_KEY_ATTR_MAX (__OVS_KEY_ATTR_MAX - 1) | 270 | #define OVS_KEY_ATTR_MAX (__OVS_KEY_ATTR_MAX - 1) |
254 | 271 | ||
272 | enum ovs_tunnel_key_attr { | ||
273 | OVS_TUNNEL_KEY_ATTR_ID, /* be64 Tunnel ID */ | ||
274 | OVS_TUNNEL_KEY_ATTR_IPV4_SRC, /* be32 src IP address. */ | ||
275 | OVS_TUNNEL_KEY_ATTR_IPV4_DST, /* be32 dst IP address. */ | ||
276 | OVS_TUNNEL_KEY_ATTR_TOS, /* u8 Tunnel IP ToS. */ | ||
277 | OVS_TUNNEL_KEY_ATTR_TTL, /* u8 Tunnel IP TTL. */ | ||
278 | OVS_TUNNEL_KEY_ATTR_DONT_FRAGMENT, /* No argument, set DF. */ | ||
279 | OVS_TUNNEL_KEY_ATTR_CSUM, /* No argument. CSUM packet. */ | ||
280 | __OVS_TUNNEL_KEY_ATTR_MAX | ||
281 | }; | ||
282 | |||
283 | #define OVS_TUNNEL_KEY_ATTR_MAX (__OVS_TUNNEL_KEY_ATTR_MAX - 1) | ||
284 | |||
255 | /** | 285 | /** |
256 | * enum ovs_frag_type - IPv4 and IPv6 fragment type | 286 | * enum ovs_frag_type - IPv4 and IPv6 fragment type |
257 | * @OVS_FRAG_TYPE_NONE: Packet is not a fragment. | 287 | * @OVS_FRAG_TYPE_NONE: Packet is not a fragment. |
@@ -304,6 +334,11 @@ struct ovs_key_udp { | |||
304 | __be16 udp_dst; | 334 | __be16 udp_dst; |
305 | }; | 335 | }; |
306 | 336 | ||
337 | struct ovs_key_sctp { | ||
338 | __be16 sctp_src; | ||
339 | __be16 sctp_dst; | ||
340 | }; | ||
341 | |||
307 | struct ovs_key_icmp { | 342 | struct ovs_key_icmp { |
308 | __u8 icmp_type; | 343 | __u8 icmp_type; |
309 | __u8 icmp_code; | 344 | __u8 icmp_code; |
@@ -350,6 +385,12 @@ struct ovs_key_nd { | |||
350 | * @OVS_FLOW_ATTR_CLEAR: If present in a %OVS_FLOW_CMD_SET request, clears the | 385 | * @OVS_FLOW_ATTR_CLEAR: If present in a %OVS_FLOW_CMD_SET request, clears the |
351 | * last-used time, accumulated TCP flags, and statistics for this flow. | 386 | * last-used time, accumulated TCP flags, and statistics for this flow. |
352 | * Otherwise ignored in requests. Never present in notifications. | 387 | * Otherwise ignored in requests. Never present in notifications. |
388 | * @OVS_FLOW_ATTR_MASK: Nested %OVS_KEY_ATTR_* attributes specifying the | ||
389 | * mask bits for wildcarded flow match. Mask bit value '1' specifies exact | ||
390 | * match with corresponding flow key bit, while mask bit value '0' specifies | ||
391 | * a wildcarded match. Omitting attribute is treated as wildcarding all | ||
392 | * corresponding fields. Optional for all requests. If not present, | ||
393 | * all flow key bits are exact match bits. | ||
353 | * | 394 | * |
354 | * These attributes follow the &struct ovs_header within the Generic Netlink | 395 | * These attributes follow the &struct ovs_header within the Generic Netlink |
355 | * payload for %OVS_FLOW_* commands. | 396 | * payload for %OVS_FLOW_* commands. |
@@ -362,6 +403,7 @@ enum ovs_flow_attr { | |||
362 | OVS_FLOW_ATTR_TCP_FLAGS, /* 8-bit OR'd TCP flags. */ | 403 | OVS_FLOW_ATTR_TCP_FLAGS, /* 8-bit OR'd TCP flags. */ |
363 | OVS_FLOW_ATTR_USED, /* u64 msecs last used in monotonic time. */ | 404 | OVS_FLOW_ATTR_USED, /* u64 msecs last used in monotonic time. */ |
364 | OVS_FLOW_ATTR_CLEAR, /* Flag to clear stats, tcp_flags, used. */ | 405 | OVS_FLOW_ATTR_CLEAR, /* Flag to clear stats, tcp_flags, used. */ |
406 | OVS_FLOW_ATTR_MASK, /* Sequence of OVS_KEY_ATTR_* attributes. */ | ||
365 | __OVS_FLOW_ATTR_MAX | 407 | __OVS_FLOW_ATTR_MAX |
366 | }; | 408 | }; |
367 | 409 | ||
diff --git a/include/uapi/linux/pci_regs.h b/include/uapi/linux/pci_regs.h index 864e324da80d..baa7852468ef 100644 --- a/include/uapi/linux/pci_regs.h +++ b/include/uapi/linux/pci_regs.h | |||
@@ -421,24 +421,24 @@ | |||
421 | #define PCI_EXP_TYPE_ROOT_PORT 0x4 /* Root Port */ | 421 | #define PCI_EXP_TYPE_ROOT_PORT 0x4 /* Root Port */ |
422 | #define PCI_EXP_TYPE_UPSTREAM 0x5 /* Upstream Port */ | 422 | #define PCI_EXP_TYPE_UPSTREAM 0x5 /* Upstream Port */ |
423 | #define PCI_EXP_TYPE_DOWNSTREAM 0x6 /* Downstream Port */ | 423 | #define PCI_EXP_TYPE_DOWNSTREAM 0x6 /* Downstream Port */ |
424 | #define PCI_EXP_TYPE_PCI_BRIDGE 0x7 /* PCI/PCI-X Bridge */ | 424 | #define PCI_EXP_TYPE_PCI_BRIDGE 0x7 /* PCIe to PCI/PCI-X Bridge */ |
425 | #define PCI_EXP_TYPE_PCIE_BRIDGE 0x8 /* PCI/PCI-X to PCIE Bridge */ | 425 | #define PCI_EXP_TYPE_PCIE_BRIDGE 0x8 /* PCI/PCI-X to PCIe Bridge */ |
426 | #define PCI_EXP_TYPE_RC_END 0x9 /* Root Complex Integrated Endpoint */ | 426 | #define PCI_EXP_TYPE_RC_END 0x9 /* Root Complex Integrated Endpoint */ |
427 | #define PCI_EXP_TYPE_RC_EC 0xa /* Root Complex Event Collector */ | 427 | #define PCI_EXP_TYPE_RC_EC 0xa /* Root Complex Event Collector */ |
428 | #define PCI_EXP_FLAGS_SLOT 0x0100 /* Slot implemented */ | 428 | #define PCI_EXP_FLAGS_SLOT 0x0100 /* Slot implemented */ |
429 | #define PCI_EXP_FLAGS_IRQ 0x3e00 /* Interrupt message number */ | 429 | #define PCI_EXP_FLAGS_IRQ 0x3e00 /* Interrupt message number */ |
430 | #define PCI_EXP_DEVCAP 4 /* Device capabilities */ | 430 | #define PCI_EXP_DEVCAP 4 /* Device capabilities */ |
431 | #define PCI_EXP_DEVCAP_PAYLOAD 0x07 /* Max_Payload_Size */ | 431 | #define PCI_EXP_DEVCAP_PAYLOAD 0x00000007 /* Max_Payload_Size */ |
432 | #define PCI_EXP_DEVCAP_PHANTOM 0x18 /* Phantom functions */ | 432 | #define PCI_EXP_DEVCAP_PHANTOM 0x00000018 /* Phantom functions */ |
433 | #define PCI_EXP_DEVCAP_EXT_TAG 0x20 /* Extended tags */ | 433 | #define PCI_EXP_DEVCAP_EXT_TAG 0x00000020 /* Extended tags */ |
434 | #define PCI_EXP_DEVCAP_L0S 0x1c0 /* L0s Acceptable Latency */ | 434 | #define PCI_EXP_DEVCAP_L0S 0x000001c0 /* L0s Acceptable Latency */ |
435 | #define PCI_EXP_DEVCAP_L1 0xe00 /* L1 Acceptable Latency */ | 435 | #define PCI_EXP_DEVCAP_L1 0x00000e00 /* L1 Acceptable Latency */ |
436 | #define PCI_EXP_DEVCAP_ATN_BUT 0x1000 /* Attention Button Present */ | 436 | #define PCI_EXP_DEVCAP_ATN_BUT 0x00001000 /* Attention Button Present */ |
437 | #define PCI_EXP_DEVCAP_ATN_IND 0x2000 /* Attention Indicator Present */ | 437 | #define PCI_EXP_DEVCAP_ATN_IND 0x00002000 /* Attention Indicator Present */ |
438 | #define PCI_EXP_DEVCAP_PWR_IND 0x4000 /* Power Indicator Present */ | 438 | #define PCI_EXP_DEVCAP_PWR_IND 0x00004000 /* Power Indicator Present */ |
439 | #define PCI_EXP_DEVCAP_RBER 0x8000 /* Role-Based Error Reporting */ | 439 | #define PCI_EXP_DEVCAP_RBER 0x00008000 /* Role-Based Error Reporting */ |
440 | #define PCI_EXP_DEVCAP_PWR_VAL 0x3fc0000 /* Slot Power Limit Value */ | 440 | #define PCI_EXP_DEVCAP_PWR_VAL 0x03fc0000 /* Slot Power Limit Value */ |
441 | #define PCI_EXP_DEVCAP_PWR_SCL 0xc000000 /* Slot Power Limit Scale */ | 441 | #define PCI_EXP_DEVCAP_PWR_SCL 0x0c000000 /* Slot Power Limit Scale */ |
442 | #define PCI_EXP_DEVCAP_FLR 0x10000000 /* Function Level Reset */ | 442 | #define PCI_EXP_DEVCAP_FLR 0x10000000 /* Function Level Reset */ |
443 | #define PCI_EXP_DEVCTL 8 /* Device Control */ | 443 | #define PCI_EXP_DEVCTL 8 /* Device Control */ |
444 | #define PCI_EXP_DEVCTL_CERE 0x0001 /* Correctable Error Reporting En. */ | 444 | #define PCI_EXP_DEVCTL_CERE 0x0001 /* Correctable Error Reporting En. */ |
@@ -454,42 +454,42 @@ | |||
454 | #define PCI_EXP_DEVCTL_READRQ 0x7000 /* Max_Read_Request_Size */ | 454 | #define PCI_EXP_DEVCTL_READRQ 0x7000 /* Max_Read_Request_Size */ |
455 | #define PCI_EXP_DEVCTL_BCR_FLR 0x8000 /* Bridge Configuration Retry / FLR */ | 455 | #define PCI_EXP_DEVCTL_BCR_FLR 0x8000 /* Bridge Configuration Retry / FLR */ |
456 | #define PCI_EXP_DEVSTA 10 /* Device Status */ | 456 | #define PCI_EXP_DEVSTA 10 /* Device Status */ |
457 | #define PCI_EXP_DEVSTA_CED 0x01 /* Correctable Error Detected */ | 457 | #define PCI_EXP_DEVSTA_CED 0x0001 /* Correctable Error Detected */ |
458 | #define PCI_EXP_DEVSTA_NFED 0x02 /* Non-Fatal Error Detected */ | 458 | #define PCI_EXP_DEVSTA_NFED 0x0002 /* Non-Fatal Error Detected */ |
459 | #define PCI_EXP_DEVSTA_FED 0x04 /* Fatal Error Detected */ | 459 | #define PCI_EXP_DEVSTA_FED 0x0004 /* Fatal Error Detected */ |
460 | #define PCI_EXP_DEVSTA_URD 0x08 /* Unsupported Request Detected */ | 460 | #define PCI_EXP_DEVSTA_URD 0x0008 /* Unsupported Request Detected */ |
461 | #define PCI_EXP_DEVSTA_AUXPD 0x10 /* AUX Power Detected */ | 461 | #define PCI_EXP_DEVSTA_AUXPD 0x0010 /* AUX Power Detected */ |
462 | #define PCI_EXP_DEVSTA_TRPND 0x20 /* Transactions Pending */ | 462 | #define PCI_EXP_DEVSTA_TRPND 0x0020 /* Transactions Pending */ |
463 | #define PCI_EXP_LNKCAP 12 /* Link Capabilities */ | 463 | #define PCI_EXP_LNKCAP 12 /* Link Capabilities */ |
464 | #define PCI_EXP_LNKCAP_SLS 0x0000000f /* Supported Link Speeds */ | 464 | #define PCI_EXP_LNKCAP_SLS 0x0000000f /* Supported Link Speeds */ |
465 | #define PCI_EXP_LNKCAP_SLS_2_5GB 0x1 /* LNKCAP2 SLS Vector bit 0 (2.5GT/s) */ | 465 | #define PCI_EXP_LNKCAP_SLS_2_5GB 0x00000001 /* LNKCAP2 SLS Vector bit 0 */ |
466 | #define PCI_EXP_LNKCAP_SLS_5_0GB 0x2 /* LNKCAP2 SLS Vector bit 1 (5.0GT/s) */ | 466 | #define PCI_EXP_LNKCAP_SLS_5_0GB 0x00000002 /* LNKCAP2 SLS Vector bit 1 */ |
467 | #define PCI_EXP_LNKCAP_MLW 0x000003f0 /* Maximum Link Width */ | 467 | #define PCI_EXP_LNKCAP_MLW 0x000003f0 /* Maximum Link Width */ |
468 | #define PCI_EXP_LNKCAP_ASPMS 0x00000c00 /* ASPM Support */ | 468 | #define PCI_EXP_LNKCAP_ASPMS 0x00000c00 /* ASPM Support */ |
469 | #define PCI_EXP_LNKCAP_L0SEL 0x00007000 /* L0s Exit Latency */ | 469 | #define PCI_EXP_LNKCAP_L0SEL 0x00007000 /* L0s Exit Latency */ |
470 | #define PCI_EXP_LNKCAP_L1EL 0x00038000 /* L1 Exit Latency */ | 470 | #define PCI_EXP_LNKCAP_L1EL 0x00038000 /* L1 Exit Latency */ |
471 | #define PCI_EXP_LNKCAP_CLKPM 0x00040000 /* L1 Clock Power Management */ | 471 | #define PCI_EXP_LNKCAP_CLKPM 0x00040000 /* Clock Power Management */ |
472 | #define PCI_EXP_LNKCAP_SDERC 0x00080000 /* Surprise Down Error Reporting Capable */ | 472 | #define PCI_EXP_LNKCAP_SDERC 0x00080000 /* Surprise Down Error Reporting Capable */ |
473 | #define PCI_EXP_LNKCAP_DLLLARC 0x00100000 /* Data Link Layer Link Active Reporting Capable */ | 473 | #define PCI_EXP_LNKCAP_DLLLARC 0x00100000 /* Data Link Layer Link Active Reporting Capable */ |
474 | #define PCI_EXP_LNKCAP_LBNC 0x00200000 /* Link Bandwidth Notification Capability */ | 474 | #define PCI_EXP_LNKCAP_LBNC 0x00200000 /* Link Bandwidth Notification Capability */ |
475 | #define PCI_EXP_LNKCAP_PN 0xff000000 /* Port Number */ | 475 | #define PCI_EXP_LNKCAP_PN 0xff000000 /* Port Number */ |
476 | #define PCI_EXP_LNKCTL 16 /* Link Control */ | 476 | #define PCI_EXP_LNKCTL 16 /* Link Control */ |
477 | #define PCI_EXP_LNKCTL_ASPMC 0x0003 /* ASPM Control */ | 477 | #define PCI_EXP_LNKCTL_ASPMC 0x0003 /* ASPM Control */ |
478 | #define PCI_EXP_LNKCTL_ASPM_L0S 0x01 /* L0s Enable */ | 478 | #define PCI_EXP_LNKCTL_ASPM_L0S 0x0001 /* L0s Enable */ |
479 | #define PCI_EXP_LNKCTL_ASPM_L1 0x02 /* L1 Enable */ | 479 | #define PCI_EXP_LNKCTL_ASPM_L1 0x0002 /* L1 Enable */ |
480 | #define PCI_EXP_LNKCTL_RCB 0x0008 /* Read Completion Boundary */ | 480 | #define PCI_EXP_LNKCTL_RCB 0x0008 /* Read Completion Boundary */ |
481 | #define PCI_EXP_LNKCTL_LD 0x0010 /* Link Disable */ | 481 | #define PCI_EXP_LNKCTL_LD 0x0010 /* Link Disable */ |
482 | #define PCI_EXP_LNKCTL_RL 0x0020 /* Retrain Link */ | 482 | #define PCI_EXP_LNKCTL_RL 0x0020 /* Retrain Link */ |
483 | #define PCI_EXP_LNKCTL_CCC 0x0040 /* Common Clock Configuration */ | 483 | #define PCI_EXP_LNKCTL_CCC 0x0040 /* Common Clock Configuration */ |
484 | #define PCI_EXP_LNKCTL_ES 0x0080 /* Extended Synch */ | 484 | #define PCI_EXP_LNKCTL_ES 0x0080 /* Extended Synch */ |
485 | #define PCI_EXP_LNKCTL_CLKREQ_EN 0x100 /* Enable clkreq */ | 485 | #define PCI_EXP_LNKCTL_CLKREQ_EN 0x0100 /* Enable clkreq */ |
486 | #define PCI_EXP_LNKCTL_HAWD 0x0200 /* Hardware Autonomous Width Disable */ | 486 | #define PCI_EXP_LNKCTL_HAWD 0x0200 /* Hardware Autonomous Width Disable */ |
487 | #define PCI_EXP_LNKCTL_LBMIE 0x0400 /* Link Bandwidth Management Interrupt Enable */ | 487 | #define PCI_EXP_LNKCTL_LBMIE 0x0400 /* Link Bandwidth Management Interrupt Enable */ |
488 | #define PCI_EXP_LNKCTL_LABIE 0x0800 /* Lnk Autonomous Bandwidth Interrupt Enable */ | 488 | #define PCI_EXP_LNKCTL_LABIE 0x0800 /* Lnk Autonomous Bandwidth Interrupt Enable */ |
489 | #define PCI_EXP_LNKSTA 18 /* Link Status */ | 489 | #define PCI_EXP_LNKSTA 18 /* Link Status */ |
490 | #define PCI_EXP_LNKSTA_CLS 0x000f /* Current Link Speed */ | 490 | #define PCI_EXP_LNKSTA_CLS 0x000f /* Current Link Speed */ |
491 | #define PCI_EXP_LNKSTA_CLS_2_5GB 0x01 /* Current Link Speed 2.5GT/s */ | 491 | #define PCI_EXP_LNKSTA_CLS_2_5GB 0x0001 /* Current Link Speed 2.5GT/s */ |
492 | #define PCI_EXP_LNKSTA_CLS_5_0GB 0x02 /* Current Link Speed 5.0GT/s */ | 492 | #define PCI_EXP_LNKSTA_CLS_5_0GB 0x0002 /* Current Link Speed 5.0GT/s */ |
493 | #define PCI_EXP_LNKSTA_NLW 0x03f0 /* Nogotiated Link Width */ | 493 | #define PCI_EXP_LNKSTA_NLW 0x03f0 /* Nogotiated Link Width */ |
494 | #define PCI_EXP_LNKSTA_NLW_SHIFT 4 /* start of NLW mask in link status */ | 494 | #define PCI_EXP_LNKSTA_NLW_SHIFT 4 /* start of NLW mask in link status */ |
495 | #define PCI_EXP_LNKSTA_LT 0x0800 /* Link Training */ | 495 | #define PCI_EXP_LNKSTA_LT 0x0800 /* Link Training */ |
@@ -534,44 +534,49 @@ | |||
534 | #define PCI_EXP_SLTSTA_EIS 0x0080 /* Electromechanical Interlock Status */ | 534 | #define PCI_EXP_SLTSTA_EIS 0x0080 /* Electromechanical Interlock Status */ |
535 | #define PCI_EXP_SLTSTA_DLLSC 0x0100 /* Data Link Layer State Changed */ | 535 | #define PCI_EXP_SLTSTA_DLLSC 0x0100 /* Data Link Layer State Changed */ |
536 | #define PCI_EXP_RTCTL 28 /* Root Control */ | 536 | #define PCI_EXP_RTCTL 28 /* Root Control */ |
537 | #define PCI_EXP_RTCTL_SECEE 0x01 /* System Error on Correctable Error */ | 537 | #define PCI_EXP_RTCTL_SECEE 0x0001 /* System Error on Correctable Error */ |
538 | #define PCI_EXP_RTCTL_SENFEE 0x02 /* System Error on Non-Fatal Error */ | 538 | #define PCI_EXP_RTCTL_SENFEE 0x0002 /* System Error on Non-Fatal Error */ |
539 | #define PCI_EXP_RTCTL_SEFEE 0x04 /* System Error on Fatal Error */ | 539 | #define PCI_EXP_RTCTL_SEFEE 0x0004 /* System Error on Fatal Error */ |
540 | #define PCI_EXP_RTCTL_PMEIE 0x08 /* PME Interrupt Enable */ | 540 | #define PCI_EXP_RTCTL_PMEIE 0x0008 /* PME Interrupt Enable */ |
541 | #define PCI_EXP_RTCTL_CRSSVE 0x10 /* CRS Software Visibility Enable */ | 541 | #define PCI_EXP_RTCTL_CRSSVE 0x0010 /* CRS Software Visibility Enable */ |
542 | #define PCI_EXP_RTCAP 30 /* Root Capabilities */ | 542 | #define PCI_EXP_RTCAP 30 /* Root Capabilities */ |
543 | #define PCI_EXP_RTSTA 32 /* Root Status */ | 543 | #define PCI_EXP_RTSTA 32 /* Root Status */ |
544 | #define PCI_EXP_RTSTA_PME 0x10000 /* PME status */ | 544 | #define PCI_EXP_RTSTA_PME 0x00010000 /* PME status */ |
545 | #define PCI_EXP_RTSTA_PENDING 0x20000 /* PME pending */ | 545 | #define PCI_EXP_RTSTA_PENDING 0x00020000 /* PME pending */ |
546 | /* | 546 | /* |
547 | * Note that the following PCI Express 'Capability Structure' registers | 547 | * The Device Capabilities 2, Device Status 2, Device Control 2, |
548 | * were introduced with 'Capability Version' 0x2 (v2). These registers | 548 | * Link Capabilities 2, Link Status 2, Link Control 2, |
549 | * do not exist on devices with Capability Version 1. Use pci_pcie_cap2() | 549 | * Slot Capabilities 2, Slot Status 2, and Slot Control 2 registers |
550 | * to use these fields safely. | 550 | * are only present on devices with PCIe Capability version 2. |
551 | * Use pcie_capability_read_word() and similar interfaces to use them | ||
552 | * safely. | ||
551 | */ | 553 | */ |
552 | #define PCI_EXP_DEVCAP2 36 /* Device Capabilities 2 */ | 554 | #define PCI_EXP_DEVCAP2 36 /* Device Capabilities 2 */ |
553 | #define PCI_EXP_DEVCAP2_ARI 0x20 /* Alternative Routing-ID */ | 555 | #define PCI_EXP_DEVCAP2_ARI 0x00000020 /* Alternative Routing-ID */ |
554 | #define PCI_EXP_DEVCAP2_LTR 0x800 /* Latency tolerance reporting */ | 556 | #define PCI_EXP_DEVCAP2_LTR 0x00000800 /* Latency tolerance reporting */ |
555 | #define PCI_EXP_OBFF_MASK 0xc0000 /* OBFF support mechanism */ | 557 | #define PCI_EXP_DEVCAP2_OBFF_MASK 0x000c0000 /* OBFF support mechanism */ |
556 | #define PCI_EXP_OBFF_MSG 0x40000 /* New message signaling */ | 558 | #define PCI_EXP_DEVCAP2_OBFF_MSG 0x00040000 /* New message signaling */ |
557 | #define PCI_EXP_OBFF_WAKE 0x80000 /* Re-use WAKE# for OBFF */ | 559 | #define PCI_EXP_DEVCAP2_OBFF_WAKE 0x00080000 /* Re-use WAKE# for OBFF */ |
558 | #define PCI_EXP_DEVCTL2 40 /* Device Control 2 */ | 560 | #define PCI_EXP_DEVCTL2 40 /* Device Control 2 */ |
559 | #define PCI_EXP_DEVCTL2_ARI 0x20 /* Alternative Routing-ID */ | 561 | #define PCI_EXP_DEVCTL2_ARI 0x20 /* Alternative Routing-ID */ |
560 | #define PCI_EXP_IDO_REQ_EN 0x100 /* ID-based ordering request enable */ | 562 | #define PCI_EXP_DEVCTL2_IDO_REQ_EN 0x0100 /* Allow IDO for requests */ |
561 | #define PCI_EXP_IDO_CMP_EN 0x200 /* ID-based ordering completion enable */ | 563 | #define PCI_EXP_DEVCTL2_IDO_CMP_EN 0x0200 /* Allow IDO for completions */ |
562 | #define PCI_EXP_LTR_EN 0x400 /* Latency tolerance reporting */ | 564 | #define PCI_EXP_DEVCTL2_LTR_EN 0x0400 /* Enable LTR mechanism */ |
563 | #define PCI_EXP_OBFF_MSGA_EN 0x2000 /* OBFF enable with Message type A */ | 565 | #define PCI_EXP_DEVCTL2_OBFF_MSGA_EN 0x2000 /* Enable OBFF Message type A */ |
564 | #define PCI_EXP_OBFF_MSGB_EN 0x4000 /* OBFF enable with Message type B */ | 566 | #define PCI_EXP_DEVCTL2_OBFF_MSGB_EN 0x4000 /* Enable OBFF Message type B */ |
565 | #define PCI_EXP_OBFF_WAKE_EN 0x6000 /* OBFF using WAKE# signaling */ | 567 | #define PCI_EXP_DEVCTL2_OBFF_WAKE_EN 0x6000 /* OBFF using WAKE# signaling */ |
568 | #define PCI_EXP_DEVSTA2 42 /* Device Status 2 */ | ||
566 | #define PCI_CAP_EXP_ENDPOINT_SIZEOF_V2 44 /* v2 endpoints end here */ | 569 | #define PCI_CAP_EXP_ENDPOINT_SIZEOF_V2 44 /* v2 endpoints end here */ |
567 | #define PCI_EXP_LNKCAP2 44 /* Link Capability 2 */ | 570 | #define PCI_EXP_LNKCAP2 44 /* Link Capabilities 2 */ |
568 | #define PCI_EXP_LNKCAP2_SLS_2_5GB 0x02 /* Supported Link Speed 2.5GT/s */ | 571 | #define PCI_EXP_LNKCAP2_SLS_2_5GB 0x00000002 /* Supported Speed 2.5GT/s */ |
569 | #define PCI_EXP_LNKCAP2_SLS_5_0GB 0x04 /* Supported Link Speed 5.0GT/s */ | 572 | #define PCI_EXP_LNKCAP2_SLS_5_0GB 0x00000004 /* Supported Speed 5.0GT/s */ |
570 | #define PCI_EXP_LNKCAP2_SLS_8_0GB 0x08 /* Supported Link Speed 8.0GT/s */ | 573 | #define PCI_EXP_LNKCAP2_SLS_8_0GB 0x00000008 /* Supported Speed 8.0GT/s */ |
571 | #define PCI_EXP_LNKCAP2_CROSSLINK 0x100 /* Crosslink supported */ | 574 | #define PCI_EXP_LNKCAP2_CROSSLINK 0x00000100 /* Crosslink supported */ |
572 | #define PCI_EXP_LNKCTL2 48 /* Link Control 2 */ | 575 | #define PCI_EXP_LNKCTL2 48 /* Link Control 2 */ |
573 | #define PCI_EXP_LNKSTA2 50 /* Link Status 2 */ | 576 | #define PCI_EXP_LNKSTA2 50 /* Link Status 2 */ |
577 | #define PCI_EXP_SLTCAP2 52 /* Slot Capabilities 2 */ | ||
574 | #define PCI_EXP_SLTCTL2 56 /* Slot Control 2 */ | 578 | #define PCI_EXP_SLTCTL2 56 /* Slot Control 2 */ |
579 | #define PCI_EXP_SLTSTA2 58 /* Slot Status 2 */ | ||
575 | 580 | ||
576 | /* Extended Capabilities (PCI-X 2.0 and Express) */ | 581 | /* Extended Capabilities (PCI-X 2.0 and Express) */ |
577 | #define PCI_EXT_CAP_ID(header) (header & 0x0000ffff) | 582 | #define PCI_EXT_CAP_ID(header) (header & 0x0000ffff) |
diff --git a/include/uapi/linux/perf_event.h b/include/uapi/linux/perf_event.h index fb104e51496e..ca1d90bcb74d 100644 --- a/include/uapi/linux/perf_event.h +++ b/include/uapi/linux/perf_event.h | |||
@@ -109,6 +109,7 @@ enum perf_sw_ids { | |||
109 | PERF_COUNT_SW_PAGE_FAULTS_MAJ = 6, | 109 | PERF_COUNT_SW_PAGE_FAULTS_MAJ = 6, |
110 | PERF_COUNT_SW_ALIGNMENT_FAULTS = 7, | 110 | PERF_COUNT_SW_ALIGNMENT_FAULTS = 7, |
111 | PERF_COUNT_SW_EMULATION_FAULTS = 8, | 111 | PERF_COUNT_SW_EMULATION_FAULTS = 8, |
112 | PERF_COUNT_SW_DUMMY = 9, | ||
112 | 113 | ||
113 | PERF_COUNT_SW_MAX, /* non-ABI */ | 114 | PERF_COUNT_SW_MAX, /* non-ABI */ |
114 | }; | 115 | }; |
@@ -134,8 +135,9 @@ enum perf_event_sample_format { | |||
134 | PERF_SAMPLE_STACK_USER = 1U << 13, | 135 | PERF_SAMPLE_STACK_USER = 1U << 13, |
135 | PERF_SAMPLE_WEIGHT = 1U << 14, | 136 | PERF_SAMPLE_WEIGHT = 1U << 14, |
136 | PERF_SAMPLE_DATA_SRC = 1U << 15, | 137 | PERF_SAMPLE_DATA_SRC = 1U << 15, |
138 | PERF_SAMPLE_IDENTIFIER = 1U << 16, | ||
137 | 139 | ||
138 | PERF_SAMPLE_MAX = 1U << 16, /* non-ABI */ | 140 | PERF_SAMPLE_MAX = 1U << 17, /* non-ABI */ |
139 | }; | 141 | }; |
140 | 142 | ||
141 | /* | 143 | /* |
@@ -157,8 +159,11 @@ enum perf_branch_sample_type { | |||
157 | PERF_SAMPLE_BRANCH_ANY_CALL = 1U << 4, /* any call branch */ | 159 | PERF_SAMPLE_BRANCH_ANY_CALL = 1U << 4, /* any call branch */ |
158 | PERF_SAMPLE_BRANCH_ANY_RETURN = 1U << 5, /* any return branch */ | 160 | PERF_SAMPLE_BRANCH_ANY_RETURN = 1U << 5, /* any return branch */ |
159 | PERF_SAMPLE_BRANCH_IND_CALL = 1U << 6, /* indirect calls */ | 161 | PERF_SAMPLE_BRANCH_IND_CALL = 1U << 6, /* indirect calls */ |
162 | PERF_SAMPLE_BRANCH_ABORT_TX = 1U << 7, /* transaction aborts */ | ||
163 | PERF_SAMPLE_BRANCH_IN_TX = 1U << 8, /* in transaction */ | ||
164 | PERF_SAMPLE_BRANCH_NO_TX = 1U << 9, /* not in transaction */ | ||
160 | 165 | ||
161 | PERF_SAMPLE_BRANCH_MAX = 1U << 7, /* non-ABI */ | 166 | PERF_SAMPLE_BRANCH_MAX = 1U << 10, /* non-ABI */ |
162 | }; | 167 | }; |
163 | 168 | ||
164 | #define PERF_SAMPLE_BRANCH_PLM_ALL \ | 169 | #define PERF_SAMPLE_BRANCH_PLM_ALL \ |
@@ -272,8 +277,9 @@ struct perf_event_attr { | |||
272 | 277 | ||
273 | exclude_callchain_kernel : 1, /* exclude kernel callchains */ | 278 | exclude_callchain_kernel : 1, /* exclude kernel callchains */ |
274 | exclude_callchain_user : 1, /* exclude user callchains */ | 279 | exclude_callchain_user : 1, /* exclude user callchains */ |
280 | mmap2 : 1, /* include mmap with inode data */ | ||
275 | 281 | ||
276 | __reserved_1 : 41; | 282 | __reserved_1 : 40; |
277 | 283 | ||
278 | union { | 284 | union { |
279 | __u32 wakeup_events; /* wakeup every n events */ | 285 | __u32 wakeup_events; /* wakeup every n events */ |
@@ -318,6 +324,7 @@ struct perf_event_attr { | |||
318 | #define PERF_EVENT_IOC_PERIOD _IOW('$', 4, __u64) | 324 | #define PERF_EVENT_IOC_PERIOD _IOW('$', 4, __u64) |
319 | #define PERF_EVENT_IOC_SET_OUTPUT _IO ('$', 5) | 325 | #define PERF_EVENT_IOC_SET_OUTPUT _IO ('$', 5) |
320 | #define PERF_EVENT_IOC_SET_FILTER _IOW('$', 6, char *) | 326 | #define PERF_EVENT_IOC_SET_FILTER _IOW('$', 6, char *) |
327 | #define PERF_EVENT_IOC_ID _IOR('$', 7, u64 *) | ||
321 | 328 | ||
322 | enum perf_event_ioc_flags { | 329 | enum perf_event_ioc_flags { |
323 | PERF_IOC_FLAG_GROUP = 1U << 0, | 330 | PERF_IOC_FLAG_GROUP = 1U << 0, |
@@ -372,9 +379,12 @@ struct perf_event_mmap_page { | |||
372 | __u64 time_running; /* time event on cpu */ | 379 | __u64 time_running; /* time event on cpu */ |
373 | union { | 380 | union { |
374 | __u64 capabilities; | 381 | __u64 capabilities; |
375 | __u64 cap_usr_time : 1, | 382 | struct { |
376 | cap_usr_rdpmc : 1, | 383 | __u64 cap_usr_time : 1, |
377 | cap_____res : 62; | 384 | cap_usr_rdpmc : 1, |
385 | cap_usr_time_zero : 1, | ||
386 | cap_____res : 61; | ||
387 | }; | ||
378 | }; | 388 | }; |
379 | 389 | ||
380 | /* | 390 | /* |
@@ -415,12 +425,29 @@ struct perf_event_mmap_page { | |||
415 | __u16 time_shift; | 425 | __u16 time_shift; |
416 | __u32 time_mult; | 426 | __u32 time_mult; |
417 | __u64 time_offset; | 427 | __u64 time_offset; |
428 | /* | ||
429 | * If cap_usr_time_zero, the hardware clock (e.g. TSC) can be calculated | ||
430 | * from sample timestamps. | ||
431 | * | ||
432 | * time = timestamp - time_zero; | ||
433 | * quot = time / time_mult; | ||
434 | * rem = time % time_mult; | ||
435 | * cyc = (quot << time_shift) + (rem << time_shift) / time_mult; | ||
436 | * | ||
437 | * And vice versa: | ||
438 | * | ||
439 | * quot = cyc >> time_shift; | ||
440 | * rem = cyc & ((1 << time_shift) - 1); | ||
441 | * timestamp = time_zero + quot * time_mult + | ||
442 | * ((rem * time_mult) >> time_shift); | ||
443 | */ | ||
444 | __u64 time_zero; | ||
418 | 445 | ||
419 | /* | 446 | /* |
420 | * Hole for extension of the self monitor capabilities | 447 | * Hole for extension of the self monitor capabilities |
421 | */ | 448 | */ |
422 | 449 | ||
423 | __u64 __reserved[120]; /* align to 1k */ | 450 | __u64 __reserved[119]; /* align to 1k */ |
424 | 451 | ||
425 | /* | 452 | /* |
426 | * Control data for the mmap() data buffer. | 453 | * Control data for the mmap() data buffer. |
@@ -468,13 +495,28 @@ enum perf_event_type { | |||
468 | /* | 495 | /* |
469 | * If perf_event_attr.sample_id_all is set then all event types will | 496 | * If perf_event_attr.sample_id_all is set then all event types will |
470 | * have the sample_type selected fields related to where/when | 497 | * have the sample_type selected fields related to where/when |
471 | * (identity) an event took place (TID, TIME, ID, CPU, STREAM_ID) | 498 | * (identity) an event took place (TID, TIME, ID, STREAM_ID, CPU, |
472 | * described in PERF_RECORD_SAMPLE below, it will be stashed just after | 499 | * IDENTIFIER) described in PERF_RECORD_SAMPLE below, it will be stashed |
473 | * the perf_event_header and the fields already present for the existing | 500 | * just after the perf_event_header and the fields already present for |
474 | * fields, i.e. at the end of the payload. That way a newer perf.data | 501 | * the existing fields, i.e. at the end of the payload. That way a newer |
475 | * file will be supported by older perf tools, with these new optional | 502 | * perf.data file will be supported by older perf tools, with these new |
476 | * fields being ignored. | 503 | * optional fields being ignored. |
504 | * | ||
505 | * struct sample_id { | ||
506 | * { u32 pid, tid; } && PERF_SAMPLE_TID | ||
507 | * { u64 time; } && PERF_SAMPLE_TIME | ||
508 | * { u64 id; } && PERF_SAMPLE_ID | ||
509 | * { u64 stream_id;} && PERF_SAMPLE_STREAM_ID | ||
510 | * { u32 cpu, res; } && PERF_SAMPLE_CPU | ||
511 | * { u64 id; } && PERF_SAMPLE_IDENTIFIER | ||
512 | * } && perf_event_attr::sample_id_all | ||
477 | * | 513 | * |
514 | * Note that PERF_SAMPLE_IDENTIFIER duplicates PERF_SAMPLE_ID. The | ||
515 | * advantage of PERF_SAMPLE_IDENTIFIER is that its position is fixed | ||
516 | * relative to header.size. | ||
517 | */ | ||
518 | |||
519 | /* | ||
478 | * The MMAP events record the PROT_EXEC mappings so that we can | 520 | * The MMAP events record the PROT_EXEC mappings so that we can |
479 | * correlate userspace IPs to code. They have the following structure: | 521 | * correlate userspace IPs to code. They have the following structure: |
480 | * | 522 | * |
@@ -495,6 +537,7 @@ enum perf_event_type { | |||
495 | * struct perf_event_header header; | 537 | * struct perf_event_header header; |
496 | * u64 id; | 538 | * u64 id; |
497 | * u64 lost; | 539 | * u64 lost; |
540 | * struct sample_id sample_id; | ||
498 | * }; | 541 | * }; |
499 | */ | 542 | */ |
500 | PERF_RECORD_LOST = 2, | 543 | PERF_RECORD_LOST = 2, |
@@ -505,6 +548,7 @@ enum perf_event_type { | |||
505 | * | 548 | * |
506 | * u32 pid, tid; | 549 | * u32 pid, tid; |
507 | * char comm[]; | 550 | * char comm[]; |
551 | * struct sample_id sample_id; | ||
508 | * }; | 552 | * }; |
509 | */ | 553 | */ |
510 | PERF_RECORD_COMM = 3, | 554 | PERF_RECORD_COMM = 3, |
@@ -515,6 +559,7 @@ enum perf_event_type { | |||
515 | * u32 pid, ppid; | 559 | * u32 pid, ppid; |
516 | * u32 tid, ptid; | 560 | * u32 tid, ptid; |
517 | * u64 time; | 561 | * u64 time; |
562 | * struct sample_id sample_id; | ||
518 | * }; | 563 | * }; |
519 | */ | 564 | */ |
520 | PERF_RECORD_EXIT = 4, | 565 | PERF_RECORD_EXIT = 4, |
@@ -525,6 +570,7 @@ enum perf_event_type { | |||
525 | * u64 time; | 570 | * u64 time; |
526 | * u64 id; | 571 | * u64 id; |
527 | * u64 stream_id; | 572 | * u64 stream_id; |
573 | * struct sample_id sample_id; | ||
528 | * }; | 574 | * }; |
529 | */ | 575 | */ |
530 | PERF_RECORD_THROTTLE = 5, | 576 | PERF_RECORD_THROTTLE = 5, |
@@ -536,6 +582,7 @@ enum perf_event_type { | |||
536 | * u32 pid, ppid; | 582 | * u32 pid, ppid; |
537 | * u32 tid, ptid; | 583 | * u32 tid, ptid; |
538 | * u64 time; | 584 | * u64 time; |
585 | * struct sample_id sample_id; | ||
539 | * }; | 586 | * }; |
540 | */ | 587 | */ |
541 | PERF_RECORD_FORK = 7, | 588 | PERF_RECORD_FORK = 7, |
@@ -546,6 +593,7 @@ enum perf_event_type { | |||
546 | * u32 pid, tid; | 593 | * u32 pid, tid; |
547 | * | 594 | * |
548 | * struct read_format values; | 595 | * struct read_format values; |
596 | * struct sample_id sample_id; | ||
549 | * }; | 597 | * }; |
550 | */ | 598 | */ |
551 | PERF_RECORD_READ = 8, | 599 | PERF_RECORD_READ = 8, |
@@ -554,6 +602,13 @@ enum perf_event_type { | |||
554 | * struct { | 602 | * struct { |
555 | * struct perf_event_header header; | 603 | * struct perf_event_header header; |
556 | * | 604 | * |
605 | * # | ||
606 | * # Note that PERF_SAMPLE_IDENTIFIER duplicates PERF_SAMPLE_ID. | ||
607 | * # The advantage of PERF_SAMPLE_IDENTIFIER is that its position | ||
608 | * # is fixed relative to header. | ||
609 | * # | ||
610 | * | ||
611 | * { u64 id; } && PERF_SAMPLE_IDENTIFIER | ||
557 | * { u64 ip; } && PERF_SAMPLE_IP | 612 | * { u64 ip; } && PERF_SAMPLE_IP |
558 | * { u32 pid, tid; } && PERF_SAMPLE_TID | 613 | * { u32 pid, tid; } && PERF_SAMPLE_TID |
559 | * { u64 time; } && PERF_SAMPLE_TIME | 614 | * { u64 time; } && PERF_SAMPLE_TIME |
@@ -593,11 +648,32 @@ enum perf_event_type { | |||
593 | * u64 dyn_size; } && PERF_SAMPLE_STACK_USER | 648 | * u64 dyn_size; } && PERF_SAMPLE_STACK_USER |
594 | * | 649 | * |
595 | * { u64 weight; } && PERF_SAMPLE_WEIGHT | 650 | * { u64 weight; } && PERF_SAMPLE_WEIGHT |
596 | * { u64 data_src; } && PERF_SAMPLE_DATA_SRC | 651 | * { u64 data_src; } && PERF_SAMPLE_DATA_SRC |
597 | * }; | 652 | * }; |
598 | */ | 653 | */ |
599 | PERF_RECORD_SAMPLE = 9, | 654 | PERF_RECORD_SAMPLE = 9, |
600 | 655 | ||
656 | /* | ||
657 | * The MMAP2 records are an augmented version of MMAP, they add | ||
658 | * maj, min, ino numbers to be used to uniquely identify each mapping | ||
659 | * | ||
660 | * struct { | ||
661 | * struct perf_event_header header; | ||
662 | * | ||
663 | * u32 pid, tid; | ||
664 | * u64 addr; | ||
665 | * u64 len; | ||
666 | * u64 pgoff; | ||
667 | * u32 maj; | ||
668 | * u32 min; | ||
669 | * u64 ino; | ||
670 | * u64 ino_generation; | ||
671 | * char filename[]; | ||
672 | * struct sample_id sample_id; | ||
673 | * }; | ||
674 | */ | ||
675 | PERF_RECORD_MMAP2 = 10, | ||
676 | |||
601 | PERF_RECORD_MAX, /* non-ABI */ | 677 | PERF_RECORD_MAX, /* non-ABI */ |
602 | }; | 678 | }; |
603 | 679 | ||
@@ -682,4 +758,28 @@ union perf_mem_data_src { | |||
682 | #define PERF_MEM_S(a, s) \ | 758 | #define PERF_MEM_S(a, s) \ |
683 | (((u64)PERF_MEM_##a##_##s) << PERF_MEM_##a##_SHIFT) | 759 | (((u64)PERF_MEM_##a##_##s) << PERF_MEM_##a##_SHIFT) |
684 | 760 | ||
761 | /* | ||
762 | * single taken branch record layout: | ||
763 | * | ||
764 | * from: source instruction (may not always be a branch insn) | ||
765 | * to: branch target | ||
766 | * mispred: branch target was mispredicted | ||
767 | * predicted: branch target was predicted | ||
768 | * | ||
769 | * support for mispred, predicted is optional. In case it | ||
770 | * is not supported mispred = predicted = 0. | ||
771 | * | ||
772 | * in_tx: running in a hardware transaction | ||
773 | * abort: aborting a hardware transaction | ||
774 | */ | ||
775 | struct perf_branch_entry { | ||
776 | __u64 from; | ||
777 | __u64 to; | ||
778 | __u64 mispred:1, /* target mispredicted */ | ||
779 | predicted:1,/* target predicted */ | ||
780 | in_tx:1, /* in transaction */ | ||
781 | abort:1, /* transaction abort */ | ||
782 | reserved:60; | ||
783 | }; | ||
784 | |||
685 | #endif /* _UAPI_LINUX_PERF_EVENT_H */ | 785 | #endif /* _UAPI_LINUX_PERF_EVENT_H */ |
diff --git a/include/uapi/linux/pkt_sched.h b/include/uapi/linux/pkt_sched.h index dbd71b0c7d8c..9b829134d422 100644 --- a/include/uapi/linux/pkt_sched.h +++ b/include/uapi/linux/pkt_sched.h | |||
@@ -73,9 +73,17 @@ struct tc_estimator { | |||
73 | #define TC_H_ROOT (0xFFFFFFFFU) | 73 | #define TC_H_ROOT (0xFFFFFFFFU) |
74 | #define TC_H_INGRESS (0xFFFFFFF1U) | 74 | #define TC_H_INGRESS (0xFFFFFFF1U) |
75 | 75 | ||
76 | /* Need to corrospond to iproute2 tc/tc_core.h "enum link_layer" */ | ||
77 | enum tc_link_layer { | ||
78 | TC_LINKLAYER_UNAWARE, /* Indicate unaware old iproute2 util */ | ||
79 | TC_LINKLAYER_ETHERNET, | ||
80 | TC_LINKLAYER_ATM, | ||
81 | }; | ||
82 | #define TC_LINKLAYER_MASK 0x0F /* limit use to lower 4 bits */ | ||
83 | |||
76 | struct tc_ratespec { | 84 | struct tc_ratespec { |
77 | unsigned char cell_log; | 85 | unsigned char cell_log; |
78 | unsigned char __reserved; | 86 | __u8 linklayer; /* lower 4 bits */ |
79 | unsigned short overhead; | 87 | unsigned short overhead; |
80 | short cell_align; | 88 | short cell_align; |
81 | unsigned short mpu; | 89 | unsigned short mpu; |
@@ -736,4 +744,45 @@ struct tc_fq_codel_xstats { | |||
736 | }; | 744 | }; |
737 | }; | 745 | }; |
738 | 746 | ||
747 | /* FQ */ | ||
748 | |||
749 | enum { | ||
750 | TCA_FQ_UNSPEC, | ||
751 | |||
752 | TCA_FQ_PLIMIT, /* limit of total number of packets in queue */ | ||
753 | |||
754 | TCA_FQ_FLOW_PLIMIT, /* limit of packets per flow */ | ||
755 | |||
756 | TCA_FQ_QUANTUM, /* RR quantum */ | ||
757 | |||
758 | TCA_FQ_INITIAL_QUANTUM, /* RR quantum for new flow */ | ||
759 | |||
760 | TCA_FQ_RATE_ENABLE, /* enable/disable rate limiting */ | ||
761 | |||
762 | TCA_FQ_FLOW_DEFAULT_RATE,/* for sockets with unspecified sk_rate, | ||
763 | * use the following rate | ||
764 | */ | ||
765 | |||
766 | TCA_FQ_FLOW_MAX_RATE, /* per flow max rate */ | ||
767 | |||
768 | TCA_FQ_BUCKETS_LOG, /* log2(number of buckets) */ | ||
769 | __TCA_FQ_MAX | ||
770 | }; | ||
771 | |||
772 | #define TCA_FQ_MAX (__TCA_FQ_MAX - 1) | ||
773 | |||
774 | struct tc_fq_qd_stats { | ||
775 | __u64 gc_flows; | ||
776 | __u64 highprio_packets; | ||
777 | __u64 tcp_retrans; | ||
778 | __u64 throttled; | ||
779 | __u64 flows_plimit; | ||
780 | __u64 pkts_too_long; | ||
781 | __u64 allocation_errors; | ||
782 | __s64 time_next_delayed_flow; | ||
783 | __u32 flows; | ||
784 | __u32 inactive_flows; | ||
785 | __u32 throttled_flows; | ||
786 | __u32 pad; | ||
787 | }; | ||
739 | #endif | 788 | #endif |
diff --git a/include/uapi/linux/ptrace.h b/include/uapi/linux/ptrace.h index 52ebcc89f306..cf1019e15f5b 100644 --- a/include/uapi/linux/ptrace.h +++ b/include/uapi/linux/ptrace.h | |||
@@ -61,6 +61,9 @@ struct ptrace_peeksiginfo_args { | |||
61 | __s32 nr; /* how may siginfos to take */ | 61 | __s32 nr; /* how may siginfos to take */ |
62 | }; | 62 | }; |
63 | 63 | ||
64 | #define PTRACE_GETSIGMASK 0x420a | ||
65 | #define PTRACE_SETSIGMASK 0x420b | ||
66 | |||
64 | /* Read signals from a shared (process wide) queue */ | 67 | /* Read signals from a shared (process wide) queue */ |
65 | #define PTRACE_PEEKSIGINFO_SHARED (1 << 0) | 68 | #define PTRACE_PEEKSIGINFO_SHARED (1 << 0) |
66 | 69 | ||
diff --git a/include/uapi/linux/reiserfs_xattr.h b/include/uapi/linux/reiserfs_xattr.h index d8ce17c2459a..38fdd648be21 100644 --- a/include/uapi/linux/reiserfs_xattr.h +++ b/include/uapi/linux/reiserfs_xattr.h | |||
@@ -16,7 +16,7 @@ struct reiserfs_xattr_header { | |||
16 | }; | 16 | }; |
17 | 17 | ||
18 | struct reiserfs_security_handle { | 18 | struct reiserfs_security_handle { |
19 | char *name; | 19 | const char *name; |
20 | void *value; | 20 | void *value; |
21 | size_t length; | 21 | size_t length; |
22 | }; | 22 | }; |
diff --git a/include/uapi/linux/rtnetlink.h b/include/uapi/linux/rtnetlink.h index 7a2144e1afae..eb0f1a554d7b 100644 --- a/include/uapi/linux/rtnetlink.h +++ b/include/uapi/linux/rtnetlink.h | |||
@@ -386,6 +386,8 @@ enum { | |||
386 | #define RTAX_RTO_MIN RTAX_RTO_MIN | 386 | #define RTAX_RTO_MIN RTAX_RTO_MIN |
387 | RTAX_INITRWND, | 387 | RTAX_INITRWND, |
388 | #define RTAX_INITRWND RTAX_INITRWND | 388 | #define RTAX_INITRWND RTAX_INITRWND |
389 | RTAX_QUICKACK, | ||
390 | #define RTAX_QUICKACK RTAX_QUICKACK | ||
389 | __RTAX_MAX | 391 | __RTAX_MAX |
390 | }; | 392 | }; |
391 | 393 | ||
diff --git a/include/uapi/linux/sctp.h b/include/uapi/linux/sctp.h index 66b466e4ca08..ca451e99b28b 100644 --- a/include/uapi/linux/sctp.h +++ b/include/uapi/linux/sctp.h | |||
@@ -28,7 +28,7 @@ | |||
28 | * | 28 | * |
29 | * Please send any bug reports or fixes you make to the | 29 | * Please send any bug reports or fixes you make to the |
30 | * email address(es): | 30 | * email address(es): |
31 | * lksctp developers <lksctp-developers@lists.sourceforge.net> | 31 | * lksctp developers <linux-sctp@vger.kernel.org> |
32 | * | 32 | * |
33 | * Or submit a bug report through the following website: | 33 | * Or submit a bug report through the following website: |
34 | * http://www.sf.net/projects/lksctp | 34 | * http://www.sf.net/projects/lksctp |
diff --git a/include/uapi/linux/serial_core.h b/include/uapi/linux/serial_core.h index 74c2bf7211f8..b47dba2c1e6f 100644 --- a/include/uapi/linux/serial_core.h +++ b/include/uapi/linux/serial_core.h | |||
@@ -226,4 +226,16 @@ | |||
226 | /* Rocketport EXPRESS/INFINITY */ | 226 | /* Rocketport EXPRESS/INFINITY */ |
227 | #define PORT_RP2 102 | 227 | #define PORT_RP2 102 |
228 | 228 | ||
229 | /* Freescale lpuart */ | ||
230 | #define PORT_LPUART 103 | ||
231 | |||
232 | /* SH-SCI */ | ||
233 | #define PORT_HSCIF 104 | ||
234 | |||
235 | /* ST ASC type numbers */ | ||
236 | #define PORT_ASC 105 | ||
237 | |||
238 | /* Tilera TILE-Gx UART */ | ||
239 | #define PORT_TILEGX 106 | ||
240 | |||
229 | #endif /* _UAPILINUX_SERIAL_CORE_H */ | 241 | #endif /* _UAPILINUX_SERIAL_CORE_H */ |
diff --git a/include/uapi/linux/snmp.h b/include/uapi/linux/snmp.h index df2e8b4f9c03..1bdb4a39d1e1 100644 --- a/include/uapi/linux/snmp.h +++ b/include/uapi/linux/snmp.h | |||
@@ -51,6 +51,10 @@ enum | |||
51 | IPSTATS_MIB_INBCASTOCTETS, /* InBcastOctets */ | 51 | IPSTATS_MIB_INBCASTOCTETS, /* InBcastOctets */ |
52 | IPSTATS_MIB_OUTBCASTOCTETS, /* OutBcastOctets */ | 52 | IPSTATS_MIB_OUTBCASTOCTETS, /* OutBcastOctets */ |
53 | IPSTATS_MIB_CSUMERRORS, /* InCsumErrors */ | 53 | IPSTATS_MIB_CSUMERRORS, /* InCsumErrors */ |
54 | IPSTATS_MIB_NOECTPKTS, /* InNoECTPkts */ | ||
55 | IPSTATS_MIB_ECT1PKTS, /* InECT1Pkts */ | ||
56 | IPSTATS_MIB_ECT0PKTS, /* InECT0Pkts */ | ||
57 | IPSTATS_MIB_CEPKTS, /* InCEPkts */ | ||
54 | __IPSTATS_MIB_MAX | 58 | __IPSTATS_MIB_MAX |
55 | }; | 59 | }; |
56 | 60 | ||
@@ -253,6 +257,7 @@ enum | |||
253 | LINUX_MIB_TCPFASTOPENLISTENOVERFLOW, /* TCPFastOpenListenOverflow */ | 257 | LINUX_MIB_TCPFASTOPENLISTENOVERFLOW, /* TCPFastOpenListenOverflow */ |
254 | LINUX_MIB_TCPFASTOPENCOOKIEREQD, /* TCPFastOpenCookieReqd */ | 258 | LINUX_MIB_TCPFASTOPENCOOKIEREQD, /* TCPFastOpenCookieReqd */ |
255 | LINUX_MIB_TCPSPURIOUS_RTX_HOSTQUEUES, /* TCPSpuriousRtxHostQueues */ | 259 | LINUX_MIB_TCPSPURIOUS_RTX_HOSTQUEUES, /* TCPSpuriousRtxHostQueues */ |
260 | LINUX_MIB_BUSYPOLLRXPACKETS, /* BusyPollRxPackets */ | ||
256 | __LINUX_MIB_MAX | 261 | __LINUX_MIB_MAX |
257 | }; | 262 | }; |
258 | 263 | ||
@@ -287,6 +292,7 @@ enum | |||
287 | LINUX_MIB_XFRMOUTPOLERROR, /* XfrmOutPolError */ | 292 | LINUX_MIB_XFRMOUTPOLERROR, /* XfrmOutPolError */ |
288 | LINUX_MIB_XFRMFWDHDRERROR, /* XfrmFwdHdrError*/ | 293 | LINUX_MIB_XFRMFWDHDRERROR, /* XfrmFwdHdrError*/ |
289 | LINUX_MIB_XFRMOUTSTATEINVALID, /* XfrmOutStateInvalid */ | 294 | LINUX_MIB_XFRMOUTSTATEINVALID, /* XfrmOutStateInvalid */ |
295 | LINUX_MIB_XFRMACQUIREERROR, /* XfrmAcquireError */ | ||
290 | __LINUX_MIB_XFRMMAX | 296 | __LINUX_MIB_XFRMMAX |
291 | }; | 297 | }; |
292 | 298 | ||
diff --git a/include/uapi/linux/tcp.h b/include/uapi/linux/tcp.h index 8d776ebc4829..377f1e59411d 100644 --- a/include/uapi/linux/tcp.h +++ b/include/uapi/linux/tcp.h | |||
@@ -111,6 +111,7 @@ enum { | |||
111 | #define TCP_REPAIR_OPTIONS 22 | 111 | #define TCP_REPAIR_OPTIONS 22 |
112 | #define TCP_FASTOPEN 23 /* Enable FastOpen on listeners */ | 112 | #define TCP_FASTOPEN 23 /* Enable FastOpen on listeners */ |
113 | #define TCP_TIMESTAMP 24 | 113 | #define TCP_TIMESTAMP 24 |
114 | #define TCP_NOTSENT_LOWAT 25 /* limit number of unsent bytes in write queue */ | ||
114 | 115 | ||
115 | struct tcp_repair_opt { | 116 | struct tcp_repair_opt { |
116 | __u32 opt_code; | 117 | __u32 opt_code; |
diff --git a/include/uapi/linux/tipc.h b/include/uapi/linux/tipc.h index f2d90091cc20..852373d27dbb 100644 --- a/include/uapi/linux/tipc.h +++ b/include/uapi/linux/tipc.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * include/linux/tipc.h: Include file for TIPC socket interface | 2 | * include/uapi/linux/tipc.h: Header for TIPC socket interface |
3 | * | 3 | * |
4 | * Copyright (c) 2003-2006, Ericsson AB | 4 | * Copyright (c) 2003-2006, Ericsson AB |
5 | * Copyright (c) 2005, 2010-2011, Wind River Systems | 5 | * Copyright (c) 2005, 2010-2011, Wind River Systems |
diff --git a/include/uapi/linux/tipc_config.h b/include/uapi/linux/tipc_config.h index 0b1e3f218a36..6b0bff09b3a7 100644 --- a/include/uapi/linux/tipc_config.h +++ b/include/uapi/linux/tipc_config.h | |||
@@ -1,5 +1,5 @@ | |||
1 | /* | 1 | /* |
2 | * include/linux/tipc_config.h: Include file for TIPC configuration interface | 2 | * include/uapi/linux/tipc_config.h: Header for TIPC configuration interface |
3 | * | 3 | * |
4 | * Copyright (c) 2003-2006, Ericsson AB | 4 | * Copyright (c) 2003-2006, Ericsson AB |
5 | * Copyright (c) 2005-2007, 2010-2011, Wind River Systems | 5 | * Copyright (c) 2005-2007, 2010-2011, Wind River Systems |
diff --git a/include/uapi/linux/uhid.h b/include/uapi/linux/uhid.h index e9ed951e2b09..414b74be4da1 100644 --- a/include/uapi/linux/uhid.h +++ b/include/uapi/linux/uhid.h | |||
@@ -30,7 +30,7 @@ enum uhid_event_type { | |||
30 | UHID_OPEN, | 30 | UHID_OPEN, |
31 | UHID_CLOSE, | 31 | UHID_CLOSE, |
32 | UHID_OUTPUT, | 32 | UHID_OUTPUT, |
33 | UHID_OUTPUT_EV, | 33 | UHID_OUTPUT_EV, /* obsolete! */ |
34 | UHID_INPUT, | 34 | UHID_INPUT, |
35 | UHID_FEATURE, | 35 | UHID_FEATURE, |
36 | UHID_FEATURE_ANSWER, | 36 | UHID_FEATURE_ANSWER, |
@@ -69,6 +69,8 @@ struct uhid_output_req { | |||
69 | __u8 rtype; | 69 | __u8 rtype; |
70 | } __attribute__((__packed__)); | 70 | } __attribute__((__packed__)); |
71 | 71 | ||
72 | /* Obsolete! Newer kernels will no longer send these events but instead convert | ||
73 | * it into raw output reports via UHID_OUTPUT. */ | ||
72 | struct uhid_output_ev_req { | 74 | struct uhid_output_ev_req { |
73 | __u16 type; | 75 | __u16 type; |
74 | __u16 code; | 76 | __u16 code; |
diff --git a/include/uapi/linux/usb/ch11.h b/include/uapi/linux/usb/ch11.h index 7692dc69ccf7..331499d597fa 100644 --- a/include/uapi/linux/usb/ch11.h +++ b/include/uapi/linux/usb/ch11.h | |||
@@ -11,6 +11,17 @@ | |||
11 | 11 | ||
12 | #include <linux/types.h> /* __u8 etc */ | 12 | #include <linux/types.h> /* __u8 etc */ |
13 | 13 | ||
14 | /* This is arbitrary. | ||
15 | * From USB 2.0 spec Table 11-13, offset 7, a hub can | ||
16 | * have up to 255 ports. The most yet reported is 10. | ||
17 | * | ||
18 | * Current Wireless USB host hardware (Intel i1480 for example) allows | ||
19 | * up to 22 devices to connect. Upcoming hardware might raise that | ||
20 | * limit. Because the arrays need to add a bit for hub status data, we | ||
21 | * use 31, so plus one evens out to four bytes. | ||
22 | */ | ||
23 | #define USB_MAXCHILDREN 31 | ||
24 | |||
14 | /* | 25 | /* |
15 | * Hub request types | 26 | * Hub request types |
16 | */ | 27 | */ |
diff --git a/include/uapi/linux/v4l2-controls.h b/include/uapi/linux/v4l2-controls.h index 69bd5bb0d5af..083bb5a5aae2 100644 --- a/include/uapi/linux/v4l2-controls.h +++ b/include/uapi/linux/v4l2-controls.h | |||
@@ -53,13 +53,13 @@ | |||
53 | #define V4L2_CTRL_CLASS_USER 0x00980000 /* Old-style 'user' controls */ | 53 | #define V4L2_CTRL_CLASS_USER 0x00980000 /* Old-style 'user' controls */ |
54 | #define V4L2_CTRL_CLASS_MPEG 0x00990000 /* MPEG-compression controls */ | 54 | #define V4L2_CTRL_CLASS_MPEG 0x00990000 /* MPEG-compression controls */ |
55 | #define V4L2_CTRL_CLASS_CAMERA 0x009a0000 /* Camera class controls */ | 55 | #define V4L2_CTRL_CLASS_CAMERA 0x009a0000 /* Camera class controls */ |
56 | #define V4L2_CTRL_CLASS_FM_TX 0x009b0000 /* FM Modulator control class */ | 56 | #define V4L2_CTRL_CLASS_FM_TX 0x009b0000 /* FM Modulator controls */ |
57 | #define V4L2_CTRL_CLASS_FLASH 0x009c0000 /* Camera flash controls */ | 57 | #define V4L2_CTRL_CLASS_FLASH 0x009c0000 /* Camera flash controls */ |
58 | #define V4L2_CTRL_CLASS_JPEG 0x009d0000 /* JPEG-compression controls */ | 58 | #define V4L2_CTRL_CLASS_JPEG 0x009d0000 /* JPEG-compression controls */ |
59 | #define V4L2_CTRL_CLASS_IMAGE_SOURCE 0x009e0000 /* Image source controls */ | 59 | #define V4L2_CTRL_CLASS_IMAGE_SOURCE 0x009e0000 /* Image source controls */ |
60 | #define V4L2_CTRL_CLASS_IMAGE_PROC 0x009f0000 /* Image processing controls */ | 60 | #define V4L2_CTRL_CLASS_IMAGE_PROC 0x009f0000 /* Image processing controls */ |
61 | #define V4L2_CTRL_CLASS_DV 0x00a00000 /* Digital Video controls */ | 61 | #define V4L2_CTRL_CLASS_DV 0x00a00000 /* Digital Video controls */ |
62 | #define V4L2_CTRL_CLASS_FM_RX 0x00a10000 /* Digital Video controls */ | 62 | #define V4L2_CTRL_CLASS_FM_RX 0x00a10000 /* FM Receiver controls */ |
63 | 63 | ||
64 | /* User-class control IDs */ | 64 | /* User-class control IDs */ |
65 | 65 | ||
@@ -161,6 +161,8 @@ enum v4l2_colorfx { | |||
161 | #define V4L2_CID_USER_SI476X_BASE (V4L2_CID_USER_BASE + 0x1040) | 161 | #define V4L2_CID_USER_SI476X_BASE (V4L2_CID_USER_BASE + 0x1040) |
162 | 162 | ||
163 | /* MPEG-class control IDs */ | 163 | /* MPEG-class control IDs */ |
164 | /* The MPEG controls are applicable to all codec controls | ||
165 | * and the 'MPEG' part of the define is historical */ | ||
164 | 166 | ||
165 | #define V4L2_CID_MPEG_BASE (V4L2_CTRL_CLASS_MPEG | 0x900) | 167 | #define V4L2_CID_MPEG_BASE (V4L2_CTRL_CLASS_MPEG | 0x900) |
166 | #define V4L2_CID_MPEG_CLASS (V4L2_CTRL_CLASS_MPEG | 1) | 168 | #define V4L2_CID_MPEG_CLASS (V4L2_CTRL_CLASS_MPEG | 1) |
@@ -522,6 +524,33 @@ enum v4l2_mpeg_video_mpeg4_profile { | |||
522 | }; | 524 | }; |
523 | #define V4L2_CID_MPEG_VIDEO_MPEG4_QPEL (V4L2_CID_MPEG_BASE+407) | 525 | #define V4L2_CID_MPEG_VIDEO_MPEG4_QPEL (V4L2_CID_MPEG_BASE+407) |
524 | 526 | ||
527 | /* Control IDs for VP8 streams | ||
528 | * Although VP8 is not part of MPEG we add these controls to the MPEG class | ||
529 | * as that class is already handling other video compression standards | ||
530 | */ | ||
531 | #define V4L2_CID_MPEG_VIDEO_VPX_NUM_PARTITIONS (V4L2_CID_MPEG_BASE+500) | ||
532 | enum v4l2_vp8_num_partitions { | ||
533 | V4L2_CID_MPEG_VIDEO_VPX_1_PARTITION = 0, | ||
534 | V4L2_CID_MPEG_VIDEO_VPX_2_PARTITIONS = 1, | ||
535 | V4L2_CID_MPEG_VIDEO_VPX_4_PARTITIONS = 2, | ||
536 | V4L2_CID_MPEG_VIDEO_VPX_8_PARTITIONS = 3, | ||
537 | }; | ||
538 | #define V4L2_CID_MPEG_VIDEO_VPX_IMD_DISABLE_4X4 (V4L2_CID_MPEG_BASE+501) | ||
539 | #define V4L2_CID_MPEG_VIDEO_VPX_NUM_REF_FRAMES (V4L2_CID_MPEG_BASE+502) | ||
540 | enum v4l2_vp8_num_ref_frames { | ||
541 | V4L2_CID_MPEG_VIDEO_VPX_1_REF_FRAME = 0, | ||
542 | V4L2_CID_MPEG_VIDEO_VPX_2_REF_FRAME = 1, | ||
543 | V4L2_CID_MPEG_VIDEO_VPX_3_REF_FRAME = 2, | ||
544 | }; | ||
545 | #define V4L2_CID_MPEG_VIDEO_VPX_FILTER_LEVEL (V4L2_CID_MPEG_BASE+503) | ||
546 | #define V4L2_CID_MPEG_VIDEO_VPX_FILTER_SHARPNESS (V4L2_CID_MPEG_BASE+504) | ||
547 | #define V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_REF_PERIOD (V4L2_CID_MPEG_BASE+505) | ||
548 | #define V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_SEL (V4L2_CID_MPEG_BASE+506) | ||
549 | enum v4l2_vp8_golden_frame_sel { | ||
550 | V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_PREV = 0, | ||
551 | V4L2_CID_MPEG_VIDEO_VPX_GOLDEN_FRAME_USE_REF_PERIOD = 1, | ||
552 | }; | ||
553 | |||
525 | /* MPEG-class control IDs specific to the CX2341x driver as defined by V4L2 */ | 554 | /* MPEG-class control IDs specific to the CX2341x driver as defined by V4L2 */ |
526 | #define V4L2_CID_MPEG_CX2341X_BASE (V4L2_CTRL_CLASS_MPEG | 0x1000) | 555 | #define V4L2_CID_MPEG_CX2341X_BASE (V4L2_CTRL_CLASS_MPEG | 0x1000) |
527 | #define V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE (V4L2_CID_MPEG_CX2341X_BASE+0) | 556 | #define V4L2_CID_MPEG_CX2341X_VIDEO_SPATIAL_FILTER_MODE (V4L2_CID_MPEG_CX2341X_BASE+0) |
diff --git a/include/uapi/linux/v4l2-dv-timings.h b/include/uapi/linux/v4l2-dv-timings.h index 4e0c58d25ff0..be709fe29552 100644 --- a/include/uapi/linux/v4l2-dv-timings.h +++ b/include/uapi/linux/v4l2-dv-timings.h | |||
@@ -823,12 +823,4 @@ | |||
823 | V4L2_DV_FL_REDUCED_BLANKING) \ | 823 | V4L2_DV_FL_REDUCED_BLANKING) \ |
824 | } | 824 | } |
825 | 825 | ||
826 | #define V4L2_DV_BT_DMT_1366X768P60 { \ | ||
827 | .type = V4L2_DV_BT_656_1120, \ | ||
828 | V4L2_INIT_BT_TIMINGS(1366, 768, 0, \ | ||
829 | V4L2_DV_HSYNC_POS_POL | V4L2_DV_VSYNC_POS_POL, \ | ||
830 | 85500000, 70, 143, 213, 3, 3, 24, 0, 0, 0, \ | ||
831 | V4L2_DV_BT_STD_DMT, 0) \ | ||
832 | } | ||
833 | |||
834 | #endif | 826 | #endif |
diff --git a/include/uapi/linux/v4l2-mediabus.h b/include/uapi/linux/v4l2-mediabus.h index 6ee63d09b32d..a9601257bb43 100644 --- a/include/uapi/linux/v4l2-mediabus.h +++ b/include/uapi/linux/v4l2-mediabus.h | |||
@@ -37,7 +37,7 @@ | |||
37 | enum v4l2_mbus_pixelcode { | 37 | enum v4l2_mbus_pixelcode { |
38 | V4L2_MBUS_FMT_FIXED = 0x0001, | 38 | V4L2_MBUS_FMT_FIXED = 0x0001, |
39 | 39 | ||
40 | /* RGB - next is 0x100d */ | 40 | /* RGB - next is 0x100e */ |
41 | V4L2_MBUS_FMT_RGB444_2X8_PADHI_BE = 0x1001, | 41 | V4L2_MBUS_FMT_RGB444_2X8_PADHI_BE = 0x1001, |
42 | V4L2_MBUS_FMT_RGB444_2X8_PADHI_LE = 0x1002, | 42 | V4L2_MBUS_FMT_RGB444_2X8_PADHI_LE = 0x1002, |
43 | V4L2_MBUS_FMT_RGB555_2X8_PADHI_BE = 0x1003, | 43 | V4L2_MBUS_FMT_RGB555_2X8_PADHI_BE = 0x1003, |
@@ -50,8 +50,9 @@ enum v4l2_mbus_pixelcode { | |||
50 | V4L2_MBUS_FMT_RGB888_1X24 = 0x100a, | 50 | V4L2_MBUS_FMT_RGB888_1X24 = 0x100a, |
51 | V4L2_MBUS_FMT_RGB888_2X12_BE = 0x100b, | 51 | V4L2_MBUS_FMT_RGB888_2X12_BE = 0x100b, |
52 | V4L2_MBUS_FMT_RGB888_2X12_LE = 0x100c, | 52 | V4L2_MBUS_FMT_RGB888_2X12_LE = 0x100c, |
53 | V4L2_MBUS_FMT_ARGB8888_1X32 = 0x100d, | ||
53 | 54 | ||
54 | /* YUV (including grey) - next is 0x2017 */ | 55 | /* YUV (including grey) - next is 0x2018 */ |
55 | V4L2_MBUS_FMT_Y8_1X8 = 0x2001, | 56 | V4L2_MBUS_FMT_Y8_1X8 = 0x2001, |
56 | V4L2_MBUS_FMT_UV8_1X8 = 0x2015, | 57 | V4L2_MBUS_FMT_UV8_1X8 = 0x2015, |
57 | V4L2_MBUS_FMT_UYVY8_1_5X8 = 0x2002, | 58 | V4L2_MBUS_FMT_UYVY8_1_5X8 = 0x2002, |
@@ -74,6 +75,7 @@ enum v4l2_mbus_pixelcode { | |||
74 | V4L2_MBUS_FMT_YUYV10_1X20 = 0x200d, | 75 | V4L2_MBUS_FMT_YUYV10_1X20 = 0x200d, |
75 | V4L2_MBUS_FMT_YVYU10_1X20 = 0x200e, | 76 | V4L2_MBUS_FMT_YVYU10_1X20 = 0x200e, |
76 | V4L2_MBUS_FMT_YUV10_1X30 = 0x2016, | 77 | V4L2_MBUS_FMT_YUV10_1X30 = 0x2016, |
78 | V4L2_MBUS_FMT_AYUV8_1X32 = 0x2017, | ||
77 | 79 | ||
78 | /* Bayer - next is 0x3019 */ | 80 | /* Bayer - next is 0x3019 */ |
79 | V4L2_MBUS_FMT_SBGGR8_1X8 = 0x3001, | 81 | V4L2_MBUS_FMT_SBGGR8_1X8 = 0x3001, |
diff --git a/include/uapi/linux/vfio.h b/include/uapi/linux/vfio.h index 284ff2436829..916e444e6f74 100644 --- a/include/uapi/linux/vfio.h +++ b/include/uapi/linux/vfio.h | |||
@@ -22,6 +22,7 @@ | |||
22 | /* Extensions */ | 22 | /* Extensions */ |
23 | 23 | ||
24 | #define VFIO_TYPE1_IOMMU 1 | 24 | #define VFIO_TYPE1_IOMMU 1 |
25 | #define VFIO_SPAPR_TCE_IOMMU 2 | ||
25 | 26 | ||
26 | /* | 27 | /* |
27 | * The IOCTL interface is designed for extensibility by embedding the | 28 | * The IOCTL interface is designed for extensibility by embedding the |
@@ -361,10 +362,14 @@ struct vfio_iommu_type1_dma_map { | |||
361 | #define VFIO_IOMMU_MAP_DMA _IO(VFIO_TYPE, VFIO_BASE + 13) | 362 | #define VFIO_IOMMU_MAP_DMA _IO(VFIO_TYPE, VFIO_BASE + 13) |
362 | 363 | ||
363 | /** | 364 | /** |
364 | * VFIO_IOMMU_UNMAP_DMA - _IOW(VFIO_TYPE, VFIO_BASE + 14, struct vfio_dma_unmap) | 365 | * VFIO_IOMMU_UNMAP_DMA - _IOWR(VFIO_TYPE, VFIO_BASE + 14, |
366 | * struct vfio_dma_unmap) | ||
365 | * | 367 | * |
366 | * Unmap IO virtual addresses using the provided struct vfio_dma_unmap. | 368 | * Unmap IO virtual addresses using the provided struct vfio_dma_unmap. |
367 | * Caller sets argsz. | 369 | * Caller sets argsz. The actual unmapped size is returned in the size |
370 | * field. No guarantee is made to the user that arbitrary unmaps of iova | ||
371 | * or size different from those used in the original mapping call will | ||
372 | * succeed. | ||
368 | */ | 373 | */ |
369 | struct vfio_iommu_type1_dma_unmap { | 374 | struct vfio_iommu_type1_dma_unmap { |
370 | __u32 argsz; | 375 | __u32 argsz; |
@@ -375,4 +380,37 @@ struct vfio_iommu_type1_dma_unmap { | |||
375 | 380 | ||
376 | #define VFIO_IOMMU_UNMAP_DMA _IO(VFIO_TYPE, VFIO_BASE + 14) | 381 | #define VFIO_IOMMU_UNMAP_DMA _IO(VFIO_TYPE, VFIO_BASE + 14) |
377 | 382 | ||
383 | /* | ||
384 | * IOCTLs to enable/disable IOMMU container usage. | ||
385 | * No parameters are supported. | ||
386 | */ | ||
387 | #define VFIO_IOMMU_ENABLE _IO(VFIO_TYPE, VFIO_BASE + 15) | ||
388 | #define VFIO_IOMMU_DISABLE _IO(VFIO_TYPE, VFIO_BASE + 16) | ||
389 | |||
390 | /* -------- Additional API for SPAPR TCE (Server POWERPC) IOMMU -------- */ | ||
391 | |||
392 | /* | ||
393 | * The SPAPR TCE info struct provides the information about the PCI bus | ||
394 | * address ranges available for DMA, these values are programmed into | ||
395 | * the hardware so the guest has to know that information. | ||
396 | * | ||
397 | * The DMA 32 bit window start is an absolute PCI bus address. | ||
398 | * The IOVA address passed via map/unmap ioctls are absolute PCI bus | ||
399 | * addresses too so the window works as a filter rather than an offset | ||
400 | * for IOVA addresses. | ||
401 | * | ||
402 | * A flag will need to be added if other page sizes are supported, | ||
403 | * so as defined here, it is always 4k. | ||
404 | */ | ||
405 | struct vfio_iommu_spapr_tce_info { | ||
406 | __u32 argsz; | ||
407 | __u32 flags; /* reserved for future use */ | ||
408 | __u32 dma32_window_start; /* 32 bit window start (bytes) */ | ||
409 | __u32 dma32_window_size; /* 32 bit window size (bytes) */ | ||
410 | }; | ||
411 | |||
412 | #define VFIO_IOMMU_SPAPR_TCE_GET_INFO _IO(VFIO_TYPE, VFIO_BASE + 12) | ||
413 | |||
414 | /* ***************************************************************** */ | ||
415 | |||
378 | #endif /* _UAPIVFIO_H */ | 416 | #endif /* _UAPIVFIO_H */ |
diff --git a/include/uapi/linux/videodev2.h b/include/uapi/linux/videodev2.h index f40b41c7e108..437f1b0f8937 100644 --- a/include/uapi/linux/videodev2.h +++ b/include/uapi/linux/videodev2.h | |||
@@ -348,6 +348,8 @@ struct v4l2_pix_format { | |||
348 | /* two non contiguous planes - one Y, one Cr + Cb interleaved */ | 348 | /* two non contiguous planes - one Y, one Cr + Cb interleaved */ |
349 | #define V4L2_PIX_FMT_NV12M v4l2_fourcc('N', 'M', '1', '2') /* 12 Y/CbCr 4:2:0 */ | 349 | #define V4L2_PIX_FMT_NV12M v4l2_fourcc('N', 'M', '1', '2') /* 12 Y/CbCr 4:2:0 */ |
350 | #define V4L2_PIX_FMT_NV21M v4l2_fourcc('N', 'M', '2', '1') /* 21 Y/CrCb 4:2:0 */ | 350 | #define V4L2_PIX_FMT_NV21M v4l2_fourcc('N', 'M', '2', '1') /* 21 Y/CrCb 4:2:0 */ |
351 | #define V4L2_PIX_FMT_NV16M v4l2_fourcc('N', 'M', '1', '6') /* 16 Y/CbCr 4:2:2 */ | ||
352 | #define V4L2_PIX_FMT_NV61M v4l2_fourcc('N', 'M', '6', '1') /* 16 Y/CrCb 4:2:2 */ | ||
351 | #define V4L2_PIX_FMT_NV12MT v4l2_fourcc('T', 'M', '1', '2') /* 12 Y/CbCr 4:2:0 64x32 macroblocks */ | 353 | #define V4L2_PIX_FMT_NV12MT v4l2_fourcc('T', 'M', '1', '2') /* 12 Y/CbCr 4:2:0 64x32 macroblocks */ |
352 | #define V4L2_PIX_FMT_NV12MT_16X16 v4l2_fourcc('V', 'M', '1', '2') /* 12 Y/CbCr 4:2:0 16x16 macroblocks */ | 354 | #define V4L2_PIX_FMT_NV12MT_16X16 v4l2_fourcc('V', 'M', '1', '2') /* 12 Y/CbCr 4:2:0 16x16 macroblocks */ |
353 | 355 | ||
@@ -395,7 +397,7 @@ struct v4l2_pix_format { | |||
395 | #define V4L2_PIX_FMT_H263 v4l2_fourcc('H', '2', '6', '3') /* H263 */ | 397 | #define V4L2_PIX_FMT_H263 v4l2_fourcc('H', '2', '6', '3') /* H263 */ |
396 | #define V4L2_PIX_FMT_MPEG1 v4l2_fourcc('M', 'P', 'G', '1') /* MPEG-1 ES */ | 398 | #define V4L2_PIX_FMT_MPEG1 v4l2_fourcc('M', 'P', 'G', '1') /* MPEG-1 ES */ |
397 | #define V4L2_PIX_FMT_MPEG2 v4l2_fourcc('M', 'P', 'G', '2') /* MPEG-2 ES */ | 399 | #define V4L2_PIX_FMT_MPEG2 v4l2_fourcc('M', 'P', 'G', '2') /* MPEG-2 ES */ |
398 | #define V4L2_PIX_FMT_MPEG4 v4l2_fourcc('M', 'P', 'G', '4') /* MPEG-4 ES */ | 400 | #define V4L2_PIX_FMT_MPEG4 v4l2_fourcc('M', 'P', 'G', '4') /* MPEG-4 part 2 ES */ |
399 | #define V4L2_PIX_FMT_XVID v4l2_fourcc('X', 'V', 'I', 'D') /* Xvid */ | 401 | #define V4L2_PIX_FMT_XVID v4l2_fourcc('X', 'V', 'I', 'D') /* Xvid */ |
400 | #define V4L2_PIX_FMT_VC1_ANNEX_G v4l2_fourcc('V', 'C', '1', 'G') /* SMPTE 421M Annex G compliant stream */ | 402 | #define V4L2_PIX_FMT_VC1_ANNEX_G v4l2_fourcc('V', 'C', '1', 'G') /* SMPTE 421M Annex G compliant stream */ |
401 | #define V4L2_PIX_FMT_VC1_ANNEX_L v4l2_fourcc('V', 'C', '1', 'L') /* SMPTE 421M Annex L compliant stream */ | 403 | #define V4L2_PIX_FMT_VC1_ANNEX_L v4l2_fourcc('V', 'C', '1', 'L') /* SMPTE 421M Annex L compliant stream */ |
@@ -555,7 +557,7 @@ struct v4l2_jpegcompression { | |||
555 | __u32 jpeg_markers; /* Which markers should go into the JPEG | 557 | __u32 jpeg_markers; /* Which markers should go into the JPEG |
556 | * output. Unless you exactly know what | 558 | * output. Unless you exactly know what |
557 | * you do, leave them untouched. | 559 | * you do, leave them untouched. |
558 | * Inluding less markers will make the | 560 | * Including less markers will make the |
559 | * resulting code smaller, but there will | 561 | * resulting code smaller, but there will |
560 | * be fewer applications which can read it. | 562 | * be fewer applications which can read it. |
561 | * The presence of the APP and COM marker | 563 | * The presence of the APP and COM marker |
@@ -567,7 +569,7 @@ struct v4l2_jpegcompression { | |||
567 | #define V4L2_JPEG_MARKER_DRI (1<<5) /* Define Restart Interval */ | 569 | #define V4L2_JPEG_MARKER_DRI (1<<5) /* Define Restart Interval */ |
568 | #define V4L2_JPEG_MARKER_COM (1<<6) /* Comment segment */ | 570 | #define V4L2_JPEG_MARKER_COM (1<<6) /* Comment segment */ |
569 | #define V4L2_JPEG_MARKER_APP (1<<7) /* App segment, driver will | 571 | #define V4L2_JPEG_MARKER_APP (1<<7) /* App segment, driver will |
570 | * allways use APP0 */ | 572 | * always use APP0 */ |
571 | }; | 573 | }; |
572 | 574 | ||
573 | /* | 575 | /* |
@@ -900,7 +902,7 @@ typedef __u64 v4l2_std_id; | |||
900 | /* | 902 | /* |
901 | * "Common" PAL - This macro is there to be compatible with the old | 903 | * "Common" PAL - This macro is there to be compatible with the old |
902 | * V4L1 concept of "PAL": /BGDKHI. | 904 | * V4L1 concept of "PAL": /BGDKHI. |
903 | * Several PAL standards are mising here: /M, /N and /Nc | 905 | * Several PAL standards are missing here: /M, /N and /Nc |
904 | */ | 906 | */ |
905 | #define V4L2_STD_PAL (V4L2_STD_PAL_BG |\ | 907 | #define V4L2_STD_PAL (V4L2_STD_PAL_BG |\ |
906 | V4L2_STD_PAL_DK |\ | 908 | V4L2_STD_PAL_DK |\ |
@@ -1055,6 +1057,16 @@ struct v4l2_bt_timings { | |||
1055 | or used depends on the hardware. */ | 1057 | or used depends on the hardware. */ |
1056 | #define V4L2_DV_FL_HALF_LINE (1 << 3) | 1058 | #define V4L2_DV_FL_HALF_LINE (1 << 3) |
1057 | 1059 | ||
1060 | /* A few useful defines to calculate the total blanking and frame sizes */ | ||
1061 | #define V4L2_DV_BT_BLANKING_WIDTH(bt) \ | ||
1062 | (bt->hfrontporch + bt->hsync + bt->hbackporch) | ||
1063 | #define V4L2_DV_BT_FRAME_WIDTH(bt) \ | ||
1064 | (bt->width + V4L2_DV_BT_BLANKING_WIDTH(bt)) | ||
1065 | #define V4L2_DV_BT_BLANKING_HEIGHT(bt) \ | ||
1066 | (bt->vfrontporch + bt->vsync + bt->vbackporch + \ | ||
1067 | bt->il_vfrontporch + bt->il_vsync + bt->il_vbackporch) | ||
1068 | #define V4L2_DV_BT_FRAME_HEIGHT(bt) \ | ||
1069 | (bt->height + V4L2_DV_BT_BLANKING_HEIGHT(bt)) | ||
1058 | 1070 | ||
1059 | /** struct v4l2_dv_timings - DV timings | 1071 | /** struct v4l2_dv_timings - DV timings |
1060 | * @type: the type of the timings | 1072 | * @type: the type of the timings |
@@ -1787,11 +1799,13 @@ struct v4l2_event_subscription { | |||
1787 | /* VIDIOC_DBG_G_REGISTER and VIDIOC_DBG_S_REGISTER */ | 1799 | /* VIDIOC_DBG_G_REGISTER and VIDIOC_DBG_S_REGISTER */ |
1788 | 1800 | ||
1789 | #define V4L2_CHIP_MATCH_BRIDGE 0 /* Match against chip ID on the bridge (0 for the bridge) */ | 1801 | #define V4L2_CHIP_MATCH_BRIDGE 0 /* Match against chip ID on the bridge (0 for the bridge) */ |
1802 | #define V4L2_CHIP_MATCH_SUBDEV 4 /* Match against subdev index */ | ||
1803 | |||
1804 | /* The following four defines are no longer in use */ | ||
1790 | #define V4L2_CHIP_MATCH_HOST V4L2_CHIP_MATCH_BRIDGE | 1805 | #define V4L2_CHIP_MATCH_HOST V4L2_CHIP_MATCH_BRIDGE |
1791 | #define V4L2_CHIP_MATCH_I2C_DRIVER 1 /* Match against I2C driver name */ | 1806 | #define V4L2_CHIP_MATCH_I2C_DRIVER 1 /* Match against I2C driver name */ |
1792 | #define V4L2_CHIP_MATCH_I2C_ADDR 2 /* Match against I2C 7-bit address */ | 1807 | #define V4L2_CHIP_MATCH_I2C_ADDR 2 /* Match against I2C 7-bit address */ |
1793 | #define V4L2_CHIP_MATCH_AC97 3 /* Match against anciliary AC97 chip */ | 1808 | #define V4L2_CHIP_MATCH_AC97 3 /* Match against ancillary AC97 chip */ |
1794 | #define V4L2_CHIP_MATCH_SUBDEV 4 /* Match against subdev index */ | ||
1795 | 1809 | ||
1796 | struct v4l2_dbg_match { | 1810 | struct v4l2_dbg_match { |
1797 | __u32 type; /* Match type */ | 1811 | __u32 type; /* Match type */ |
@@ -1808,13 +1822,6 @@ struct v4l2_dbg_register { | |||
1808 | __u64 val; | 1822 | __u64 val; |
1809 | } __attribute__ ((packed)); | 1823 | } __attribute__ ((packed)); |
1810 | 1824 | ||
1811 | /* VIDIOC_DBG_G_CHIP_IDENT */ | ||
1812 | struct v4l2_dbg_chip_ident { | ||
1813 | struct v4l2_dbg_match match; | ||
1814 | __u32 ident; /* chip identifier as specified in <media/v4l2-chip-ident.h> */ | ||
1815 | __u32 revision; /* chip revision, chip specific */ | ||
1816 | } __attribute__ ((packed)); | ||
1817 | |||
1818 | #define V4L2_CHIP_FL_READABLE (1 << 0) | 1825 | #define V4L2_CHIP_FL_READABLE (1 << 0) |
1819 | #define V4L2_CHIP_FL_WRITABLE (1 << 1) | 1826 | #define V4L2_CHIP_FL_WRITABLE (1 << 1) |
1820 | 1827 | ||
@@ -1915,12 +1922,6 @@ struct v4l2_create_buffers { | |||
1915 | #define VIDIOC_DBG_S_REGISTER _IOW('V', 79, struct v4l2_dbg_register) | 1922 | #define VIDIOC_DBG_S_REGISTER _IOW('V', 79, struct v4l2_dbg_register) |
1916 | #define VIDIOC_DBG_G_REGISTER _IOWR('V', 80, struct v4l2_dbg_register) | 1923 | #define VIDIOC_DBG_G_REGISTER _IOWR('V', 80, struct v4l2_dbg_register) |
1917 | 1924 | ||
1918 | /* Experimental, meant for debugging, testing and internal use. | ||
1919 | Never use this ioctl in applications! | ||
1920 | Note: this ioctl is deprecated in favor of VIDIOC_DBG_G_CHIP_INFO and | ||
1921 | will go away in the future. */ | ||
1922 | #define VIDIOC_DBG_G_CHIP_IDENT _IOWR('V', 81, struct v4l2_dbg_chip_ident) | ||
1923 | |||
1924 | #define VIDIOC_S_HW_FREQ_SEEK _IOW('V', 82, struct v4l2_hw_freq_seek) | 1925 | #define VIDIOC_S_HW_FREQ_SEEK _IOW('V', 82, struct v4l2_hw_freq_seek) |
1925 | 1926 | ||
1926 | #define VIDIOC_S_DV_TIMINGS _IOWR('V', 87, struct v4l2_dv_timings) | 1927 | #define VIDIOC_S_DV_TIMINGS _IOWR('V', 87, struct v4l2_dv_timings) |
diff --git a/include/uapi/linux/virtio_config.h b/include/uapi/linux/virtio_config.h index b7cda390fd00..3ce768c6910d 100644 --- a/include/uapi/linux/virtio_config.h +++ b/include/uapi/linux/virtio_config.h | |||
@@ -51,4 +51,7 @@ | |||
51 | * suppressed them? */ | 51 | * suppressed them? */ |
52 | #define VIRTIO_F_NOTIFY_ON_EMPTY 24 | 52 | #define VIRTIO_F_NOTIFY_ON_EMPTY 24 |
53 | 53 | ||
54 | /* Can the device handle any descriptor layout? */ | ||
55 | #define VIRTIO_F_ANY_LAYOUT 27 | ||
56 | |||
54 | #endif /* _UAPI_LINUX_VIRTIO_CONFIG_H */ | 57 | #endif /* _UAPI_LINUX_VIRTIO_CONFIG_H */ |
diff --git a/include/uapi/linux/virtio_console.h b/include/uapi/linux/virtio_console.h index c312f16bc4e7..ba260dd0b33a 100644 --- a/include/uapi/linux/virtio_console.h +++ b/include/uapi/linux/virtio_console.h | |||
@@ -38,6 +38,7 @@ | |||
38 | /* Feature bits */ | 38 | /* Feature bits */ |
39 | #define VIRTIO_CONSOLE_F_SIZE 0 /* Does host provide console size? */ | 39 | #define VIRTIO_CONSOLE_F_SIZE 0 /* Does host provide console size? */ |
40 | #define VIRTIO_CONSOLE_F_MULTIPORT 1 /* Does host provide multiple ports? */ | 40 | #define VIRTIO_CONSOLE_F_MULTIPORT 1 /* Does host provide multiple ports? */ |
41 | #define VIRTIO_CONSOLE_F_EMERG_WRITE 2 /* Does host support emergency write? */ | ||
41 | 42 | ||
42 | #define VIRTIO_CONSOLE_BAD_ID (~(__u32)0) | 43 | #define VIRTIO_CONSOLE_BAD_ID (~(__u32)0) |
43 | 44 | ||
@@ -48,6 +49,8 @@ struct virtio_console_config { | |||
48 | __u16 rows; | 49 | __u16 rows; |
49 | /* max. number of ports this device can hold */ | 50 | /* max. number of ports this device can hold */ |
50 | __u32 max_nr_ports; | 51 | __u32 max_nr_ports; |
52 | /* emergency write register */ | ||
53 | __u32 emerg_wr; | ||
51 | } __attribute__((packed)); | 54 | } __attribute__((packed)); |
52 | 55 | ||
53 | /* | 56 | /* |
diff --git a/include/uapi/linux/virtio_net.h b/include/uapi/linux/virtio_net.h index c520203fac2f..172a7f00780c 100644 --- a/include/uapi/linux/virtio_net.h +++ b/include/uapi/linux/virtio_net.h | |||
@@ -60,7 +60,7 @@ | |||
60 | 60 | ||
61 | struct virtio_net_config { | 61 | struct virtio_net_config { |
62 | /* The config defining mac address (if VIRTIO_NET_F_MAC) */ | 62 | /* The config defining mac address (if VIRTIO_NET_F_MAC) */ |
63 | __u8 mac[6]; | 63 | __u8 mac[ETH_ALEN]; |
64 | /* See VIRTIO_NET_F_STATUS and VIRTIO_NET_S_* above */ | 64 | /* See VIRTIO_NET_F_STATUS and VIRTIO_NET_S_* above */ |
65 | __u16 status; | 65 | __u16 status; |
66 | /* Maximum number of each of transmit and receive queues; | 66 | /* Maximum number of each of transmit and receive queues; |
@@ -70,7 +70,9 @@ struct virtio_net_config { | |||
70 | __u16 max_virtqueue_pairs; | 70 | __u16 max_virtqueue_pairs; |
71 | } __attribute__((packed)); | 71 | } __attribute__((packed)); |
72 | 72 | ||
73 | /* This is the first element of the scatter-gather list. If you don't | 73 | /* This header comes first in the scatter-gather list. |
74 | * If VIRTIO_F_ANY_LAYOUT is not negotiated, it must | ||
75 | * be the first element of the scatter-gather list. If you don't | ||
74 | * specify GSO or CSUM features, you can simply ignore the header. */ | 76 | * specify GSO or CSUM features, you can simply ignore the header. */ |
75 | struct virtio_net_hdr { | 77 | struct virtio_net_hdr { |
76 | #define VIRTIO_NET_HDR_F_NEEDS_CSUM 1 // Use csum_start, csum_offset | 78 | #define VIRTIO_NET_HDR_F_NEEDS_CSUM 1 // Use csum_start, csum_offset |
diff --git a/include/uapi/linux/virtio_pci.h b/include/uapi/linux/virtio_pci.h index ea66f3f60d63..e5ec1caab82a 100644 --- a/include/uapi/linux/virtio_pci.h +++ b/include/uapi/linux/virtio_pci.h | |||
@@ -80,7 +80,9 @@ | |||
80 | 80 | ||
81 | /* The remaining space is defined by each driver as the per-driver | 81 | /* The remaining space is defined by each driver as the per-driver |
82 | * configuration space */ | 82 | * configuration space */ |
83 | #define VIRTIO_PCI_CONFIG(dev) ((dev)->msix_enabled ? 24 : 20) | 83 | #define VIRTIO_PCI_CONFIG_OFF(msix_enabled) ((msix_enabled) ? 24 : 20) |
84 | /* Deprecated: please use VIRTIO_PCI_CONFIG_OFF instead */ | ||
85 | #define VIRTIO_PCI_CONFIG(dev) VIRTIO_PCI_CONFIG_OFF((dev)->msix_enabled) | ||
84 | 86 | ||
85 | /* Virtio ABI version, this must match exactly */ | 87 | /* Virtio ABI version, this must match exactly */ |
86 | #define VIRTIO_PCI_ABI_VERSION 0 | 88 | #define VIRTIO_PCI_ABI_VERSION 0 |
diff --git a/include/uapi/linux/wimax/i2400m.h b/include/uapi/linux/wimax/i2400m.h index 62d356153565..fd198bc24a3c 100644 --- a/include/uapi/linux/wimax/i2400m.h +++ b/include/uapi/linux/wimax/i2400m.h | |||
@@ -122,7 +122,7 @@ | |||
122 | #define __LINUX__WIMAX__I2400M_H__ | 122 | #define __LINUX__WIMAX__I2400M_H__ |
123 | 123 | ||
124 | #include <linux/types.h> | 124 | #include <linux/types.h> |
125 | 125 | #include <linux/if_ether.h> | |
126 | 126 | ||
127 | /* | 127 | /* |
128 | * Host Device Interface (HDI) common to all busses | 128 | * Host Device Interface (HDI) common to all busses |
@@ -487,7 +487,7 @@ struct i2400m_tlv_l4_message_versions { | |||
487 | struct i2400m_tlv_detailed_device_info { | 487 | struct i2400m_tlv_detailed_device_info { |
488 | struct i2400m_tlv_hdr hdr; | 488 | struct i2400m_tlv_hdr hdr; |
489 | __u8 reserved1[400]; | 489 | __u8 reserved1[400]; |
490 | __u8 mac_address[6]; | 490 | __u8 mac_address[ETH_ALEN]; |
491 | __u8 reserved2[2]; | 491 | __u8 reserved2[2]; |
492 | } __attribute__((packed)); | 492 | } __attribute__((packed)); |
493 | 493 | ||
diff --git a/include/uapi/mtd/ubi-user.h b/include/uapi/mtd/ubi-user.h index 53cae1e11e57..723c324590c1 100644 --- a/include/uapi/mtd/ubi-user.h +++ b/include/uapi/mtd/ubi-user.h | |||
@@ -173,7 +173,10 @@ | |||
173 | 173 | ||
174 | #define UBI_VOL_IOC_MAGIC 'O' | 174 | #define UBI_VOL_IOC_MAGIC 'O' |
175 | 175 | ||
176 | /* Start UBI volume update */ | 176 | /* Start UBI volume update |
177 | * Note: This actually takes a pointer (__s64*), but we can't change | ||
178 | * that without breaking the ABI on 32bit systems | ||
179 | */ | ||
177 | #define UBI_IOCVOLUP _IOW(UBI_VOL_IOC_MAGIC, 0, __s64) | 180 | #define UBI_IOCVOLUP _IOW(UBI_VOL_IOC_MAGIC, 0, __s64) |
178 | /* LEB erasure command, used for debugging, disabled by default */ | 181 | /* LEB erasure command, used for debugging, disabled by default */ |
179 | #define UBI_IOCEBER _IOW(UBI_VOL_IOC_MAGIC, 1, __s32) | 182 | #define UBI_IOCEBER _IOW(UBI_VOL_IOC_MAGIC, 1, __s32) |
diff --git a/include/uapi/rdma/ib_user_verbs.h b/include/uapi/rdma/ib_user_verbs.h index 805711ea2005..0b233c56b0e4 100644 --- a/include/uapi/rdma/ib_user_verbs.h +++ b/include/uapi/rdma/ib_user_verbs.h | |||
@@ -43,6 +43,7 @@ | |||
43 | * compatibility are made. | 43 | * compatibility are made. |
44 | */ | 44 | */ |
45 | #define IB_USER_VERBS_ABI_VERSION 6 | 45 | #define IB_USER_VERBS_ABI_VERSION 6 |
46 | #define IB_USER_VERBS_CMD_THRESHOLD 50 | ||
46 | 47 | ||
47 | enum { | 48 | enum { |
48 | IB_USER_VERBS_CMD_GET_CONTEXT, | 49 | IB_USER_VERBS_CMD_GET_CONTEXT, |
@@ -85,7 +86,9 @@ enum { | |||
85 | IB_USER_VERBS_CMD_OPEN_XRCD, | 86 | IB_USER_VERBS_CMD_OPEN_XRCD, |
86 | IB_USER_VERBS_CMD_CLOSE_XRCD, | 87 | IB_USER_VERBS_CMD_CLOSE_XRCD, |
87 | IB_USER_VERBS_CMD_CREATE_XSRQ, | 88 | IB_USER_VERBS_CMD_CREATE_XSRQ, |
88 | IB_USER_VERBS_CMD_OPEN_QP | 89 | IB_USER_VERBS_CMD_OPEN_QP, |
90 | IB_USER_VERBS_CMD_CREATE_FLOW = IB_USER_VERBS_CMD_THRESHOLD, | ||
91 | IB_USER_VERBS_CMD_DESTROY_FLOW | ||
89 | }; | 92 | }; |
90 | 93 | ||
91 | /* | 94 | /* |
@@ -123,6 +126,15 @@ struct ib_uverbs_cmd_hdr { | |||
123 | __u16 out_words; | 126 | __u16 out_words; |
124 | }; | 127 | }; |
125 | 128 | ||
129 | struct ib_uverbs_cmd_hdr_ex { | ||
130 | __u32 command; | ||
131 | __u16 in_words; | ||
132 | __u16 out_words; | ||
133 | __u16 provider_in_words; | ||
134 | __u16 provider_out_words; | ||
135 | __u32 cmd_hdr_reserved; | ||
136 | }; | ||
137 | |||
126 | struct ib_uverbs_get_context { | 138 | struct ib_uverbs_get_context { |
127 | __u64 response; | 139 | __u64 response; |
128 | __u64 driver_data[0]; | 140 | __u64 driver_data[0]; |
@@ -684,6 +696,91 @@ struct ib_uverbs_detach_mcast { | |||
684 | __u64 driver_data[0]; | 696 | __u64 driver_data[0]; |
685 | }; | 697 | }; |
686 | 698 | ||
699 | struct ib_kern_eth_filter { | ||
700 | __u8 dst_mac[6]; | ||
701 | __u8 src_mac[6]; | ||
702 | __be16 ether_type; | ||
703 | __be16 vlan_tag; | ||
704 | }; | ||
705 | |||
706 | struct ib_kern_spec_eth { | ||
707 | __u32 type; | ||
708 | __u16 size; | ||
709 | __u16 reserved; | ||
710 | struct ib_kern_eth_filter val; | ||
711 | struct ib_kern_eth_filter mask; | ||
712 | }; | ||
713 | |||
714 | struct ib_kern_ipv4_filter { | ||
715 | __be32 src_ip; | ||
716 | __be32 dst_ip; | ||
717 | }; | ||
718 | |||
719 | struct ib_kern_spec_ipv4 { | ||
720 | __u32 type; | ||
721 | __u16 size; | ||
722 | __u16 reserved; | ||
723 | struct ib_kern_ipv4_filter val; | ||
724 | struct ib_kern_ipv4_filter mask; | ||
725 | }; | ||
726 | |||
727 | struct ib_kern_tcp_udp_filter { | ||
728 | __be16 dst_port; | ||
729 | __be16 src_port; | ||
730 | }; | ||
731 | |||
732 | struct ib_kern_spec_tcp_udp { | ||
733 | __u32 type; | ||
734 | __u16 size; | ||
735 | __u16 reserved; | ||
736 | struct ib_kern_tcp_udp_filter val; | ||
737 | struct ib_kern_tcp_udp_filter mask; | ||
738 | }; | ||
739 | |||
740 | struct ib_kern_spec { | ||
741 | union { | ||
742 | struct { | ||
743 | __u32 type; | ||
744 | __u16 size; | ||
745 | __u16 reserved; | ||
746 | }; | ||
747 | struct ib_kern_spec_eth eth; | ||
748 | struct ib_kern_spec_ipv4 ipv4; | ||
749 | struct ib_kern_spec_tcp_udp tcp_udp; | ||
750 | }; | ||
751 | }; | ||
752 | |||
753 | struct ib_kern_flow_attr { | ||
754 | __u32 type; | ||
755 | __u16 size; | ||
756 | __u16 priority; | ||
757 | __u8 num_of_specs; | ||
758 | __u8 reserved[2]; | ||
759 | __u8 port; | ||
760 | __u32 flags; | ||
761 | /* Following are the optional layers according to user request | ||
762 | * struct ib_flow_spec_xxx | ||
763 | * struct ib_flow_spec_yyy | ||
764 | */ | ||
765 | }; | ||
766 | |||
767 | struct ib_uverbs_create_flow { | ||
768 | __u32 comp_mask; | ||
769 | __u64 response; | ||
770 | __u32 qp_handle; | ||
771 | struct ib_kern_flow_attr flow_attr; | ||
772 | }; | ||
773 | |||
774 | struct ib_uverbs_create_flow_resp { | ||
775 | __u32 comp_mask; | ||
776 | __u32 flow_handle; | ||
777 | }; | ||
778 | |||
779 | struct ib_uverbs_destroy_flow { | ||
780 | __u32 comp_mask; | ||
781 | __u32 flow_handle; | ||
782 | }; | ||
783 | |||
687 | struct ib_uverbs_create_srq { | 784 | struct ib_uverbs_create_srq { |
688 | __u64 response; | 785 | __u64 response; |
689 | __u64 user_handle; | 786 | __u64 user_handle; |
diff --git a/include/uapi/rdma/rdma_user_cm.h b/include/uapi/rdma/rdma_user_cm.h index 1ee9239ff8c2..99b80abf360a 100644 --- a/include/uapi/rdma/rdma_user_cm.h +++ b/include/uapi/rdma/rdma_user_cm.h | |||
@@ -45,8 +45,8 @@ | |||
45 | enum { | 45 | enum { |
46 | RDMA_USER_CM_CMD_CREATE_ID, | 46 | RDMA_USER_CM_CMD_CREATE_ID, |
47 | RDMA_USER_CM_CMD_DESTROY_ID, | 47 | RDMA_USER_CM_CMD_DESTROY_ID, |
48 | RDMA_USER_CM_CMD_BIND_ADDR, | 48 | RDMA_USER_CM_CMD_BIND_IP, |
49 | RDMA_USER_CM_CMD_RESOLVE_ADDR, | 49 | RDMA_USER_CM_CMD_RESOLVE_IP, |
50 | RDMA_USER_CM_CMD_RESOLVE_ROUTE, | 50 | RDMA_USER_CM_CMD_RESOLVE_ROUTE, |
51 | RDMA_USER_CM_CMD_QUERY_ROUTE, | 51 | RDMA_USER_CM_CMD_QUERY_ROUTE, |
52 | RDMA_USER_CM_CMD_CONNECT, | 52 | RDMA_USER_CM_CMD_CONNECT, |
@@ -59,9 +59,13 @@ enum { | |||
59 | RDMA_USER_CM_CMD_GET_OPTION, | 59 | RDMA_USER_CM_CMD_GET_OPTION, |
60 | RDMA_USER_CM_CMD_SET_OPTION, | 60 | RDMA_USER_CM_CMD_SET_OPTION, |
61 | RDMA_USER_CM_CMD_NOTIFY, | 61 | RDMA_USER_CM_CMD_NOTIFY, |
62 | RDMA_USER_CM_CMD_JOIN_MCAST, | 62 | RDMA_USER_CM_CMD_JOIN_IP_MCAST, |
63 | RDMA_USER_CM_CMD_LEAVE_MCAST, | 63 | RDMA_USER_CM_CMD_LEAVE_MCAST, |
64 | RDMA_USER_CM_CMD_MIGRATE_ID | 64 | RDMA_USER_CM_CMD_MIGRATE_ID, |
65 | RDMA_USER_CM_CMD_QUERY, | ||
66 | RDMA_USER_CM_CMD_BIND, | ||
67 | RDMA_USER_CM_CMD_RESOLVE_ADDR, | ||
68 | RDMA_USER_CM_CMD_JOIN_MCAST | ||
65 | }; | 69 | }; |
66 | 70 | ||
67 | /* | 71 | /* |
@@ -95,28 +99,51 @@ struct rdma_ucm_destroy_id_resp { | |||
95 | __u32 events_reported; | 99 | __u32 events_reported; |
96 | }; | 100 | }; |
97 | 101 | ||
98 | struct rdma_ucm_bind_addr { | 102 | struct rdma_ucm_bind_ip { |
99 | __u64 response; | 103 | __u64 response; |
100 | struct sockaddr_in6 addr; | 104 | struct sockaddr_in6 addr; |
101 | __u32 id; | 105 | __u32 id; |
102 | }; | 106 | }; |
103 | 107 | ||
104 | struct rdma_ucm_resolve_addr { | 108 | struct rdma_ucm_bind { |
109 | __u32 id; | ||
110 | __u16 addr_size; | ||
111 | __u16 reserved; | ||
112 | struct sockaddr_storage addr; | ||
113 | }; | ||
114 | |||
115 | struct rdma_ucm_resolve_ip { | ||
105 | struct sockaddr_in6 src_addr; | 116 | struct sockaddr_in6 src_addr; |
106 | struct sockaddr_in6 dst_addr; | 117 | struct sockaddr_in6 dst_addr; |
107 | __u32 id; | 118 | __u32 id; |
108 | __u32 timeout_ms; | 119 | __u32 timeout_ms; |
109 | }; | 120 | }; |
110 | 121 | ||
122 | struct rdma_ucm_resolve_addr { | ||
123 | __u32 id; | ||
124 | __u32 timeout_ms; | ||
125 | __u16 src_size; | ||
126 | __u16 dst_size; | ||
127 | __u32 reserved; | ||
128 | struct sockaddr_storage src_addr; | ||
129 | struct sockaddr_storage dst_addr; | ||
130 | }; | ||
131 | |||
111 | struct rdma_ucm_resolve_route { | 132 | struct rdma_ucm_resolve_route { |
112 | __u32 id; | 133 | __u32 id; |
113 | __u32 timeout_ms; | 134 | __u32 timeout_ms; |
114 | }; | 135 | }; |
115 | 136 | ||
116 | struct rdma_ucm_query_route { | 137 | enum { |
138 | RDMA_USER_CM_QUERY_ADDR, | ||
139 | RDMA_USER_CM_QUERY_PATH, | ||
140 | RDMA_USER_CM_QUERY_GID | ||
141 | }; | ||
142 | |||
143 | struct rdma_ucm_query { | ||
117 | __u64 response; | 144 | __u64 response; |
118 | __u32 id; | 145 | __u32 id; |
119 | __u32 reserved; | 146 | __u32 option; |
120 | }; | 147 | }; |
121 | 148 | ||
122 | struct rdma_ucm_query_route_resp { | 149 | struct rdma_ucm_query_route_resp { |
@@ -129,9 +156,26 @@ struct rdma_ucm_query_route_resp { | |||
129 | __u8 reserved[3]; | 156 | __u8 reserved[3]; |
130 | }; | 157 | }; |
131 | 158 | ||
159 | struct rdma_ucm_query_addr_resp { | ||
160 | __u64 node_guid; | ||
161 | __u8 port_num; | ||
162 | __u8 reserved; | ||
163 | __u16 pkey; | ||
164 | __u16 src_size; | ||
165 | __u16 dst_size; | ||
166 | struct sockaddr_storage src_addr; | ||
167 | struct sockaddr_storage dst_addr; | ||
168 | }; | ||
169 | |||
170 | struct rdma_ucm_query_path_resp { | ||
171 | __u32 num_paths; | ||
172 | __u32 reserved; | ||
173 | struct ib_path_rec_data path_data[0]; | ||
174 | }; | ||
175 | |||
132 | struct rdma_ucm_conn_param { | 176 | struct rdma_ucm_conn_param { |
133 | __u32 qp_num; | 177 | __u32 qp_num; |
134 | __u32 reserved; | 178 | __u32 qkey; |
135 | __u8 private_data[RDMA_MAX_PRIVATE_DATA]; | 179 | __u8 private_data[RDMA_MAX_PRIVATE_DATA]; |
136 | __u8 private_data_len; | 180 | __u8 private_data_len; |
137 | __u8 srq; | 181 | __u8 srq; |
@@ -192,13 +236,22 @@ struct rdma_ucm_notify { | |||
192 | __u32 event; | 236 | __u32 event; |
193 | }; | 237 | }; |
194 | 238 | ||
195 | struct rdma_ucm_join_mcast { | 239 | struct rdma_ucm_join_ip_mcast { |
196 | __u64 response; /* rdma_ucm_create_id_resp */ | 240 | __u64 response; /* rdma_ucm_create_id_resp */ |
197 | __u64 uid; | 241 | __u64 uid; |
198 | struct sockaddr_in6 addr; | 242 | struct sockaddr_in6 addr; |
199 | __u32 id; | 243 | __u32 id; |
200 | }; | 244 | }; |
201 | 245 | ||
246 | struct rdma_ucm_join_mcast { | ||
247 | __u64 response; /* rdma_ucma_create_id_resp */ | ||
248 | __u64 uid; | ||
249 | __u32 id; | ||
250 | __u16 addr_size; | ||
251 | __u16 reserved; | ||
252 | struct sockaddr_storage addr; | ||
253 | }; | ||
254 | |||
202 | struct rdma_ucm_get_event { | 255 | struct rdma_ucm_get_event { |
203 | __u64 response; | 256 | __u64 response; |
204 | }; | 257 | }; |
diff --git a/include/uapi/sound/asound.h b/include/uapi/sound/asound.h index e3983d508272..041203f20f6d 100644 --- a/include/uapi/sound/asound.h +++ b/include/uapi/sound/asound.h | |||
@@ -817,6 +817,8 @@ typedef int __bitwise snd_ctl_elem_iface_t; | |||
817 | #define SNDRV_CTL_POWER_D3hot (SNDRV_CTL_POWER_D3|0x0000) /* Off, with power */ | 817 | #define SNDRV_CTL_POWER_D3hot (SNDRV_CTL_POWER_D3|0x0000) /* Off, with power */ |
818 | #define SNDRV_CTL_POWER_D3cold (SNDRV_CTL_POWER_D3|0x0001) /* Off, without power */ | 818 | #define SNDRV_CTL_POWER_D3cold (SNDRV_CTL_POWER_D3|0x0001) /* Off, without power */ |
819 | 819 | ||
820 | #define SNDRV_CTL_ELEM_ID_NAME_MAXLEN 44 | ||
821 | |||
820 | struct snd_ctl_elem_id { | 822 | struct snd_ctl_elem_id { |
821 | unsigned int numid; /* numeric identifier, zero = invalid */ | 823 | unsigned int numid; /* numeric identifier, zero = invalid */ |
822 | snd_ctl_elem_iface_t iface; /* interface identifier */ | 824 | snd_ctl_elem_iface_t iface; /* interface identifier */ |
diff --git a/include/uapi/sound/hdspm.h b/include/uapi/sound/hdspm.h index 1f59ea2a4a76..d956c3593f65 100644 --- a/include/uapi/sound/hdspm.h +++ b/include/uapi/sound/hdspm.h | |||
@@ -111,7 +111,7 @@ struct hdspm_ltc { | |||
111 | enum hdspm_ltc_input_format input_format; | 111 | enum hdspm_ltc_input_format input_format; |
112 | }; | 112 | }; |
113 | 113 | ||
114 | #define SNDRV_HDSPM_IOCTL_GET_LTC _IOR('H', 0x46, struct hdspm_mixer_ioctl) | 114 | #define SNDRV_HDSPM_IOCTL_GET_LTC _IOR('H', 0x46, struct hdspm_ltc) |
115 | 115 | ||
116 | /** | 116 | /** |
117 | * The status data reflects the device's current state | 117 | * The status data reflects the device's current state |