[PATCH 2/5] btrfs: fix deadlock with extent-same and readpage

2015-06-30 Thread Mark Fasheh
-readpage() does page_lock() before extent_lock(), we do the opposite in extent-same. We want to reverse the order in btrfs_extent_same() but it's not quite straightforward since the page locks are taken inside btrfs_cmp_data(). So I split btrfs_cmp_data() into 3 parts with a small context

[PATCH 2/5] btrfs: fix deadlock with extent-same and readpage

2015-06-26 Thread Mark Fasheh
-readpage() does page_lock() before extent_lock(), we do the opposite in extent-same. We want to reverse the order in btrfs_extent_same() but it's not quite straightforward since the page locks are taken inside btrfs_cmp_data(). So I split btrfs_cmp_data() into 3 parts with a small context

Re: [PATCH 2/5] btrfs: fix deadlock with extent-same and readpage

2015-06-24 Thread Liu Bo
On Tue, Jun 23, 2015 at 02:28:37PM -0700, Mark Fasheh wrote: -readpage() does page_lock() before extent_lock(), we do the opposite in extent-same. We want to reverse the order in btrfs_extent_same() but it's not quite straightforward since the page locks are taken inside btrfs_cmp_data().

[PATCH 2/5] btrfs: fix deadlock with extent-same and readpage

2015-06-23 Thread Mark Fasheh
-readpage() does page_lock() before extent_lock(), we do the opposite in extent-same. We want to reverse the order in btrfs_extent_same() but it's not quite straightforward since the page locks are taken inside btrfs_cmp_data(). So I split btrfs_cmp_data() into 3 parts with a small context

[PATCH 2/5] btrfs: fix deadlock with extent-same and readpage

2015-06-22 Thread Mark Fasheh
-readpage() does page_lock() before extent_lock(), we do the opposite in extent-same. We want to reverse the order in btrfs_extent_same() but it's not quite straightforward since the page locks are taken inside btrfs_cmp_data(). So I split btrfs_cmp_data() into 3 parts with a small context