mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-11-13 00:53:09 +00:00
hv: use asm_pause() to replace inline ASM to satisfy MISRAC
pause_cpu() --> asm_pause() hlt_cpu() --> asm_hlt() inline ASM pause --> asm_pause() Tracked-On: #1821 Signed-off-by: Shuo A Liu <shuo.a.liu@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
@@ -6,6 +6,7 @@
|
||||
|
||||
#ifndef LOGMSG_H
|
||||
#define LOGMSG_H
|
||||
#include <cpu.h>
|
||||
|
||||
/* Logging severity levels */
|
||||
#define LOG_FATAL 1U
|
||||
@@ -116,6 +117,6 @@ void vprintf(const char *fmt, va_list args);
|
||||
#define panic(...) \
|
||||
do { pr_fatal("PANIC: %s line: %d\n", __func__, __LINE__); \
|
||||
pr_fatal(__VA_ARGS__); \
|
||||
while (1) { asm volatile ("pause" ::: "memory"); }; } while (0)
|
||||
while (1) { asm_pause(); }; } while (0)
|
||||
|
||||
#endif /* LOGMSG_H */
|
||||
|
||||
Reference in New Issue
Block a user