[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20231227142441.f9a76fa3c8b9b79eea8f93a2@linux-foundation.org>
Date: Wed, 27 Dec 2023 14:24:41 -0800
From: Andrew Morton <akpm@...ux-foundation.org>
To: Deepak Gupta <debug@...osinc.com>
Cc: rick.p.edgecombe@...el.com, broonie@...nel.org, linux-mm@...ck.org,
linux-kernel@...r.kernel.org
Subject: Re: [PATCH v1] mm: abstract shadow stack vma behind
arch_is_shadow_stack_vma
On Wed, 27 Dec 2023 14:20:36 -0800 Deepak Gupta <debug@...osinc.com> wrote:
> On Wed, Dec 27, 2023 at 1:45 PM Andrew Morton <akpm@...ux-foundation.org> wrote:
> >
> > On Fri, 22 Dec 2023 15:51:04 -0800 Deepak Gupta <debug@...osinc.com> wrote:
> >
> > > x86 has used VM_SHADOW_STACK (alias to VM_HIGH_ARCH_5) to encode shadow
> > > stack VMA. VM_SHADOW_STACK is thus not possible on 32bit. Some arches may
> > > need a way to encode shadow stack on 32bit and 64bit both and they may
> > > encode this information differently in VMAs.
> >
> > Is such a patch in the pipeline? Otherwise we're making a change that
> > serves no purpose.
>
> Yes I do have patches in the pipeline for riscv.
> On riscv, presence of only `VM_WRITE` (i.e. (flags & (VM_READ |
> VM_WRITE | VM_EXEC))
> == VM_WRITE) would mean a shadow stack.
> And yes there would be relevant patches to ensure that existing consumers using
> `PROT_WRITE` gets translated to (VM_WRITE | VM_READ)
OK, please plan to carry this patch in whatever tree contains the above.
Powered by blists - more mailing lists