Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 53911
b: refs/heads/master
c: 62918a0
h: refs/heads/master
i:
  53909: 8bb3fe4
  53907: dfd77f0
  53903: 1ec9c50
v: v3
  • Loading branch information
Siddha, Suresh B authored and Andi Kleen committed May 2, 2007
1 parent c221081 commit d9cb52c
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 3 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 57a4f91ae5571edd7c0428285d8df16bb8bf5f40
refs/heads/master: 62918a036148230ba1ad175dc8a0952e3752ac57
7 changes: 5 additions & 2 deletions trunk/mm/slab.c
Original file line number Diff line number Diff line change
Expand Up @@ -1146,7 +1146,7 @@ static inline int cache_free_alien(struct kmem_cache *cachep, void *objp)
* Make sure we are not freeing a object from another node to the array
* cache on this cpu.
*/
if (likely(slabp->nodeid == node) || unlikely(!use_alien_caches))
if (likely(slabp->nodeid == node))
return 0;

l3 = cachep->nodelists[node];
Expand Down Expand Up @@ -1394,6 +1394,9 @@ void __init kmem_cache_init(void)
int order;
int node;

if (num_possible_nodes() == 1)
use_alien_caches = 0;

for (i = 0; i < NUM_INIT_LISTS; i++) {
kmem_list3_init(&initkmem_list3[i]);
if (i < MAX_NUMNODES)
Expand Down Expand Up @@ -3563,7 +3566,7 @@ static inline void __cache_free(struct kmem_cache *cachep, void *objp)
check_irq_off();
objp = cache_free_debugcheck(cachep, objp, __builtin_return_address(0));

if (cache_free_alien(cachep, objp))
if (use_alien_caches && cache_free_alien(cachep, objp))
return;

if (likely(ac->avail < ac->limit)) {
Expand Down

0 comments on commit d9cb52c

Please sign in to comment.