]> xenbits.xensource.com Git - people/dwmw2/xen.git/commitdiff
x86/p2m: p2m_flags_to_type() deals only with "unsigned int"
authorJan Beulich <jbeulich@suse.com>
Fri, 21 Feb 2020 16:16:25 +0000 (17:16 +0100)
committerJan Beulich <jbeulich@suse.com>
Fri, 21 Feb 2020 16:16:25 +0000 (17:16 +0100)
PTE flags, for now at least, get stored in "unsigned int". Hence there's
no need to widen the values to "unsigned long" before processing them.

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/include/asm-x86/p2m.h

index cca6a1a223f250c3f4f64fe65b487da3c116eb6e..517974be5425e0f002572c42846bfe8990961c60 100644 (file)
@@ -796,7 +796,7 @@ extern void audit_p2m(struct domain *d,
  */
 
 /* Extract the type from the PTE flags that store it */
-static inline p2m_type_t p2m_flags_to_type(unsigned long flags)
+static inline p2m_type_t p2m_flags_to_type(unsigned int flags)
 {
     /* For AMD IOMMUs we need to use type 0 for plain RAM, but we need
      * to make sure that an entirely empty PTE doesn't have RAM type */