Hi Ken, All,

 

I like your approach of providing a minimalistic version of printf() for the logging purpose only.

This would benefit to code size and performance while rich print formatting has no practical needs in this project.

 

Best regards,

Anton

 

 

From: TF-M <tf-m-bounces@lists.trustedfirmware.org> On Behalf Of Ken Liu via TF-M
Sent: 27 December 2019 03:38
To: tf-m@lists.trustedfirmware.org
Cc: nd <nd@arm.com>
Subject: [TF-M] The logging mechanism change in TF-M

 

Hi,

 

We met some issues while implementing logging APIs like printf:

 

 

So it would be better that we remove the reference to toolchain stdout APIs, this could simplify the logging implementation since firmware logging MAY not need rich format (Comments?). A customized printf-like API is provided for logging but not being named as ‘printf’ directly.

 

Due to the default logging device (UART) driver may be implemented for threads only, the logging functionality in exceptions is going to be suppressed for a while until we figure out how the logging in exceptions can be – there is a trade-off between security consideration (isolation) and performance (Routing the logging API to somewhere costs).

 

Please provide your thinking, or what kind of logging API you are using.

 

Thanks

 

/Ken