aboutsummaryrefslogtreecommitdiffstats
path: root/fs/gfs2/main.c
diff options
context:
space:
mode:
authorBob Peterson <rpeterso@redhat.com>2020-06-17 07:47:34 -0500
committerAndreas Gruenbacher <agruenba@redhat.com>2020-07-03 12:05:34 +0200
commit7542486b89b2e321ffe0de82163b425d6a38bc72 (patch)
tree69dad92b550226ee3e77caf2b141542f8686ef8a /fs/gfs2/main.c
parent34244d711dea568f4a42c5b0d6b3d620f8cb6971 (diff)
downloadlinux-7542486b89b2e321ffe0de82163b425d6a38bc72.tar.gz
gfs2: eliminate GIF_ORDERED in favor of list_empty
In several places, we used the GIF_ORDERED inode flag to determine if an inode was on the ordered writes list. However, since we always held the sd_ordered_lock spin_lock during the manipulation, we can just as easily check list_empty(&ip->i_ordered) instead. This allows us to keep more than one ordered writes list to make journal writing improvements. This patch eliminates GIF_ORDERED in favor of checking list_empty. Signed-off-by: Bob Peterson <rpeterso@redhat.com>
Diffstat (limited to 'fs/gfs2/main.c')
-rw-r--r--fs/gfs2/main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/fs/gfs2/main.c b/fs/gfs2/main.c
index 733470ca6be9d..c7393ee9cf683 100644
--- a/fs/gfs2/main.c
+++ b/fs/gfs2/main.c
@@ -39,6 +39,7 @@ static void gfs2_init_inode_once(void *foo)
atomic_set(&ip->i_sizehint, 0);
init_rwsem(&ip->i_rw_mutex);
INIT_LIST_HEAD(&ip->i_trunc_list);
+ INIT_LIST_HEAD(&ip->i_ordered);
ip->i_qadata = NULL;
gfs2_holder_mark_uninitialized(&ip->i_rgd_gh);
memset(&ip->i_res, 0, sizeof(ip->i_res));