]> git.baikalelectronics.ru Git - kernel.git/commit
GFS2: Wake up io waiters whenever a flush is done
authorBob Peterson <rpeterso@redhat.com>
Sat, 7 Jan 2017 03:14:28 +0000 (22:14 -0500)
committerBob Peterson <rpeterso@redhat.com>
Sat, 7 Jan 2017 03:14:28 +0000 (22:14 -0500)
commitd62707a853f11f259b1043c364d93763b5e4a0ed
tree1175b1dc2e02d148dbee7e1c941b15aadffb2982
parent8847f89ba1b884f2ede0beaff4ec98efd760356e
GFS2: Wake up io waiters whenever a flush is done

Before this patch, if a process called function gfs2_log_reserve to
reserve some journal blocks, but the journal not enough blocks were
free, it would call io_schedule. However, in the log flush daemon,
it woke up the waiters only if an gfs2_ail_flush was no longer
required. This resulted in situations where processes would wait
forever because the number of blocks required was so high that it
pushed the journal into a perpetual state of flush being required.

This patch changes the logd daemon so that it wakes up io waiters
every time the log is actually flushed.

Signed-off-by: Bob Peterson <rpeterso@redhat.com>
fs/gfs2/log.c