lkml.org 
[lkml]   [2012]   [Oct]   [31]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH] Sometimes, there is OOPS happened when we use oprofile.
On 31.10.12 14:33:17, H. Peter Anvin wrote:
> I'm vaguely concerned about the following:
>
> + * To always return a non-null
> + * stack pointer we fall back to regs as stack if no previous stack
> + * exists.
>
> The logic being that if there is no stack pointer and the stack is
> too empty, to simply assume regs point to the top of the stack? Is
> this possible to ever be actually seen?

I discussed this with Steven too (https://lkml.org/lkml/2012/9/6/322)
and we both had a bad feeling with returning a null pointer by
kernel_stack_pointer() (implemented in version 1 of this patch). It
could be null if tinfo->previous_esp is null (last stack). Not sure
when this may happen.

So using regs as fallback seemed to be ok as this was in for years:

7b6c6c7 x86, 32-bit: fix kernel_trap_sp()

-Robert


\
 
 \ /
  Last update: 2012-11-01 00:21    [W:0.052 / U:2.564 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site