mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-09-23 09:47:44 +00:00
HV: explicitly init lock variable before using it
1. though "pci_device_lock" & "logmsg_ctl.lock" are set to 0 when system dose memory initialization, it is better to explicitly init them before using. 2. unify the usage of spinlock_init Tracked-On: #4827 Signed-off-by: Minggui Cao <minggui.cao@intel.com> Acked-by: Eddie Dong <eddie.dong@intel.com>
This commit is contained in:
@@ -29,6 +29,8 @@ void init_logmsg(uint32_t flags)
|
||||
{
|
||||
logmsg_ctl.flags = flags;
|
||||
logmsg_ctl.seq = 0;
|
||||
|
||||
spinlock_init(&(logmsg_ctl.lock));
|
||||
}
|
||||
|
||||
void do_logmsg(uint32_t severity, const char *fmt, ...)
|
||||
|
Reference in New Issue
Block a user