Re: [PATCH 16/33] riscv/shstk: If needed allocate a new shadow stack on clone

2024-10-08 Thread Deepak Gupta
On Tue, Oct 08, 2024 at 02:18:58PM +0800, Zong Li wrote: On Tue, Oct 8, 2024 at 1:31 PM Deepak Gupta wrote: On Tue, Oct 08, 2024 at 01:16:17PM +0800, Zong Li wrote: >On Tue, Oct 8, 2024 at 7:30 AM Deepak Gupta wrote: >> >> On Mon, Oct 07, 2024 at 04:17:47PM +0800, Zong Li wrote: >> >On Wed, O

Re: [PATCH 16/33] riscv/shstk: If needed allocate a new shadow stack on clone

2024-10-07 Thread Zong Li
On Tue, Oct 8, 2024 at 1:31 PM Deepak Gupta wrote: > > On Tue, Oct 08, 2024 at 01:16:17PM +0800, Zong Li wrote: > >On Tue, Oct 8, 2024 at 7:30 AM Deepak Gupta wrote: > >> > >> On Mon, Oct 07, 2024 at 04:17:47PM +0800, Zong Li wrote: > >> >On Wed, Oct 2, 2024 at 12:20 AM Deepak Gupta wrote: > >>

Re: [PATCH 16/33] riscv/shstk: If needed allocate a new shadow stack on clone

2024-10-07 Thread Deepak Gupta
On Tue, Oct 08, 2024 at 01:16:17PM +0800, Zong Li wrote: On Tue, Oct 8, 2024 at 7:30 AM Deepak Gupta wrote: On Mon, Oct 07, 2024 at 04:17:47PM +0800, Zong Li wrote: >On Wed, Oct 2, 2024 at 12:20 AM Deepak Gupta wrote: >> >> Userspace specifies CLONE_VM to share address space and spawn new thr

Re: [PATCH 16/33] riscv/shstk: If needed allocate a new shadow stack on clone

2024-10-07 Thread Zong Li
On Tue, Oct 8, 2024 at 7:30 AM Deepak Gupta wrote: > > On Mon, Oct 07, 2024 at 04:17:47PM +0800, Zong Li wrote: > >On Wed, Oct 2, 2024 at 12:20 AM Deepak Gupta wrote: > >> > >> Userspace specifies CLONE_VM to share address space and spawn new thread. > >> `clone` allow userspace to specify a new

Re: [PATCH 16/33] riscv/shstk: If needed allocate a new shadow stack on clone

2024-10-07 Thread Deepak Gupta
On Mon, Oct 07, 2024 at 04:17:47PM +0800, Zong Li wrote: On Wed, Oct 2, 2024 at 12:20 AM Deepak Gupta wrote: Userspace specifies CLONE_VM to share address space and spawn new thread. `clone` allow userspace to specify a new stack for new thread. However there is no way to specify new shadow st

Re: [PATCH 16/33] riscv/shstk: If needed allocate a new shadow stack on clone

2024-10-07 Thread Zong Li
On Wed, Oct 2, 2024 at 12:20 AM Deepak Gupta wrote: > > Userspace specifies CLONE_VM to share address space and spawn new thread. > `clone` allow userspace to specify a new stack for new thread. However > there is no way to specify new shadow stack base address without changing > API. This patch a

[PATCH 16/33] riscv/shstk: If needed allocate a new shadow stack on clone

2024-10-01 Thread Deepak Gupta
Userspace specifies CLONE_VM to share address space and spawn new thread. `clone` allow userspace to specify a new stack for new thread. However there is no way to specify new shadow stack base address without changing API. This patch allocates a new shadow stack whenever CLONE_VM is given. In cas