Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
bcache: fix race of writeback thread starting before complete initial…
…ization The bch_writeback_thread might BUG_ON in read_dirty() if dc->sb==BDEV_STATE_DIRTY and bch_sectors_dirty_init has not yet completed its related initialization. This patch downs the dc->writeback_lock until after initialization is complete, thus preventing bch_writeback_thread from proceeding prematurely. See this thread: http://thread.gmane.org/gmane.linux.kernel.bcache.devel/3453 Signed-off-by: Eric Wheeler <[email protected]> Tested-by: Marc MERLIN <[email protected]> Cc: <[email protected]> Signed-off-by: Jens Axboe <[email protected]>
- Loading branch information