mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-08-10 12:32:45 +00:00
1. fix cpu family calculation
2. Modifie the parameter 'fl' order Tracked-On:#3142 Signed-off-by: Andy <andyx.liu@intel.com>
This commit is contained in:
parent
238d8bbaa2
commit
aba357dd36
@ -214,9 +214,9 @@ void init_pcpu_capabilities(void)
|
||||
cpuid(CPUID_FEATURES, &eax, &unused,
|
||||
&boot_cpu_data.cpuid_leaves[FEAT_1_ECX],
|
||||
&boot_cpu_data.cpuid_leaves[FEAT_1_EDX]);
|
||||
family = (eax >> 8U) & 0xffU;
|
||||
family = (eax >> 8U) & 0xfU;
|
||||
if (family == 0xFU) {
|
||||
family += (eax >> 20U) & 0xffU;
|
||||
family += ((eax >> 20U) & 0xffU) << 4U;
|
||||
}
|
||||
boot_cpu_data.family = (uint8_t)family;
|
||||
|
||||
|
4
hypervisor/lib/sprintf.c
Normal file → Executable file
4
hypervisor/lib/sprintf.c
Normal file → Executable file
@ -105,8 +105,8 @@ static const char *get_flags(const char *s_arg, uint32_t *flags)
|
||||
PRINT_FLAG_ALTERNATE_FORM, /* # */
|
||||
PRINT_FLAG_PAD_ZERO, /* 0 */
|
||||
PRINT_FLAG_LEFT_JUSTIFY, /* - */
|
||||
PRINT_FLAG_SIGN, /* + */
|
||||
PRINT_FLAG_SPACE /* ' ' */
|
||||
PRINT_FLAG_SPACE, /* ' ' */
|
||||
PRINT_FLAG_SIGN /* + */
|
||||
};
|
||||
uint32_t i;
|
||||
bool found;
|
||||
|
Loading…
Reference in New Issue
Block a user