Due to the GLF_LFLUSH flag being reset for each block which exits the
journal, it was possible for the journal flush to be skipped in case
two flushes (one of which must be an inode specific flush) raced with
each other. The simple solution is just to remove the optimisation
allowing skipping of the lflush rwsem in certain cases.
We'll review this later and possibly reintroduce the optimisation but
for now correctness is the more important feature.
Signed-off-by: Steven Whitehouse <swhiteho@redhat.com>
-unsigned int gfs2_struct2blk(struct gfs2_sbd *sdp, unsigned int nstruct,
- unsigned int ssize);
+extern unsigned int gfs2_struct2blk(struct gfs2_sbd *sdp, unsigned int nstruct,
+ unsigned int ssize);
-int gfs2_log_reserve(struct gfs2_sbd *sdp, unsigned int blks);
-void gfs2_log_incr_head(struct gfs2_sbd *sdp);
+extern int gfs2_log_reserve(struct gfs2_sbd *sdp, unsigned int blks);
+extern void gfs2_log_incr_head(struct gfs2_sbd *sdp);