diff options
Diffstat (limited to 'mm/slab.c')
-rw-r--r-- | mm/slab.c | 11 |
1 files changed, 6 insertions, 5 deletions
@@ -654,7 +654,7 @@ static void init_node_lock_keys(int q) | |||
654 | 654 | ||
655 | l3 = s->cs_cachep->nodelists[q]; | 655 | l3 = s->cs_cachep->nodelists[q]; |
656 | if (!l3 || OFF_SLAB(s->cs_cachep)) | 656 | if (!l3 || OFF_SLAB(s->cs_cachep)) |
657 | return; | 657 | continue; |
658 | lockdep_set_class(&l3->list_lock, &on_slab_l3_key); | 658 | lockdep_set_class(&l3->list_lock, &on_slab_l3_key); |
659 | alc = l3->alien; | 659 | alc = l3->alien; |
660 | /* | 660 | /* |
@@ -665,7 +665,7 @@ static void init_node_lock_keys(int q) | |||
665 | * for alloc_alien_cache, | 665 | * for alloc_alien_cache, |
666 | */ | 666 | */ |
667 | if (!alc || (unsigned long)alc == BAD_ALIEN_MAGIC) | 667 | if (!alc || (unsigned long)alc == BAD_ALIEN_MAGIC) |
668 | return; | 668 | continue; |
669 | for_each_node(r) { | 669 | for_each_node(r) { |
670 | if (alc[r]) | 670 | if (alc[r]) |
671 | lockdep_set_class(&alc[r]->lock, | 671 | lockdep_set_class(&alc[r]->lock, |
@@ -935,7 +935,6 @@ static int transfer_objects(struct array_cache *to, | |||
935 | 935 | ||
936 | from->avail -= nr; | 936 | from->avail -= nr; |
937 | to->avail += nr; | 937 | to->avail += nr; |
938 | to->touched = 1; | ||
939 | return nr; | 938 | return nr; |
940 | } | 939 | } |
941 | 940 | ||
@@ -2961,8 +2960,10 @@ retry: | |||
2961 | spin_lock(&l3->list_lock); | 2960 | spin_lock(&l3->list_lock); |
2962 | 2961 | ||
2963 | /* See if we can refill from the shared array */ | 2962 | /* See if we can refill from the shared array */ |
2964 | if (l3->shared && transfer_objects(ac, l3->shared, batchcount)) | 2963 | if (l3->shared && transfer_objects(ac, l3->shared, batchcount)) { |
2964 | l3->shared->touched = 1; | ||
2965 | goto alloc_done; | 2965 | goto alloc_done; |
2966 | } | ||
2966 | 2967 | ||
2967 | while (batchcount > 0) { | 2968 | while (batchcount > 0) { |
2968 | struct list_head *entry; | 2969 | struct list_head *entry; |
@@ -3099,7 +3100,7 @@ static bool slab_should_failslab(struct kmem_cache *cachep, gfp_t flags) | |||
3099 | if (cachep == &cache_cache) | 3100 | if (cachep == &cache_cache) |
3100 | return false; | 3101 | return false; |
3101 | 3102 | ||
3102 | return should_failslab(obj_size(cachep), flags); | 3103 | return should_failslab(obj_size(cachep), flags, cachep->flags); |
3103 | } | 3104 | } |
3104 | 3105 | ||
3105 | static inline void *____cache_alloc(struct kmem_cache *cachep, gfp_t flags) | 3106 | static inline void *____cache_alloc(struct kmem_cache *cachep, gfp_t flags) |