x86/fpu: Calculate the default sizes independently
authorChang S. Bae <chang.seok.bae@intel.com>
Thu, 21 Oct 2021 22:55:25 +0000 (15:55 -0700)
committerBorislav Petkov <bp@suse.de>
Tue, 26 Oct 2021 08:53:02 +0000 (10:53 +0200)
commit2ae996e0c1a38ca57a52438ab9deec6761dcba62
tree8d7dc44ff61ff3a4b17a5f1d3c761a2da1c10f3c
parenteec2113eabd92b7bfbaf1033fa82dc8eb4951203
x86/fpu: Calculate the default sizes independently

When dynamically enabled states are supported the maximum and default sizes
for the kernel buffers and user space interfaces are not longer identical.

Put the necessary calculations in place which only take the default enabled
features into account.

Signed-off-by: Chang S. Bae <chang.seok.bae@intel.com>
Signed-off-by: Thomas Gleixner <tglx@linutronix.de>
Signed-off-by: Borislav Petkov <bp@suse.de>
Link: https://lore.kernel.org/r/20211021225527.10184-22-chang.seok.bae@intel.com
arch/x86/kernel/fpu/xstate.c