• Ingo Molnar's avatar
    x86/fpu: Split copy_xstate_to_user() into copy_xstate_to_kernel() & copy_xstate_to_user() · f0d4f30a
    Ingo Molnar authored
    copy_xstate_to_user() is a weird API - in part due to a bad API inherited
    from the regset APIs.
    
    But don't propagate that bad API choice into the FPU code - so as a first
    step split the API into kernel and user buffer handling routines.
    
    (Also split the xstate_copyout() internal helper.)
    
    The split API is a dumb duplication that should be obviously correct, the
    real splitting will be done in the next patch.
    
    Cc: Andrew Morton <akpm@linux-foundation.org>
    Cc: Andy Lutomirski <luto@amacapital.net>
    Cc: Andy Lutomirski <luto@kernel.org>
    Cc: Borislav Petkov <bp@alien8.de>
    Cc: Dave Hansen <dave.hansen@linux.intel.com>
    Cc: Eric Biggers <ebiggers3@gmail.com>
    Cc: Fenghua Yu <fenghua.yu@intel.com>
    Cc: Linus Torvalds <torvalds@linux-foundation.org>
    Cc: Oleg Nesterov <oleg@redhat.com>
    Cc: Peter Zijlstra <peterz@infradead.org>
    Cc: Rik van Riel <riel@redhat.com>
    Cc: Thomas Gleixner <tglx@linutronix.de>
    Cc: Yu-cheng Yu <yu-cheng.yu@intel.com>
    Link: http://lkml.kernel.org/r/20170923130016.21448-3-mingo@kernel.orgSigned-off-by: default avatarIngo Molnar <mingo@kernel.org>
    f0d4f30a
xstate.c 30.7 KB