vmx: tiny fix for MACRO name and print format

1. CPU_SEG_WRITE->CPU_SEG_READ: it's actually seg read
2. 0x%hu -> 0x%x: it need print hex format

Tracked-On: #1833
Signed-off-by: Jason Chen CJ <jason.cj.chen@intel.com>
This commit is contained in:
Jason Chen CJ
2018-11-16 12:47:54 +08:00
committed by lijinxia
parent 9c025190a9
commit 2c581751de
2 changed files with 14 additions and 14 deletions

View File

@@ -331,9 +331,9 @@ void stop_cpus(void);
void wait_sync_change(uint64_t *sync, uint64_t wake_sync);
void cpu_l1d_flush(void);
#define CPU_SEG_WRITE(seg, value16) \
#define CPU_SEG_READ(seg, result_ptr) \
{ \
asm volatile ("mov %%" STRINGIFY(seg) ", %%ax": "=a" (value16)); \
asm volatile ("mov %%" STRINGIFY(seg) ", %0": "=r" (*(result_ptr))); \
}
/* Read control register */