From beb999445adaa6d794f0d706ca8a0c835cb1468c Mon Sep 17 00:00:00 2001 From: Massimo Maggi Date: Sun, 7 Oct 2012 21:54:06 +0200 Subject: [PATCH] Switch KM_SLEEP to KM_PUSHPAGE Prevent snapshot_check to initiate I/O during memory allocation. Signed-off-by: Massimo Maggi Signed-off-by: Brian Behlendorf Closes #1023 --- module/zfs/dmu_objset.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/module/zfs/dmu_objset.c b/module/zfs/dmu_objset.c index c1bc1de7b..628b23be1 100644 --- a/module/zfs/dmu_objset.c +++ b/module/zfs/dmu_objset.c @@ -848,7 +848,7 @@ snapshot_check(void *arg1, void *arg2, dmu_tx_t *tx) if (strlen(sn->htag) + MAX_TAG_PREFIX_LEN >= MAXNAMELEN) return (E2BIG); - sn->ha = kmem_alloc(sizeof (struct dsl_ds_holdarg), KM_SLEEP); + sn->ha = kmem_alloc(sizeof(struct dsl_ds_holdarg), KM_PUSHPAGE); sn->ha->temphold = B_TRUE; sn->ha->htag = sn->htag; } -- 2.40.0