aboutsummaryrefslogtreecommitdiffstats
path: root/include/uapi/linux
diff options
context:
space:
mode:
authorLinus Torvalds <torvalds@linux-foundation.org>2016-05-21 01:20:48 -0400
committerLinus Torvalds <torvalds@linux-foundation.org>2016-05-21 01:20:48 -0400
commit2f37dd131c5d3a2eac21cd5baf80658b1b02a8ac (patch)
treee0f191b15865268e694c02f1f02cbc26a168ddf9 /include/uapi/linux
parent3aa2fc1667acdd9cca816a2bc9529f494bd61b05 (diff)
parentffc83a79b44e02995ab5e93af07e26f6c7243c53 (diff)
Merge tag 'staging-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging
Pull staging and IIO driver updates from Greg KH: "Here's the big staging and iio driver update for 4.7-rc1. I think we almost broke even with this release, only adding a few more lines than we removed, which isn't bad overall given that there's a bunch of new iio drivers added. The Lustre developers seem to have woken up from their sleep and have been doing a great job in cleaning up the code and pruning unused or old cruft, the filesystem is almost readable :) Other than that, just a lot of basic coding style cleanups in the churn. All have been in linux-next for a while with no reported issues" * tag 'staging-4.7-rc1' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/staging: (938 commits) Staging: emxx_udc: emxx_udc: fixed coding style issue staging/gdm724x: fix "alignment should match open parenthesis" issues staging/gdm724x: Fix avoid CamelCase staging: unisys: rename misleading var ii with frag staging: unisys: visorhba: switch success handling to error handling staging: unisys: visorhba: main path needs to flow down the left margin staging: unisys: visorinput: handle_locking_key() simplifications staging: unisys: visorhba: fail gracefully for thread creation failures staging: unisys: visornic: comment restructuring and removing bad diction staging: unisys: fix format string %Lx to %llx for u64 staging: unisys: remove unused struct members staging: unisys: visorchannel: correct variable misspelling staging: unisys: visorhba: replace functionlike macro with function staging: dgnc: Need to check for NULL of ch staging: dgnc: remove redundant condition check staging: dgnc: fix 'line over 80 characters' staging: dgnc: clean up the dgnc_get_modem_info() staging: lustre: lnet: enable configuration per NI interface staging: lustre: o2iblnd: properly set ibr_why staging: lustre: o2iblnd: remove last of kiblnd_tunables_fini ...
Diffstat (limited to 'include/uapi/linux')
-rw-r--r--include/uapi/linux/iio/types.h2
-rw-r--r--include/uapi/linux/sync_file.h100
2 files changed, 102 insertions, 0 deletions
diff --git a/include/uapi/linux/iio/types.h b/include/uapi/linux/iio/types.h
index c077617f3304..b0916fc72cce 100644
--- a/include/uapi/linux/iio/types.h
+++ b/include/uapi/linux/iio/types.h
@@ -38,6 +38,7 @@ enum iio_chan_type {
38 IIO_CONCENTRATION, 38 IIO_CONCENTRATION,
39 IIO_RESISTANCE, 39 IIO_RESISTANCE,
40 IIO_PH, 40 IIO_PH,
41 IIO_UVINDEX,
41}; 42};
42 43
43enum iio_modifier { 44enum iio_modifier {
@@ -77,6 +78,7 @@ enum iio_modifier {
77 IIO_MOD_Q, 78 IIO_MOD_Q,
78 IIO_MOD_CO2, 79 IIO_MOD_CO2,
79 IIO_MOD_VOC, 80 IIO_MOD_VOC,
81 IIO_MOD_LIGHT_UV,
80}; 82};
81 83
82enum iio_event_type { 84enum iio_event_type {
diff --git a/include/uapi/linux/sync_file.h b/include/uapi/linux/sync_file.h
new file mode 100644
index 000000000000..413303d37b56
--- /dev/null
+++ b/include/uapi/linux/sync_file.h
@@ -0,0 +1,100 @@
1/*
2 * Copyright (C) 2012 Google, Inc.
3 *
4 * This program is distributed in the hope that it will be useful,
5 * but WITHOUT ANY WARRANTY; without even the implied warranty of
6 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
7 * GNU General Public License for more details.
8 *
9 */
10
11#ifndef _UAPI_LINUX_SYNC_H
12#define _UAPI_LINUX_SYNC_H
13
14#include <linux/ioctl.h>
15#include <linux/types.h>
16
17/**
18 * struct sync_merge_data - data passed to merge ioctl
19 * @name: name of new fence
20 * @fd2: file descriptor of second fence
21 * @fence: returns the fd of the new fence to userspace
22 * @flags: merge_data flags
23 * @pad: padding for 64-bit alignment, should always be zero
24 */
25struct sync_merge_data {
26 char name[32];
27 __s32 fd2;
28 __s32 fence;
29 __u32 flags;
30 __u32 pad;
31};
32
33/**
34 * struct sync_fence_info - detailed fence information
35 * @obj_name: name of parent sync_timeline
36* @driver_name: name of driver implementing the parent
37* @status: status of the fence 0:active 1:signaled <0:error
38 * @flags: fence_info flags
39 * @timestamp_ns: timestamp of status change in nanoseconds
40 */
41struct sync_fence_info {
42 char obj_name[32];
43 char driver_name[32];
44 __s32 status;
45 __u32 flags;
46 __u64 timestamp_ns;
47};
48
49/**
50 * struct sync_file_info - data returned from fence info ioctl
51 * @name: name of fence
52 * @status: status of fence. 1: signaled 0:active <0:error
53 * @flags: sync_file_info flags
54 * @num_fences number of fences in the sync_file
55 * @pad: padding for 64-bit alignment, should always be zero
56 * @sync_fence_info: pointer to array of structs sync_fence_info with all
57 * fences in the sync_file
58 */
59struct sync_file_info {
60 char name[32];
61 __s32 status;
62 __u32 flags;
63 __u32 num_fences;
64 __u32 pad;
65
66 __u64 sync_fence_info;
67};
68
69#define SYNC_IOC_MAGIC '>'
70
71/**
72 * Opcodes 0, 1 and 2 were burned during a API change to avoid users of the
73 * old API to get weird errors when trying to handling sync_files. The API
74 * change happened during the de-stage of the Sync Framework when there was
75 * no upstream users available.
76 */
77
78/**
79 * DOC: SYNC_IOC_MERGE - merge two fences
80 *
81 * Takes a struct sync_merge_data. Creates a new fence containing copies of
82 * the sync_pts in both the calling fd and sync_merge_data.fd2. Returns the
83 * new fence's fd in sync_merge_data.fence
84 */
85#define SYNC_IOC_MERGE _IOWR(SYNC_IOC_MAGIC, 3, struct sync_merge_data)
86
87/**
88 * DOC: SYNC_IOC_FENCE_INFO - get detailed information on a fence
89 *
90 * Takes a struct sync_file_info_data with extra space allocated for pt_info.
91 * Caller should write the size of the buffer into len. On return, len is
92 * updated to reflect the total size of the sync_file_info_data including
93 * pt_info.
94 *
95 * pt_info is a buffer containing sync_pt_infos for every sync_pt in the fence.
96 * To iterate over the sync_pt_infos, use the sync_pt_info.len field.
97 */
98#define SYNC_IOC_FILE_INFO _IOWR(SYNC_IOC_MAGIC, 4, struct sync_file_info)
99
100#endif /* _UAPI_LINUX_SYNC_H */