[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [PATCH] x86: drop/replace MEMORY_GUARD



On 14/12/2021 15:13, Jan Beulich wrote:
> --- a/xen/arch/x86/traps.c
> +++ b/xen/arch/x86/traps.c
> @@ -642,7 +642,7 @@ void show_stack_overflow(unsigned int cp
>  {
>      unsigned long esp = regs->rsp;
>      unsigned long curr_stack_base = esp & ~(STACK_SIZE - 1);
> -#ifdef MEMORY_GUARD
> +#ifdef CONFIG_DEBUG
>      unsigned long esp_top, esp_bottom;
>  #endif
>  
> @@ -650,7 +650,7 @@ void show_stack_overflow(unsigned int cp
>          printk("Current stack base %p differs from expected %p\n",
>                 _p(curr_stack_base), stack_base[cpu]);
>  
> -#ifdef MEMORY_GUARD
> +#ifdef CONFIG_DEBUG

Looking at these, I think we'd be better dropping the ifdef and
compiling it in unconditionally.

This is only used in the #DF path, which is a fatal error path. 
Throwing away information we trivially have to hand is actively
unhelpful to whomever is analysing the logs.

Preferably with the ifdefary dropped, Reviewed-by: Andrew Cooper
<andrew.cooper3@xxxxxxxxxx>



 


Rackspace

Lists.xenproject.org is hosted with RackSpace, monitoring our
servers 24x7x365 and backed by RackSpace's Fanatical Support®.