Re: [PATCH v8 32/43] arm64: mte: Switch GCR_EL1 in kernel entry and exit

2020-11-05 Thread Catalin Marinas
On Thu, Nov 05, 2020 at 12:18:47AM +0100, Andrey Konovalov wrote: > From: Vincenzo Frascino > > When MTE is present, the GCR_EL1 register contains the tags mask that > allows to exclude tags from the random generation via the IRG instruction. > > With the introduction of the new Tag-Based KASAN

Re: [PATCH v8 32/43] arm64: mte: Switch GCR_EL1 in kernel entry and exit

2020-11-05 Thread Andrey Konovalov
On Thu, Nov 5, 2020 at 6:30 PM Catalin Marinas wrote: > > On Thu, Nov 05, 2020 at 12:18:47AM +0100, Andrey Konovalov wrote: > > diff --git a/arch/arm64/kernel/mte.c b/arch/arm64/kernel/mte.c > > index 14b0c19a33e3..cc7e0f8707f7 100644 > > --- a/arch/arm64/kernel/mte.c > > +++ b/arch/arm64/kernel/m

Re: [PATCH v8 32/43] arm64: mte: Switch GCR_EL1 in kernel entry and exit

2020-11-05 Thread Catalin Marinas
On Thu, Nov 05, 2020 at 12:18:47AM +0100, Andrey Konovalov wrote: > diff --git a/arch/arm64/kernel/mte.c b/arch/arm64/kernel/mte.c > index 14b0c19a33e3..cc7e0f8707f7 100644 > --- a/arch/arm64/kernel/mte.c > +++ b/arch/arm64/kernel/mte.c > @@ -23,6 +23,8 @@ > #include > #include > > +u64 gcr_k