mirror of
https://github.com/projectacrn/acrn-hypervisor.git
synced 2025-06-19 04:02:05 +00:00
HV:treewide:rename union lapic_id and struct segment
For data structure types "union lapic_id and struct segment", its name is identical with variable name in the same scope. This MISRA C violation is detected by static analysis tool. Naming convention rule:If the data structure is corresponding to hardware resource (such as register, segment selector), its name need resource shorten name suffix (such as _reg, _sel). The following udpates are made: union lapic_id-->union lapic_id_reg struct segment-->struct segment_sel Signed-off-by: Xiangyang Wu <xiangyang.wu@linux.intel.com> Reviewed-by: Junjie Mao <junjie.mao@intel.com>
This commit is contained in:
parent
c477211d4e
commit
159d57b703
@ -100,7 +100,7 @@ struct cpu_gp_regs {
|
|||||||
uint64_t r15;
|
uint64_t r15;
|
||||||
};
|
};
|
||||||
|
|
||||||
struct segment {
|
struct segment_sel {
|
||||||
uint16_t selector;
|
uint16_t selector;
|
||||||
uint64_t base;
|
uint64_t base;
|
||||||
uint32_t limit;
|
uint32_t limit;
|
||||||
@ -155,16 +155,16 @@ struct run_context {
|
|||||||
uint64_t vmx_cr4;
|
uint64_t vmx_cr4;
|
||||||
|
|
||||||
/* segment registers */
|
/* segment registers */
|
||||||
struct segment cs;
|
struct segment_sel cs;
|
||||||
struct segment ss;
|
struct segment_sel ss;
|
||||||
struct segment ds;
|
struct segment_sel ds;
|
||||||
struct segment es;
|
struct segment_sel es;
|
||||||
struct segment fs;
|
struct segment_sel fs;
|
||||||
struct segment gs;
|
struct segment_sel gs;
|
||||||
struct segment tr;
|
struct segment_sel tr;
|
||||||
struct segment idtr;
|
struct segment_sel idtr;
|
||||||
struct segment ldtr;
|
struct segment_sel ldtr;
|
||||||
struct segment gdtr;
|
struct segment_sel gdtr;
|
||||||
|
|
||||||
/* The 512 bytes area to save the FPU/MMX/SSE states for the guest */
|
/* The 512 bytes area to save the FPU/MMX/SSE states for the guest */
|
||||||
uint64_t
|
uint64_t
|
||||||
|
@ -112,7 +112,7 @@ enum intr_cpu_startup_shorthand {
|
|||||||
INTR_CPU_STARTUP_UNKNOWN,
|
INTR_CPU_STARTUP_UNKNOWN,
|
||||||
};
|
};
|
||||||
|
|
||||||
union lapic_id {
|
union lapic_id_reg {
|
||||||
uint32_t value;
|
uint32_t value;
|
||||||
struct {
|
struct {
|
||||||
uint8_t xapic_id;
|
uint8_t xapic_id;
|
||||||
|
Loading…
Reference in New Issue
Block a user