Skip to content

Commit

Permalink
---
Browse files Browse the repository at this point in the history
yaml
---
r: 101341
b: refs/heads/master
c: e79aec2
h: refs/heads/master
i:
  101339: 0fe132f
v: v3
  • Loading branch information
Rabin Vincent authored and Pekka Enberg committed Jul 15, 2008
1 parent da699da commit d84a136
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 12 deletions.
2 changes: 1 addition & 1 deletion [refs]
Original file line number Diff line number Diff line change
@@ -1,2 +1,2 @@
---
refs/heads/master: 88e4ccf294ca62c2da998012a83533ce150c8dce
refs/heads/master: e79aec291da55aa322ddb5d8f3bb04cdf69470d5
14 changes: 3 additions & 11 deletions trunk/mm/slab.c
Original file line number Diff line number Diff line change
Expand Up @@ -1901,15 +1901,7 @@ static void check_poison_obj(struct kmem_cache *cachep, void *objp)
#endif

#if DEBUG
/**
* slab_destroy_objs - destroy a slab and its objects
* @cachep: cache pointer being destroyed
* @slabp: slab pointer being destroyed
*
* Call the registered destructor for each object in a slab that is being
* destroyed.
*/
static void slab_destroy_objs(struct kmem_cache *cachep, struct slab *slabp)
static void slab_destroy_debugcheck(struct kmem_cache *cachep, struct slab *slabp)
{
int i;
for (i = 0; i < cachep->num; i++) {
Expand Down Expand Up @@ -1938,7 +1930,7 @@ static void slab_destroy_objs(struct kmem_cache *cachep, struct slab *slabp)
}
}
#else
static void slab_destroy_objs(struct kmem_cache *cachep, struct slab *slabp)
static void slab_destroy_debugcheck(struct kmem_cache *cachep, struct slab *slabp)
{
}
#endif
Expand All @@ -1956,7 +1948,7 @@ static void slab_destroy(struct kmem_cache *cachep, struct slab *slabp)
{
void *addr = slabp->s_mem - slabp->colouroff;

slab_destroy_objs(cachep, slabp);
slab_destroy_debugcheck(cachep, slabp);
if (unlikely(cachep->flags & SLAB_DESTROY_BY_RCU)) {
struct slab_rcu *slab_rcu;

Expand Down

0 comments on commit d84a136

Please sign in to comment.