| version 1.156, 2008/03/27 18:30:15 |
version 1.157, 2008/04/24 11:38:36 |
| Line 814 pool_init(struct pool *pp, size_t size, |
|
| Line 814 pool_init(struct pool *pp, size_t size, |
|
| pp->pr_entered_file = NULL; |
pp->pr_entered_file = NULL; |
| pp->pr_entered_line = 0; |
pp->pr_entered_line = 0; |
| |
|
| /* |
mutex_init(&pp->pr_lock, MUTEX_DEFAULT, ipl); |
| * XXXAD hack to prevent IP input processing from blocking. |
|
| */ |
|
| if (ipl == IPL_SOFTNET) { |
|
| mutex_init(&pp->pr_lock, MUTEX_DEFAULT, IPL_VM); |
|
| } else { |
|
| mutex_init(&pp->pr_lock, MUTEX_DEFAULT, ipl); |
|
| } |
|
| cv_init(&pp->pr_cv, wchan); |
cv_init(&pp->pr_cv, wchan); |
| pp->pr_ipl = ipl; |
pp->pr_ipl = ipl; |
| |
|
| Line 1629 pool_reclaim(struct pool *pp) |
|
| Line 1622 pool_reclaim(struct pool *pp) |
|
| } |
} |
| |
|
| /* |
/* |
| * XXXSMP Because mutexes at IPL_SOFTXXX are still spinlocks, |
* XXXSMP Because we do not want to cause non-MPSAFE code |
| * and we are called from the pagedaemon without kernel_lock. |
* to block. |
| * Does not apply to IPL_SOFTBIO. |
|
| */ |
*/ |
| if (pp->pr_ipl == IPL_SOFTNET || pp->pr_ipl == IPL_SOFTCLOCK || |
if (pp->pr_ipl == IPL_SOFTNET || pp->pr_ipl == IPL_SOFTCLOCK || |
| pp->pr_ipl == IPL_SOFTSERIAL) { |
pp->pr_ipl == IPL_SOFTSERIAL) { |
| Line 2074 pool_cache_bootstrap(pool_cache_t pc, si |
|
| Line 2066 pool_cache_bootstrap(pool_cache_t pc, si |
|
| if (palloc == NULL && ipl == IPL_NONE) |
if (palloc == NULL && ipl == IPL_NONE) |
| palloc = &pool_allocator_nointr; |
palloc = &pool_allocator_nointr; |
| pool_init(pp, size, align, align_offset, flags, wchan, palloc, ipl); |
pool_init(pp, size, align, align_offset, flags, wchan, palloc, ipl); |
| |
mutex_init(&pc->pc_lock, MUTEX_DEFAULT, ipl); |
| /* |
|
| * XXXAD hack to prevent IP input processing from blocking. |
|
| */ |
|
| if (ipl == IPL_SOFTNET) { |
|
| mutex_init(&pc->pc_lock, MUTEX_DEFAULT, IPL_VM); |
|
| } else { |
|
| mutex_init(&pc->pc_lock, MUTEX_DEFAULT, ipl); |
|
| } |
|
| |
|
| if (ctor == NULL) { |
if (ctor == NULL) { |
| ctor = (int (*)(void *, void *, int))nullop; |
ctor = (int (*)(void *, void *, int))nullop; |