summaryrefslogtreecommitdiffstats
path: root/include/linux/proportions.h
diff options
context:
space:
mode:
authorThomas Gleixner <tglx@linutronix.de>2009-07-25 16:43:30 +0200
committerIngo Molnar <mingo@elte.hu>2011-09-13 11:11:50 +0200
commit740969f91e950b64a18fdd0a25164cdee042abf0 (patch)
treeb152f88baf3868a7f3df4fa712ecd6a8c811d0a4 /include/linux/proportions.h
parentcdcc136ffd264849a943acb42c36ffe9b458f811 (diff)
downloadop-kernel-dev-740969f91e950b64a18fdd0a25164cdee042abf0.zip
op-kernel-dev-740969f91e950b64a18fdd0a25164cdee042abf0.tar.gz
locking, lib/proportions: Annotate prop_local_percpu::lock as raw
The prop_local_percpu::lock can be taken in atomic context and therefore cannot be preempted on -rt - annotate it. In mainline this change documents the low level nature of the lock - otherwise there's no functional difference. Lockdep and Sparse checking will work as usual. Signed-off-by: Thomas Gleixner <tglx@linutronix.de> Signed-off-by: Ingo Molnar <mingo@elte.hu>
Diffstat (limited to 'include/linux/proportions.h')
-rw-r--r--include/linux/proportions.h6
1 files changed, 3 insertions, 3 deletions
diff --git a/include/linux/proportions.h b/include/linux/proportions.h
index cf793bb..ef35bb7 100644
--- a/include/linux/proportions.h
+++ b/include/linux/proportions.h
@@ -58,7 +58,7 @@ struct prop_local_percpu {
*/
int shift;
unsigned long period;
- spinlock_t lock; /* protect the snapshot state */
+ raw_spinlock_t lock; /* protect the snapshot state */
};
int prop_local_init_percpu(struct prop_local_percpu *pl);
@@ -106,11 +106,11 @@ struct prop_local_single {
*/
unsigned long period;
int shift;
- spinlock_t lock; /* protect the snapshot state */
+ raw_spinlock_t lock; /* protect the snapshot state */
};
#define INIT_PROP_LOCAL_SINGLE(name) \
-{ .lock = __SPIN_LOCK_UNLOCKED(name.lock), \
+{ .lock = __RAW_SPIN_LOCK_UNLOCKED(name.lock), \
}
int prop_local_init_single(struct prop_local_single *pl);
OpenPOWER on IntegriCloud