Hi Raef,
Thanks for quick reply.
These upgrade strategies are not something we need, or smth we plan to add.
Just wanted to know whether there are any plans upstream to adjust our schedule accordingly.
But if there are no plans regarding this topic then it looks ok for me.
Regards, Bohdan Hunko Cypress Semiconductor Ukraine Engineer CSUKR CSS ICW SW FW Mobile: +38099 50 19 714 Bohdan.Hunko@infineon.com
-----Original Message----- From: Raef Coles Raef.Coles@arm.com Sent: Tuesday, December 12, 2023 14:02 To: tf-m@lists.trustedfirmware.org; Hunko Bohdan (CSS ICW SW FW 3) Bohdan.Hunko@infineon.com Cc: nd nd@arm.com Subject: Re: Redundant checks in FWU code
Caution: This e-mail originated outside Infineon Technologies. Do not click on links or open attachments unless you validate it is safehttps://intranet-content.infineon.com/explore/aboutinfineon/rules/informationsecurity/ug/SocialEngineering/Pages/SocialEngineeringElements_en.aspx.
Hey Bohdan
Unfortunately I don't think there's any work to support this scheduled currently. We'd welcome such a contribution if this is something you need, and would be happy to help with reviews and design input.
Apologies, Raef
________________________________________ From: Bohdan.Hunko--- via TF-M tf-m@lists.trustedfirmware.org Sent: 12 December 2023 11:55 To: tf-m@lists.trustedfirmware.org Cc: nd Subject: [TF-M] Re: Redundant checks in FWU code
Hi all,
Any updates on this topic? (See the questions in previous mail)
Regards, Bohdan Hunko
Cypress Semiconductor Ukraine Engineer CSUKR CSS ICW SW FW Mobile: +38099 50 19 714 Bohdan.Hunko@infineon.commailto:Bohdan.Hunko@infineon.com
From: Bohdan.Hunko--- via TF-M tf-m@lists.trustedfirmware.org Sent: Friday, December 8, 2023 11:39 To: Sherry.Zhang2@arm.com; tf-m@lists.trustedfirmware.org Cc: nd@arm.com Subject: [TF-M] Re: Redundant checks in FWU code
Caution: This e-mail originated outside Infineon Technologies. Do not click on links or open attachments unless you validate it is safehttps://intranet-content.infineon.com/explore/aboutinfineon/rules/informationsecurity/ug/SocialEngineering/Pages/SocialEngineeringElements_en.aspx.
Hi Sherry,
Thanks for the explanations.
So if I understood correctly, there is a plan to support then? If so then when? It is not an issue for us but just want to know to better schedule our work.
Regards, Bohdan Hunko
Cypress Semiconductor Ukraine Engineer CSUKR CSS ICW SW FW Mobile: +38099 50 19 714 Bohdan.Hunko@infineon.commailto:Bohdan.Hunko@infineon.com
From: Sherry Zhang <Sherry.Zhang2@arm.commailto:Sherry.Zhang2@arm.com> Sent: Friday, December 8, 2023 04:43 To: Hunko Bohdan (CSS ICW SW FW 3) <Bohdan.Hunko@infineon.commailto:Bohdan.Hunko@infineon.com>; tf-m@lists.trustedfirmware.orgmailto:tf-m@lists.trustedfirmware.org Cc: nd <nd@arm.commailto:nd@arm.com> Subject: RE: Redundant checks in FWU code
Caution: This e-mail originated outside Infineon Technologies. Do not click on links or open attachments unless you validate it is safehttps://intranet-content.infineon.com/explore/aboutinfineon/rules/informationsecurity/ug/SocialEngineering/Pages/SocialEngineeringElements_en.aspx.
Hi Bohdan,
FWU is not supported in DIRECT_XIP and RAM_LOAD upgrade strategies. The main reason is that, in FWU, it does not record which slot is the active running slot and always takes the primary slot as the active running slot. In the c source code, these two upgrade strategies are taken into consideration in component state management to make it easier to support them later in FWU.
Regards, Sherry Zhang
From: Bohdan.Hunko@infineon.commailto:Bohdan.Hunko@infineon.com <Bohdan.Hunko@infineon.commailto:Bohdan.Hunko@infineon.com> Sent: Thursday, December 7, 2023 10:52 PM To: tf-m@lists.trustedfirmware.orgmailto:tf-m@lists.trustedfirmware.org; Sherry Zhang <Sherry.Zhang2@arm.commailto:Sherry.Zhang2@arm.com> Subject: Redundant checks in FWU code
Hi all,
In config/check_config.cmake there is a following code: tfm_invalid_config((MCUBOOT_UPGRADE_STRATEGY STREQUAL " DIRECT_XIP " OR MCUBOOT_UPGRADE_STRATEGY STREQUAL "RAM_LOAD") AND TFM_PARTITION_FIRMWARE_UPDATE)
So looks like FWU is not supported when DIRECT_XIP or RAM_LOAD upgrade strategies are used.
But then in FWU code I see a lot of checks for DIRECT_XIP or RAM_LOAD, for example in fwu_bootloader_get_image_info: #if !defined(MCUBOOT_DIRECT_XIP) && !defined(MCUBOOT_RAM_LOAD) && \ !defined(MCUBOOT_OVERWRITE_ONLY)
What is the point of these checks if it is impossible to compile FWU code with DIRECT_XIP Because of check in config/check_config.cmake?
Regards, Bohdan Hunko
Cypress Semiconductor Ukraine Engineer CSUKR CSS ICW SW FW Mobile: +38099 50 19 714 Bohdan.Hunko@infineon.commailto:Bohdan.Hunko@infineon.com