[PW_SID:1163446] tee: optee: add RISC-V RPMI TEE transport - #2651
Open
linux-riscv-bot wants to merge 5 commits into
Open
[PW_SID:1163446] tee: optee: add RISC-V RPMI TEE transport#2651linux-riscv-bot wants to merge 5 commits into
linux-riscv-bot wants to merge 5 commits into
Conversation
Add an OP-TEE transport for RISC-V using the RPMI TEE service group over the SBI MPXY mailbox framework. Request one mailbox channel per hart and use the channel corresponding to the current CPU when issuing a TEE request. Probe the RPMI TEE service group and required memory-sharing capabilities before registering the transport. This provides the basic transport and discovery support needed by the following patches. Signed-off-by: Amirreza Zarrabi <amirreza.zarrabi@oss.qualcomm.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Add the shared-memory and call support required by the RISC-V RPMI transport. Use RPMI memory parcels to share memory between Linux and OP-TEE and keep a mapping between parcel identifiers and struct tee_shm. Pass the parcel identifier and offset when referencing shared memory from OP-TEE message parameters. Implement scheduled calls using RPMI TEE_CALL, including yielding calls, RPC handling and shared-memory allocation. Also add OP-TEE version and capability negotiation and complete registration of the OP-TEE device. Signed-off-by: Amirreza Zarrabi <amirreza.zarrabi@oss.qualcomm.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Use the OP-TEE shared argument cache when secure world advertises OPTEE_ABI_SEC_CAP_ARG_OFFSET. In this mode the argument structure can reside at an offset within an already registered parcel-backed shared-memory buffer, allowing the same buffer to be reused across calls instead of creating and reclaiming a parcel for each call. Signed-off-by: Amirreza Zarrabi <amirreza.zarrabi@oss.qualcomm.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Add asynchronous notification support using the RPMI TEE signal bus. Set up a signal bus between OP-TEE and Linux and use the platform interrupt as the availability doorbell. When signalled, retrieve pending signals and pass normal notification values to optee_notif_send(). Reserve one signal value for requesting the OP-TEE bottom-half handler. Enable this only when secure world advertises asynchronous notification support. Signed-off-by: Amirreza Zarrabi <amirreza.zarrabi@oss.qualcomm.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
Add a device-tree binding for the OP-TEE RISC-V transport using the RPMI TEE service group over SBI MPXY. Describe one mailbox channel per hart and an optional interrupt used as the availability doorbell for asynchronous notifications. Add the binding to the existing OP-TEE MAINTAINERS entry. Signed-off-by: Amirreza Zarrabi <amirreza.zarrabi@oss.qualcomm.com> Signed-off-by: Linux RISC-V bot <linux.riscv.bot@gmail.com>
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
PR for series 1163446 applied to workflow__riscv__fixes
Name: tee: optee: add RISC-V RPMI TEE transport
URL: https://patchwork.kernel.org/series/1163446/
Version: 1