Re: [PATCH 18/42] btrfs: move the dio_sem higher up the callchain

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



On Fri, Oct 12, 2018 at 03:32:32PM -0400, Josef Bacik wrote:
> --- a/fs/btrfs/tree-log.c
> +++ b/fs/btrfs/tree-log.c
> @@ -4374,7 +4374,6 @@ static int btrfs_log_changed_extents(struct btrfs_trans_handle *trans,
>  
>  	INIT_LIST_HEAD(&extents);
>  
> -	down_write(&inode->dio_sem);

I'll add lockdep_assert_held(&inode->dio_sem) so it's documented and
runtime checked.

>  	write_lock(&tree->lock);
>  	test_gen = root->fs_info->last_trans_committed;
>  	logged_start = start;
> @@ -4440,7 +4439,6 @@ static int btrfs_log_changed_extents(struct btrfs_trans_handle *trans,
>  	}
>  	WARN_ON(!list_empty(&extents));
>  	write_unlock(&tree->lock);
> -	up_write(&inode->dio_sem);
>  
>  	btrfs_release_path(path);
>  	if (!ret)
> -- 
> 2.14.3



[Index of Archives]     [Linux Filesystem Development]     [Linux NFS]     [Linux NILFS]     [Linux USB Devel]     [Linux Audio Users]     [Yosemite News]     [Linux Kernel]     [Linux SCSI]

  Powered by Linux