Change KM_PUSHPAGE -> KM_SLEEP

By marking DMU transaction processing contexts with PF_FSTRANS
we can revert the KM_PUSHPAGE -> KM_SLEEP changes.  This brings
us back in line with upstream.  In some cases this means simply
swapping the flags back.  For others fnvlist_alloc() was replaced
by nvlist_alloc(..., KM_PUSHPAGE) and must be reverted back to
fnvlist_alloc() which assumes KM_SLEEP.

The one place KM_PUSHPAGE is kept is when allocating ARC buffers
which allows us to dip in to reserved memory.  This is again the
same as upstream.

Signed-off-by: Brian Behlendorf <behlendorf1@llnl.gov>
This commit is contained in:
Brian Behlendorf
2014-11-20 19:09:39 -05:00
parent efcd79a883
commit 79c76d5b65
65 changed files with 269 additions and 281 deletions
+3 -3
View File
@@ -449,7 +449,7 @@ txg_dispatch_callbacks(dsl_pool_t *dp, uint64_t txg)
TASKQ_THREADS_CPU_PCT | TASKQ_PREPOPULATE);
}
cb_list = kmem_alloc(sizeof (list_t), KM_PUSHPAGE);
cb_list = kmem_alloc(sizeof (list_t), KM_SLEEP);
list_create(cb_list, sizeof (dmu_tx_callback_t),
offsetof(dmu_tx_callback_t, dcb_node));
@@ -486,8 +486,8 @@ txg_sync_thread(dsl_pool_t *dp)
(void) spl_fstrans_mark();
txg_thread_enter(tx, &cpr);
vs1 = kmem_alloc(sizeof (vdev_stat_t), KM_PUSHPAGE);
vs2 = kmem_alloc(sizeof (vdev_stat_t), KM_PUSHPAGE);
vs1 = kmem_alloc(sizeof (vdev_stat_t), KM_SLEEP);
vs2 = kmem_alloc(sizeof (vdev_stat_t), KM_SLEEP);
start = delta = 0;
for (;;) {