7.4. The Fucked Up Sparc

Alan Cox says "the irq disable/enable is in the register window on a sparc". Andi Kleen says "when you do restore_flags in a different function you mess up all the register windows".

So never pass the flags word set by spin_lock_irqsave() and brethren to another function (unless it's declared inline). Usually no-one does this, but now you've been warned. Dave Miller can never do anything in a straightforward manner (I can say that, because I have pictures of him and a certain PowerPC maintainer in a compromising position).