NVIDIA DRIVE OS Linux API Reference

5.1.0.2 Release

 All Data Structures Namespaces Files Functions Variables Typedefs Enumerations Enumerator Macros Groups Pages

Detailed Description

Defines common data types and functions for Trusted Little Kernel (TLK).

Data Structures

struct  te_service_id_t
 Defines a unique 16-byte ID for each TLK service. More...
 
struct  te_service_status_t
 
union  te_session_t
 Holds session information. More...
 
struct  te_oper_param_t
 Holds the operation object parameters. More...
 
struct  te_operation_t
 Holds operation object information that is to be delivered to the TLK Secure Service. More...
 

Macros

#define SERVICE_PORT_NAME_PREFIX   "com.nvidia.tos"
 
#define UUID_STR_SIZE_BYTES   ((2U * sizeof(te_service_id_t)) + 4U)
 
#define MAX_PORT_NAME_LENGTH   sizeof(SERVICE_PORT_NAME_PREFIX) + UUID_STR_SIZE_BYTES
 
#define OTE_TASK_NAME_MAX_LENGTH   24
 Defines the maximum length of a zero-terminated informative task name. More...
 
#define OTE_TASK_PRIVATE_DATA_LENGTH   20
 Defines the length of private data for the Trusted Application (TA). More...
 
#define TIPC_MAX_CHUNK_SIZE   4040
 
#define TIPC_CHUNK_MSG_ACK   0xcafefeedU
 
#define WORD_SIZE   sizeof(uint32_t)
 
#define ROUNDUP(a, b)   (((a) + ((b)-1)) & ~((b)-1))
 
#define ROUNDDOWN(a, b)   ((a) & ~((b)-1))
 

Typedefs

typedef uint64_t cmnptr_t
 Holds a pointer large enough to support 32- and 64-bit clients. More...
 

Enumerations

enum  te_oper_param_type_t {
  TE_PARAM_TYPE_NONE = 0x0U,
  TE_PARAM_TYPE_INT_RO = 0x1U,
  TE_PARAM_TYPE_INT_RW = 0x2U,
  TE_PARAM_TYPE_MEM_RO = 0x3U,
  TE_PARAM_TYPE_MEM_RW = 0x4U,
  TE_PARAM_TYPE_PERSIST_MEM_RO = 0x100U,
  TE_PARAM_TYPE_PERSIST_MEM_RW = 0x101U,
  TE_PARAM_TYPE_FLAGS_PHYS_LIST = 0x1000U,
  TE_PARAM_TYPE_ALL_FLAGS
}
 Specifies the operation object's parameter types. More...
 
enum  {
  TE_MEM_TYPE_NS_USER = 0x0U,
  TE_MEM_TYPE_NS_KERNEL = 0x1U
}
 

Functions

te_result_origin_t te_get_result_origin (te_session_t *session)
 Returns the origin of a returned result. More...
 

Macro Definition Documentation

#define MAX_PORT_NAME_LENGTH   sizeof(SERVICE_PORT_NAME_PREFIX) + UUID_STR_SIZE_BYTES

Definition at line 64 of file ote_common.h.

#define OTE_TASK_NAME_MAX_LENGTH   24

Defines the maximum length of a zero-terminated informative task name.

Definition at line 68 of file ote_common.h.

#define OTE_TASK_PRIVATE_DATA_LENGTH   20

Defines the length of private data for the Trusted Application (TA).

The definition goes in the manifest. The semantics of this optional data is defined per each TA.

To hold an SHA1 digest, this definition must be at least 20 bytes. Such a digest enables building a chain of trust to a TA with the manifest data.

This definition can be used to perform tasks such as:

  • Loading public keys
  • Loading X509 certificates and digests

Definition at line 82 of file ote_common.h.

#define ROUNDDOWN (   a,
 
)    ((a) & ~((b)-1))

Definition at line 99 of file ote_common.h.

#define ROUNDUP (   a,
 
)    (((a) + ((b)-1)) & ~((b)-1))

Definition at line 98 of file ote_common.h.

#define SERVICE_PORT_NAME_PREFIX   "com.nvidia.tos"

Definition at line 58 of file ote_common.h.

#define TIPC_CHUNK_MSG_ACK   0xcafefeedU

Definition at line 95 of file ote_common.h.

#define TIPC_MAX_CHUNK_SIZE   4040

Definition at line 89 of file ote_common.h.

#define UUID_STR_SIZE_BYTES   ((2U * sizeof(te_service_id_t)) + 4U)

Definition at line 61 of file ote_common.h.

#define WORD_SIZE   sizeof(uint32_t)

Definition at line 97 of file ote_common.h.

Typedef Documentation

typedef uint64_t cmnptr_t

Holds a pointer large enough to support 32- and 64-bit clients.

Definition at line 137 of file ote_common.h.

Enumeration Type Documentation

anonymous enum
Enumerator
TE_MEM_TYPE_NS_USER 
TE_MEM_TYPE_NS_KERNEL 

Definition at line 169 of file ote_common.h.

Specifies the operation object's parameter types.

Enumerator
TE_PARAM_TYPE_NONE 
TE_PARAM_TYPE_INT_RO 
TE_PARAM_TYPE_INT_RW 
TE_PARAM_TYPE_MEM_RO 
TE_PARAM_TYPE_MEM_RW 
TE_PARAM_TYPE_PERSIST_MEM_RO 
TE_PARAM_TYPE_PERSIST_MEM_RW 
TE_PARAM_TYPE_FLAGS_PHYS_LIST 
TE_PARAM_TYPE_ALL_FLAGS 

Definition at line 123 of file ote_common.h.

Function Documentation

te_result_origin_t te_get_result_origin ( te_session_t session)

Returns the origin of a returned result.

Because it is possible for the operation to fail anywhere in the pipeline, this function returns the general block where the returned result originated.

Parameters
[in]sessionA valid session pointer.
Returns
A te_result_origin_t ID number.