Btrfs: 32bit cleanups
authorChris Mason <chris.mason@oracle.com>
Mon, 26 Feb 2007 15:55:42 +0000 (10:55 -0500)
committerDavid Woodhouse <dwmw2@hera.kernel.org>
Mon, 26 Feb 2007 15:55:42 +0000 (10:55 -0500)
Signed-off-by: Chris Mason <chris.mason@oracle.com>
fs/btrfs/print-tree.c
fs/btrfs/random-test.c

index 1d591270f4c4bfcdbf7ad9b5b2408e834c5029ca..a9a14223e1869f5f8065ae03cd64f2f8d6521fd6 100644 (file)
@@ -43,7 +43,7 @@ void print_tree(struct ctree_root *root, struct tree_buffer *t)
                print_leaf((struct leaf *)c);
                return;
        }
-       printf("node %Lu level %d total ptrs %d free spc %lu\n", t->blocknr,
+       printf("node %Lu level %d total ptrs %d free spc %u\n", t->blocknr,
                node_level(c->header.flags), c->header.nritems,
                NODEPTRS_PER_BLOCK - c->header.nritems);
        fflush(stdout);
index 111a248bd5c29c9b0ea481e2a147d9fb1b44d25b..7078263acc3dfc6a83eed6ee4620e975aa958455 100644 (file)
@@ -40,15 +40,16 @@ static int ins_one(struct ctree_root *root, struct radix_tree_root *radix)
        struct key key;
        int ret;
        char buf[128];
+       unsigned long oid;
        init_path(&path);
        ret = setup_key(radix, &key, 0);
        sprintf(buf, "str-%Lu\n", key.objectid);
        ret = insert_item(root, &key, buf, strlen(buf));
        if (ret)
                goto error;
+       oid = (unsigned long)key.objectid;
        radix_tree_preload(GFP_KERNEL);
-       ret = radix_tree_insert(radix, key.objectid,
-                                       (void *)key.objectid);
+       ret = radix_tree_insert(radix, oid, (void *)oid);
        radix_tree_preload_end();
        if (ret)
                goto error;