summaryrefslogtreecommitdiff
path: root/make-bcache.c
diff options
context:
space:
mode:
authorGabriel <g2p.code@gmail.com>2013-05-01 19:15:18 +0200
committerGabriel <g2p.code@gmail.com>2013-05-08 09:40:46 +0200
commit315ab92e58e3984351df8650527986b2b950e189 (patch)
tree0d196745be071547392d4867377a3a22cfcd75a2 /make-bcache.c
parentaf6e3f1c7421e8517e0b9e1a99a88c9e2b34236d (diff)
super-show: print cache mode (writethrough, writeback, writearound, none)
Diffstat (limited to 'make-bcache.c')
-rw-r--r--make-bcache.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/make-bcache.c b/make-bcache.c
index 0a47c0c..2a5124b 100644
--- a/make-bcache.c
+++ b/make-bcache.c
@@ -192,7 +192,8 @@ static void write_sb(char *dev, unsigned block_size, unsigned bucket_size,
uuid_unparse(sb.set_uuid, set_uuid_str);
if (SB_IS_BDEV(&sb)) {
- SET_BDEV_WRITEBACK(&sb, writeback);
+ SET_BDEV_CACHE_MODE(
+ &sb, writeback ? CACHE_MODE_WRITEBACK : CACHE_MODE_WRITETHROUGH);
if (data_offset != BDEV_DATA_START_DEFAULT) {
sb.version = BCACHE_SB_VERSION_BDEV_WITH_OFFSET;