$OpenBSD: patch-sal_osl_unx_asm_interlck_sparc_s,v 1.1 2009/06/02 21:48:39 robert Exp $
--- sal/osl/unx/asm/interlck_sparc.s.orig.port	Tue Jun  2 01:19:31 2009
+++ sal/osl/unx/asm/interlck_sparc.s	Tue Jun  2 01:20:10 2009
@@ -68,7 +68,7 @@ osl_decrementInterLockCountFuncPtr:
 
 .section   ".text"
 
-#if defined(NETBSD) || defined(LINUX)
+#if defined(NETBSD) || defined(LINUX) || defined(OPENBSD)
 /* add the address of the calling "call" instruction (stored in %o7) to
  * %o5 which contains _GLOBAL_OFFSET_TABLE_
  */
@@ -82,7 +82,7 @@ osl_decrementInterLockCountFuncPtr:
 
 osl_incrementInterlockedCount:
 
-#if defined(NETBSD) || defined(LINUX)
+#if defined(NETBSD) || defined(LINUX) || defined(OPENBSD)
         mov     %o7, %g1
         sethi   %hi(_GLOBAL_OFFSET_TABLE_-4), %o5
         call    .Laddoseven
@@ -105,7 +105,7 @@ osl_incrementInterlockedCount:
 
 osl_decrementInterlockedCount:
 
-#if defined(NETBSD) || defined(LINUX)
+#if defined(NETBSD) || defined(LINUX) || defined(OPENBSD)
         mov     %o7, %g1
         sethi   %hi(_GLOBAL_OFFSET_TABLE_-4), %o5
         call    .Laddoseven
@@ -113,7 +113,7 @@ osl_decrementInterlockedCount:
         mov     %g1, %o7
 #endif
         set     osl_decrementInterLockCountFuncPtr, %o1
-#if defined(NETBSD) || defined(LINUX)
+#if defined(NETBSD) || defined(LINUX) || defined(OPENBSD)
         ld      [%o1 + %o5], %o1
 #endif
         ld      [%o1], %o1
@@ -128,7 +128,7 @@ osl_decrementInterlockedCount:
 
 osl_InterlockedCountSetV9:
 
-#if defined(NETBSD) || defined(LINUX)
+#if defined(NETBSD) || defined(LINUX) || defined(OPENBSD)
         mov	    %o7, %g1
         sethi	%hi(_GLOBAL_OFFSET_TABLE_-4), %o5
         call	.Laddoseven
@@ -142,7 +142,7 @@ osl_InterlockedCountSetV9:
         nop                                             ! delay slot
         set     osl_incrementInterlockedCountV8, %o0
         set     osl_decrementInterlockedCountV8, %o3
-#if defined(NETBSD) || defined(LINUX)
+#if defined(NETBSD) || defined(LINUX) || defined(OPENBSD)
         ld      [%o0 + %o5], %o0
         ld      [%o1 + %o5], %o1
         ld      [%o2 + %o5], %o2
@@ -153,7 +153,7 @@ osl_InterlockedCountSetV9:
         st      %o0,[%o1]
 1:      set     osl_incrementInterlockedCountV9, %o0
         set     osl_decrementInterlockedCountV9, %o3
-#if defined(NETBSD) || defined(LINUX)
+#if defined(NETBSD) || defined(LINUX) || defined(OPENBSD)
         ld      [%o0 + %o5], %o0
         ld      [%o1 + %o5], %o1
         ld      [%o2 + %o5], %o2
