Skip to content

Commit e9e7368

Browse files
committed
doc: crypto: minor edits and fixes
Fixed inaccuracies in nrf_cc3xx_mbedcrypto.rst. Added cross-links in all pages. NCSDK-33729. Signed-off-by: Grzegorz Ferenc <[email protected]>
1 parent 36ba54a commit e9e7368

File tree

5 files changed

+25
-31
lines changed

5 files changed

+25
-31
lines changed

crypto/README.rst

Lines changed: 7 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,12 @@
11
.. _crypto:
22

3-
Crypto Libraries
4-
################
3+
Cryptographic libraries
4+
#######################
5+
6+
The cryptographic libraries in this section are backends for the following components in the |NCS|:
7+
8+
* nrf_cc3xx_platform, nrf_cc3xx_mbedcrypto, and nrf_oberon are used by the :ref:`nrf:crypto_drivers`.
9+
* nrf_cc310_bl is used by the :ref:`doc_bl_crypto` library.
510

611
.. toctree::
712
:maxdepth: 2

crypto/doc/nrf_cc310_bl.rst

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ nrf_cc310_bl crypto library
77
:local:
88
:depth: 2
99

10-
The nrf_cc310_bl library is a software library to interface with Arm CryptoCell CC310 hardware accelerator that is available on the nRF52840 SoC and the nRF91 Series.
10+
The nrf_cc310_bl library is a software library that is used as a backend by the :ref:`doc_bl_crypto` library in the |NCS| to interface with Arm CryptoCell CC310 hardware accelerator that is available on the nRF52840 SoC and the nRF91 Series.
1111
The library adds hardware support for cryptographic algorithms to be used in bootloader-specific use cases.
1212

1313
The nrf_cc310_bl library supports the following cryptographic algorithms:

crypto/doc/nrf_cc3xx_mbedcrypto.rst

Lines changed: 11 additions & 21 deletions
Original file line numberDiff line numberDiff line change
@@ -8,17 +8,18 @@ nrf_cc3xx_mbedcrypto library
88
:local:
99
:depth: 2
1010

11-
The nrf_cc3xx_mbedcrypto library is software library to interface with the Arm CryptoCell hardware accelerator that is available on the nRF52840 SoC, the nRF53 Series, and the nRF91 Series.
11+
The nrf_cc3xx_mbedcrypto library is a software library used by the :ref:`nrf:crypto_drivers_cc3xx` in the |NCS| to interface with the Arm CryptoCell hardware accelerator that is available on the nRF52840 SoC, the nRF53 Series, and the nRF91 Series.
1212
The library adds hardware support for selected cryptographic algorithms.
1313

14+
.. note::
15+
Do not link to this library directly.
16+
See :ref:`nrf:psa_crypto_support` for information on how to enable its related driver.
17+
1418
Integration with Mbed TLS
1519
=========================
16-
The nrf_cc3xx_mbedcrypto library provides low-level integration with the Mbed TLS version provided in nRF Connect SDK.
17-
Some of the APIs expressed in this library use the Mbed TLS "alternative implementation" abstraction layer.
18-
19-
.. note::
20-
It is not recommended to link to this library directly. Use the :ref:`nrf:nrf_security`.
2120

21+
The nrf_cc3xx_mbedcrypto library provides low-level integration with the Mbed TLS version provided in the |NCS|.
22+
Some of the APIs expressed in this library use the Mbed TLS :ref:`legacy crypto <nrf:legacy_crypto_support>` abstraction layer.
2223

2324
Supported cryptographic algorithms
2425
==================================
@@ -133,8 +134,9 @@ Otherwise, the library will default to use the clib functions :c:func:`calloc` a
133134

134135
PSA driver integration
135136
======================
136-
Starting from version 0.9.13, the nrf_oberon library contains a companion library that provides PSA driver integration for select features.
137-
This must be used with the :ref:`nrf:nrf_security`.
137+
138+
Starting from version 0.9.13, the nrf_cc3xx_mbedcrypto library contains a companion nrf_cc3xx_platform library that provides access to low-level CryptoCell APIs.
139+
Both must be used through the :ref:`nrf:crypto_drivers_cc3xx` in the |NCS|.
138140

139141
Supported features
140142
------------------
@@ -155,20 +157,8 @@ The supported features for the PSA driver companion library are:
155157

156158
Initializing the library
157159
------------------------
158-
The library requires initialization before use.
159-
You can initialize it by calling the :c:func:`mbedtls_platform_setup`/:c:func:`mbedtls_platform_teardown` functions.
160-
161-
.. code-block:: c
162-
:caption: Initializing the library
163160

164-
int ret;
165-
static mbedtls_platform_context platform_context = {0};
166-
167-
ret = mbedtls_platform_setup(&platform_context);
168-
if (ret != 0) {
169-
/* Failed to initialize nrf_cc3xx_mbedcrypto platform */
170-
return ret,
171-
}
161+
Use the library through the :ref:`nrf:crypto_drivers_cc3xx` in the |NCS|.
172162

173163
.. note::
174164
There is no need to enable/disable the CC310 hardware by writing to the ``NRF_CRYPTOCELL->ENABLE`` and ``NRF_CRYPTOCELL_S->ENABLE`` registers.

crypto/doc/nrf_cc3xx_platform.rst

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -8,16 +8,13 @@ nrf_cc3xx_platform library
88
:local:
99
:depth: 2
1010

11-
The nrf_cc3xx_platform library is software library to interface with the Arm CryptoCell CC310/CC312 hardware accelerator that is available on the nRF52840 SoC, the nRF53 Series, and the nRF91 Series.
11+
The nrf_cc3xx_platform library is a software library used by the :ref:`nrf:crypto_drivers_cc3xx` in the |NCS| to interface with the Arm CryptoCell CC310/CC312 hardware accelerator that is available on the nRF52840 SoC, the nRF53 Series, and the nRF91 Series.
1212

13-
The platform library provides low-level functionality needed by the CC310/CC312
14-
mbedcrypto library.
13+
The platform library provides low-level functionality needed by the CC310/CC312 mbedcrypto library.
1514

16-
This includes memory, mutex, and entropy APIs needed for the CC310/CC312 mbedcrypto
17-
library.
15+
This includes memory, mutex, and entropy APIs needed for the CC310/CC312 mbedcrypto library.
1816

19-
The library adds hardware support for the True Random Number Generator, TRNG,
20-
available in the CC310/CC312 hardware.
17+
The library adds hardware support for the True Random Number Generator, TRNG, available in the CC310/CC312 hardware.
2118

2219
API documentation
2320
=================

crypto/doc/nrf_oberon.rst

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -10,6 +10,7 @@ nrf_oberon crypto library
1010
The nrf_oberon library contains a collection of cryptographic algorithms created by Oberon Microsystems, licensed to Nordic Semiconductor ASA for redistribution.
1111
The library provides highly optimized software for Nordic Semiconductor SoCs based on Cortex-M0, Cortex-M4, and Cortex-M33 architectures.
1212

13+
The library is used by the :ref:`nrf:crypto_drivers_oberon` in the |NCS|.
1314

1415
Supported cryptographic algorithms
1516
==================================
@@ -29,6 +30,7 @@ Supported cryptographic algorithms
2930

3031
Initializing the library
3132
========================
33+
3234
The library does not require any initialization before the APIs can be used, although some APIs require calling specific initialization functions before use.
3335

3436

0 commit comments

Comments
 (0)