projects
/
linux-2.6-microblaze.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
mm: memcg/slab: allocate obj_cgroups for non-root slab pages
[linux-2.6-microblaze.git]
/
include
/
linux
/
slab_def.h
diff --git
a/include/linux/slab_def.h
b/include/linux/slab_def.h
index
abc7de7
..
ccda7b9
100644
(file)
--- a/
include/linux/slab_def.h
+++ b/
include/linux/slab_def.h
@@
-114,4
+114,10
@@
static inline unsigned int obj_to_index(const struct kmem_cache *cache,
return reciprocal_divide(offset, cache->reciprocal_buffer_size);
}
+static inline int objs_per_slab_page(const struct kmem_cache *cache,
+ const struct page *page)
+{
+ return cache->num;
+}
+
#endif /* _LINUX_SLAB_DEF_H */