mirror of
https://github.com/BobTheBlinker/android_kernel_motorola_sm6375.git
synced 2026-10-25 06:03:36 -04:00
lib: percpu_counter_init_irq
provide a way to tell lockdep about percpu_counters that are supposed to be used from irq safe contexts. Signed-off-by: Peter Zijlstra <a.p.zijlstra@chello.nl> Signed-off-by: Andrew Morton <akpm@linux-foundation.org> Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
This commit is contained in:
parent
833f4077bf
commit
dc62a30e27
2 changed files with 15 additions and 0 deletions
|
|
@ -31,6 +31,7 @@ struct percpu_counter {
|
|||
#endif
|
||||
|
||||
int percpu_counter_init(struct percpu_counter *fbc, s64 amount);
|
||||
int percpu_counter_init_irq(struct percpu_counter *fbc, s64 amount);
|
||||
void percpu_counter_destroy(struct percpu_counter *fbc);
|
||||
void percpu_counter_set(struct percpu_counter *fbc, s64 amount);
|
||||
void __percpu_counter_add(struct percpu_counter *fbc, s64 amount, s32 batch);
|
||||
|
|
@ -84,6 +85,8 @@ static inline int percpu_counter_init(struct percpu_counter *fbc, s64 amount)
|
|||
return 0;
|
||||
}
|
||||
|
||||
#define percpu_counter_init_irq percpu_counter_init
|
||||
|
||||
static inline void percpu_counter_destroy(struct percpu_counter *fbc)
|
||||
{
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue