Module Name: src
Committed By: skrll
Date: Mon Aug 10 14:37:38 UTC 2020
Modified Files:
src/common/lib/libc/arch/mips/atomic: membar_ops.S
src/sys/arch/mips/include: asm.h
Log Message:
More SYNC centralisation
To generate a diff of this commit:
cvs rdiff -u -r1.9 -r1.10 src/common/lib/libc/arch/mips/atomic/membar_ops.S
cvs rdiff -u -r1.59 -r1.60 src/sys/arch/mips/include/asm.h
Please note that diffs are not public domain; they are subject to the
copyright notices on the relevant files.
Modified files:
Index: src/common/lib/libc/arch/mips/atomic/membar_ops.S
diff -u src/common/lib/libc/arch/mips/atomic/membar_ops.S:1.9 src/common/lib/libc/arch/mips/atomic/membar_ops.S:1.10
--- src/common/lib/libc/arch/mips/atomic/membar_ops.S:1.9 Sat Aug 1 09:26:49 2020
+++ src/common/lib/libc/arch/mips/atomic/membar_ops.S Mon Aug 10 14:37:38 2020
@@ -1,4 +1,4 @@
-/* $NetBSD: membar_ops.S,v 1.9 2020/08/01 09:26:49 skrll Exp $ */
+/* $NetBSD: membar_ops.S,v 1.10 2020/08/10 14:37:38 skrll Exp $ */
/*-
* Copyright (c) 2006, 2007 The NetBSD Foundation, Inc.
@@ -31,19 +31,12 @@
#include "atomic_op_asm.h"
-// If we are on building for MIPS III or later, put in SYNCs
-#if __mips >= 3 || !defined(__mips_o32)
-# define SYNC sync
-#else
-# define SYNC nop
-#endif
-
.text
.set noreorder
LEAF(_membar_sync)
j ra
- SYNC
+ BDSYNC
END(_membar_sync)
#ifdef __OCTEON__
Index: src/sys/arch/mips/include/asm.h
diff -u src/sys/arch/mips/include/asm.h:1.59 src/sys/arch/mips/include/asm.h:1.60
--- src/sys/arch/mips/include/asm.h:1.59 Sun Aug 9 08:13:09 2020
+++ src/sys/arch/mips/include/asm.h Mon Aug 10 14:37:38 2020
@@ -1,4 +1,4 @@
-/* $NetBSD: asm.h,v 1.59 2020/08/09 08:13:09 skrll Exp $ */
+/* $NetBSD: asm.h,v 1.60 2020/08/10 14:37:38 skrll Exp $ */
/*
* Copyright (c) 1992, 1993
@@ -519,10 +519,14 @@ _C_LABEL(x):
#define LLSCSYNC sync 4; sync 4
#define SYNC sync 4 /* sync 4 == syncw - sync all writes */
#define BDSYNC sync 4 /* sync 4 == syncw - sync all writes */
-#else
+#elif __mips >= 3 || !defined(__mips_o32)
#define LLSCSYNC sync
#define SYNC sync
#define BDSYNC sync
+#else
+#define LLSCSYNC /* nothing */
+#define SYNC /* nothing */
+#define BDSYNC nop
#endif
/* CPU dependent hook for cp0 load delays */