diff options
author | Jan Kara <jack@suse.cz> | 2017-03-23 01:36:57 +0100 |
---|---|---|
committer | Jens Axboe <axboe@fb.com> | 2017-03-22 20:11:28 -0600 |
commit | 5318ce7d46866e1dbc20ab9349b93753edba0b3e (patch) | |
tree | 6a4070a385e86006c64868a2f9bd363ab002cfc8 /include/linux/backing-dev-defs.h | |
parent | e8cb72b322cf4a729633b7e2080fbeab477f6ea2 (diff) | |
download | lwn-5318ce7d46866e1dbc20ab9349b93753edba0b3e.tar.gz lwn-5318ce7d46866e1dbc20ab9349b93753edba0b3e.zip |
bdi: Shutdown writeback on all cgwbs in cgwb_bdi_destroy()
Currently we waited for all cgwbs to get freed in cgwb_bdi_destroy()
which also means that writeback has been shutdown on them. Since this
wait is going away, directly shutdown writeback on cgwbs from
cgwb_bdi_destroy() to avoid live writeback structures after
bdi_unregister() has finished. To make that safe with concurrent
shutdown from cgwb_release_workfn(), we also have to make sure
wb_shutdown() returns only after the bdi_writeback structure is really
shutdown.
Acked-by: Tejun Heo <tj@kernel.org>
Signed-off-by: Jan Kara <jack@suse.cz>
Signed-off-by: Jens Axboe <axboe@fb.com>
Diffstat (limited to 'include/linux/backing-dev-defs.h')
-rw-r--r-- | include/linux/backing-dev-defs.h | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/include/linux/backing-dev-defs.h b/include/linux/backing-dev-defs.h index 8fb3dcdebc80..8af720f22a2d 100644 --- a/include/linux/backing-dev-defs.h +++ b/include/linux/backing-dev-defs.h @@ -21,6 +21,7 @@ struct dentry; */ enum wb_state { WB_registered, /* bdi_register() was done */ + WB_shutting_down, /* wb_shutdown() in progress */ WB_writeback_running, /* Writeback is in progress */ WB_has_dirty_io, /* Dirty inodes on ->b_{dirty|io|more_io} */ }; |