[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-ID: <20190613132342.GZ28398@e103592.cambridge.arm.com>
Date: Thu, 13 Jun 2019 14:23:43 +0100
From: Dave Martin <Dave.Martin@....com>
To: Catalin Marinas <catalin.marinas@....com>
Cc: linux-arch@...r.kernel.org, linux-doc@...r.kernel.org,
Szabolcs Nagy <szabolcs.nagy@....com>,
Andrey Konovalov <andreyknvl@...gle.com>,
Will Deacon <will.deacon@....com>,
linux-kernel@...r.kernel.org, linux-mm@...ck.org,
Alexander Viro <viro@...iv.linux.org.uk>,
linux-kselftest@...r.kernel.org,
Vincenzo Frascino <vincenzo.frascino@....com>,
linux-arm-kernel@...ts.infradead.org
Subject: Re: [PATCH v4 1/2] arm64: Define
Documentation/arm64/tagged-address-abi.txt
On Thu, Jun 13, 2019 at 01:28:21PM +0100, Catalin Marinas wrote:
> On Thu, Jun 13, 2019 at 12:37:32PM +0100, Dave P Martin wrote:
> > On Thu, Jun 13, 2019 at 11:15:34AM +0100, Vincenzo Frascino wrote:
> > > On 12/06/2019 16:35, Catalin Marinas wrote:
> > > > On Wed, Jun 12, 2019 at 03:21:10PM +0100, Vincenzo Frascino wrote:
> > > >> + - PR_GET_TAGGED_ADDR_CTRL: can be used to check the status of the Tagged
> > > >> + Address ABI.
> [...]
> > Is there a canonical way to detect whether this whole API/ABI is
> > available? (i.e., try to call this prctl / check for an HWCAP bit,
> > etc.)
>
> The canonical way is a prctl() call. HWCAP doesn't make sense since it's
> not a hardware feature. If you really want a different way of detecting
> this (which I don't think it's worth), we can reinstate the AT_FLAGS
> bit.
Sure, I think this probably makes sense -- I'm still getting my around
which parts of the design are directly related to MTE and which aren't.
I was a bit concerned about the interaction between
PR_SET_TAGGED_ADDR_CTRL and the sysctl: the caller might conclude that
this API is unavailable when actually tagged addresses are stuck on.
I'm not sure whether this matters, but it's a bit weird.
One option would be to change the semantics, so that the sysctl just
forbids turning tagging from off to on. Alternatively, we could return
a different error code to distinguish this case.
Or we just leave it as proposed.
Cheers
---Dave
Powered by blists - more mailing lists