X-Git-Url: http://git.onelab.eu/?a=blobdiff_plain;f=fs%2Fjffs%2Fintrep.h;h=5c7abe0e26953555549a3361109d5110da7a106f;hb=43bc926fffd92024b46cafaf7350d669ba9ca884;hp=cbd4ed790490d27d881dd1159406538b3efa5279;hpb=5273a3df6485dc2ad6aa7ddd441b9a21970f003b;p=linux-2.6.git diff --git a/fs/jffs/intrep.h b/fs/jffs/intrep.h index cbd4ed790..5c7abe0e2 100644 --- a/fs/jffs/intrep.h +++ b/fs/jffs/intrep.h @@ -20,9 +20,6 @@ struct jffs_node *jffs_alloc_node(void); void jffs_free_node(struct jffs_node *n); int jffs_get_node_inuse(void); -long jffs_get_file_count(void); - -__u32 jffs_checksum(const void *data, int size); void jffs_cleanup_control(struct jffs_control *c); int jffs_build_fs(struct super_block *sb); @@ -36,15 +33,9 @@ struct jffs_file *jffs_find_child(struct jffs_file *dir, const char *name, int l void jffs_free_node(struct jffs_node *node); int jffs_foreach_file(struct jffs_control *c, int (*func)(struct jffs_file *)); -int jffs_free_node_list(struct jffs_file *f); -int jffs_free_file(struct jffs_file *f); int jffs_possibly_delete_file(struct jffs_file *f); -int jffs_build_file(struct jffs_file *f); -int jffs_insert_file_into_hash(struct jffs_file *f); int jffs_insert_file_into_tree(struct jffs_file *f); -int jffs_unlink_file_from_hash(struct jffs_file *f); int jffs_unlink_file_from_tree(struct jffs_file *f); -int jffs_remove_redundant_nodes(struct jffs_file *f); int jffs_file_count(struct jffs_file *f); int jffs_write_node(struct jffs_control *c, struct jffs_node *node, @@ -56,32 +47,11 @@ int jffs_read_data(struct jffs_file *f, unsigned char *buf, __u32 read_offset, _ /* Garbage collection stuff. */ int jffs_garbage_collect_thread(void *c); void jffs_garbage_collect_trigger(struct jffs_control *c); -int jffs_garbage_collect_now(struct jffs_control *c); - -/* Is there enough space on the flash? */ -static inline int JFFS_ENOUGH_SPACE(struct jffs_control *c, __u32 space) -{ - struct jffs_fmcontrol *fmc = c->fmc; - - while (1) { - if ((fmc->flash_size - (fmc->used_size + fmc->dirty_size)) - >= fmc->min_free_size + space) { - return 1; - } - if (fmc->dirty_size < fmc->sector_size) - return 0; - - if (jffs_garbage_collect_now(c)) { - D1(printk("JFFS_ENOUGH_SPACE: jffs_garbage_collect_now() failed.\n")); - return 0; - } - } -} /* For debugging purposes. */ -void jffs_print_node(struct jffs_node *n); -void jffs_print_raw_inode(struct jffs_raw_inode *raw_inode); +#if 0 int jffs_print_file(struct jffs_file *f); +#endif /* 0 */ void jffs_print_hash_table(struct jffs_control *c); void jffs_print_tree(struct jffs_file *first_file, int indent);