/* * @(#)68K.gcc 11.1 (Sleepycat) 7/25/99 * * For gcc/68K, 0 is clear, 1 is set. */ #define MUTEX_SET(tsl) ({ \ register tsl_t *__l = (tsl); \ int __r; \ asm volatile("tas %1; \n \ seq %0" \ : "=dm" (__r), "=m" (*__l) \ : "1" (*__l) \ ); \ __r & 1; \ }) #define MUTEX_UNSET(tsl) (*(tsl) = 0) #define MUTEX_INIT(tsl) MUTEX_UNSET(tsl)