X-Git-Url: http://dolda2000.com/gitweb/?p=vcfs.git;a=blobdiff_plain;f=blocktree.h;fp=blocktree.h;h=fd2ea99107a152c7c471acfd3b9422f402357e31;hp=c962874398bc6c668bce5f713addfec7fd29ef77;hb=34b0b3532283082d4a90afa728a1fc84b20a3f6f;hpb=efe8eeebe84e835d36717a0ea3085d9c8084aafb diff --git a/blocktree.h b/blocktree.h index c962874..fd2ea99 100644 --- a/blocktree.h +++ b/blocktree.h @@ -4,10 +4,6 @@ #include "store.h" #include "inttypes.h" -#define BT_INDBITS 10 -#define BT_INDSZ (1 << BT_INDBITS) -#define BT_INDBSZ (sizeof(struct btnode) * BT_INDSZ) - typedef loff_t block_t; struct btnode { @@ -23,10 +19,10 @@ struct btop { void *pdata; }; -ssize_t btget(struct store *st, struct btnode *tree, block_t bl, void *buf, size_t len); -int btputmany(struct store *st, struct btnode *tree, struct btop *ops, int numops); -int btput(struct store *st, struct btnode *tree, block_t bl, void *buf, size_t len); -block_t btcount(struct store *st, struct btnode *tree); +ssize_t btget(struct store *st, struct btnode *tree, block_t bl, void *buf, size_t len, size_t blsize); +int btputmany(struct store *st, struct btnode *tree, struct btop *ops, int numops, size_t blsize); +int btput(struct store *st, struct btnode *tree, block_t bl, void *buf, size_t len, size_t blsize); +block_t btcount(struct store *st, struct btnode *tree, size_t blsize); void btsortops(struct btop *ops, int numops); void btmkop(struct btop *op, block_t bl, void *buf, size_t len);