Mercurial > illumos > illumos-gate
changeset 4079:4c31c5bc2389
6453594 Number of unreclaimed files and Number of inodes in ufs delete queue are not always in sync
author | vk154806 |
---|---|
date | Fri, 20 Apr 2007 06:09:57 -0700 |
parents | 63cca4b3778c |
children | 7fe2cd8abb79 |
files | usr/src/uts/common/fs/ufs/ufs_thread.c |
diffstat | 1 files changed, 9 insertions(+), 1 deletions(-) [+] |
line wrap: on
line diff
--- a/usr/src/uts/common/fs/ufs/ufs_thread.c Fri Apr 20 05:39:31 2007 -0700 +++ b/usr/src/uts/common/fs/ufs/ufs_thread.c Fri Apr 20 06:09:57 2007 -0700 @@ -19,7 +19,7 @@ * CDDL HEADER END */ /* - * Copyright 2006 Sun Microsystems, Inc. All rights reserved. + * Copyright 2007 Sun Microsystems, Inc. All rights reserved. * Use is subject to license terms. */ @@ -264,11 +264,19 @@ * Ignore if deletes are not allowed (wlock/hlock) */ if (ULOCKFS_IS_NOIDEL(ITOUL(ip))) { + mutex_enter(&delq->uq_mutex); + delq_info->delq_unreclaimed_blocks -= ip->i_blocks; + delq_info->delq_unreclaimed_files--; + mutex_exit(&delq->uq_mutex); VN_RELE(vp); return; } if ((vp->v_count > 1) || (ip->i_mode == 0)) { + mutex_enter(&delq->uq_mutex); + delq_info->delq_unreclaimed_blocks -= ip->i_blocks; + delq_info->delq_unreclaimed_files--; + mutex_exit(&delq->uq_mutex); VN_RELE(vp); return; }