History

Merge tag 'char-misc-5.1-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc

Pull char/misc driver fixes from Greg KH: "Here are some binder, habanalabs, and vboxguest driver fixes for 5.1-rc3. The Binder fixes resolve some reported issues found by testing, first by the selinux developers, and then earlier today by syzbot. The habanalabs fixes are all minor, resolving a number of tiny things. The vboxguest patches are a bit larger. They resolve the fact that virtual box decided to change their api in their latest release in a way that broke the existing kernel code, despite saying that they were never going to do that. So this is a bit of a "new feature", but is good to get merged so that 5.1 will work with the latest release. The changes are not large and of course virtual box "swears" they will not break this again, but no one is holding their breath here. All of these have been in linux-next for a while with no reported issues" * tag 'char-misc-5.1-rc3' of git://git.kernel.org/pub/scm/linux/kernel/git/gregkh/char-misc: virt: vbox: Implement passing requestor info to the host for VirtualBox 6.0.x binder: fix race between munmap() and direct reclaim binder: fix BUG_ON found by selinux-testsuite habanalabs: cast to expected type habanalabs: prevent host crash during suspend/resume habanalabs: perform accounting for active CS habanalabs: fix mapping with page size bigger than 4KB habanalabs: complete user context cleanup before hard reset habanalabs: fix bug when mapping very large memory area habanalabs: fix MMU number of pages calculation

Linus Torvalds committed 7 years ago

Commit 6f510922 parents 3467b90 0532a1b18 files · +324 −184Browse files

Showing the changes to include/uapi/linux (1 of 18 files). Show all

Unified · Split

include/uapi/linux/vbox_vmmdev_types.h+60−0
@@ -102,6 +102,66 @@ enum vmmdev_request_type { · 101 unmodified lines
102102 #define VMMDEVREQ_HGCM_CALL VMMDEVREQ_HGCM_CALL32
103103 #endif
104104
105+/* vmmdev_request_header.requestor defines */
106+
107+/* Requestor user not given. */
108+#define VMMDEV_REQUESTOR_USR_NOT_GIVEN 0x00000000
109+/* The kernel driver (vboxguest) is the requestor. */
110+#define VMMDEV_REQUESTOR_USR_DRV 0x00000001
111+/* Some other kernel driver is the requestor. */
112+#define VMMDEV_REQUESTOR_USR_DRV_OTHER 0x00000002
113+/* The root or a admin user is the requestor. */
114+#define VMMDEV_REQUESTOR_USR_ROOT 0x00000003
115+/* Regular joe user is making the request. */
116+#define VMMDEV_REQUESTOR_USR_USER 0x00000006
117+/* User classification mask. */
118+#define VMMDEV_REQUESTOR_USR_MASK 0x00000007
119+
120+/* Kernel mode request. Note this is 0, check for !USERMODE instead. */
121+#define VMMDEV_REQUESTOR_KERNEL 0x00000000
122+/* User mode request. */
123+#define VMMDEV_REQUESTOR_USERMODE 0x00000008
124+/* User or kernel mode classification mask. */
125+#define VMMDEV_REQUESTOR_MODE_MASK 0x00000008
126+
127+/* Don't know the physical console association of the requestor. */
128+#define VMMDEV_REQUESTOR_CON_DONT_KNOW 0x00000000
129+/*
130+ * The request originates with a process that is NOT associated with the
131+ * physical console.
132+ */
133+#define VMMDEV_REQUESTOR_CON_NO 0x00000010
134+/* Requestor process is associated with the physical console. */
135+#define VMMDEV_REQUESTOR_CON_YES 0x00000020
136+/* Console classification mask. */
137+#define VMMDEV_REQUESTOR_CON_MASK 0x00000030
138+
139+/* Requestor is member of special VirtualBox user group. */
140+#define VMMDEV_REQUESTOR_GRP_VBOX 0x00000080
141+
142+/* Note: trust level is for windows guests only, linux always uses not-given */
143+/* Requestor trust level: Unspecified */
144+#define VMMDEV_REQUESTOR_TRUST_NOT_GIVEN 0x00000000
145+/* Requestor trust level: Untrusted (SID S-1-16-0) */
146+#define VMMDEV_REQUESTOR_TRUST_UNTRUSTED 0x00001000
147+/* Requestor trust level: Untrusted (SID S-1-16-4096) */
148+#define VMMDEV_REQUESTOR_TRUST_LOW 0x00002000
149+/* Requestor trust level: Medium (SID S-1-16-8192) */
150+#define VMMDEV_REQUESTOR_TRUST_MEDIUM 0x00003000
151+/* Requestor trust level: Medium plus (SID S-1-16-8448) */
152+#define VMMDEV_REQUESTOR_TRUST_MEDIUM_PLUS 0x00004000
153+/* Requestor trust level: High (SID S-1-16-12288) */
154+#define VMMDEV_REQUESTOR_TRUST_HIGH 0x00005000
155+/* Requestor trust level: System (SID S-1-16-16384) */
156+#define VMMDEV_REQUESTOR_TRUST_SYSTEM 0x00006000
157+/* Requestor trust level >= Protected (SID S-1-16-20480, S-1-16-28672) */
158+#define VMMDEV_REQUESTOR_TRUST_PROTECTED 0x00007000
159+/* Requestor trust level mask */
160+#define VMMDEV_REQUESTOR_TRUST_MASK 0x00007000
161+
162+/* Requestor is using the less trusted user device node (/dev/vboxuser) */
163+#define VMMDEV_REQUESTOR_USER_DEVICE 0x00008000
164+
105165 /** HGCM service location types. */
106166 enum vmmdev_hgcm_service_location_type {
107167 VMMDEV_HGCM_LOC_INVALID = 0,