Hi Bohdan,

 

  1. Makes sense. Would you like to provide a patch?
  2. I guess you’re referring to the ITS and PS *flash* areas?

Flash devices are usually accessed from flash controllers.

So even if you assigned an MMIO region with the flash address, ITS wouldn’t access it directly.

In theory, a flash controller MMIO region can be added to ITS instead.

Since the ITS is a PRoT, it is privileged. It’s OK not having that MMIO regions.

 

Best Regards,

Kevin

 

From: Bohdan.Hunko--- via TF-M <tf-m@lists.trustedfirmware.org>
Sent: Wednesday, July 6, 2022 7:20 PM
To: tf-m@lists.trustedfirmware.org
Subject: [TF-M] Manifest files questions

 

Hi everyone,

 

I have several questions related to manifest files in TFM:

  1. Currently TFM dos not support dynamic memory allocation, so heap_size manifest field is a bit special. Presence of heap_size field for library model will generate error in tfm_spm_db_func.inc.template but when TFM_PSA_API is ON heap_size is used in partition_load_info.template which will silently set .heap_size struct field to 0 without generation of any error.
    As dynamic memory allocation is not supported I think error should be generated in both files. Also I think that error should only be generated if heap_size filed is present and is not “0” (if it is not present or is 0 then no error should be generated because it is compliant with “no dynamic memory rule”)
  2. Manifest files support numbered mmio regions for partitions.
    Example
      "mmio_regions": [
        {
          "base": "MY_CUSTOM_REGION_BASE",
          "size": "MY_CUSTOM_REGION_SIZE",
          "permission": "READ-WRITE"
        }
    ]
    The questions is why doesn’t TFM use this field for ITS and PS areas instead of handling them manually? Can this be reworked to use mmio regions? If so then is this work planned and when approximately it will be done?

 

Regards,

Bohdan Hunko

 

Cypress Semiconductor Ukraine

Engineer

CSUKR CSS ICW SW FW

Mobile: +38099 50 19 714
Bohdan.Hunko@infineon.com