svn commit: r208049 - in user/jmallett/octeon/sys/cddl/compat/opensolaris: kern sys

Stanislav Sedov stas at FreeBSD.org
Thu May 13 20:51:21 UTC 2010


Author: stas
Date: Thu May 13 20:51:20 2010
New Revision: 208049
URL: http://svn.freebsd.org/changeset/base/208049

Log:
  - Fix n32 mips build of opensolaris bits.
    Opensolaris code defines 63 bits atomics in non-LP64 case,
    which are also defined/supported by mips n32 code.

Modified:
  user/jmallett/octeon/sys/cddl/compat/opensolaris/kern/opensolaris_atomic.c
  user/jmallett/octeon/sys/cddl/compat/opensolaris/sys/atomic.h

Modified: user/jmallett/octeon/sys/cddl/compat/opensolaris/kern/opensolaris_atomic.c
==============================================================================
--- user/jmallett/octeon/sys/cddl/compat/opensolaris/kern/opensolaris_atomic.c	Thu May 13 20:48:39 2010	(r208048)
+++ user/jmallett/octeon/sys/cddl/compat/opensolaris/kern/opensolaris_atomic.c	Thu May 13 20:51:20 2010	(r208049)
@@ -53,6 +53,7 @@ atomic_init(void)
 #endif
 
 #ifndef __LP64__
+#if !defined(__mips_n32)
 void
 atomic_add_64(volatile uint64_t *target, int64_t delta)
 {
@@ -61,6 +62,7 @@ atomic_add_64(volatile uint64_t *target,
 	*target += delta;
 	mtx_unlock(&atomic_mtx);
 }
+#endif
 
 void
 atomic_dec_64(volatile uint64_t *target)

Modified: user/jmallett/octeon/sys/cddl/compat/opensolaris/sys/atomic.h
==============================================================================
--- user/jmallett/octeon/sys/cddl/compat/opensolaris/sys/atomic.h	Thu May 13 20:48:39 2010	(r208048)
+++ user/jmallett/octeon/sys/cddl/compat/opensolaris/sys/atomic.h	Thu May 13 20:51:20 2010	(r208049)
@@ -37,7 +37,9 @@
 #define cas32	atomic_cmpset_32
 
 #ifndef __LP64__
+#if !defined(__mips_n32)
 extern void atomic_add_64(volatile uint64_t *target, int64_t delta);
+#endif
 extern void atomic_dec_64(volatile uint64_t *target);
 extern void *atomic_cas_ptr(volatile void *target, void *cmp,  void *newval);
 #endif


More information about the svn-src-user mailing list