Hi Bertrand,

On 30/05/2024 14:22, Bertrand Marquis wrote:
On 30 May 2024, at 12:35, Julien Grall <[email protected]> wrote:

Hi Bertrand,

On 30/05/2024 10:40, Bertrand Marquis wrote:
But we are making assumption that all TEE implementation will have its
node inside "/firmware/". I am not 100% sure that this is correct. For
example I saw that Google Trusty uses "/trusty" node (directly inside
the DTS root). On other hand, it is not defined in dts bindings, as far
as I know.
Regarding the firmware part you can easily handle that by looking for /firmware
and create it if it does not exist before creating your sub-node and this should
be node in the optee node creation function not in tee.c.

This would work if the node /firmware doesn't exist. But how would you handle 
the case where it is already present?

I looked at the libfdt API and AFAICT the DTB creation needs to be linear. IOW, 
you can't add a subnode to an already created node.

There is an helper to create a placeholder, but AFAIK this is only for a 
property. You also need to know the size in advance.

I thought it was possible but i definitely can be wrong.

As right now we have only one need for the node, we could delay a possible 
solution and just create it in the optee driver.

I am fine with that.

Cheers,

--
Julien Grall

Reply via email to