diff options
author | 2010-07-02 23:26:36 +0100 | |
---|---|---|
committer | 2011-08-29 13:45:19 -0700 | |
commit | 84eb950db13ca40a0572ce9957e14723500943d6 (patch) | |
tree | f2912697d8dbaade7fb1a948a6ba439a501fc03a /lib/mpi/mpiutil.c | |
parent | x86: Use xadd helper more widely (diff) | |
download | wireguard-linux-84eb950db13ca40a0572ce9957e14723500943d6.tar.xz wireguard-linux-84eb950db13ca40a0572ce9957e14723500943d6.zip |
x86, ticketlock: Clean up types and accessors
A few cleanups to the way spinlocks are defined and accessed:
- define __ticket_t which is the size of a spinlock ticket (ie, enough
bits to hold all the cpus)
- Define struct arch_spinlock as a union containing plain slock and
the head and tail tickets
- Use head and tail to implement some of the spinlock predicates.
- Make all ticket variables unsigned.
- Use TICKET_SHIFT to form constants
Most of this will be used in later patches.
Signed-off-by: Jeremy Fitzhardinge <jeremy.fitzhardinge@citrix.com>
Link: http://lkml.kernel.org/r/4E5BCC40.3030501@goop.org
Signed-off-by: H. Peter Anvin <hpa@linux.intel.com>
Diffstat (limited to 'lib/mpi/mpiutil.c')
0 files changed, 0 insertions, 0 deletions