x86: remove _PAGE_PSE check from get_page_from_l2e()
authorJan Beulich <jbeulich@suse.com>
Fri, 15 Dec 2017 10:14:31 +0000 (11:14 +0100)
committerJan Beulich <jbeulich@suse.com>
Fri, 15 Dec 2017 10:14:31 +0000 (11:14 +0100)
With L2_DISALLOW_MASK containing _PAGE_PSE unconditionally as of commit
56fff3e5e9 ("x86: nuke PV superpage option and code") there's no point
anymore in separately checking for the bit.

Signed-off-by: Jan Beulich <jbeulich@suse.com>
Reviewed-by: Andrew Cooper <andrew.cooper3@citrix.com>
xen/arch/x86/mm.c

index 3eb338036e717c1464a50b87ed949107293f7fb9..11a21c254cf53e7164457c7f4066f8c541aa6e2e 100644 (file)
@@ -1113,15 +1113,11 @@ get_page_from_l2e(
         return -EINVAL;
     }
 
-    if ( !(l2e_get_flags(l2e) & _PAGE_PSE) )
-    {
-        rc = get_page_and_type_from_mfn(_mfn(mfn), PGT_l1_page_table, d, 0, 0);
-        if ( unlikely(rc == -EINVAL) && get_l2_linear_pagetable(l2e, pfn, d) )
-            rc = 0;
-        return rc;
-    }
+    rc = get_page_and_type_from_mfn(_mfn(mfn), PGT_l1_page_table, d, 0, 0);
+    if ( unlikely(rc == -EINVAL) && get_l2_linear_pagetable(l2e, pfn, d) )
+        rc = 0;
 
-    return -EINVAL;
+    return rc;
 }