mm/core, x86/mm/pkeys: Add execute-only protection keys support
[linux-2.6-block.git] / arch / x86 / kernel / fpu / xstate.c
index 50813c35e9d969e1008173b6321f850482b09156..1b1981812bb611b0e890a812b2e377d8abd39493 100644 (file)
@@ -877,8 +877,6 @@ int arch_set_user_pkey_access(struct task_struct *tsk, int pkey,
        int pkey_shift = (pkey * PKRU_BITS_PER_PKEY);
        u32 new_pkru_bits = 0;
 
-       if (!validate_pkey(pkey))
-               return -EINVAL;
        /*
         * This check implies XSAVE support.  OSPKE only gets
         * set if we enable XSAVE and we enable PKU in XCR0.