Re: [PATCH v2 3/4] x86/split_lock: Handle #AC exception for split lock

From: Dave Hansen
Date: Fri Jun 29 2018 - 13:47:29 EST


On 06/29/2018 10:39 AM, Fenghua Yu wrote:
> On Fri, Jun 29, 2018 at 10:29:08AM -0700, Dave Hansen wrote:
>> On 06/29/2018 10:16 AM, Fenghua Yu wrote:
>>> On Fri, Jun 29, 2018 at 09:33:54AM -0700, Luck, Tony wrote:
>>>>>> + WARN_ONCE(1, "A split lock issue is detected. Please FIX it\n");
>>>>> But, warning here is also not super useful. Shouldn't we be dumping out
>>>>> the info in 'regs' instead of the current context? We don't care about
>>>>> the state in the #AC handler, we care about 'regs'.
>>> But WARN dump not only the state in the #AC handler, but also dump the regs
>>> in the current context. And WARN dumps stack.
>> Oh, I forgot about the fancy stack following. That might give us useful
>> output, although mixed with useless output about the #AC handler.
> The useful split lock info follows useless #AC handler info.

Can we do better than this?

Why don't I see the page fault stack in oopses that result in page
fault, for instance?