]> xenbits.xensource.com Git - people/larsk/xen.git/commitdiff
x86: adjust cr3_pcid() return type
authorJan Beulich <jbeulich@suse.com>
Wed, 18 Sep 2019 13:14:08 +0000 (15:14 +0200)
committerJan Beulich <jbeulich@suse.com>
Wed, 18 Sep 2019 13:14:08 +0000 (15:14 +0200)
There's no need for it to be 64 bits wide - only the low twelve bits
of CR3 hold the PCID.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Roger Pau Monné <roger.pau@citrix.com>
Acked-by: Andrew Cooper <andrew.cooper3@citrix.com>
xen/arch/x86/flushtlb.c
xen/include/asm-x86/processor.h

index 4004129c4920c7b45a4437b7fe0c0ed289acc79f..915094dd616945b897e33edbcff654dd8a5c6eb5 100644 (file)
@@ -103,7 +103,8 @@ static void do_tlb_flush(void)
 
 void switch_cr3_cr4(unsigned long cr3, unsigned long cr4)
 {
-    unsigned long flags, old_cr4, old_pcid;
+    unsigned long flags, old_cr4;
+    unsigned int old_pcid;
     u32 t;
 
     /* This non-reentrant function is sometimes called in interrupt context. */
index a6733721f0d6cd85790850f2137ed75a2145697f..e25c3223e4333011de213bbedb414ac6a7e6523e 100644 (file)
@@ -287,7 +287,7 @@ static inline unsigned long cr3_pa(unsigned long cr3)
     return cr3 & X86_CR3_ADDR_MASK;
 }
 
-static inline unsigned long cr3_pcid(unsigned long cr3)
+static inline unsigned int cr3_pcid(unsigned long cr3)
 {
     return cr3 & X86_CR3_PCID_MASK;
 }