Re: [PATCH v2 26/37] arm64: mte: Convert gcr_user into an exclude mask
From: Catalin Marinas
Date: Thu Sep 17 2020 - 13:10:48 EST
On Tue, Sep 15, 2020 at 11:16:08PM +0200, Andrey Konovalov wrote:
> From: Vincenzo Frascino <vincenzo.frascino@xxxxxxx>
>
> The gcr_user mask is a per thread mask that represents the tags that are
> excluded from random generation when the Memory Tagging Extension is
> present and an 'irg' instruction is invoked.
>
> gcr_user affects the behavior on EL0 only.
>
> Currently that mask is an include mask and it is controlled by the user
> via prctl() while GCR_EL1 accepts an exclude mask.
>
> Convert the include mask into an exclude one to make it easier the
> register setting.
>
> Note: This change will affect gcr_kernel (for EL1) introduced with a
> future patch.
>
> Signed-off-by: Vincenzo Frascino <vincenzo.frascino@xxxxxxx>
> Signed-off-by: Andrey Konovalov <andreyknvl@xxxxxxxxxx>
Reviewed-by: Catalin Marinas <catalin.marinas@xxxxxxx>