diff options
Diffstat (limited to 'include/asm-x86/paravirt.h')
-rw-r--r-- | include/asm-x86/paravirt.h | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/include/asm-x86/paravirt.h b/include/asm-x86/paravirt.h index c56b17a5eba0..73547acbbbf5 100644 --- a/include/asm-x86/paravirt.h +++ b/include/asm-x86/paravirt.h | |||
@@ -101,6 +101,11 @@ struct pv_cpu_ops { | |||
101 | unsigned long (*read_cr4)(void); | 101 | unsigned long (*read_cr4)(void); |
102 | void (*write_cr4)(unsigned long); | 102 | void (*write_cr4)(unsigned long); |
103 | 103 | ||
104 | #ifdef CONFIG_X86_64 | ||
105 | unsigned long (*read_cr8)(void); | ||
106 | void (*write_cr8)(unsigned long); | ||
107 | #endif | ||
108 | |||
104 | /* Segment descriptor handling */ | 109 | /* Segment descriptor handling */ |
105 | void (*load_tr_desc)(void); | 110 | void (*load_tr_desc)(void); |
106 | void (*load_gdt)(const struct desc_ptr *); | 111 | void (*load_gdt)(const struct desc_ptr *); |
@@ -614,6 +619,16 @@ static inline void write_cr4(unsigned long x) | |||
614 | PVOP_VCALL1(pv_cpu_ops.write_cr4, x); | 619 | PVOP_VCALL1(pv_cpu_ops.write_cr4, x); |
615 | } | 620 | } |
616 | 621 | ||
622 | static inline unsigned long read_cr8(void) | ||
623 | { | ||
624 | return PVOP_CALL0(unsigned long, pv_cpu_ops.read_cr8); | ||
625 | } | ||
626 | |||
627 | static inline void write_cr8(unsigned long x) | ||
628 | { | ||
629 | PVOP_VCALL1(pv_cpu_ops.write_cr8, x); | ||
630 | } | ||
631 | |||
617 | static inline void raw_safe_halt(void) | 632 | static inline void raw_safe_halt(void) |
618 | { | 633 | { |
619 | PVOP_VCALL0(pv_irq_ops.safe_halt); | 634 | PVOP_VCALL0(pv_irq_ops.safe_halt); |