Re: [PATCH 11/23] x86, kaiser: map entry stack variables

2017-11-23 Thread Andy Lutomirski
On Thu, Nov 23, 2017 at 7:37 AM, Dave Hansen wrote: > On 11/22/2017 07:31 PM, Andy Lutomirski wrote: >> On Wed, Nov 22, 2017 at 4:34 PM, Dave Hansen >> wrote: >>> >>> From: Dave Hansen >>> >>> There are times where the kernel is entered but there is not a >>> safe stack, like at SYSCALL entry.

Re: [PATCH 11/23] x86, kaiser: map entry stack variables

2017-11-23 Thread Dave Hansen
On 11/22/2017 07:31 PM, Andy Lutomirski wrote: > On Wed, Nov 22, 2017 at 4:34 PM, Dave Hansen > wrote: >> >> From: Dave Hansen >> >> There are times where the kernel is entered but there is not a >> safe stack, like at SYSCALL entry. To obtain a safe stack, the >> per-cpu variables 'rsp_scratch'

Re: [PATCH 11/23] x86, kaiser: map entry stack variables

2017-11-22 Thread Andy Lutomirski
On Wed, Nov 22, 2017 at 4:34 PM, Dave Hansen wrote: > > From: Dave Hansen > > There are times where the kernel is entered but there is not a > safe stack, like at SYSCALL entry. To obtain a safe stack, the > per-cpu variables 'rsp_scratch' and 'cpu_current_top_of_stack' > are used to save the ol

[PATCH 11/23] x86, kaiser: map entry stack variables

2017-11-22 Thread Dave Hansen
From: Dave Hansen There are times where the kernel is entered but there is not a safe stack, like at SYSCALL entry. To obtain a safe stack, the per-cpu variables 'rsp_scratch' and 'cpu_current_top_of_stack' are used to save the old %rsp value and to find where the kernel stack should start. Yo