From 13fe019870c8779bf2f5b3ff731b512cf89133ef Mon Sep 17 00:00:00 2001 From: Matthew Ahrens Date: Wed, 4 Sep 2013 07:00:57 -0500 Subject: Illumos #3464 3464 zfs synctask code needs restructuring Reviewed by: Dan Kimmel Reviewed by: Adam Leventhal Reviewed by: George Wilson Reviewed by: Christopher Siden Approved by: Garrett D'Amore References: https://www.illumos.org/issues/3464 illumos/illumos-gate@3b2aab18808792cbd248a12f1edf139b89833c13 Ported-by: Tim Chase Signed-off-by: Brian Behlendorf Closes #1495 --- module/zfs/dnode.c | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'module/zfs/dnode.c') diff --git a/module/zfs/dnode.c b/module/zfs/dnode.c index d8d66513d..d88134d72 100644 --- a/module/zfs/dnode.c +++ b/module/zfs/dnode.c @@ -74,7 +74,11 @@ dnode_cons(void *arg, void *unused, int kmflag) mutex_init(&dn->dn_dbufs_mtx, NULL, MUTEX_DEFAULT, NULL); cv_init(&dn->dn_notxholds, NULL, CV_DEFAULT, NULL); - refcount_create(&dn->dn_holds); + /* + * Every dbuf has a reference, and dropping a tracked reference is + * O(number of references), so don't track dn_holds. + */ + refcount_create_untracked(&dn->dn_holds); refcount_create(&dn->dn_tx_holds); list_link_init(&dn->dn_link); -- cgit v1.2.3