[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20200510084625.GA19352@zn.tnic>
Date: Sun, 10 May 2020 10:46:25 +0200
From: Borislav Petkov <bp@...en8.de>
To: Yu-cheng Yu <yu-cheng.yu@...el.com>
Cc: linux-kernel@...r.kernel.org, x86@...nel.org,
"H. Peter Anvin" <hpa@...or.com>,
Thomas Gleixner <tglx@...utronix.de>,
Ingo Molnar <mingo@...hat.com>,
Dave Hansen <dave.hansen@...ux.intel.com>,
Tony Luck <tony.luck@...el.com>,
Andy Lutomirski <luto@...nel.org>,
Rik van Riel <riel@...riel.com>,
"Ravi V. Shankar" <ravi.v.shankar@...el.com>,
Sebastian Andrzej Siewior <bigeasy@...utronix.de>,
Fenghua Yu <fenghua.yu@...el.com>,
Peter Zijlstra <peterz@...radead.org>
Subject: Re: [PATCH v3 09/10] x86/fpu/xstate: Preserve supervisor states for
slow path of __fpu__restore_sig()
On Sat, Mar 28, 2020 at 09:43:06AM -0700, Yu-cheng Yu wrote:
> The signal return code is responsible for taking an XSAVE buffer present
> in user memory and loading it into the hardware registers. This
> operation only affects user XSAVE state and never affects supervisor state.
>
> The fast path through this code simply points XRSTOR directly at the
> user buffer. However, due to page faults, this XRSTOR can fail. If it
^^^^^^^^^^^^^^^^^^
"However, since user memory is not guaranteed to be always mapped, ... "
> fails, the signal return code falls back to a slow path which can
> tolerate page faults.
>
> That slow path copies the xfeatures one by one out of the user buffer
> into the task's fpu state area. However, by being in a context where it
> can handle page faults, the code can also schedule. That exposes us to
^^
Pls use passive voice in your commit message: no "we" or "I", etc, and
describe your changes in imperative mood.
Fix this in all your commit messages pls.
--
Regards/Gruss,
Boris.
https://people.kernel.org/tglx/notes-about-netiquette
Powered by blists - more mailing lists