Thread (17 messages) 17 messages, 4 authors, 2021-07-21

Re: [PATCH v5 6/8] tee: Correct inappropriate usage of TEE_SHM_DMA_BUF flag

From: Jens Wiklander <jens.wiklander@linaro.org>
Date: 2021-06-15 07:10:24
Also in: linux-mips, lkml, op-tee

On Tue, Jun 15, 2021 at 12:33 AM Tyler Hicks
[off-list ref] wrote:
From: Sumit Garg <redacted>

Currently TEE_SHM_DMA_BUF flag has been inappropriately used to not
register shared memory allocated for private usage by underlying TEE
driver: OP-TEE in this case. So rather add a new flag as TEE_SHM_PRIV
that can be utilized by underlying TEE drivers for private allocation
and usage of shared memory.

With this corrected, allow tee_shm_alloc_kernel_buf() to allocate a
shared memory region without the backing of dma-buf.

Cc: stable@vger.kernel.org
Signed-off-by: Sumit Garg <redacted>
Co-developed-by: Tyler Hicks <redacted>
Signed-off-by: Tyler Hicks <redacted>
---
 drivers/tee/optee/call.c     | 2 +-
 drivers/tee/optee/core.c     | 3 ++-
 drivers/tee/optee/rpc.c      | 5 +++--
 drivers/tee/optee/shm_pool.c | 8 ++++++--
 drivers/tee/tee_shm.c        | 4 ++--
 include/linux/tee_drv.h      | 1 +
 6 files changed, 15 insertions(+), 8 deletions(-)
Reviewed-by: Jens Wiklander <jens.wiklander@linaro.org>
Keyboard shortcuts
hback out one level
jnext message in thread
kprevious message in thread
ldrill in
Escclose help / fold thread tree
?toggle this help