diff options
author | Ralf Baechle <ralf@linux-mips.org> | 1998-08-25 09:12:35 +0000 |
---|---|---|
committer | Ralf Baechle <ralf@linux-mips.org> | 1998-08-25 09:12:35 +0000 |
commit | c7fc24dc4420057f103afe8fc64524ebc25c5d37 (patch) | |
tree | 3682407a599b8f9f03fc096298134cafba1c9b2f /arch/sparc/lib | |
parent | 1d793fade8b063fde3cf275bf1a5c2d381292cd9 (diff) |
o Merge with Linux 2.1.116.
o New Newport console code.
o New G364 console code.
Diffstat (limited to 'arch/sparc/lib')
-rw-r--r-- | arch/sparc/lib/Makefile | 17 | ||||
-rw-r--r-- | arch/sparc/lib/locks.S | 74 |
2 files changed, 5 insertions, 86 deletions
diff --git a/arch/sparc/lib/Makefile b/arch/sparc/lib/Makefile index 6ec986c86..9ce3a6630 100644 --- a/arch/sparc/lib/Makefile +++ b/arch/sparc/lib/Makefile @@ -1,4 +1,4 @@ -# $Id: Makefile,v 1.25 1998/01/30 10:58:43 jj Exp $ +# $Id: Makefile,v 1.26 1998/07/26 03:02:43 davem Exp $ # Makefile for Sparc library files.. # @@ -45,8 +45,6 @@ blockops.o: blockops.S memset.o: memset.S $(CC) -D__ASSEMBLY__ -ansi -c -o memset.o memset.S -ifdef SMP - locks.o: locks.S $(CC) -D__ASSEMBLY__ $(AFLAGS) -ansi -c -o locks.o locks.S @@ -56,20 +54,9 @@ atomic.o: atomic.S bitops.o: bitops.S $(CC) -D__ASSEMBLY__ $(AFLAGS) -ansi -c -o bitops.o bitops.S +ifdef SMP irqlock.o: irqlock.S $(CC) -D__ASSEMBLY__ $(AFLAGS) -ansi -c -o irqlock.o irqlock.S - -else - -locks.o: locks.S - $(CC) -D__ASSEMBLY__ -ansi -c -o locks.o locks.S - -atomic.o: atomic.S - $(CC) -D__ASSEMBLY__ -ansi -c -o atomic.o atomic.S - -bitops.o: bitops.S - $(CC) -D__ASSEMBLY__ -ansi -c -o bitops.o bitops.S - endif strlen.o: strlen.S diff --git a/arch/sparc/lib/locks.S b/arch/sparc/lib/locks.S index e91efdc09..8d634704f 100644 --- a/arch/sparc/lib/locks.S +++ b/arch/sparc/lib/locks.S @@ -1,4 +1,4 @@ -/* $Id: locks.S,v 1.12 1997/04/22 18:48:07 davem Exp $ +/* $Id: locks.S,v 1.13 1998/07/30 11:29:28 davem Exp $ * locks.S: SMP low-level lock primitives on Sparc. * * Copyright (C) 1996 David S. Miller (davem@caip.rutgers.edu) @@ -20,8 +20,8 @@ * itself in %g1, %g4 must be restored into %o7 when we return, * and the caller wants us to return to him at three instructions * previous to the call instruction which got us here. See how - * this is used in asm/smp_lock.h and asm/spinlock.h if what I - * just said confuses you to no end. + * this is used in asm/spinlock.h if what I just said confuses + * you to no end. */ .globl ___spinlock_waitfor ___spinlock_waitfor: @@ -32,74 +32,6 @@ ___spinlock_waitfor: jmpl %o7 - 12, %g0 mov %g4, %o7 -___lk_busy_spin: - orcc %g2, 0, %g0 - bne,a ___lk_busy_spin - ldub [%g1 + 0], %g2 - b 1f - ldstub [%g1 + 0], %g2 - - .globl ___lock_kernel -___lock_kernel: - addcc %g2, -1, %g2 - bcs,a 9f - st %g2, [%g6 + AOFF_task_lock_depth] - rd %psr, %g3 - or %g3, PSR_PIL, %g2 - wr %g2, 0x0, %psr - nop; nop; nop - ldstub [%g1 + 0], %g2 -1: orcc %g2, 0, %g0 - bne,a ___lk_busy_spin - ldub [%g1 + 0], %g2 - stb %g5, [%g1 + 1] - mov -1, %g2 - st %g2, [%g6 + AOFF_task_lock_depth] - wr %g3, 0x0, %psr - nop; nop; nop -9: jmpl %o7 + 0x8, %g0 - mov %g4, %o7 - - .globl ___lock_reacquire_kernel -___lock_reacquire_kernel: - rd %psr, %g3 - or %g3, PSR_PIL, %g7 - wr %g7, 0x0, %psr - nop; nop; nop - st %g2, [%g6 + AOFF_task_lock_depth] - ldstub [%g1 + 0], %g2 -1: orcc %g2, 0, %g0 - be 3f - ldub [%g1 + 0], %g2 -2: orcc %g2, 0, %g0 - bne,a 2b - ldub [%g1 + 0], %g2 - b 1b - ldstub [%g1 + 0], %g2 -3: stb %g5, [%g1 + 1] - wr %g3, 0x0, %psr - nop; nop; nop - jmpl %o7 + 0x8, %g0 - mov %g4, %o7 - - .globl ___unlock_kernel -___unlock_kernel: - addcc %g2, 1, %g2 - bne,a 1f - st %g2, [%g6 + AOFF_task_lock_depth] - rd %psr, %g3 - or %g3, PSR_PIL, %g2 - wr %g2, 0x0, %psr - nop; nop; nop - mov NO_PROC_ID, %g2 - stb %g2, [%g1 + 1] - stb %g0, [%g1 + 0] - st %g0, [%g6 + AOFF_task_lock_depth] - wr %g3, 0x0, %psr - nop; nop; nop; -1: jmpl %o7 + 0x8, %g0 - mov %g4, %o7 - /* Read/writer locks, as usual this is overly clever to make it * as fast as possible. */ |