Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 276041
b: refs/heads/master
c: 9ada193
h: refs/heads/master
i:
  276039: 2f217b7
v: v3
  • Loading branch information
Shaohua Li authored and Pekka Enberg committed Nov 15, 2011
1 parent 5ccd539 commit 5e021e6
Show file tree
Hide file tree
Showing 2 changed files with 13 additions and 5 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: f64ae042d94d376b54e7a343d93c48561e9d2e16
refs/heads/master: 9ada19342b2441f290f0043ed7c562682c8c4ede
16 changes: 12 additions & 4 deletions trunk/mm/slub.c
Original file line number Diff line number Diff line change
Expand Up @@ -1862,7 +1862,7 @@ static void unfreeze_partials(struct kmem_cache *s)
{
struct kmem_cache_node *n = NULL;
struct kmem_cache_cpu *c = this_cpu_ptr(s->cpu_slab);
struct page *page;
struct page *page, *discard_page = NULL;

while ((page = c->partial)) {
enum slab_modes { M_PARTIAL, M_FREE };
Expand Down Expand Up @@ -1916,14 +1916,22 @@ static void unfreeze_partials(struct kmem_cache *s)
"unfreezing slab"));

if (m == M_FREE) {
stat(s, DEACTIVATE_EMPTY);
discard_slab(s, page);
stat(s, FREE_SLAB);
page->next = discard_page;
discard_page = page;
}
}

if (n)
spin_unlock(&n->list_lock);

while (discard_page) {
page = discard_page;
discard_page = discard_page->next;

stat(s, DEACTIVATE_EMPTY);
discard_slab(s, page);
stat(s, FREE_SLAB);
}
}

/*
Expand Down

0 comments on commit 5e021e6

Please sign in to comment.