]> git.baikalelectronics.ru Git - kernel.git/commit
[SPARC64]: Avoid membar instructions in delay slots.
authorDavid S. Miller <davem@davemloft.net>
Mon, 27 Jun 2005 22:42:04 +0000 (15:42 -0700)
committerDavid S. Miller <davem@davemloft.net>
Mon, 27 Jun 2005 22:42:04 +0000 (15:42 -0700)
commit983210496a5d05744e3b4eeaf48fec41a12837b6
tree8c8c377a7e5cbf608d730ec45e091e4f2b826a82
parente5c35d4badc8c7e666ee506237e4100ce7bb4210
[SPARC64]: Avoid membar instructions in delay slots.

In particular, avoid membar instructions in the delay
slot of a jmpl instruction.

UltraSPARC-I, II, IIi, and IIe have a bug, documented in
the UltraSPARC-IIi User's Manual, Appendix K, Erratum 51

The long and short of it is that if the IMU unit misses
on a branch or jmpl, and there is a store buffer synchronizing
membar in the delay slot, the chip can stop fetching instructions.

If interrupts are enabled or some other trap is enabled, the
chip will unwedge itself, but performance will suffer.

We already had a workaround for this bug in a few spots, but
it's better to have the entire tree sanitized for this rule.

Signed-off-by: David S. Miller <davem@davemloft.net>
15 files changed:
arch/sparc64/kernel/entry.S
arch/sparc64/kernel/semaphore.c
arch/sparc64/kernel/trampoline.S
arch/sparc64/lib/U1memcpy.S
arch/sparc64/lib/VISsave.S
arch/sparc64/lib/atomic.S
arch/sparc64/lib/bitops.S
arch/sparc64/lib/debuglocks.c
arch/sparc64/lib/dec_and_lock.S
arch/sparc64/lib/rwsem.S
arch/sparc64/mm/init.c
arch/sparc64/mm/ultra.S
include/asm-sparc64/rwsem.h
include/asm-sparc64/spinlock.h
include/asm-sparc64/spitfire.h