Skip to content

Commit bbf2f13

Browse files
gmarullcarlescufi
authored andcommitted
nrf_security: fix Doxygen issues
Headers had numerous Doxygen issues, this patch fixes all of them so that Doxygen build is clean from warnings/errors. Signed-off-by: Gerard Marull-Paretas <[email protected]>
1 parent fca1c7d commit bbf2f13

File tree

5 files changed

+117
-176
lines changed

5 files changed

+117
-176
lines changed

subsys/nrf_security/include/crypto_compat.h

Lines changed: 13 additions & 13 deletions
Original file line numberDiff line numberDiff line change
@@ -1,5 +1,5 @@
11
/**
2-
* \file psa/crypto_compat.h
2+
* \file crypto_compat.h
33
*
44
* \brief PSA cryptography module: Backward compatibility aliases
55
*
@@ -46,12 +46,12 @@ static inline int psa_key_handle_is_null(psa_key_handle_t handle)
4646
/** Open a handle to an existing persistent key.
4747
*
4848
* Open a handle to a persistent key. A key is persistent if it was created
49-
* with a lifetime other than #PSA_KEY_LIFETIME_VOLATILE. A persistent key
49+
* with a lifetime other than PSA_KEY_LIFETIME_VOLATILE. A persistent key
5050
* always has a nonzero key identifier, set with psa_set_key_id() when
5151
* creating the key. Implementations may provide additional pre-provisioned
5252
* keys that can be opened with psa_open_key(). Such keys have an application
5353
* key identifier in the vendor range, as documented in the description of
54-
* #psa_key_id_t.
54+
* psa_key_id_t.
5555
*
5656
* The application must eventually close the handle with psa_close_key() or
5757
* psa_destroy_key() to release associated resources. If the application dies
@@ -93,11 +93,11 @@ static inline int psa_key_handle_is_null(psa_key_handle_t handle)
9393
* permission to access it. Note that this specification does not
9494
* define any way to create such a key, but it may be possible
9595
* through implementation-specific means.
96-
* \retval #PSA_ERROR_COMMUNICATION_FAILURE \emptydescription
97-
* \retval #PSA_ERROR_CORRUPTION_DETECTED \emptydescription
98-
* \retval #PSA_ERROR_STORAGE_FAILURE \emptydescription
99-
* \retval #PSA_ERROR_DATA_INVALID \emptydescription
100-
* \retval #PSA_ERROR_DATA_CORRUPT \emptydescription
96+
* \retval #PSA_ERROR_COMMUNICATION_FAILURE
97+
* \retval PSA_ERROR_CORRUPTION_DETECTED
98+
* \retval #PSA_ERROR_STORAGE_FAILURE
99+
* \retval PSA_ERROR_DATA_INVALID
100+
* \retval #PSA_ERROR_DATA_CORRUPT
101101
* \retval #PSA_ERROR_BAD_STATE
102102
* The library has not been previously initialized by psa_crypto_init().
103103
* It is implementation-dependent whether a failure to initialize
@@ -137,8 +137,8 @@ psa_status_t psa_open_key(mbedtls_svc_key_id_t key,
137137
* \p handle was a valid handle or \c 0. It is now closed.
138138
* \retval #PSA_ERROR_INVALID_HANDLE
139139
* \p handle is not a valid handle nor \c 0.
140-
* \retval #PSA_ERROR_COMMUNICATION_FAILURE \emptydescription
141-
* \retval #PSA_ERROR_CORRUPTION_DETECTED \emptydescription
140+
* \retval #PSA_ERROR_COMMUNICATION_FAILURE
141+
* \retval PSA_ERROR_CORRUPTION_DETECTED
142142
* \retval #PSA_ERROR_BAD_STATE
143143
* The library has not been previously initialized by psa_crypto_init().
144144
* It is implementation-dependent whether a failure to initialize
@@ -175,8 +175,8 @@ psa_status_t psa_close_key(psa_key_handle_t handle);
175175
* \param[in] data Ignored.
176176
* \param data_length Must be 0.
177177
*
178-
* \retval #PSA_SUCCESS \emptydescription
179-
* \retval #PSA_ERROR_NOT_SUPPORTED \emptydescription
178+
* \retval #PSA_SUCCESS
179+
* \retval #PSA_ERROR_NOT_SUPPORTED
180180
*/
181181
static inline psa_status_t MBEDTLS_DEPRECATED psa_set_key_domain_parameters(
182182
psa_key_attributes_t *attributes,
@@ -202,7 +202,7 @@ static inline psa_status_t MBEDTLS_DEPRECATED psa_set_key_domain_parameters(
202202
* \param data_size Ignored.
203203
* \param[out] data_length Set to 0.
204204
*
205-
* \retval #PSA_SUCCESS \emptydescription
205+
* \retval #PSA_SUCCESS
206206
*/
207207
static inline psa_status_t MBEDTLS_DEPRECATED psa_get_key_domain_parameters(
208208
const psa_key_attributes_t *attributes,

subsys/nrf_security/include/psa/client.h

Lines changed: 16 additions & 24 deletions
Original file line numberDiff line numberDiff line change
@@ -119,6 +119,10 @@ uint32_t psa_version(uint32_t sid);
119119
/**
120120
* \brief Connect to an RoT Service by its SID.
121121
*
122+
* The call is invalid if one or more of the following are true:
123+
* - The RoT Service ID is not present.
124+
* - The RoT Service version is not supported.
125+
* - The caller is not allowed to access the RoT service.
122126
* \param[in] sid ID of the RoT Service to connect to.
123127
* \param[in] version Requested version of the RoT Service.
124128
*
@@ -127,12 +131,6 @@ uint32_t psa_version(uint32_t sid);
127131
* connection.
128132
* \retval PSA_ERROR_CONNECTION_BUSY The SPM or RoT Service cannot make the
129133
* connection at the moment.
130-
* \retval "PROGRAMMER ERROR" The call is a PROGRAMMER ERROR if one or more
131-
* of the following are true:
132-
* \arg The RoT Service ID is not present.
133-
* \arg The RoT Service version is not supported.
134-
* \arg The caller is not allowed to access the RoT
135-
* service.
136134
*/
137135
psa_handle_t psa_connect(uint32_t sid, uint32_t version);
138136

@@ -147,6 +145,14 @@ psa_handle_t psa_connect(uint32_t sid, uint32_t version);
147145
* range has to be reduced into a 16-bit integer. So with this encoding,
148146
* the valid range for 'type' is 0-32767.
149147
*
148+
* The call is invalid if one or more of the following are true:
149+
* - An invalid handle was passed.
150+
* - The connection is already handling a request.
151+
* - type < 0.
152+
* - An invalid memory reference was provided.
153+
* - in_len + out_len > PSA_MAX_IOVEC.
154+
* - The message is unrecognized by the RoT Service or incorrectly formatted.
155+
*
150156
* \param[in] handle A handle to an established connection.
151157
* \param[in] type The request type.
152158
* Must be zero( \ref PSA_IPC_CALL) or positive.
@@ -157,16 +163,6 @@ psa_handle_t psa_connect(uint32_t sid, uint32_t version);
157163
*
158164
* \retval >=0 RoT Service-specific status value.
159165
* \retval <0 RoT Service-specific error code.
160-
* \retval PSA_ERROR_PROGRAMMER_ERROR The connection has been terminated by the
161-
* RoT Service. The call is a PROGRAMMER ERROR if
162-
* one or more of the following are true:
163-
* \arg An invalid handle was passed.
164-
* \arg The connection is already handling a request.
165-
* \arg type < 0.
166-
* \arg An invalid memory reference was provided.
167-
* \arg in_len + out_len > PSA_MAX_IOVEC.
168-
* \arg The message is unrecognized by the RoT
169-
* Service or incorrectly formatted.
170166
*/
171167
psa_status_t psa_call(psa_handle_t handle, int32_t type,
172168
const psa_invec *in_vec,
@@ -177,16 +173,12 @@ psa_status_t psa_call(psa_handle_t handle, int32_t type,
177173
/**
178174
* \brief Close a connection to an RoT Service.
179175
*
176+
* The call is invalid if one or more of the following are true:
177+
* - An invalid handle was provided that is not the null handle.
178+
* - The connection is currently handling a request.
179+
*
180180
* \param[in] handle A handle to an established connection, or the
181181
* null handle.
182-
*
183-
* \retval void Success.
184-
* \retval "PROGRAMMER ERROR" The call is a PROGRAMMER ERROR if one or more
185-
* of the following are true:
186-
* \arg An invalid handle was provided that is not
187-
* the null handle.
188-
* \arg The connection is currently handling a
189-
* request.
190182
*/
191183
void psa_close(psa_handle_t handle);
192184

0 commit comments

Comments
 (0)