[BACK]Return to lock.h CVS log [TXT][DIR] Up to [cvs.NetBSD.org] / src / sys / arch / acorn32 / include

Please note that diffs are not public domain; they are subject to the copyright notices on the relevant files.

Diff for /src/sys/arch/acorn32/include/lock.h between version 1.6.76.1 and 1.6.76.2

version 1.6.76.1, 2008/06/02 13:21:43 version 1.6.76.2, 2009/01/17 13:27:47
Line 32 
Line 32 
 #ifndef _ACORN32_LOCK_H_  #ifndef _ACORN32_LOCK_H_
 #define _ACORN32_LOCK_H_  #define _ACORN32_LOCK_H_
   
   #include <sys/param.h>
   
 #ifdef _KERNEL_OPT  #ifdef _KERNEL_OPT
 #include "opt_multiprocessor.h"  #include "opt_multiprocessor.h"
 #endif  #endif
   
 #if defined(_KERNEL) && defined(MULTIPROCESSOR)  #if defined(_HARDKERNEL) && defined(MULTIPROCESSOR)
   
 #include <arm/cpufunc.h>  #include <arm/cpufunc.h>
   
 static __inline int  static __inline int
 __swp(int __val, volatile int *__ptr)  __swp(int __val, volatile unsigned char *__ptr)
 {  {
   
         __asm volatile("swp %0, %1, [%2]"          __asm volatile("swpb %0, %1, [%2]"
             : "=r" (__val) : "r" (__val), "r" (__ptr) : "memory");              : "=r" (__val) : "r" (__val), "r" (__ptr) : "memory");
         return __val;          return __val;
 }  }
Line 83  __cpu_simple_unlock(__cpu_simple_lock_t 
Line 85  __cpu_simple_unlock(__cpu_simple_lock_t 
         *alp = __SIMPLELOCK_UNLOCKED;          *alp = __SIMPLELOCK_UNLOCKED;
 }  }
   
 #else /* !(_KERNEL && MULTIPROCESSOR) */  #else /* !(_HARDKERNEL && MULTIPROCESSOR) */
 #include <arm/lock.h>  #include <arm/lock.h>
 #endif /* !(_KERNEL && MULTIPROCESSOR) */  #endif /* !(_HARDKERNEL && MULTIPROCESSOR) */
 #endif  #endif

Legend:
Removed from v.1.6.76.1  
changed lines
  Added in v.1.6.76.2

CVSweb <webmaster@jp.NetBSD.org>