[PATCH] arm64/ptrace: Don't clear calling process' TIF_SME on OOM

Mark Brown broonie at kernel.org
Tue Sep 6 09:37:45 PDT 2022


On Tue, Sep 06, 2022 at 05:27:15PM +0100, Will Deacon wrote:
> On Fri, Sep 02, 2022 at 02:28:02PM +0100, Mark Brown wrote:
> > If allocating memory for the target SVE state in za_set() fails we clear
> > TIF_SME for the ptracing task which is obviously not correct.  If we are

> Is this fixing a real (i.e. user-observable) issue, or is it removing some
> redundant code? I'm afraid I can't tell from the commit message and I'm
> trying to figure out whether we should be queueing it for -rc (and CC'ing
> stable) or not.

Since we're clearing TIF_SME for the process doing the ptrace there's
the potential for causing an issue in that process where we trap a new
SME usage and flush the SME state in the process which is a data
corruption issue which would be observable.
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 488 bytes
Desc: not available
URL: <http://lists.infradead.org/pipermail/linux-arm-kernel/attachments/20220906/2571d86a/attachment.sig>


More information about the linux-arm-kernel mailing list