Re: [PATCH v2] Btrfs: set leave_spinning in btrfs_get_extent

2018-08-24 Thread Liu Bo
On Fri, Aug 24, 2018 at 04:59:49PM +0200, David Sterba wrote: > On Thu, Aug 23, 2018 at 07:41:05AM +0800, Liu Bo wrote: > > Unless it's going to read inline extents from btree leaf to page, > > btrfs_get_extent won't sleep during the period of holding path lock. > > > > This sets leave_spinning at

Re: [PATCH v2] Btrfs: set leave_spinning in btrfs_get_extent

2018-08-24 Thread David Sterba
On Thu, Aug 23, 2018 at 07:41:05AM +0800, Liu Bo wrote: > Unless it's going to read inline extents from btree leaf to page, > btrfs_get_extent won't sleep during the period of holding path lock. > > This sets leave_spinning at first and sets path to blocking mode right > before reading inline exte

[PATCH v2] Btrfs: set leave_spinning in btrfs_get_extent

2018-08-22 Thread Liu Bo
Unless it's going to read inline extents from btree leaf to page, btrfs_get_extent won't sleep during the period of holding path lock. This sets leave_spinning at first and sets path to blocking mode right before reading inline extent if that's the case. The benefit is that a path in spinning mod