[PATCH v1 4/4] arm64/mte: Add userspace interface for enabling asymmetric mode

Mark Brown broonie at kernel.org
Thu Mar 3 07:44:40 PST 2022


On Thu, Mar 03, 2022 at 10:34:34AM +0000, Catalin Marinas wrote:
> On Wed, Mar 02, 2022 at 12:58:48PM -0800, Evgenii Stepanov wrote:

> > One option would be to introduce a new, future-proofed prctl with a
> > wider mask, and throw in a few extra reserved bits just in case. Then
> > have the legacy prctl always clear MTE_CTRL_TCF_ASYMM.

> If this problem is real, we can easily tweak the current proposal so the
> that ASYMM can only be set *if* both ASYNC and SYNC are set. IOW, it's
> not a specific mode an app requests on its own but rather something the
> kernel may choose via the preferred mode if the app opted in. We still
> introduce a new bit for ASYMM but not change the mask.

That would work for the normal usage case but it would mean that the
only way to guarantee you actually end up with asymmetric mode would be
to force it on as the system default which might be annoying if you're
trying to test that userspace code works with all the modes.  It's not
the end of the world I think but I can see testsuites running into
issues.
-------------- 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/20220303/f7a62f5c/attachment.sig>


More information about the linux-arm-kernel mailing list