// SPDX-License-Identifier: MPL-2.0 #ifndef SH_LIB_PRINT_H #define SH_LIB_PRINT_H #include "std/status.h" #include "std/type.h" #include "kernel/log.h" #include "kernel/conf.h" #include "cpu/ap.h" #define SH_DEBUG SH_LOG_DEBUG #define SH_LOG SH_LOG_LOG #define SH_WARNING SH_LOG_WARNING #define SH_ERROR SH_LOG_ERROR #define SH_CRITICAL SH_LOG_CRITICAL #define SH_FATAL SH_LOG_FATAL #define SH_TEST SH_LOG_TEST #define SH_FAULT SH_LOG_FAULT // Setup rings buffer for APs SH_STATUS sh_print_setup_ring_buffers_per_ap(sh_conf_BOOT_CONFIG *boot_config); // Print string SH_STATUS sh_print(sh_log_OUTPUT_TYPE output_type,char* text); // Print string, format it before hand SH_STATUS sh_printf(sh_log_OUTPUT_TYPE output_type,char* format,...); // Priority print string, reserved to IRQ handler SH_STATUS sh_iprint(sh_log_OUTPUT_TYPE output_type,char* text); // Priority print string, reserved to IRQ handler, format it before hand SH_STATUS sh_iprintf(sh_log_OUTPUT_TYPE output_type,char* text,...); // Format a string and put it into the provided buffer SH_STATUS sh_sprintf(char* output_string,sh_uint64 output_len,char* format,...); #endif