]> git.proxmox.com Git - mirror_ubuntu-hirsute-kernel.git/commitdiff
Btrfs: reorder key offset and flags
authorChris Mason <chris.mason@oracle.com>
Wed, 14 Mar 2007 18:26:53 +0000 (14:26 -0400)
committerDavid Woodhouse <dwmw2@hera.kernel.org>
Wed, 14 Mar 2007 18:26:53 +0000 (14:26 -0400)
Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/TODO
fs/btrfs/ctree.h
fs/btrfs/print-tree.c

index ff90e5eaf431487035ddada3bc271702c58f4500..8142be88d71c7ae58023a138e6e5bf46de02f757 100644 (file)
@@ -1,7 +1,6 @@
 * cleanup, add more error checking, get rid of BUG_ONs
 * Make IO functions look more like the page cache
 * Fix ENOSPC handling
-* make blocksize a mkfs parameter instead of #define
 * make a real mkfs and superblock
 * Do checksumming
 * Define FS objects in terms of different item types
index c61ad0f69be9ce22d5ffdab521508de32fd10ac8..73ebc824924a9ecc8d2994d4082910dd4fec1b54 100644 (file)
  */
 struct btrfs_disk_key {
        __le64 objectid;
-       __le32 flags;
        __le64 offset;
+       __le32 flags;
 } __attribute__ ((__packed__));
 
 struct btrfs_key {
        u64 objectid;
-       u32 flags;
        u64 offset;
+       u32 flags;
 } __attribute__ ((__packed__));
 
 /*
index 7a189eaa589fb530e8d428949b3c77c9ad3d0e3c..4c710190343d3d0219600915a449d49d40d96282 100644 (file)
@@ -18,11 +18,11 @@ void btrfs_print_leaf(struct btrfs_root *root, struct btrfs_leaf *l)
        fflush(stdout);
        for (i = 0 ; i < nr ; i++) {
                item = l->items + i;
-               printf("\titem %d key (%Lu %u %Lu) itemoff %d itemsize %d\n",
+               printf("\titem %d key (%Lu %Lu %u) itemoff %d itemsize %d\n",
                        i,
                        btrfs_key_objectid(&item->key),
-                       btrfs_key_flags(&item->key),
                        btrfs_key_offset(&item->key),
+                       btrfs_key_flags(&item->key),
                        btrfs_item_offset(item),
                        btrfs_item_size(item));
                printf("\t\titem data %.*s\n", btrfs_item_size(item),
@@ -55,10 +55,12 @@ void btrfs_print_tree(struct btrfs_root *root, struct btrfs_buffer *t)
                (u32)BTRFS_NODEPTRS_PER_BLOCK(root) - nr);
        fflush(stdout);
        for (i = 0; i < nr; i++) {
-               printf("\tkey %d (%Lu %u %Lu) block %Lu\n",
+               printf("\tkey %d (%Lu %Lu %u) block %Lu\n",
                       i,
-                      c->ptrs[i].key.objectid, c->ptrs[i].key.flags,
-                      c->ptrs[i].key.offset, btrfs_node_blockptr(c, i));
+                      c->ptrs[i].key.objectid,
+                      c->ptrs[i].key.offset,
+                      c->ptrs[i].key.flags,
+                      btrfs_node_blockptr(c, i));
                fflush(stdout);
        }
        for (i = 0; i < nr; i++) {