OSDN Git Service

x86/fpu/xstate: Provide xstate_calculate_size()
authorChang S. Bae <chang.seok.bae@intel.com>
Thu, 21 Oct 2021 22:55:07 +0000 (15:55 -0700)
committerBorislav Petkov <bp@suse.de>
Tue, 26 Oct 2021 08:18:09 +0000 (10:18 +0200)
commit84e4dccc8fce20b497388d756e12de5c9006eb48
tree4dd53a75557ed02fe93248718fffa5d0fa3d017a
parent3aac3ebea08f2d342364f827c8979ab0e1dd591e
x86/fpu/xstate: Provide xstate_calculate_size()

Split out the size calculation from the paranoia check so it can be used
for recalculating buffer sizes when dynamically enabled features are
supported.

Signed-off-by: Chang S. Bae <chang.seok.bae@intel.com>
[ tglx: Adopted to changed base code ]
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Chang S. Bae <chang.seok.bae@intel.com>
Signed-off-by: Borislav Petkov <bp@suse.de>
Link: https://lkml.kernel.org/r/20211021225527.10184-4-chang.seok.bae@intel.com
arch/x86/kernel/fpu/xstate.c