• Matt Fleming's avatar
    sh: Make the atomic functions safe for irqsoff tracing · 0c50f6f3
    Matt Fleming authored
    The irqsoff tracer uses the atomic_* functions internally, but the
    implementations of those functions in arch/sh/include/asm/atomic-irq.h
    disable irqs to achieve atomicity. A continuous loop ensues where we
    disable interrupts, trace the interrupt disabling, call atomic_*
    functions, disable interrupts, trace the interrupt disabling, etc..
    
    The simplest solution to all this is to just convert uses of
    local_irq_save()/local_irq_restore() the raw_* equivalents because the
    raw_* equivalents don't call trace_hardirqs_on()/trace_hardirqs_off().
    Signed-off-by: default avatarMatt Fleming <matt@console-pimps.org>
    Signed-off-by: default avatarPaul Mundt <lethal@linux-sh.org>
    0c50f6f3
atomic-irq.h 1.34 KB