Re: [patch] cli()/sti() cleanup, 2.5.27-A2

Ingo Molnar (mingo@elte.hu)
Mon, 22 Jul 2002 20:01:29 +0200 (CEST)


On Mon, 22 Jul 2002, Linus Torvalds wrote:

> I'd much rather keep the current "local_xxx" versions, since they
> clearly say that it's local to the CPU. Let's face it, people SHOULD NOT
> USE THESE!

okay, agreed.

> So I vote for
>
> local_irq_save(flags) - save and disable
> local_irq_restore(flags) - restore
> local_irq_disable() - disable
> local_irq_enable() - enable

i've added this one as well:

local_save_flags(flags) - save

a fair number of places want (and need) to use __save_flags(flags)-type of
functionality, without the irq-disabling side-effect.

But also, a number of places now do:

local_save_flags(flags);
local_irq_disable();

which should be:

local_irq_save(flags);

(these places will be simplified in an upcoming patch.)

The new __cli/__sti cleanup patch is at:

http://redhat.com/~mingo/remove-irqlock-patches/cli-sti-cleanup-2.5.27-B2

compiles, boots & works just fine on x86 UP and SMP.

Ingo

-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/