]> git.apps.os.sepia.ceph.com Git - ceph.git/commitdiff
include: add less verbose CompatSet dump
authorPatrick Donnelly <pdonnell@redhat.com>
Mon, 5 Apr 2021 14:55:20 +0000 (07:55 -0700)
committerPatrick Donnelly <pdonnell@redhat.com>
Mon, 16 Aug 2021 21:12:40 +0000 (14:12 -0700)
For printing in `fs dump`.

Signed-off-by: Patrick Donnelly <pdonnell@redhat.com>
(cherry picked from commit 56b36e69fae0fcfb5081ede3934f1d63cde0494a)

src/include/CompatSet.h

index 38ed85b319a1f3f5d1cba057e50f7a92f9033b4b..b63e573d3d535f2a9e7db32f9e9a8653d72395a9 100644 (file)
@@ -222,6 +222,13 @@ struct CompatSet {
     return true;
   }
 
+  std::ostream& printlite(std::ostream& o) const {
+    o << "{c=[" << std::hex << compat.mask << "]";
+    o << ",r=[" << std::hex << ro_compat.mask << "]";
+    o << ",i=[" << std::hex << incompat.mask << "]}";
+    return o;
+  }
+
   void encode(ceph::buffer::list& bl) const {
     compat.encode(bl);
     ro_compat.encode(bl);