aboutsummaryrefslogtreecommitdiffstats
path: root/module/zfs/ddt.c
diff options
context:
space:
mode:
authorBrian Behlendorf <[email protected]>2012-09-19 11:50:22 -0700
committerBrian Behlendorf <[email protected]>2012-09-19 11:52:36 -0700
commit95fd8c9a7f979e4c4941d329e6457cc84a81edfa (patch)
treec52315db5fa8de5eae92e266504b9c69e7b6c24d /module/zfs/ddt.c
parent0a2f7b3662fd10e7ac56a4b2859248eb98e31d6d (diff)
Switch KM_SLEEP to KM_PUSHPAGE
This warning indicates the incorrect use of KM_SLEEP in a call path which must use KM_PUSHPAGE to avoid deadlocking in direct reclaim. See commit b8d06fca089fae4680c3a552fc55c512bfb02202 for additional details. SPL: Fixing allocation for task txg_sync (6093) which used GFP flags 0x297bda7c with PF_NOFS set Signed-off-by: Brian Behlendorf <[email protected]> Issue #973
Diffstat (limited to 'module/zfs/ddt.c')
-rw-r--r--module/zfs/ddt.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/module/zfs/ddt.c b/module/zfs/ddt.c
index f93024d8f..895422b50 100644
--- a/module/zfs/ddt.c
+++ b/module/zfs/ddt.c
@@ -653,7 +653,7 @@ ddt_alloc(const ddt_key_t *ddk)
ddt_entry_t *dde;
/* XXX: Move to a slab */
- dde = kmem_zalloc(sizeof (ddt_entry_t), KM_SLEEP);
+ dde = kmem_zalloc(sizeof (ddt_entry_t), KM_PUSHPAGE);
cv_init(&dde->dde_cv, NULL, CV_DEFAULT, NULL);
dde->dde_key = *ddk;
@@ -802,7 +802,7 @@ ddt_table_alloc(spa_t *spa, enum zio_checksum c)
ddt_t *ddt;
/* XXX: Move to a slab */
- ddt = kmem_zalloc(sizeof (*ddt), KM_SLEEP | KM_NODEBUG);
+ ddt = kmem_zalloc(sizeof (*ddt), KM_PUSHPAGE | KM_NODEBUG);
mutex_init(&ddt->ddt_lock, NULL, MUTEX_DEFAULT, NULL);
avl_create(&ddt->ddt_tree, ddt_entry_compare,
@@ -904,7 +904,7 @@ ddt_class_contains(spa_t *spa, enum ddt_class max_class, const blkptr_t *bp)
return (B_TRUE);
ddt = spa->spa_ddt[BP_GET_CHECKSUM(bp)];
- dde = kmem_alloc(sizeof(ddt_entry_t), KM_SLEEP);
+ dde = kmem_alloc(sizeof(ddt_entry_t), KM_PUSHPAGE);
ddt_key_fill(&(dde->dde_key), bp);