summaryrefslogtreecommitdiff
path: root/units/local-fs-pre.target
diff options
context:
space:
mode:
authorVito Caputo <vito.caputo@coreos.com>2016-02-12 04:59:57 -0800
committerVito Caputo <vito.caputo@coreos.com>2016-02-19 18:50:20 -0800
commitac2e41f5103ce2c679089c4f8fb6be61d7caec07 (patch)
treeaa9015d7a0e9466e783704d857dd5db0fec70512 /units/local-fs-pre.target
parent69a3a6fd3d96101d42a01d0e7d33ae2ef613e54a (diff)
journal: asynchronous journal_file_set_offline()
This adds a wait flag to journal_file_set_offline(), when false the offline is performed asynchronously in a separate thread. When wait is true, if an asynchronous offline is already in-progress it is restarted and waited for. Otherwise the offline is performed synchronously without the use of a thread. journal_file_set_online() cancels or waits for the asynchronous offline to complete if in-flight, depending on where in the offline process the thread happens to be. If the thread is in the fsync() phase, it is cancelled and waiting is unnecessary. Otherwise, the thread is joined before proceeding. A new offline_state member is added to JournalFile which is used via atomic operations for communicating between the offline thread and the journal_file_set_{offline,online}() functions.
Diffstat (limited to 'units/local-fs-pre.target')
0 files changed, 0 insertions, 0 deletions