Two easy fixes I caught with debug enabled

git-svn-id: https://outreach.scidac.gov/svn/spl/trunk@143 7e1ea52c-4ff2-0310-8f11-9dd32ca42a1c
This commit is contained in:
behlendo 2008-07-01 04:06:09 +00:00
parent 3ba97a6743
commit f78a933f8a
1 changed files with 2 additions and 3 deletions

View File

@ -619,8 +619,8 @@ spl_cache_grow(spl_kmem_cache_t *skc, int flags)
if (flags & __GFP_WAIT) { if (flags & __GFP_WAIT) {
flags |= __GFP_NOFAIL; flags |= __GFP_NOFAIL;
might_sleep();
local_irq_enable(); local_irq_enable();
might_sleep();
} }
sks = spl_slab_alloc(skc, flags); sks = spl_slab_alloc(skc, flags);
@ -1006,7 +1006,7 @@ spl_kmem_init(void)
spl_kmem_cache_shrinker = set_shrinker(KMC_DEFAULT_SEEKS, spl_kmem_cache_shrinker = set_shrinker(KMC_DEFAULT_SEEKS,
spl_kmem_cache_generic_shrinker); spl_kmem_cache_generic_shrinker);
if (spl_kmem_cache_shrinker == NULL) if (spl_kmem_cache_shrinker == NULL)
GOTO(out, rc = -ENOMEM); RETURN(rc = -ENOMEM);
#else #else
register_shrinker(&spl_kmem_cache_shrinker); register_shrinker(&spl_kmem_cache_shrinker);
#endif #endif
@ -1018,7 +1018,6 @@ spl_kmem_init(void)
spl_kmem_init_tracking(&kmem_list, &kmem_lock, KMEM_TABLE_SIZE); spl_kmem_init_tracking(&kmem_list, &kmem_lock, KMEM_TABLE_SIZE);
spl_kmem_init_tracking(&vmem_list, &vmem_lock, VMEM_TABLE_SIZE); spl_kmem_init_tracking(&vmem_list, &vmem_lock, VMEM_TABLE_SIZE);
#endif #endif
out:
RETURN(rc); RETURN(rc);
} }