walnux/include
Theodore Karatapanis 707cdaf42e drivers/misc/optee: Expanded RPC support.
This commit expands RPC support for the OP-TEE driver using 2 files:
1) drivers/misc/optee_rpc.c
   * Add support for RPCs that can be handled directly by the kernel.
   * Can delegate RPC handling to optee_supplicant.c for RPCs that
     need userspace interaction.
2) drivers/misc/optee_supplicant.c
   * Enable communication between the userspace TEE supplicant and the
     kernel driver.

Additional changes were needed to the following files:
1) drivers/misc/optee.c
   * Add ioctls used SOLELY by the userspace TEE supplicant.
   * Register /dev/teepriv0 if the supplicant is enabled in Kconfig
   * Add OPTEE_ROLE_CA and OPTEE_ROLE_SUPPLICANT conditionals to
     differentiate paths, between a normal Client Application (CA)
     and the TEE supplicant.
   * Change some functions from static to "public" to reuse them
     in other C files.
   * Adjust optee_to/from_msg_param() to work with RPCs.

2) drivers/misc/optee_smc.c
   * Call the RPC handler from optee_rpc.c

3) drivers/misc/optee_msg.h
   * Add definition needed for RPCs

4) drivers/misc/tee.h
   * Add ioctl definitions
   * Add TEE_SHM_SUPP flag, checked when unregistering supplicant
     memory.

5) Documentation/guides/optee.rs
   * Add documentation for RPCs and the supplicant.

6) drivers/misc/{CMakeLists.txt, Make.defs}
   * Account for the new files.

7) drivers/misc/Kconfig
   * Add DEV_OPTEE_SUPPLICANT option to enable/disable the supplicant
     driver.

Signed-off-by: Theodore Karatapanis <tkaratapanis@census-labs.com>
2025-08-06 02:29:33 +08:00
..
android include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
arpa include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
crypto style: fix spelling in code comments and strings 2025-05-23 10:48:41 +08:00
cxx fix a typo 2024-12-15 17:53:48 -03:00
net net: use bps units for bitrate in SocketCAN interfaces. 2025-04-16 11:07:27 -03:00
netinet include/netinet/arp.h: change the type of arp_dev from uint8_t to char 2024-12-26 23:29:23 +08:00
netpacket netpacket/sockaddr_ll: Add valid packet types for sll_pkttype 2024-12-31 09:41:39 +08:00
nuttx drivers/misc/optee: Expanded RPC support. 2025-08-06 02:29:33 +08:00
ssp include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
sys drivers/fs: Control the behavior of FTL by passing oflags during the open process. 2025-07-16 14:11:41 +08:00
.gitignore include/.gitignore: add openlibm to gitignore 2024-10-13 02:27:28 +08:00
aio.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
alloca.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
assert.h assert: add header files to resolve compile failed 2024-10-12 09:29:37 +08:00
byteswap.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
ctype.h libcxx: fix compile error 2024-10-23 09:42:57 +08:00
debug.h libc/stream: Support lowsyslog. 2025-04-02 12:01:46 +08:00
dirent.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
dlfcn.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
dsp.h style: fix spelling in code comments and strings 2025-05-23 10:48:41 +08:00
dspb16.h style: fix spelling in code comments and strings 2025-05-23 10:48:41 +08:00
elf.h modlib:Standardized module loading method 2024-10-05 15:22:02 +08:00
elf32.h modlib:Standardized module loading method 2024-10-05 15:22:02 +08:00
elf64.h modlib:Standardized module loading method 2024-10-05 15:22:02 +08:00
endian.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
err.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
errno.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
execinfo.h sched: support backtrace record 2024-10-11 00:37:27 +08:00
fcntl.h drivers/fs: Control the behavior of FTL by passing oflags during the open process. 2025-07-16 14:11:41 +08:00
fixedmath.h style: fix spelling in code comments and strings 2025-05-23 10:48:41 +08:00
fnmatch.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
ftw.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
gcov.h gcov: Refactoring the implementation framework of gcov 2025-07-03 00:17:58 +08:00
getopt.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
glob.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
grp.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
hex2bin.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
iconv.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
ifaddrs.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
imx_container.h arch/arm64/imx9: Add ROMAPI and AHAB support for i.MX9 2025-05-09 19:21:17 +08:00
inttypes.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
iso646.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
langinfo.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
libgen.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
libintl.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
limits.h Add LINE_MAX configuration 2024-12-26 13:25:19 +08:00
locale.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
lzf.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
malloc.h memdump: add dump for the orphan nodes(neighbor of free node) 2024-10-08 23:55:59 +08:00
mqueue.h [POSIX][Bug] mqueue.h: Include file does not conform the standard 2024-12-09 21:21:09 +08:00
netdb.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
nl_types.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
nxflat.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
obstack.h libs/libc/obstack: fix allocated chunk overrun due to invalid limit 2024-10-30 11:53:18 -03:00
poll.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
pthread.h Clean up the nxmutex library 2025-05-08 16:00:05 +08:00
pty.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
pwd.h libs/libc/pwd: add new member to passwd struct 2024-10-16 11:15:25 +08:00
regex.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
resolv.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
sched.h sched: remove csection and reduce the interrupt disabling time in sched_[un]lock 2025-01-23 19:58:49 +08:00
search.h include/search: migrate to SPDX identifier 2024-12-16 14:18:35 +08:00
semaphore.h style: fix spelling in code comments and strings 2025-05-23 10:48:41 +08:00
shadow.h libs/libc/unistd: add getspnam function 2024-10-16 11:15:25 +08:00
signal.h signal: add include/sys/signal.h to the signal 2024-12-20 11:46:14 -03:00
spawn.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
stdbool.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
stddef.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
stdint.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
stdio.h libc: add nx_strdup() & nx_strndup() support 2024-10-15 01:16:48 +08:00
stdlib.h include/stdlib.h: define system()'s prototype for the flat build 2025-02-07 09:03:14 +08:00
stdnoreturn.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
string.h fix misspelled names in locally scoped code 2025-05-15 10:12:12 +08:00
strings.h libc/strings: fix compile warning if enable -Wshadow 2025-03-05 11:20:01 -03:00
syscall.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
syslog.h drivers/syslog: Add RFC 5424 protocol support 2025-06-13 20:26:57 +08:00
termios.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
threads.h include/threads.h: Replace thrd_ defines by actual function definitions 2024-12-19 21:56:02 +08:00
time.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
unistd.h nuttx: add get_current_dir_name implementation 2024-12-19 20:55:51 +08:00
utime.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
uuid.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00
wait.h wait: add wait.h header file 2024-12-20 11:46:14 -03:00
wchar.h fix misspelled names in locally scoped code 2025-05-15 10:12:12 +08:00
wctype.h include: migrate to SPDX identifier 2024-10-04 08:18:42 +08:00