git://ftp.safe.ca
/
safe
/
jmp
/
linux-2.6
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
memcg: show memcg information during OOM
[safe/jmp/linux-2.6]
/
mm
/
slab.c
diff --git
a/mm/slab.c
b/mm/slab.c
index
f97e564
..
208323f
100644
(file)
--- a/
mm/slab.c
+++ b/
mm/slab.c
@@
-2157,7
+2157,7
@@
kmem_cache_create (const char *name, size_t size, size_t align,
/*
* We use cache_chain_mutex to ensure a consistent view of
/*
* We use cache_chain_mutex to ensure a consistent view of
- * cpu_online_ma
p
as well. Please see cpuup_callback
+ * cpu_online_ma
sk
as well. Please see cpuup_callback
*/
get_online_cpus();
mutex_lock(&cache_chain_mutex);
*/
get_online_cpus();
mutex_lock(&cache_chain_mutex);
@@
-3318,6
+3318,8
@@
__cache_alloc_node(struct kmem_cache *cachep, gfp_t flags, int nodeid,
unsigned long save_flags;
void *ptr;
unsigned long save_flags;
void *ptr;
+ lockdep_trace_alloc(flags);
+
if (slab_should_failslab(cachep, flags))
return NULL;
if (slab_should_failslab(cachep, flags))
return NULL;
@@
-3394,6
+3396,8
@@
__cache_alloc(struct kmem_cache *cachep, gfp_t flags, void *caller)
unsigned long save_flags;
void *objp;
unsigned long save_flags;
void *objp;
+ lockdep_trace_alloc(flags);
+
if (slab_should_failslab(cachep, flags))
return NULL;
if (slab_should_failslab(cachep, flags))
return NULL;
@@
-3988,8
+3992,7
@@
static void cache_reap(struct work_struct *w)
struct kmem_cache *searchp;
struct kmem_list3 *l3;
int node = numa_node_id();
struct kmem_cache *searchp;
struct kmem_list3 *l3;
int node = numa_node_id();
- struct delayed_work *work =
- container_of(w, struct delayed_work, work);
+ struct delayed_work *work = to_delayed_work(w);
if (!mutex_trylock(&cache_chain_mutex))
/* Give up. Setup the next iteration. */
if (!mutex_trylock(&cache_chain_mutex))
/* Give up. Setup the next iteration. */
@@
-4457,3
+4460,4
@@
size_t ksize(const void *objp)
return obj_size(virt_to_cache(objp));
}
return obj_size(virt_to_cache(objp));
}
+EXPORT_SYMBOL(ksize);