Lines Matching refs:s

90 int slab_unmergeable(struct kmem_cache *s);
161 void get_slabinfo(struct kmem_cache *s, struct slabinfo *sinfo);
162 void slabinfo_show_stats(struct seq_file *m, struct kmem_cache *s);
184 static inline bool is_root_cache(struct kmem_cache *s) in is_root_cache() argument
186 return s->memcg_params.is_root_cache; in is_root_cache()
189 static inline bool slab_equal_or_root(struct kmem_cache *s, in slab_equal_or_root() argument
192 return p == s || p == s->memcg_params.root_cache; in slab_equal_or_root()
200 static inline const char *cache_name(struct kmem_cache *s) in cache_name() argument
202 if (!is_root_cache(s)) in cache_name()
203 s = s->memcg_params.root_cache; in cache_name()
204 return s->name; in cache_name()
213 cache_from_memcg_idx(struct kmem_cache *s, int idx) in cache_from_memcg_idx() argument
219 arr = rcu_dereference(s->memcg_params.memcg_caches); in cache_from_memcg_idx()
232 static inline struct kmem_cache *memcg_root_cache(struct kmem_cache *s) in memcg_root_cache() argument
234 if (is_root_cache(s)) in memcg_root_cache()
235 return s; in memcg_root_cache()
236 return s->memcg_params.root_cache; in memcg_root_cache()
241 struct kmem_cache *s) in memcg_charge_slab() argument
245 if (is_root_cache(s)) in memcg_charge_slab()
248 s->memcg_params.memcg); in memcg_charge_slab()
258 static inline bool is_root_cache(struct kmem_cache *s) in is_root_cache() argument
263 static inline bool slab_equal_or_root(struct kmem_cache *s, in slab_equal_or_root() argument
269 static inline const char *cache_name(struct kmem_cache *s) in cache_name() argument
271 return s->name; in cache_name()
275 cache_from_memcg_idx(struct kmem_cache *s, int idx) in cache_from_memcg_idx() argument
280 static inline struct kmem_cache *memcg_root_cache(struct kmem_cache *s) in memcg_root_cache() argument
282 return s; in memcg_root_cache()
286 struct kmem_cache *s) in memcg_charge_slab() argument
291 static inline void slab_init_memcg_params(struct kmem_cache *s) in slab_init_memcg_params() argument
296 static inline struct kmem_cache *cache_from_obj(struct kmem_cache *s, void *x) in cache_from_obj() argument
308 if (!memcg_kmem_enabled() && !unlikely(s->flags & SLAB_DEBUG_FREE)) in cache_from_obj()
309 return s; in cache_from_obj()
313 if (slab_equal_or_root(cachep, s)) in cache_from_obj()
317 __func__, s->name, cachep->name); in cache_from_obj()
319 return s; in cache_from_obj()
354 static inline struct kmem_cache_node *get_node(struct kmem_cache *s, int node) in get_node() argument
356 return s->node[node]; in get_node()