blob: 46c569a105fdd44b4c3dd785b486dba8e91d39d1 [file] [log] [blame]
Venkatesh Yadav Abbarapua8656c22024-12-19 10:09:18 +05301.. SPDX-License-Identifier: GPL-2.0
2
3.. index::
4 single: optee (command)
5
6optee command
7=============
8
9Synopsis
10--------
11
12::
13
14 optee hello
15 optee hello <value>
16
17Description
18-----------
19
20This is an OP-TEE sanity test which invokes the "Hello World"
21Trusted Application (TA). The TA does two things:
22- It prints debug and information messages to the secure console (if logging is enabled)
23- It increments the integer value passed as a parameter and returns it
24
25
26value
27 Integer value that the TA is expected to increment and return.
28 The default value is 0.
29
30To enable the OP-TEE Hello World example please refer
31https://optee.readthedocs.io/en/latest/building/gits/optee_examples/optee_examples.html
32
33Examples
34--------
35
36::
37
38 ==> optee hello
39 D/TA: TA_CreateEntryPoint:39 has been called
40 I/TA: Hello World!
41 Value before: 0x0
42 Calling TA
43 D/TA: inc_value:105 has been called
44 I/TA: Got value: 0 from NW
45 I/TA: Increase value to: 1
46 Value after: 0x1
47 I/TA: Goodbye!
48 D/TA: TA_DestroyEntryPoint:50 has been called
49
50 ==> optee hello 74
51 D/TA: TA_CreateEntryPoint:39 has been called
52 I/TA: Hello World!
53 Value before: 0x74
54 Calling TA
55 D/TA: inc_value:105 has been called
56 I/TA: Got value: 116 from NW
57 I/TA: Increase value to: 117
58 Value after: 0x75
59 I/TA: Goodbye!
60 D/TA: TA_DestroyEntryPoint:50 has been called
61
62Configuration
63-------------
64
65The optee command is enabled by CONFIG_OPTEE=y and CONFIG_CMD_OPTEE=y.
66
67Return value
68------------
69
70The return value $? is 0 (true) if the command succeeds, 1 (false) otherwise.