summaryrefslogtreecommitdiff
path: root/src/backend/storage/buffer/s_lock.c
diff options
context:
space:
mode:
authorBruce Momjian <bruce@momjian.us>1998-12-18 17:25:41 +0000
committerBruce Momjian <bruce@momjian.us>1998-12-18 17:25:41 +0000
commitb8d5f02e4e83cece64e932899bbb96709c2113ea (patch)
tree35fdd9a7974da698560d97063b030a1b8f699679 /src/backend/storage/buffer/s_lock.c
parentc0d816c57a21d161dca18c9f7b28b4bd27ba7d92 (diff)
I have ported PostgreSQL 6.4 to Cobalt Qube running Linux 2.0.33 with
MIPS cpu (I think it's R4000). I have tested the patches on LinuxPPC and FreeBSD. I believe they do not harm other platforms. -- Tatsuo Ishii
Diffstat (limited to 'src/backend/storage/buffer/s_lock.c')
-rw-r--r--src/backend/storage/buffer/s_lock.c25
1 files changed, 23 insertions, 2 deletions
diff --git a/src/backend/storage/buffer/s_lock.c b/src/backend/storage/buffer/s_lock.c
index 439240a386f..77f3dbc5ad0 100644
--- a/src/backend/storage/buffer/s_lock.c
+++ b/src/backend/storage/buffer/s_lock.c
@@ -7,7 +7,7 @@
*
*
* IDENTIFICATION
- * $Header: /cvsroot/pgsql/src/backend/storage/buffer/Attic/s_lock.c,v 1.13 1998/12/15 12:46:21 vadim Exp $
+ * $Header: /cvsroot/pgsql/src/backend/storage/buffer/Attic/s_lock.c,v 1.14 1998/12/18 17:25:39 momjian Exp $
*
*-------------------------------------------------------------------------
*/
@@ -124,7 +124,28 @@ success: \n\
#endif /* PPC */
-
+#if defined(__mips)
+static void
+tas_dummy()
+{
+ __asm__(" \n\
+.global tas \n\
+tas: \n\
+ .frame $sp, 0, $31 \n\
+ ll $14, 0($4) \n\
+ or $15, $14, 1 \n\
+ sc $15, 0($4) \n\
+ beq $15, 0, fail \n\
+ bne $14, 0, fail \n\
+ li $2, 0 \n\
+ .livereg 0x2000FF0E,0x00000FFF \n\
+ j $31 \n\
+fail: \n\
+ li $2, 1 \n\
+ j $31 \n\
+ ");
+}
+#endif /* __mips */
#else /* defined(__GNUC__) */
/***************************************************************************