lkml.org 
[lkml]   [2021]   [Oct]   [20]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: [PATCH stable-4.14.y] btrfs: always wait on ordered extents at fsync time
On Tue, Oct 19, 2021 at 06:38:20PM +0800, Anand Jain wrote:
> From: Josef Bacik <jbacik@fb.com>
>
> Commit b5e6c3e170b77025b5f6174258c7ad71eed2d4de upstream.
>
> There's a priority inversion that exists currently with btrfs fsync. In
> some cases we will collect outstanding ordered extents onto a list and
> only wait on them at the very last second. However this "very last
> second" falls inside of a transaction handle, so if we are in a lower
> priority cgroup we can end up holding the transaction open for longer
> than needed, so if a high priority cgroup is also trying to fsync()
> it'll see latency.
>
> Signed-off-by: Josef Bacik <jbacik@fb.com>
> Reviewed-by: Filipe Manana <fdmanana@suse.com>
> Signed-off-by: David Sterba <dsterba@suse.com>
> Signed-off-by: Anand Jain <anand.jain@oracle.com>
> ---
> fs/btrfs/file.c | 56 ++++---------------------------------------------
> 1 file changed, 4 insertions(+), 52 deletions(-)

Now applied, thanks.

greg k-h

\
 
 \ /
  Last update: 2021-10-20 14:33    [W:5.843 / U:2.540 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site