diff options
author | Christoph Lameter <cl@linux.com> | 2014-06-04 19:07:56 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2014-06-04 19:54:03 -0400 |
commit | 7c8e0181e6e0b8079c4c2ce902bf52d7a2c6fa5d (patch) | |
tree | fe5aee0e426d8f0528856bb0decb95636ff3e8a0 /mm/slub.c | |
parent | dc6f6c97f1d3d58fef81f0f9db0c7d068b2cf392 (diff) |
mm: replace __get_cpu_var uses with this_cpu_ptr
Replace places where __get_cpu_var() is used for an address calculation
with this_cpu_ptr().
Signed-off-by: Christoph Lameter <cl@linux.com>
Cc: Tejun Heo <tj@kernel.org>
Cc: Hugh Dickins <hughd@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm/slub.c')
-rw-r--r-- | mm/slub.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -2209,7 +2209,7 @@ static inline void *new_slab_objects(struct kmem_cache *s, gfp_t flags, | |||
2209 | 2209 | ||
2210 | page = new_slab(s, flags, node); | 2210 | page = new_slab(s, flags, node); |
2211 | if (page) { | 2211 | if (page) { |
2212 | c = __this_cpu_ptr(s->cpu_slab); | 2212 | c = raw_cpu_ptr(s->cpu_slab); |
2213 | if (c->page) | 2213 | if (c->page) |
2214 | flush_slab(s, c); | 2214 | flush_slab(s, c); |
2215 | 2215 | ||
@@ -2425,7 +2425,7 @@ redo: | |||
2425 | * and the retrieval of the tid. | 2425 | * and the retrieval of the tid. |
2426 | */ | 2426 | */ |
2427 | preempt_disable(); | 2427 | preempt_disable(); |
2428 | c = __this_cpu_ptr(s->cpu_slab); | 2428 | c = this_cpu_ptr(s->cpu_slab); |
2429 | 2429 | ||
2430 | /* | 2430 | /* |
2431 | * The transaction ids are globally unique per cpu and per operation on | 2431 | * The transaction ids are globally unique per cpu and per operation on |
@@ -2681,7 +2681,7 @@ redo: | |||
2681 | * during the cmpxchg then the free will succedd. | 2681 | * during the cmpxchg then the free will succedd. |
2682 | */ | 2682 | */ |
2683 | preempt_disable(); | 2683 | preempt_disable(); |
2684 | c = __this_cpu_ptr(s->cpu_slab); | 2684 | c = this_cpu_ptr(s->cpu_slab); |
2685 | 2685 | ||
2686 | tid = c->tid; | 2686 | tid = c->tid; |
2687 | preempt_enable(); | 2687 | preempt_enable(); |