partitions: crypto: introduce option to disable RNG independent of key derivation

We introduce a compile-time option to control whether to disable
the API for tfm_crypto_generate_random, independent of the key
derivation. In addition to that, the above API function is moved
into its own source file.

The change allows us to disable or enable the random number
generation API function independent of whether we disable or
enable the key derivation. This introduces some additional
flexibility to the user, who can now enable the random number
generation API while they can disable the key derivation API
family.

The change does not introduce behavioral changes.

Change-Id: I7306caa38476ff1a67c918ddb9e5780e25cebd27
Signed-off-by: Ioannis Glaropoulos <Ioannis.Glaropoulos@nordicsemi.no>
5 files changed