lkml.org 
[lkml]   [2021]   [Jun]   [22]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
    /
    Date
    From
    SubjectRe: [patch V3 57/66] x86/pkru: Remove xstate fiddling from write_pkru()
    On Fri, Jun 18, 2021 at 04:19:20PM +0200, Thomas Gleixner wrote:
    > The PKRU value of a task is stored in task->thread.pkru when the task is
    > scheduled out. PKRU is restored on schedule in from there. So keeping the
    > XSAVE buffer up to date is a pointless exercise.
    >
    > Remove the xstate fiddling and cleanup all related functions.
    >
    > Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
    > ---
    > arch/x86/include/asm/pkru.h | 17 ++++-------------
    > arch/x86/include/asm/special_insns.h | 14 +-------------
    > arch/x86/kvm/x86.c | 4 ++--
    > 3 files changed, 7 insertions(+), 28 deletions(-)

    Yap, untangling PKRU from XSAVE makes the related code a lot nicer, I
    gotta say.

    Reviewed-by: Borislav Petkov <bp@suse.de>

    --
    Regards/Gruss,
    Boris.

    SUSE Software Solutions Germany GmbH, GF: Felix Imendörffer, HRB 36809, AG Nürnberg

    \
     
     \ /
      Last update: 2021-06-22 19:16    [W:4.645 / U:0.012 seconds]
    ©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site