{"id":75815,"date":"2026-01-25T18:45:55","date_gmt":"2026-01-25T15:15:55","guid":{"rendered":"https:\/\/afaghhosting.net\/blog\/cve-2026-23005-x86-fpu-clear-xstate_bvi-in-guest-xsave-state-whenever-xfdi1\/"},"modified":"2026-01-25T18:45:55","modified_gmt":"2026-01-25T15:15:55","slug":"cve-2026-23005-x86-fpu-clear-xstate_bvi-in-guest-xsave-state-whenever-xfdi1","status":"publish","type":"post","link":"https:\/\/afaghhosting.net\/blog\/cve-2026-23005-x86-fpu-clear-xstate_bvi-in-guest-xsave-state-whenever-xfdi1\/","title":{"rendered":"CVE-2026-23005 &#8211; x86\/fpu: Clear XSTATE_BV[i] in guest XSAVE state whenever XFD[i]=1"},"content":{"rendered":"<p>CVE ID : CVE-2026-23005<\/p>\n<p>Published :  Jan. 25, 2026, 3:15 p.m. | 1\u00a0hour, 46\u00a0minutes ago<\/p>\n<p>Description : In the Linux kernel, the following vulnerability has been resolved:<\/p>\n<p>x86\/fpu: Clear XSTATE_BV[i] in guest XSAVE state whenever XFD[i]=1<\/p>\n<p>When loading guest XSAVE state via KVM_SET_XSAVE, and when updating XFD in<br \/>\nresponse to a guest WRMSR, clear XFD-disabled features in the saved (or to<br \/>\nbe restored) XSTATE_BV to ensure KVM doesn&#8217;t attempt to load state for<br \/>\nfeatures that are disabled via the guest&#8217;s XFD.  Because the kernel<br \/>\nexecutes XRSTOR with the guest&#8217;s XFD, saving XSTATE_BV[i]=1 with XFD[i]=1<br \/>\nwill cause XRSTOR to #NM and panic the kernel.<\/p>\n<p>E.g. if fpu_update_guest_xfd() sets XFD without clearing XSTATE_BV:<\/p>\n<p>  &#8212;&#8212;&#8212;&#8212;[ cut here ]&#8212;&#8212;&#8212;&#8212;<br \/>\n  WARNING: arch\/x86\/kernel\/traps.c:1524 at exc_device_not_available+0x101\/0x110, CPU#29: amx_test\/848<br \/>\n  Modules linked in: kvm_intel kvm irqbypass<br \/>\n  CPU: 29 UID: 1000 PID: 848 Comm: amx_test Not tainted 6.19.0-rc2-ffa07f7fd437-x86_amx_nm_xfd_non_init-vm #171 NONE<br \/>\n  Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 0.0.0 02\/06\/2015<br \/>\n  RIP: 0010:exc_device_not_available+0x101\/0x110<br \/>\n  Call Trace:<\/p>\n<p>   asm_exc_device_not_available+0x1a\/0x20<br \/>\n  RIP: 0010:restore_fpregs_from_fpstate+0x36\/0x90<br \/>\n   switch_fpu_return+0x4a\/0xb0<br \/>\n   kvm_arch_vcpu_ioctl_run+0x1245\/0x1e40 [kvm]\n   kvm_vcpu_ioctl+0x2c3\/0x8f0 [kvm]\n   __x64_sys_ioctl+0x8f\/0xd0<br \/>\n   do_syscall_64+0x62\/0x940<br \/>\n   entry_SYSCALL_64_after_hwframe+0x4b\/0x53<\/p>\n<p>  &#8212;[ end trace 0000000000000000 ]&#8212;<\/p>\n<p>This can happen if the guest executes WRMSR(MSR_IA32_XFD) to set XFD[18] = 1,<br \/>\nand a host IRQ triggers kernel_fpu_begin() prior to the vmexit handler&#8217;s<br \/>\ncall to fpu_update_guest_xfd().<\/p>\n<p>and if userspace stuffs XSTATE_BV[i]=1 via KVM_SET_XSAVE:<\/p>\n<p>  &#8212;&#8212;&#8212;&#8212;[ cut here ]&#8212;&#8212;&#8212;&#8212;<br \/>\n  WARNING: arch\/x86\/kernel\/traps.c:1524 at exc_device_not_available+0x101\/0x110, CPU#14: amx_test\/867<br \/>\n  Modules linked in: kvm_intel kvm irqbypass<br \/>\n  CPU: 14 UID: 1000 PID: 867 Comm: amx_test Not tainted 6.19.0-rc2-2dace9faccd6-x86_amx_nm_xfd_non_init-vm #168 NONE<br \/>\n  Hardware name: QEMU Standard PC (Q35 + ICH9, 2009), BIOS 0.0.0 02\/06\/2015<br \/>\n  RIP: 0010:exc_device_not_available+0x101\/0x110<br \/>\n  Call Trace:<\/p>\n<p>   asm_exc_device_not_available+0x1a\/0x20<br \/>\n  RIP: 0010:restore_fpregs_from_fpstate+0x36\/0x90<br \/>\n   fpu_swap_kvm_fpstate+0x6b\/0x120<br \/>\n   kvm_load_guest_fpu+0x30\/0x80 [kvm]\n   kvm_arch_vcpu_ioctl_run+0x85\/0x1e40 [kvm]\n   kvm_vcpu_ioctl+0x2c3\/0x8f0 [kvm]\n   __x64_sys_ioctl+0x8f\/0xd0<br \/>\n   do_syscall_64+0x62\/0x940<br \/>\n   entry_SYSCALL_64_after_hwframe+0x4b\/0x53<\/p>\n<p>  &#8212;[ end trace 0000000000000000 ]&#8212;<\/p>\n<p>The new behavior is consistent with the AMX architecture.  Per Intel&#8217;s SDM,<br \/>\nXSAVE saves XSTATE_BV as &#8216;0&#8217; for components that are disabled via XFD<br \/>\n(and non-compacted XSAVE saves the initial configuration of the state<br \/>\ncomponent):<\/p>\n<p>  If XSAVE, XSAVEC, XSAVEOPT, or XSAVES is saving the state component i,<br \/>\n  the instruction does not generate #NM when XCR0[i] = IA32_XFD[i] = 1;<br \/>\n  instead, it operates as if XINUSE[i] = 0 (and the state component was<br \/>\n  in its initial state): it saves bit i of XSTATE_BV field of the XSAVE<br \/>\n  header as 0; in addition, XSAVE saves the initial configuration of the<br \/>\n  state component (the other instructions do not save state component i).<\/p>\n<p>Alternatively, KVM could always do XRSTOR with XFD=0, e.g. by using<br \/>\na constant XFD based on the set of enabled features when XSAVEing for<br \/>\na struct fpu_guest.  However, having XSTATE_BV[i]=1 for XFD-disabled<br \/>\nfeatures can only happen in the above interrupt case, or in similar<br \/>\nscenarios involving preemption on preemptible kernels, because<br \/>\nfpu_swap_kvm_fpstate()&#8217;s call to save_fpregs_to_fpstate() saves the<br \/>\noutgoing FPU state with the current XFD; and that is (on all but the<br \/>\nfirst WRMSR to XFD) the guest XFD.<\/p>\n<p>Therefore, XFD can only go out of sync with XSTATE_BV in the above<br \/>\ninterrupt case, or in similar scenarios involving preemption on<br \/>\npreemptible kernels, and it we can consider it (de facto) part of KVM<br \/>\nABI that KVM_GET_XSAVE returns XSTATE_BV[i]=0 for XFD-disabled features.<\/p>\n[Move clea<br \/>\n&#8212;truncated&#8212;<\/p>\n<p>Severity: 0.0 | NA<\/p>\n<p>Visit the link for more details, such as CVSS details, affected products, timeline, and more&#8230;\u00a0<\/p>\n","protected":false},"excerpt":{"rendered":"<p>CVE ID : CVE-2026-23005 Published : Jan. 25, 2026, 3:15 p.m. | 1\u00a0hour, 46\u00a0minutes ago Description : In the Linux kernel, the following vulnerability has been resolved: x86\/fpu: Clear XSTATE_BV[i] in guest XSAVE state whenever XFD[i]=1 When loading guest XSAVE state via KVM_SET_XSAVE, and when updating XFD in response to a guest WRMSR, clear XFD-disabled &hellip;<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[26],"tags":[],"class_list":["post-75815","post","type-post","status-publish","format-standard","hentry","category-vulnerability"],"_links":{"self":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/75815","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/comments?post=75815"}],"version-history":[{"count":0,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/posts\/75815\/revisions"}],"wp:attachment":[{"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/media?parent=75815"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/categories?post=75815"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/afaghhosting.net\/blog\/wp-json\/wp\/v2\/tags?post=75815"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}