dm thin: allow pool in read-only mode to transition to read-write mode
A thin-pool may be in read-only mode because the pool's data or metadata space was exhausted. To allow for recovery, by adding more space to the pool, we must allow a pool to transition from PM_READ_ONLY to PM_WRITE mode. Otherwise, running out of space will render the pool permanently read-only. Signed-off-by: Joe Thornber <ejt@redhat.com> Signed-off-by: Mike Snitzer <snitzer@redhat.com> Cc: stable@vger.kernel.org
This commit is contained in:

committed by
Mike Snitzer

parent
5383ef3a92
commit
9b7aaa64f9
@@ -108,9 +108,9 @@ int dm_bm_unlock(struct dm_block *b);
|
||||
int dm_bm_flush_and_unlock(struct dm_block_manager *bm,
|
||||
struct dm_block *superblock);
|
||||
|
||||
/*
|
||||
* Request data be prefetched into the cache.
|
||||
*/
|
||||
/*
|
||||
* Request data is prefetched into the cache.
|
||||
*/
|
||||
void dm_bm_prefetch(struct dm_block_manager *bm, dm_block_t b);
|
||||
|
||||
/*
|
||||
@@ -125,6 +125,7 @@ void dm_bm_prefetch(struct dm_block_manager *bm, dm_block_t b);
|
||||
* be returned if you do.
|
||||
*/
|
||||
void dm_bm_set_read_only(struct dm_block_manager *bm);
|
||||
void dm_bm_set_read_write(struct dm_block_manager *bm);
|
||||
|
||||
u32 dm_bm_checksum(const void *data, size_t len, u32 init_xor);
|
||||
|
||||
|
Reference in New Issue
Block a user