Date: Mon, 1 Dec 2003 13:11:18 -0800 (PST) From: Peter Wemm <peter@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 43248 for review Message-ID: <200312012111.hB1LBIKF067937@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=43248 Change 43248 by peter@peter_daintree on 2003/12/01 13:10:58 MTX_LOCK_SPIN and MTX_UNLOCK_SPIN are not used.. kill the broken definitions of them. XXX also appears to be unused on i386. Affected files ... .. //depot/projects/hammer/sys/amd64/include/mutex.h#6 edit Differences ... ==== //depot/projects/hammer/sys/amd64/include/mutex.h#6 (text+ko) ==== @@ -33,7 +33,6 @@ #define _MACHINE_MUTEX_H_ #ifndef LOCORE - #ifdef _KERNEL /* Global locks */ @@ -41,35 +40,5 @@ #endif /* _KERNEL */ -#else /* !LOCORE */ - -/* - * Simple assembly macros to get and release mutexes. - * - * Note: All of these macros accept a "flags" argument and are analoguous - * to the mtx_lock_flags and mtx_unlock_flags general macros. If one - * desires to not pass a flag, the value 0 may be passed as second - * argument. - * - * XXX: We only have MTX_LOCK_SPIN and MTX_UNLOCK_SPIN for now, since that's - * all we use right now. We should add MTX_LOCK and MTX_UNLOCK (for sleep - * locks) in the near future, however. - */ -#define MTX_LOCK_SPIN(lck, flags) \ - pushq $0 ; \ - pushq $0 ; \ - pushq $flags ; \ - pushq $lck ; \ - call _mtx_lock_spin_flags ; \ - addq $0x20, %rsp ; \ - -#define MTX_UNLOCK_SPIN(lck) \ - pushq $0 ; \ - pushq $0 ; \ - pushq $0 ; \ - pushq $lck ; \ - call _mtx_unlock_spin_flags ; \ - addq $0x20, %rsp ; \ - #endif /* !LOCORE */ #endif /* __MACHINE_MUTEX_H */
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200312012111.hB1LBIKF067937>