<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="https://devzone.nordicsemi.com/cfs-file/__key/system/syndication/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/" xmlns:atom="http://www.w3.org/2005/Atom"><channel><title>Custom SPM dependencies</title><link>https://devzone.nordicsemi.com/f/nordic-q-a/76339/custom-spm-dependencies</link><description>Hello, 
 We need to add secure services to our application, and I followed the guide in https://devzone.nordicsemi.com/nordic/nrf-connect-sdk-guides/b/software/posts/using-a-custom-secure-partition-manager-wtih-your-application 
 However the build fails</description><dc:language>en-US</dc:language><generator>Telligent Community 13</generator><lastBuildDate>Tue, 29 Jun 2021 08:46:09 GMT</lastBuildDate><atom:link rel="self" type="application/rss+xml" href="https://devzone.nordicsemi.com/f/nordic-q-a/76339/custom-spm-dependencies" /><item><title>RE: Custom SPM dependencies</title><link>https://devzone.nordicsemi.com/thread/317633?ContentTypeID=1</link><pubDate>Tue, 29 Jun 2021 08:46:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2b40cc85-3a6d-4d4d-ac87-230bf5c9ba74</guid><dc:creator>NelsonGoncalves</dc:creator><description>&lt;p&gt;I found the cause this morning, while trying to figure out the reason behind&amp;nbsp;&lt;a href="https://devzone.nordicsemi.com/f/nordic-q-a/76883/increase-size-of-custom-spm-partition"&gt;this issue&lt;/a&gt;.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Because I am using crypto functions in my non-secure app, the crypto library needs an entropy source from the secure side. This is implemented as a secure service, in function&amp;nbsp;&amp;quot;`spm_request_random_number_nse&amp;quot;.&lt;/p&gt;
&lt;p&gt;I need to explicitly set&amp;nbsp;&lt;span&gt;CONFIG_SPM_SERVICE_RNG=y in the custom SPM prj.conf, so that it gets build in the SPM image and can latter be used by the non-secure application.&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span&gt;Because I do not use an entropy source, I believed it was not needed. But it turns out it is required by the crypto library. Hence the confusion.&lt;/span&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom SPM dependencies</title><link>https://devzone.nordicsemi.com/thread/317630?ContentTypeID=1</link><pubDate>Tue, 29 Jun 2021 08:36:23 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:c80746a3-53c9-4625-b48a-4de8fbb7b7a8</guid><dc:creator>Heidi</dc:creator><description>&lt;p&gt;Hi, I&amp;#39;m able to reproduce the error you&amp;#39;re seeing when building the application you provided.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;Unfortunately, I have not been able to solve the issue yet as we are very short-staffed due to the summer holidays.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom SPM dependencies</title><link>https://devzone.nordicsemi.com/thread/316508?ContentTypeID=1</link><pubDate>Tue, 22 Jun 2021 13:59:30 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:f3285695-e85a-4ce9-8fce-8d6fccb6f992</guid><dc:creator>NelsonGoncalves</dc:creator><description>&lt;p&gt;Hello Heidi,&lt;/p&gt;
&lt;p&gt;Searching through the menuconfig, it seems that option CONFIG_SPM_SERVICE_RNG is set (=y) because CONFIG_SECURE_SERVICES is set, which in turn is set by CONFIG_SPM.&lt;/p&gt;
&lt;p&gt;So I believe it is mandatory whem building a custom SPM. And it&amp;#39;s strange that you are not able to reproduce it.&lt;/p&gt;
&lt;p&gt;Here is the skeleton of my application, which reproduces the error.&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/custom_5F00_spm_5F00_dependencies.zip"&gt;devzone.nordicsemi.com/.../custom_5F00_spm_5F00_dependencies.zip&lt;/a&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom SPM dependencies</title><link>https://devzone.nordicsemi.com/thread/316242?ContentTypeID=1</link><pubDate>Mon, 21 Jun 2021 11:19:40 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:1a3a32d7-32cc-452d-96a4-35646fc2211d</guid><dc:creator>Heidi</dc:creator><description>&lt;p&gt;Hi, you can use menuconfig (run west menuconfig in the build directory) to see why a configuration is set and then go up from there.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Use &amp;quot;/&amp;quot; to search for symbols and &amp;quot;?&amp;quot; to see more information about the symbol (for instance, why it&amp;#39;s been set).&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Note that if it&amp;#39;s&amp;nbsp;been set by prj.conf directly, then that won&amp;#39;t show up here.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I&amp;#39;m not able to reproduce what you&amp;#39;re seeing but if you send over your application I can try to do this myself.&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom SPM dependencies</title><link>https://devzone.nordicsemi.com/thread/315881?ContentTypeID=1</link><pubDate>Thu, 17 Jun 2021 12:50:09 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:32a80ae5-a7c1-4a5c-8b9e-76661c085a77</guid><dc:creator>NelsonGoncalves</dc:creator><description>&lt;p&gt;Hello Heidi,&lt;/p&gt;
&lt;p&gt;We are using roughly the same configuration options and directory structure, the differences are:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;my custom SPM does not use the UARTE2 nor the PWM peripherals&lt;/li&gt;
&lt;li&gt;my custom SPM uses the crypto hardware and the mbedtls library&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Looking at the documentation here&amp;nbsp;&lt;a href="https://developer.nordicsemi.com/nRF_Connect_SDK/doc/1.5.0/kconfig/CONFIG_SPM_SERVICE_RNG.html?highlight=config_spm_service_rng#cmdoption-arg-CONFIG_SPM_SERVICE_RNG"&gt;https://developer.nordicsemi.com/nRF_Connect_SDK/doc/1.5.0/kconfig/CONFIG_SPM_SERVICE_RNG.html?highlight=config_spm_service_rng#cmdoption-arg-CONFIG_SPM_SERVICE_RNG&lt;/a&gt;, I believe that CONFIG_SPM_SERVICE_RNG is set when building the SPM.&lt;/p&gt;
&lt;p&gt;Maybe it is because I am including the mbedtls library ?&amp;nbsp;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item><item><title>RE: Custom SPM dependencies</title><link>https://devzone.nordicsemi.com/thread/315803?ContentTypeID=1</link><pubDate>Thu, 17 Jun 2021 09:37:47 GMT</pubDate><guid isPermaLink="false">137ad170-7792-4731-bb38-c0d22fbe4515:2514a13c-d430-4384-9bf9-690c26c564b5</guid><dc:creator>Heidi</dc:creator><description>&lt;p&gt;Hi!&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;I&amp;#39;m not able to reproduce this build error when following the tutorial.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Here is the application I am building with, can you see if there are any difference to your application.&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;a href="https://devzone.nordicsemi.com/cfs-file/__key/communityserver-discussions-components-files/4/custom_5F00_spm_5F00_NCS_5F00_1_5F00_5_5F00_0.7z"&gt;devzone.nordicsemi.com/.../custom_5F00_spm_5F00_NCS_5F00_1_5F00_5_5F00_0.7z&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;
&lt;p&gt;Best regards,&lt;/p&gt;
&lt;p&gt;Heidi&lt;/p&gt;
&lt;p&gt;&lt;/p&gt;&lt;div style="clear:both;"&gt;&lt;/div&gt;</description></item></channel></rss>