History

tee: add private login method for kernel clients

There are use-cases where user-space shouldn't be allowed to communicate directly with a TEE device which is dedicated to provide a specific service for a kernel client. So add a private login method for kernel clients and disallow user-space to open-session using GP implementation defined login method range: (0x80000000 - 0xBFFFFFFF).

Sumit Garg committed 6 years ago

Commit 104edb91 parent 2a6ba3f2 files · +16 −0Browse files

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

Unified · Split

include/uapi/linux/tee.h+9−0
@@ -173,6 +173,15 @@ struct tee_ioctl_buf_data { · 172 unmodified lines
173173 #define TEE_IOCTL_LOGIN_APPLICATION 4
174174 #define TEE_IOCTL_LOGIN_USER_APPLICATION 5
175175 #define TEE_IOCTL_LOGIN_GROUP_APPLICATION 6
176+/*
177+ * Disallow user-space to use GP implementation specific login
178+ * method range (0x80000000 - 0xBFFFFFFF). This range is rather
179+ * being reserved for REE kernel clients or TEE implementation.
180+ */
181+#define TEE_IOCTL_LOGIN_REE_KERNEL_MIN 0x80000000
182+#define TEE_IOCTL_LOGIN_REE_KERNEL_MAX 0xBFFFFFFF
183+/* Private login method for REE kernel clients */
184+#define TEE_IOCTL_LOGIN_REE_KERNEL 0x80000000
176185
177186 /**
178187 * struct tee_ioctl_param - parameter

Keyboard shortcuts

General

Show keyboard shortcuts
?
Focus the current search
/

Issues and pull requests

Open filters
f

Issues, pull requests and Inbox

Select next item
j↓
Select previous item
k↑
Open selected item
Enter
Dismiss filters or clear selection
Esc

Repository code

Go to file
t