Groups | Search | Server Info | Keyboard shortcuts | Login | Register [http] [https] [nntp] [nntps]
Groups > linux.kernel > #1441549 > unrolled thread
| Started by | Steven Rostedt <rostedt@goodmis.org> |
|---|---|
| First post | 2016-07-12 18:50 +0200 |
| Last post | 2016-07-12 18:50 +0200 |
| Articles | 1 — 1 participant |
Back to article view | Back to linux.kernel
This discussion starts older than the indexed window; earlier articles aren't shown. The article labeled Started by
below is the oldest one visible, not the original post.
[PATCH RT 02/14] mm/zsmalloc: Use get/put_cpu_light in zs_map_object()/zs_unmap_object() Steven Rostedt <rostedt@goodmis.org> - 2016-07-12 18:50 +0200
| From | Steven Rostedt <rostedt@goodmis.org> |
|---|---|
| Date | 2016-07-12 18:50 +0200 |
| Subject | [PATCH RT 02/14] mm/zsmalloc: Use get/put_cpu_light in zs_map_object()/zs_unmap_object() |
| Message-ID | <rU92F-7wG-1@gated-at.bofh.it> |
3.14.72-rt76-rc1 stable review patch.
If anyone has any objections, please let me know.
------------------
From: Mike Galbraith <umgwanakikbuti@gmail.com>
Otherwise, we get a ___might_sleep() splat.
Signed-off-by: Mike Galbraith <umgwanakikbuti@gmail.com>
Signed-off-by: Sebastian Andrzej Siewior <bigeasy@linutronix.de>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
---
mm/zsmalloc.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/mm/zsmalloc.c b/mm/zsmalloc.c
index c03ca5e9fe15..df9c7a189118 100644
--- a/mm/zsmalloc.c
+++ b/mm/zsmalloc.c
@@ -1037,7 +1037,7 @@ void *zs_map_object(struct zs_pool *pool, unsigned long handle,
class = &pool->size_class[class_idx];
off = obj_idx_to_offset(page, obj_idx, class->size);
- area = &get_cpu_var(zs_map_area);
+ area = per_cpu_ptr(&zs_map_area, get_cpu_light());
area->vm_mm = mm;
if (off + class->size <= PAGE_SIZE) {
/* this object is contained entirely within a page */
@@ -1083,7 +1083,7 @@ void zs_unmap_object(struct zs_pool *pool, unsigned long handle)
__zs_unmap_object(area, pages, off, class->size);
}
- put_cpu_var(zs_map_area);
+ put_cpu_light();
}
EXPORT_SYMBOL_GPL(zs_unmap_object);
--
2.8.1
Back to top | Article view | linux.kernel
csiph-web