blob: 8f54b308d696992b13b54c3e3141c68314f90ad1 [file] [log] [blame]
Patrick Williams92b42cb2022-09-03 06:53:57 -05001From 9028b2463c1ea96f51c3ba53e2479346019ff6ad Mon Sep 17 00:00:00 2001
2From: Jens Wiklander <jens.wiklander@linaro.org>
3Date: Thu, 25 Mar 2021 15:08:44 +0100
4Subject: [PATCH] tee: add sec_world_id to struct tee_shm
5
6Adds sec_world_id to struct tee_shm which describes a shared memory
7object. sec_world_id can be used by a driver to store an id assigned by
8secure world.
9
10Reviewed-by: Sumit Garg <sumit.garg@linaro.org>
11Signed-off-by: Jens Wiklander <jens.wiklander@linaro.org>
12
13Upstream-Status: Submitted [https://github.com/torvalds/linux/commit/9028b2463c1ea96f51c3ba53e2479346019ff6ad]
14Signed-off-by: Anton Antonov <Anton.Antonov@arm.com>
15
16---
17 include/linux/tee_drv.h | 7 ++++++-
18 1 file changed, 6 insertions(+), 1 deletion(-)
19
20diff --git a/include/linux/tee_drv.h b/include/linux/tee_drv.h
21index 3ebfea0781f100..a1f03461369bd9 100644
22--- a/include/linux/tee_drv.h
23+++ b/include/linux/tee_drv.h
24@@ -197,7 +197,11 @@ int tee_session_calc_client_uuid(uuid_t *uuid, u32 connection_method,
25 * @num_pages: number of locked pages
26 * @dmabuf: dmabuf used to for exporting to user space
27 * @flags: defined by TEE_SHM_* in tee_drv.h
28- * @id: unique id of a shared memory object on this device
29+ * @id: unique id of a shared memory object on this device, shared
30+ * with user space
31+ * @sec_world_id:
32+ * secure world assigned id of this shared memory object, not
33+ * used by all drivers
34 *
35 * This pool is only supposed to be accessed directly from the TEE
36 * subsystem and from drivers that implements their own shm pool manager.
37@@ -213,6 +217,7 @@ struct tee_shm {
38 struct dma_buf *dmabuf;
39 u32 flags;
40 int id;
41+ u64 sec_world_id;
42 };
43
44 /**