]> git.sesse.net Git - bcachefs-tools-debian/commitdiff
Show the writeback flag and the discard flag.
authorGabriel <g2p.code@gmail.com>
Sun, 10 Mar 2013 10:04:10 +0000 (11:04 +0100)
committerGabriel <g2p.code@gmail.com>
Sun, 10 Mar 2013 10:04:10 +0000 (11:04 +0100)
bcache-super-show.c

index 011027ac0a6664f991ddfc2a2c27481a8cbe0de8..47c8b87c148912ea1e29effba86cce30773815d3 100644 (file)
@@ -131,13 +131,17 @@ int main(int argc, char **argv)
        if (sb.version == 0) {
                printf(
                                "dev.cache.first_bucket\t%u\n"
-                               "dev.cache.first_sector\t%u\n",
+                               "dev.cache.first_sector\t%u\n"
+                               "dev.cache.discard\t%s\n",
                                sb.first_bucket,
-                               sb.bucket_size * sb.first_bucket);
+                               sb.bucket_size * sb.first_bucket,
+                               CACHE_DISCARD(&sb) ? "yes" : "no");
        } else if (sb.version == CACHE_BACKING_DEV) {
                printf(
-                               "dev.data.first_sector\t%u\n",
-                               BDEV_DATA_START);
+                               "dev.data.first_sector\t%u\n"
+                               "dev.data.writeback\t%s\n",
+                               BDEV_DATA_START,
+                               BDEV_WRITEBACK(&sb) ? "yes" : "no");
        }
        putchar('\n');