lkml.org 
[lkml]   [2009]   [Apr]   [23]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH 0/2] [GIT PULL] tracing: various bug fixes
Steven Rostedt wrote:
> Ah, this is a lockdep thing.
>
> The raw_local_irq_save/restore in __native_flush_tlb_global does not
> update hardirqs_enabled.
>
> When we call into ftrace, when we cross page bounderies, we disable
> interrupts using the normal local_irq_save/restore calls.
>
> But when we restore, it detects that interrupts are not going to be
> enabled, and keeps hardirqs_enabled off.
>
> The printk solved the issue because it called local_irq_restore, which set
> the variable back.
>
> I guess there's two solutions here. One, we can change the
> raw_local_irq_enable/disable variants in __native_flush_tlb_global to the
> non-raw type (it should protect against recursion).
>
> or we can try to make the ring buffer use the raw_local_irq variants too.
> I tried this once before, and it did cause issues.
>
> Note, there's a "check_flags" in lockdep, but it is only called on
> locking, it is not called when we only disable/enable interrupts.
>

OK, the good news is that its not a callee-save calling convention
problem, which is what I feared. But it does sound pretty awkward to
fix. Does __native_flush_tlb_global() have to use
raw_local_irq_save/restore?

J


\
 
 \ /
  Last update: 2009-04-23 18:53    [W:0.075 / U:0.184 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site