diff options
author | David Rientjes <rientjes@google.com> | 2009-03-31 18:23:29 -0400 |
---|---|---|
committer | Linus Torvalds <torvalds@linux-foundation.org> | 2009-04-01 11:59:15 -0400 |
commit | 88c3bd707c2552bcef93cc3724647903aece159d (patch) | |
tree | 68c104f559854b1f5fea01ed8568584e535ac597 /mm | |
parent | 71aa653c6bfa6743d838342105ebc067145394e4 (diff) |
vmscan: print shrink_slab symbol name on negative shrinker objects
When a shrinker has a negative number of objects to delete, the symbol
name of the shrinker should be printed, not shrink_slab. This also makes
the error message slightly more informative.
Cc: Ingo Molnar <mingo@elte.hu>
Signed-off-by: David Rientjes <rientjes@google.com>
Signed-off-by: Andrew Morton <akpm@linux-foundation.org>
Signed-off-by: Linus Torvalds <torvalds@linux-foundation.org>
Diffstat (limited to 'mm')
-rw-r--r-- | mm/vmscan.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/mm/vmscan.c b/mm/vmscan.c index e70fae31e968..f4619c6cd59e 100644 --- a/mm/vmscan.c +++ b/mm/vmscan.c | |||
@@ -214,8 +214,9 @@ unsigned long shrink_slab(unsigned long scanned, gfp_t gfp_mask, | |||
214 | do_div(delta, lru_pages + 1); | 214 | do_div(delta, lru_pages + 1); |
215 | shrinker->nr += delta; | 215 | shrinker->nr += delta; |
216 | if (shrinker->nr < 0) { | 216 | if (shrinker->nr < 0) { |
217 | printk(KERN_ERR "%s: nr=%ld\n", | 217 | printk(KERN_ERR "shrink_slab: %pF negative objects to " |
218 | __func__, shrinker->nr); | 218 | "delete nr=%ld\n", |
219 | shrinker->shrink, shrinker->nr); | ||
219 | shrinker->nr = max_pass; | 220 | shrinker->nr = max_pass; |
220 | } | 221 | } |
221 | 222 | ||