implementing noinit section on zephyr

NCS 2.7.0

nrf52840

I'm currently porting software that was originally developed for nrf52832 on NRF5 SDK to run on Zephyr. I am currently on a deadline to delivery a prototype of the manufacturing test firmware to the factory for first PCB validation.  This release will be single image and then I will begin work to implement the bootloader which of course will mean multi-image build.

One of the tests utilized a noinit region to confirm that power to the nrf processor was cut between phases of the test.  The implementation of noinit data was fairly straight forward on nrf5 sdk.  A section was defined in the flash_placement.xml.  This section also had to be coordinated with the bootloader so it wasn't overwritten.

I'm trying to understand the process with zephyr. I will make some statements of my understanding from reading portions of the documentation.  Please correct anything I get wrong.  I also have some questions inline which I will number and bold.

It seems like it may vary depending on whether it is single image or multi-image.  For multi-image it appears the partition manager comes into play.  I'm unclear on how it works for single image. 

A note I found on the partition manager page ( Partition Manager )  

When you build a multi-image application using the Partition Manager, the devicetree source flash partitions are ignored.

Would imply that single image builds take partition definitions from devicetree.  

Alternatively, it seems I can use partition manage with a single image by including the Kconfig variable CONFIG_PM_SINGLE_IMAGE in my prj.conf.  

It also appears with partition manager there is a mechanism for a subsystem to provide a supplemental configuration, however I only find subsys/partition_manager within the nrf module.  

1) Out of general curiosity, Is partition_manager a proprietary element of NCS that is not included with Zephyr itself?

2) Can I add a subsystem pm.yml from my out-of-tree customer/application repository?  

3) Is partition_manager the recommended way to add a noinit section?  Are there any samples that would demonstrate how it should be implemented?

4) Since my project will ultimately be multi-image with a bootloader, is my best choice to develop with partition_manager?  

5) Any change with partition_manager in NCS 2.8.0 or planned for the future?

a*

Parents
  • After switching on CONFIG_PM_SIGNLE_IMAGE, I'm finding that my fixed partitions defined in device tree are broken.  It looks like partition manager can only handle predefined regions that are commonly used by zephyr.  

    6) Is there any plan for multi-image builds to fully support device tree specified fixed partitions?  Perhaps the partition_manager could process devicetree output and automatically generate the correct sections based for the fixed partitions?

    7) Is it the case that I need to define custom partitions in the root image via a file like pm.yml?

Reply
  • After switching on CONFIG_PM_SIGNLE_IMAGE, I'm finding that my fixed partitions defined in device tree are broken.  It looks like partition manager can only handle predefined regions that are commonly used by zephyr.  

    6) Is there any plan for multi-image builds to fully support device tree specified fixed partitions?  Perhaps the partition_manager could process devicetree output and automatically generate the correct sections based for the fixed partitions?

    7) Is it the case that I need to define custom partitions in the root image via a file like pm.yml?

Children
No Data
Related