summaryrefslogtreecommitdiff
path: root/security
diff options
context:
space:
mode:
Diffstat (limited to 'security')
-rw-r--r--security/tlk_driver/ote_log.c6
1 files changed, 4 insertions, 2 deletions
diff --git a/security/tlk_driver/ote_log.c b/security/tlk_driver/ote_log.c
index 9a70077dbe7b..0e8f6b290f30 100644
--- a/security/tlk_driver/ote_log.c
+++ b/security/tlk_driver/ote_log.c
@@ -186,9 +186,11 @@ static int __init ote_logger_init(void)
smc_args[0] = TE_SMC_INIT_LOGGER;
smc_args[1] = (uintptr_t)cb;
- tlk_generic_smc(smc_args[0], smc_args[1], 0);
- ote_logging_enabled = 1;
+ /* enable logging only if secure firmware supports it */
+ if (!tlk_generic_smc(smc_args[0], smc_args[1], 0))
+ ote_logging_enabled = 1;
+
ote_print_logs();
#else
smc_args[0] = TE_SMC_INIT_LOGGER;