Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

drivers: Add FFA_CONSOLE based console driver for log #6843

Merged
merged 1 commit into from
May 21, 2024

Conversation

ysbnim
Copy link
Contributor

@ysbnim ysbnim commented May 17, 2024

This console driver uses FFA_CONSOLE ABI to write the trace logs.

If CFG_FFA_CONSOLE is enabled, OP-TEE will try to initialize the FFA console driver.

@ysbnim ysbnim force-pushed the master branch 3 times, most recently from 54a282e to 0cedbe4 Compare May 17, 2024 14:01
Copy link
Contributor

@jforissier jforissier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Hi @ysbnim, thanks for the patch! Please see my comments below.

core/drivers/ffa_console.c Outdated Show resolved Hide resolved
core/drivers/ffa_console.c Outdated Show resolved Hide resolved
core/drivers/ffa_console.c Outdated Show resolved Hide resolved
core/drivers/ffa_console.c Outdated Show resolved Hide resolved
core/drivers/ffa_console.c Outdated Show resolved Hide resolved
core/include/drivers/ffa_console.h Outdated Show resolved Hide resolved
core/kernel/console.c Show resolved Hide resolved
@ysbnim ysbnim force-pushed the master branch 2 times, most recently from 6a1c24f to 908df06 Compare May 18, 2024 13:11
Copy link
Contributor

@jforissier jforissier left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

One more comment on something I missed during my first review. With that:

Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>

core/drivers/ffa_console.c Outdated Show resolved Hide resolved
This console driver uses FFA_CONSOLE ABI to write the trace logs.

If CFG_FFA_CONSOLE is enabled, OP-TEE will try to initialize the console
driver that uses FFA interface to print trace logs.

Signed-off-by: Sungbae Yoo <sungbaey@nvidia.com>
Reviewed-by: Jerome Forissier <jerome.forissier@linaro.org>
@jforissier jforissier merged commit d4a8769 into OP-TEE:master May 21, 2024
7 checks passed
Copy link
Contributor

@jenswi-linaro jenswi-linaro left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I'm adding a few comments I'd like to have addressed in a new PR.

#include <drivers/serial.h>
#include <kernel/thread_arch.h>

#define FFA_CONSOLE_LOG_32 (0x8400008A)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is defined in core/arch/arm/include/ffa.h already.


static void ffa_console_putc(struct serial_chip *chip __unused, int ch)
{
thread_hvc(FFA_CONSOLE_LOG_32, 1, ch, 0);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The ABI supports printing more than one character at a time.
Can thread_smccc() be used instead to support an SPMC at EL3?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants