Re: [PATCH v4 8/8] x86/fpu/xstate: Warn if guest-only supervisor states are detected in normal fpstate

From: Chang S. Bae
Date: Thu Apr 03 2025 - 20:02:30 EST


On 4/2/2025 7:30 AM, Chao Gao wrote:

The goal is to ensure that guest-only _supervisor_ features are not enabled in
non-guest FPUs.

I think the common XSAVE path matters here. The other XSAVE paths — signal delivery and saving the LBR state — already handle supervisor states properly. Signal delivery excludes all of supervisor states from the RFBM, while LBR state saving triggers a warning if any non-LBR state is set in the RFBM. Given this, the guard seems good enough unless missing something.

Thanks,
Chang