From: Pavel Tikhomirov <ptikhomi...@virtuozzo.com> Replace jbd2_complete_transaction() with ext4_fc_commit() to utilize fast commit functionality when available, improving performance.
Similar to upstream commit: aa75f4d3daae ("ext4: main fast-commit commit path") Part of rework for ext4_sync_files function. Fixes: 26337aacaafa9 ("ext4: add mfsync support") https://virtuozzo.atlassian.net/browse/VSTOR-107255 Signed-off-by: Pavel Tikhomirov <ptikhomi...@virtuozzo.com> Feature: ext4: optimized sync of a set of files - mfsync() --- fs/ext4/fsync.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/fs/ext4/fsync.c b/fs/ext4/fsync.c index cd5105081d43f..b77cab6f12c61 100644 --- a/fs/ext4/fsync.c +++ b/fs/ext4/fsync.c @@ -268,7 +268,7 @@ int ext4_sync_files(struct file **files, unsigned int *flags, unsigned int nr_fi !jbd2_trans_will_send_data_barrier(journal, commit_tid)) need_barrier = true; - err2 = jbd2_complete_transaction(journal, commit_tid); + err2 = ext4_fc_commit(journal, commit_tid); /* Even if we had to wait for commit completion, it does not * mean a flush has been issued after data demanded by this * fsync were written back. Commit could be in state after -- 2.43.0 _______________________________________________ Devel mailing list Devel@openvz.org https://lists.openvz.org/mailman/listinfo/devel